@matter-server/dashboard 1.3.3 → 1.4.0-alpha.0-20260802-ac0d816

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.
Files changed (183) hide show
  1. package/dist/esm/client/models/descriptions.d.ts.map +1 -1
  2. package/dist/esm/client/models/descriptions.js +67 -62
  3. package/dist/esm/client/models/descriptions.js.map +1 -1
  4. package/dist/esm/components/avsum-ptz-strip.d.ts.map +1 -1
  5. package/dist/esm/components/avsum-ptz-strip.js +75 -75
  6. package/dist/esm/components/avsum-ptz-strip.js.map +1 -1
  7. package/dist/esm/components/dialog-box/dialog-box.d.ts.map +1 -1
  8. package/dist/esm/components/dialog-box/dialog-box.js +6 -4
  9. package/dist/esm/components/dialog-box/dialog-box.js.map +1 -1
  10. package/dist/esm/components/dialogs/acl/acl-actions.d.ts.map +1 -1
  11. package/dist/esm/components/dialogs/acl/acl-actions.js +11 -4
  12. package/dist/esm/components/dialogs/acl/acl-actions.js.map +1 -1
  13. package/dist/esm/components/dialogs/acl/node-acl-add-dialog.d.ts.map +1 -1
  14. package/dist/esm/components/dialogs/acl/node-acl-add-dialog.js +15 -15
  15. package/dist/esm/components/dialogs/acl/node-acl-add-dialog.js.map +1 -1
  16. package/dist/esm/components/dialogs/binding/binding-actions.d.ts +8 -3
  17. package/dist/esm/components/dialogs/binding/binding-actions.d.ts.map +1 -1
  18. package/dist/esm/components/dialogs/binding/binding-actions.js +45 -11
  19. package/dist/esm/components/dialogs/binding/binding-actions.js.map +1 -1
  20. package/dist/esm/components/dialogs/binding/node-binding-dialog.d.ts.map +1 -1
  21. package/dist/esm/components/dialogs/binding/node-binding-dialog.js +37 -37
  22. package/dist/esm/components/dialogs/binding/node-binding-dialog.js.map +1 -1
  23. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-dialog.d.ts.map +1 -1
  24. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-dialog.js +16 -16
  25. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-dialog.js.map +1 -1
  26. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-thread.d.ts.map +1 -1
  27. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-thread.js +13 -13
  28. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-thread.js.map +1 -1
  29. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-wifi.d.ts.map +1 -1
  30. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-wifi.js +13 -13
  31. package/dist/esm/components/dialogs/commission-node-dialog/commission-node-wifi.js.map +1 -1
  32. package/dist/esm/components/dialogs/dev/attribute-write-dialog.d.ts.map +1 -1
  33. package/dist/esm/components/dialogs/dev/attribute-write-dialog.js +5 -1
  34. package/dist/esm/components/dialogs/dev/attribute-write-dialog.js.map +1 -1
  35. package/dist/esm/components/dialogs/dev/command-invoke-dialog.d.ts.map +1 -1
  36. package/dist/esm/components/dialogs/dev/command-invoke-dialog.js +3 -3
  37. package/dist/esm/components/dialogs/dev/command-invoke-dialog.js.map +1 -1
  38. package/dist/esm/components/dialogs/settings/log-level-section.d.ts.map +1 -1
  39. package/dist/esm/components/dialogs/settings/log-level-section.js +14 -14
  40. package/dist/esm/components/dialogs/settings/log-level-section.js.map +1 -1
  41. package/dist/esm/components/dialogs/settings/settings-dialog.d.ts.map +1 -1
  42. package/dist/esm/components/dialogs/settings/settings-dialog.js +83 -81
  43. package/dist/esm/components/dialogs/settings/settings-dialog.js.map +1 -1
  44. package/dist/esm/components/webrtc-stream-view.d.ts.map +1 -1
  45. package/dist/esm/components/webrtc-stream-view.js +11 -11
  46. package/dist/esm/components/webrtc-stream-view.js.map +1 -1
  47. package/dist/esm/pages/camera-overlay.d.ts.map +1 -1
  48. package/dist/esm/pages/camera-overlay.js +90 -87
  49. package/dist/esm/pages/camera-overlay.js.map +1 -1
  50. package/dist/esm/pages/cluster-commands/clusters/access-control-commands.d.ts.map +1 -1
  51. package/dist/esm/pages/cluster-commands/clusters/access-control-commands.js +32 -28
  52. package/dist/esm/pages/cluster-commands/clusters/access-control-commands.js.map +1 -1
  53. package/dist/esm/pages/cluster-commands/clusters/avsum-commands.d.ts.map +1 -1
  54. package/dist/esm/pages/cluster-commands/clusters/avsum-commands.js +130 -129
  55. package/dist/esm/pages/cluster-commands/clusters/avsum-commands.js.map +1 -1
  56. package/dist/esm/pages/cluster-commands/clusters/basic-information-commands.d.ts.map +1 -1
  57. package/dist/esm/pages/cluster-commands/clusters/basic-information-commands.js.map +1 -1
  58. package/dist/esm/pages/cluster-commands/clusters/binding-commands.d.ts.map +1 -1
  59. package/dist/esm/pages/cluster-commands/clusters/binding-commands.js +32 -30
  60. package/dist/esm/pages/cluster-commands/clusters/binding-commands.js.map +1 -1
  61. package/dist/esm/pages/cluster-commands/clusters/chime-commands.d.ts +5 -0
  62. package/dist/esm/pages/cluster-commands/clusters/chime-commands.d.ts.map +1 -1
  63. package/dist/esm/pages/cluster-commands/clusters/chime-commands.js +45 -24
  64. package/dist/esm/pages/cluster-commands/clusters/chime-commands.js.map +1 -1
  65. package/dist/esm/pages/cluster-commands/clusters/closure-control-commands.d.ts.map +1 -1
  66. package/dist/esm/pages/cluster-commands/clusters/closure-control-commands.js +79 -79
  67. package/dist/esm/pages/cluster-commands/clusters/closure-control-commands.js.map +1 -1
  68. package/dist/esm/pages/cluster-commands/clusters/icd-management-commands.d.ts.map +1 -1
  69. package/dist/esm/pages/cluster-commands/clusters/icd-management-commands.js +27 -20
  70. package/dist/esm/pages/cluster-commands/clusters/icd-management-commands.js.map +1 -1
  71. package/dist/esm/pages/components/header.d.ts.map +1 -1
  72. package/dist/esm/pages/components/header.js +32 -32
  73. package/dist/esm/pages/components/header.js.map +1 -1
  74. package/dist/esm/pages/components/node-details.d.ts.map +1 -1
  75. package/dist/esm/pages/components/node-details.js +43 -42
  76. package/dist/esm/pages/components/node-details.js.map +1 -1
  77. package/dist/esm/pages/matter-cluster-view.d.ts +3 -0
  78. package/dist/esm/pages/matter-cluster-view.d.ts.map +1 -1
  79. package/dist/esm/pages/matter-cluster-view.js +105 -90
  80. package/dist/esm/pages/matter-cluster-view.js.map +1 -1
  81. package/dist/esm/pages/matter-endpoint-view.d.ts +3 -2
  82. package/dist/esm/pages/matter-endpoint-view.d.ts.map +1 -1
  83. package/dist/esm/pages/matter-endpoint-view.js +65 -20
  84. package/dist/esm/pages/matter-endpoint-view.js.map +1 -1
  85. package/dist/esm/pages/matter-network-view.d.ts.map +1 -1
  86. package/dist/esm/pages/matter-network-view.js +20 -20
  87. package/dist/esm/pages/matter-network-view.js.map +1 -1
  88. package/dist/esm/pages/matter-node-view.d.ts.map +1 -1
  89. package/dist/esm/pages/matter-node-view.js +9 -5
  90. package/dist/esm/pages/matter-node-view.js.map +1 -1
  91. package/dist/esm/pages/matter-server-view.d.ts.map +1 -1
  92. package/dist/esm/pages/matter-server-view.js +6 -6
  93. package/dist/esm/pages/matter-server-view.js.map +1 -1
  94. package/dist/esm/pages/network/device-panel.d.ts.map +1 -1
  95. package/dist/esm/pages/network/device-panel.js +10 -10
  96. package/dist/esm/pages/network/device-panel.js.map +1 -1
  97. package/dist/esm/pages/network/network-details.d.ts.map +1 -1
  98. package/dist/esm/pages/network/network-details.js +384 -382
  99. package/dist/esm/pages/network/network-details.js.map +1 -1
  100. package/dist/esm/pages/network/thread-graph.d.ts.map +1 -1
  101. package/dist/esm/pages/network/thread-graph.js.map +1 -1
  102. package/dist/esm/pages/network/update-connections-dialog.d.ts.map +1 -1
  103. package/dist/esm/pages/network/update-connections-dialog.js +30 -30
  104. package/dist/esm/pages/network/update-connections-dialog.js.map +1 -1
  105. package/dist/esm/util/binding.d.ts +18 -0
  106. package/dist/esm/util/binding.d.ts.map +1 -1
  107. package/dist/esm/util/binding.js +28 -6
  108. package/dist/esm/util/binding.js.map +1 -1
  109. package/dist/esm/util/chime.d.ts.map +1 -1
  110. package/dist/esm/util/chime.js +9 -2
  111. package/dist/esm/util/chime.js.map +1 -1
  112. package/dist/esm/util/icd.d.ts +6 -2
  113. package/dist/esm/util/icd.d.ts.map +1 -1
  114. package/dist/esm/util/icd.js +6 -6
  115. package/dist/esm/util/icd.js.map +1 -1
  116. package/dist/esm/util/matter-status.d.ts +11 -0
  117. package/dist/esm/util/matter-status.d.ts.map +1 -1
  118. package/dist/esm/util/matter-status.js +16 -0
  119. package/dist/esm/util/matter-status.js.map +1 -1
  120. package/dist/esm/util/node-label.d.ts +1 -1
  121. package/dist/esm/util/node-label.d.ts.map +1 -1
  122. package/dist/esm/util/node-label.js +6 -2
  123. package/dist/esm/util/node-label.js.map +1 -1
  124. package/dist/esm/util/shared-styles.d.ts +2 -0
  125. package/dist/esm/util/shared-styles.d.ts.map +1 -1
  126. package/dist/esm/util/shared-styles.js +38 -0
  127. package/dist/esm/util/shared-styles.js.map +1 -1
  128. package/dist/web/index.html +1 -0
  129. package/dist/web/js/{attribute-write-dialog-Dfm95ZtQ.js → attribute-write-dialog-lNuCZ3k9.js} +2 -2
  130. package/dist/web/js/{command-invoke-dialog-DrORSE5f.js → command-invoke-dialog-BsvOYKuy.js} +4 -4
  131. package/dist/web/js/{commission-node-dialog-Wjb4chGv.js → commission-node-dialog-BHdEFbdo.js} +21 -21
  132. package/dist/web/js/{commission-node-existing-Ykm-eejQ.js → commission-node-existing-DHnKVo6U.js} +1 -1
  133. package/dist/web/js/{commission-node-thread-DacHGwnB.js → commission-node-thread-Cj3toV8W.js} +14 -14
  134. package/dist/web/js/{commission-node-wifi-CEKp93HM.js → commission-node-wifi-BdAS2Vof.js} +14 -14
  135. package/dist/web/js/{dialog-box-DEKE_ZlH.js → dialog-box-DQV4kYxU.js} +7 -5
  136. package/dist/web/js/{fabric-label-dialog-CcMZOA7F.js → fabric-label-dialog-Be5bxfzQ.js} +1 -1
  137. package/dist/web/js/main.js +1 -1
  138. package/dist/web/js/{matter-dashboard-app-CEG7MSLx.js → matter-dashboard-app-B186DbKC.js} +1494 -1209
  139. package/dist/web/js/{node-acl-add-dialog-BDM3Rcou.js → node-acl-add-dialog-D4ZLnora.js} +16 -16
  140. package/dist/web/js/{node-binding-dialog-CYsbUPsh.js → node-binding-dialog-MGTLF9MJ.js} +38 -38
  141. package/dist/web/js/{node-label-dialog-DFIMPMuJ.js → node-label-dialog-DgbTIGwf.js} +1 -1
  142. package/dist/web/js/{settings-dialog-CGXliJcr.js → settings-dialog-BQJbHl4j.js} +98 -96
  143. package/package.json +3 -3
  144. package/src/client/models/descriptions.ts +67 -62
  145. package/src/components/avsum-ptz-strip.ts +109 -100
  146. package/src/components/dialog-box/dialog-box.ts +20 -12
  147. package/src/components/dialogs/acl/acl-actions.ts +15 -6
  148. package/src/components/dialogs/acl/node-acl-add-dialog.ts +35 -29
  149. package/src/components/dialogs/binding/binding-actions.ts +58 -15
  150. package/src/components/dialogs/binding/node-binding-dialog.ts +78 -66
  151. package/src/components/dialogs/commission-node-dialog/commission-node-dialog.ts +25 -23
  152. package/src/components/dialogs/commission-node-dialog/commission-node-thread.ts +22 -20
  153. package/src/components/dialogs/commission-node-dialog/commission-node-wifi.ts +22 -20
  154. package/src/components/dialogs/dev/attribute-write-dialog.ts +10 -4
  155. package/src/components/dialogs/dev/command-invoke-dialog.ts +13 -9
  156. package/src/components/dialogs/settings/log-level-section.ts +21 -19
  157. package/src/components/dialogs/settings/settings-dialog.ts +141 -115
  158. package/src/components/webrtc-stream-view.ts +30 -22
  159. package/src/pages/camera-overlay.ts +165 -132
  160. package/src/pages/cluster-commands/clusters/access-control-commands.ts +47 -37
  161. package/src/pages/cluster-commands/clusters/avsum-commands.ts +210 -187
  162. package/src/pages/cluster-commands/clusters/basic-information-commands.ts +5 -3
  163. package/src/pages/cluster-commands/clusters/binding-commands.ts +40 -36
  164. package/src/pages/cluster-commands/clusters/chime-commands.ts +84 -52
  165. package/src/pages/cluster-commands/clusters/closure-control-commands.ts +171 -139
  166. package/src/pages/cluster-commands/clusters/icd-management-commands.ts +51 -34
  167. package/src/pages/components/header.ts +62 -50
  168. package/src/pages/components/node-details.ts +87 -72
  169. package/src/pages/matter-cluster-view.ts +154 -121
  170. package/src/pages/matter-endpoint-view.ts +76 -25
  171. package/src/pages/matter-network-view.ts +36 -30
  172. package/src/pages/matter-node-view.ts +14 -8
  173. package/src/pages/matter-server-view.ts +11 -9
  174. package/src/pages/network/device-panel.ts +20 -18
  175. package/src/pages/network/network-details.ts +758 -618
  176. package/src/pages/network/thread-graph.ts +5 -3
  177. package/src/pages/network/update-connections-dialog.ts +64 -52
  178. package/src/util/binding.ts +42 -6
  179. package/src/util/chime.ts +9 -2
  180. package/src/util/icd.ts +12 -8
  181. package/src/util/matter-status.ts +26 -0
  182. package/src/util/node-label.ts +6 -2
  183. package/src/util/shared-styles.ts +39 -0
@@ -12,7 +12,7 @@ import "@material/web/iconbutton/outlined-icon-button";
12
12
  import "@material/web/list/list";
13
13
  import "@material/web/list/list-item";
14
14
  import { isTestNodeId, MatterClient, MatterNode, toBigIntAwareJson } from "@matter-server/ws-client";
15
- import { mdiAlertCircleOutline, mdiPencil, mdiPlay, mdiRefresh } from "@mdi/js";
15
+ import { mdiAlertCircleOutline, mdiFilterOffOutline, mdiPencil, mdiPlay, mdiRefresh } from "@mdi/js";
16
16
  import { css, html, LitElement, nothing, type TemplateResult } from "lit";
17
17
  import { customElement, property, state } from "lit/decorators.js";
18
18
  import { unsafeHTML } from "lit/directives/unsafe-html.js";
@@ -33,7 +33,7 @@ import {
33
33
  DESCRIPTOR_CLUSTER_ID,
34
34
  TAG_LIST_ATTR,
35
35
  } from "../util/semantic-tags.js";
36
- import { notFoundStyles } from "../util/shared-styles.js";
36
+ import { infoPanelStyles, notFoundStyles } from "../util/shared-styles.js";
37
37
  import { BaseClusterCommands, getClusterCommandsTag } from "./cluster-commands/index.js";
38
38
  import { bindingContext } from "./components/context.js";
39
39
 
@@ -105,6 +105,8 @@ class MatterClusterView extends LitElement {
105
105
 
106
106
  // Per-attribute refresh state, keyed by attribute id (within the current ep/cluster)
107
107
  @state() private _refreshState: Record<number, RefreshState> = {};
108
+ @state() private _unfilteredBusy: Record<number, boolean> = {};
109
+ private _viewKey = "";
108
110
 
109
111
  private _unsubscribeDev?: () => void;
110
112
 
@@ -177,26 +179,32 @@ class MatterClusterView extends LitElement {
177
179
  (attribute, index) => html`
178
180
  <md-list-item class=${index % 2 === 1 ? "alternate-row" : ""}>
179
181
  <div slot="headline">
180
- ${clusters[this.cluster!]?.attributes[attribute.key]?.label ??
181
- "Custom/Unknown Attribute"}
182
+ ${
183
+ clusters[this.cluster!]?.attributes[attribute.key]?.label ??
184
+ "Custom/Unknown Attribute"
185
+ }
182
186
  </div>
183
187
  <div slot="supporting-text">
184
188
  AttributeId: ${attribute.key} (${formatHex(attribute.key)}) - Value type:
185
189
  ${clusters[this.cluster!]?.attributes[attribute.key]?.type ?? "unknown"}
186
190
  </div>
187
191
  <div slot="end" class="row-end">
188
- ${this._devMode
189
- ? this._renderAttributeDevActions(attribute.key, attribute.value)
190
- : nothing}
191
- ${toBigIntAwareJson(attribute.value).length > 30
192
- ? html`<md-outlined-button
193
- @click=${() => {
194
- this._showAttributeValue(attribute.value);
195
- }}
196
- >
197
- Show value
198
- </md-outlined-button>`
199
- : html`<code>${toBigIntAwareJson(attribute.value)}</code>`}
192
+ ${
193
+ this._devMode
194
+ ? this._renderAttributeDevActions(attribute.key, attribute.value)
195
+ : nothing
196
+ }
197
+ ${
198
+ toBigIntAwareJson(attribute.value).length > 30
199
+ ? html`<md-outlined-button
200
+ @click=${() => {
201
+ this._showAttributeValue(attribute.value);
202
+ }}
203
+ >
204
+ Show value
205
+ </md-outlined-button>`
206
+ : html`<code>${toBigIntAwareJson(attribute.value)}</code>`
207
+ }
200
208
  </div>
201
209
  </md-list-item>
202
210
  `,
@@ -223,19 +231,30 @@ class MatterClusterView extends LitElement {
223
231
  >
224
232
  <ha-svg-icon .path=${mdiRefresh}></ha-svg-icon>
225
233
  </md-outlined-icon-button>
226
- ${meta?.writable
227
- ? html`
228
- <md-outlined-icon-button
229
- class="dev-action pencil"
230
- title="Write attribute…"
231
- aria-label="Write attribute"
232
- ?disabled=${!online}
233
- @click=${() => this._openAttributeWriteDialog(attributeId, currentValue, meta.label)}
234
- >
235
- <ha-svg-icon .path=${mdiPencil}></ha-svg-icon>
236
- </md-outlined-icon-button>
237
- `
238
- : nothing}
234
+ <md-outlined-icon-button
235
+ class="dev-action unfiltered"
236
+ title="Read unfiltered (all fabrics) — shown only, not cached"
237
+ aria-label="Read attribute unfiltered"
238
+ ?disabled=${!online || this._unfilteredBusy[attributeId] === true}
239
+ @click=${() => this._readUnfiltered(attributeId)}
240
+ >
241
+ <ha-svg-icon .path=${mdiFilterOffOutline}></ha-svg-icon>
242
+ </md-outlined-icon-button>
243
+ ${
244
+ meta?.writable
245
+ ? html`
246
+ <md-outlined-icon-button
247
+ class="dev-action pencil"
248
+ title="Write attribute…"
249
+ aria-label="Write attribute"
250
+ ?disabled=${!online}
251
+ @click=${() => this._openAttributeWriteDialog(attributeId, currentValue, meta.label)}
252
+ >
253
+ <ha-svg-icon .path=${mdiPencil}></ha-svg-icon>
254
+ </md-outlined-icon-button>
255
+ `
256
+ : nothing
257
+ }
239
258
  </span>
240
259
  `;
241
260
  }
@@ -253,9 +272,10 @@ class MatterClusterView extends LitElement {
253
272
 
254
273
  this._refreshState = { ...this._refreshState, [attributeId]: "loading" };
255
274
  try {
256
- const result = await this.client.readAttribute(nodeId, path);
275
+ // Fabric-filtered to match the subscription: matter.js discards a read whose filtering
276
+ // differs, so an unfiltered one would put values into the cache that nothing ever refreshes.
277
+ const result = await this.client.readAttribute(nodeId, path, undefined, true);
257
278
  if (!isSameContext()) return;
258
- // Defensive merge — attribute_updated events usually do this already.
259
279
  for (const [key, value] of Object.entries(result)) {
260
280
  this.node.attributes[key] = value;
261
281
  }
@@ -271,7 +291,45 @@ class MatterClusterView extends LitElement {
271
291
  if (!isSameContext()) return;
272
292
  this._refreshState = { ...this._refreshState, [attributeId]: "idle" };
273
293
  const message = err instanceof Error ? err.message : String(err);
274
- showAlertDialog({ title: "Read failed", text: message });
294
+ showAlertDialog({ title: "Read failed", text: message }).catch(alertErr =>
295
+ console.error("Failed to show the read error", alertErr),
296
+ );
297
+ }
298
+ }
299
+
300
+ /**
301
+ * Read across all fabrics for diagnostics. The result is displayed only — merging it would put
302
+ * values into the attribute cache that the fabric-filtered subscription never refreshes.
303
+ */
304
+ private async _readUnfiltered(attributeId: number) {
305
+ if (!this.node) return;
306
+ const nodeId = this.node.node_id;
307
+ const endpoint = this.endpoint;
308
+ const cluster = this.cluster;
309
+ const path = `${endpoint}/${cluster}/${attributeId}`;
310
+ // The busy flag is cleared for the same view even while detached, since nothing resets it on
311
+ // reconnect and the button would stay disabled forever.
312
+ const isSameView = () =>
313
+ this.node?.node_id === nodeId && this.endpoint === endpoint && this.cluster === cluster;
314
+ const isSameContext = () => this.isConnected && isSameView();
315
+
316
+ this._unfilteredBusy = { ...this._unfilteredBusy, [attributeId]: true };
317
+ try {
318
+ const result = await this.client.readAttribute(nodeId, path, undefined, false);
319
+ if (!isSameContext()) return;
320
+ showAlertDialog({
321
+ title: "Unfiltered read (all fabrics)",
322
+ text: path in result ? toBigIntAwareJson(result[path]) : "The device returned no value for this path.",
323
+ asCodeBlock: true,
324
+ }).catch(err => console.error("Failed to show the unfiltered read", err));
325
+ } catch (err) {
326
+ if (!isSameContext()) return;
327
+ showAlertDialog({
328
+ title: "Read failed",
329
+ text: err instanceof Error ? err.message : String(err),
330
+ }).catch(alertErr => console.error("Failed to show the read error", alertErr));
331
+ } finally {
332
+ if (isSameView()) this._unfilteredBusy = { ...this._unfilteredBusy, [attributeId]: false };
275
333
  }
276
334
  }
277
335
 
@@ -308,33 +366,35 @@ class MatterClusterView extends LitElement {
308
366
  Commands
309
367
  </summary>
310
368
  <div class="dev-commands-content">
311
- ${commands.length === 0
312
- ? html`<p class="empty">No invokable commands for this cluster.</p>`
313
- : html`
314
- <ul class="command-list">
315
- ${commands.map(
316
- cmd => html`
317
- <li class="command-row">
318
- <div class="command-meta">
319
- <span class="command-label">${cmd.label}</span>
320
- <span class="command-sub"
321
- >CommandId ${cmd.id} (${formatHex(cmd.id)}) ·
322
- <code>${cmd.name}</code></span
369
+ ${
370
+ commands.length === 0
371
+ ? html`<p class="empty">No invokable commands for this cluster.</p>`
372
+ : html`
373
+ <ul class="command-list">
374
+ ${commands.map(
375
+ cmd => html`
376
+ <li class="command-row">
377
+ <div class="command-meta">
378
+ <span class="command-label">${cmd.label}</span>
379
+ <span class="command-sub"
380
+ >CommandId ${cmd.id} (${formatHex(cmd.id)}) ·
381
+ <code>${cmd.name}</code></span
382
+ >
383
+ </div>
384
+ <md-outlined-button
385
+ class="dev-invoke-button"
386
+ ?disabled=${!online}
387
+ @click=${() => this._openCommandInvokeDialog(cmd.id, cmd.name)}
323
388
  >
324
- </div>
325
- <md-outlined-button
326
- class="dev-invoke-button"
327
- ?disabled=${!online}
328
- @click=${() => this._openCommandInvokeDialog(cmd.id, cmd.name)}
329
- >
330
- <ha-svg-icon slot="icon" .path=${mdiPlay}></ha-svg-icon>
331
- Invoke
332
- </md-outlined-button>
333
- </li>
334
- `,
335
- )}
336
- </ul>
337
- `}
389
+ <ha-svg-icon slot="icon" .path=${mdiPlay}></ha-svg-icon>
390
+ Invoke
391
+ </md-outlined-button>
392
+ </li>
393
+ `,
394
+ )}
395
+ </ul>
396
+ `
397
+ }
338
398
  </div>
339
399
  </details>
340
400
  </div>
@@ -382,19 +442,21 @@ class MatterClusterView extends LitElement {
382
442
  return html`
383
443
  <div class="info-section">
384
444
  <div class="info-section-header">Active Features</div>
385
- ${activeFeatures.length === 0
386
- ? html`<p class="empty">No active features</p>`
387
- : html`
388
- <ul class="chip-list">
389
- ${activeFeatures.map(
390
- feature => html`
391
- <li class="chip" title="Bit ${feature.bit} (${feature.code})">
392
- ${feature.label}
393
- </li>
394
- `,
395
- )}
396
- </ul>
397
- `}
445
+ ${
446
+ activeFeatures.length === 0
447
+ ? html`<p class="empty">No active features</p>`
448
+ : html`
449
+ <ul class="chip-list">
450
+ ${activeFeatures.map(
451
+ feature => html`
452
+ <li class="chip" title="Bit ${feature.bit} (${feature.code})">
453
+ ${feature.label}
454
+ </li>
455
+ `,
456
+ )}
457
+ </ul>
458
+ `
459
+ }
398
460
  </div>
399
461
  `;
400
462
  }
@@ -409,18 +471,20 @@ class MatterClusterView extends LitElement {
409
471
  return html`
410
472
  <div class="info-section">
411
473
  <div class="info-section-header">Semantic Tags (TagList)</div>
412
- ${tagList.length === 0
413
- ? html`<p class="empty">No semantic tags</p>`
414
- : html`
415
- <ul class="chip-list">
416
- ${tagList.map(entry => {
417
- const { text, title, erroneous } = describeSemanticTagListEntry(entry);
418
- return html`<li class=${erroneous ? "chip chip-error" : "chip"} title=${title}>
419
- ${text}
420
- </li>`;
421
- })}
422
- </ul>
423
- `}
474
+ ${
475
+ tagList.length === 0
476
+ ? html`<p class="empty">No semantic tags</p>`
477
+ : html`
478
+ <ul class="chip-list">
479
+ ${tagList.map(entry => {
480
+ const { text, title, erroneous } = describeSemanticTagListEntry(entry);
481
+ return html`<li class=${erroneous ? "chip chip-error" : "chip"} title=${title}>
482
+ ${text}
483
+ </li>`;
484
+ })}
485
+ </ul>
486
+ `
487
+ }
424
488
  </div>
425
489
  `;
426
490
  }
@@ -458,9 +522,13 @@ class MatterClusterView extends LitElement {
458
522
  override updated(changedProperties: Map<string, unknown>) {
459
523
  super.updated(changedProperties);
460
524
 
461
- // Reset per-attribute refresh state when navigating to a different cluster/endpoint.
462
- if (changedProperties.has("cluster") || changedProperties.has("endpoint")) {
525
+ // Reset per-attribute read state when navigating to a different node/endpoint/cluster. Keyed on
526
+ // the node id, not the property: `node` is a fresh object on every nodes_changed tick.
527
+ const viewKey = `${this.node?.node_id ?? ""}/${this.endpoint}/${this.cluster}`;
528
+ if (viewKey !== this._viewKey) {
529
+ this._viewKey = viewKey;
463
530
  this._refreshState = {};
531
+ this._unfilteredBusy = {};
464
532
  this._scrollCommandPanelIntoView();
465
533
  }
466
534
 
@@ -490,6 +558,7 @@ class MatterClusterView extends LitElement {
490
558
 
491
559
  static override styles = [
492
560
  notFoundStyles,
561
+ infoPanelStyles,
493
562
  css`
494
563
  :host {
495
564
  display: block;
@@ -711,42 +780,6 @@ class MatterClusterView extends LitElement {
711
780
  border-radius: 3px;
712
781
  }
713
782
 
714
- .info-panel {
715
- background-color: var(--md-sys-color-surface-container);
716
- border: 1px solid var(--md-sys-color-outline-variant);
717
- border-radius: 12px;
718
- padding: 14px 16px;
719
- }
720
-
721
- .info-section + .info-section {
722
- margin-top: 12px;
723
- padding-top: 12px;
724
- border-top: 1px solid var(--md-sys-color-outline-variant);
725
- }
726
-
727
- .info-section-header {
728
- font-weight: 500;
729
- color: var(--md-sys-color-on-surface);
730
- margin-bottom: 10px;
731
- }
732
-
733
- .chip-list {
734
- list-style: none;
735
- margin: 0;
736
- padding: 0;
737
- display: flex;
738
- flex-wrap: wrap;
739
- gap: 8px;
740
- }
741
-
742
- .chip {
743
- font-size: 0.85rem;
744
- color: var(--md-sys-color-on-secondary-container);
745
- background: var(--md-sys-color-secondary-container);
746
- padding: 4px 10px;
747
- border-radius: 8px;
748
- }
749
-
750
783
  .chip.chip-error {
751
784
  color: var(--md-sys-color-on-error-container);
752
785
  background: var(--md-sys-color-error-container);
@@ -13,16 +13,17 @@ import "@material/web/list/list-item";
13
13
  import { consume } from "@lit/context";
14
14
  import { MatterClient, MatterNode, isTestNodeId } from "@matter-server/ws-client";
15
15
  import { mdiAlertCircleOutline, mdiChevronRight } from "@mdi/js";
16
- import { LitElement, css, html, nothing } from "lit";
16
+ import { LitElement, type TemplateResult, css, html, nothing } from "lit";
17
17
  import { customElement, property } from "lit/decorators.js";
18
18
  import { guard } from "lit/directives/guard.js";
19
19
  import "./cluster-commands/clusters/binding-commands.js";
20
20
  import { clientContext, tickContext } from "../client/client-context.js";
21
21
  import { clusters } from "../client/models/descriptions.js";
22
22
  import "../components/ha-svg-icon";
23
+ import { BINDING_CLUSTER_ID, boundClientClusterIds, sourceClientClusters } from "../util/binding.js";
23
24
  import { getEndpointDeviceTypes } from "../util/endpoints.js";
24
25
  import { formatHex, formatNodeAddress, getEffectiveFabricIndex } from "../util/format_hex.js";
25
- import { notFoundStyles } from "../util/shared-styles.js";
26
+ import { infoPanelStyles, notFoundStyles } from "../util/shared-styles.js";
26
27
  import { bindingContext } from "./components/context.js";
27
28
 
28
29
  declare global {
@@ -77,7 +78,10 @@ class MatterEndpointView extends LitElement {
77
78
  this.client.serverInfo.fabric_index,
78
79
  isTestNodeId(this.node.node_id),
79
80
  );
80
- const nodeHex = formatNodeAddress(fabricIndex, this.node.node_id);
81
+ const nodeId = this.node.node_id;
82
+ const nodeHex = formatNodeAddress(fabricIndex, nodeId);
83
+ const endpointClusters = getUniqueClusters(this.node, this.endpoint);
84
+ const hasBindingCluster = endpointClusters.includes(BINDING_CLUSTER_ID);
81
85
 
82
86
  return html`
83
87
  <dashboard-header
@@ -90,16 +94,20 @@ class MatterEndpointView extends LitElement {
90
94
  <node-details .node=${this.node}></node-details>
91
95
  </div>
92
96
 
97
+ ${hasBindingCluster ? this._renderClientClustersSection(this.node) : nothing}
98
+
93
99
  <!-- Binding editor (when this endpoint has a Binding cluster) -->
94
- ${getUniqueClusters(this.node, this.endpoint).includes(30)
95
- ? html`<div class="container">
96
- <binding-cluster-commands
97
- .node=${this.node}
98
- .endpoint=${this.endpoint}
99
- .cluster=${30}
100
- ></binding-cluster-commands>
101
- </div>`
102
- : nothing}
100
+ ${
101
+ hasBindingCluster
102
+ ? html`<div class="container">
103
+ <binding-cluster-commands
104
+ .node=${this.node}
105
+ .endpoint=${this.endpoint}
106
+ .cluster=${BINDING_CLUSTER_ID}
107
+ ></binding-cluster-commands>
108
+ </div>`
109
+ : nothing
110
+ }
103
111
 
104
112
  <!-- Endpoint clusters listing -->
105
113
  <div class="container">
@@ -117,19 +125,22 @@ class MatterEndpointView extends LitElement {
117
125
  .join(" / ")}
118
126
  </div>
119
127
  </md-list-item>
120
- ${guard([this.node?.attributes.length], () =>
121
- getUniqueClusters(this.node!, this.endpoint).map(cluster => {
122
- return html`
123
- <md-list-item
124
- type="link"
125
- href=${`#node/${this.node!.node_id}/${this.endpoint}/${cluster}`}
126
- >
127
- <div slot="headline">${clusters[cluster]?.label ?? "Custom/Unknown Cluster"}</div>
128
- <div slot="supporting-text">ClusterId ${cluster} (${formatHex(cluster)})</div>
129
- <ha-svg-icon slot="end" .path=${mdiChevronRight}></ha-svg-icon>
130
- </md-list-item>
131
- `;
132
- }),
128
+ ${guard(
129
+ // Must name the rendered set itself; anything derived from the attribute
130
+ // cache depends on how that cache mutates and can go stale.
131
+ [nodeId, this.endpoint, endpointClusters.join(",")],
132
+ () =>
133
+ endpointClusters.map(cluster => {
134
+ return html`
135
+ <md-list-item type="link" href=${`#node/${nodeId}/${this.endpoint}/${cluster}`}>
136
+ <div slot="headline">
137
+ ${clusters[cluster]?.label ?? "Custom/Unknown Cluster"}
138
+ </div>
139
+ <div slot="supporting-text">ClusterId ${cluster} (${formatHex(cluster)})</div>
140
+ <ha-svg-icon slot="end" .path=${mdiChevronRight}></ha-svg-icon>
141
+ </md-list-item>
142
+ `;
143
+ }),
133
144
  )}
134
145
  </md-list>
135
146
  </div>
@@ -140,8 +151,36 @@ class MatterEndpointView extends LitElement {
140
151
  history.back();
141
152
  }
142
153
 
154
+ private _renderClientClustersSection(node: MatterNode): TemplateResult | typeof nothing {
155
+ const clientClusters = sourceClientClusters(node, this.endpoint);
156
+ if (clientClusters.length === 0) return nothing;
157
+ const boundClusterIds = boundClientClusterIds(node, this.endpoint);
158
+
159
+ return html`
160
+ <div class="container">
161
+ <div class="info-panel">
162
+ <div class="info-section">
163
+ <div class="info-section-header">Client Clusters</div>
164
+ <ul class="chip-list" role="list">
165
+ ${clientClusters.map(id => {
166
+ const bound = boundClusterIds.has(id);
167
+ return html`
168
+ <li class=${bound ? "chip chip-bound" : "chip"}>
169
+ ${clusters[id]?.label ?? "Custom/Unknown Cluster"} ${formatHex(id)}
170
+ ${bound ? html`<span class="chip-state">Bound</span>` : nothing}
171
+ </li>
172
+ `;
173
+ })}
174
+ </ul>
175
+ </div>
176
+ </div>
177
+ </div>
178
+ `;
179
+ }
180
+
143
181
  static override styles = [
144
182
  notFoundStyles,
183
+ infoPanelStyles,
145
184
  css`
146
185
  :host {
147
186
  display: block;
@@ -178,6 +217,18 @@ class MatterEndpointView extends LitElement {
178
217
  font-weight: bold;
179
218
  font-size: 0.8em;
180
219
  }
220
+
221
+ .chip.chip-bound {
222
+ color: var(--md-sys-color-on-primary-container);
223
+ background: var(--md-sys-color-primary-container);
224
+ }
225
+
226
+ .chip-state {
227
+ font-weight: 500;
228
+ margin-left: 8px;
229
+ padding-left: 8px;
230
+ border-left: 1px solid currentcolor;
231
+ }
181
232
  `,
182
233
  ];
183
234
  }
@@ -354,29 +354,31 @@ class MatterNetworkView extends LitElement {
354
354
  >
355
355
  <ha-svg-icon .path=${mdiEyeOff}></ha-svg-icon>
356
356
  </button>
357
- ${this._showHideMenu
358
- ? html`
359
- <div
360
- id="hide-options-menu"
361
- class="hide-dropdown"
362
- role="group"
363
- aria-label="Hide options"
364
- >
365
- ${HIDE_OPTIONS.map(
366
- option => html`
367
- <label class="hide-option">
368
- <input
369
- type="checkbox"
370
- .checked=${this[option.key]}
371
- @change=${() => this._handleToggleHideOption(option.key)}
372
- />
373
- <span>${option.label}</span>
374
- </label>
375
- `,
376
- )}
377
- </div>
378
- `
379
- : ""}
357
+ ${
358
+ this._showHideMenu
359
+ ? html`
360
+ <div
361
+ id="hide-options-menu"
362
+ class="hide-dropdown"
363
+ role="group"
364
+ aria-label="Hide options"
365
+ >
366
+ ${HIDE_OPTIONS.map(
367
+ option => html`
368
+ <label class="hide-option">
369
+ <input
370
+ type="checkbox"
371
+ .checked=${this[option.key]}
372
+ @change=${() => this._handleToggleHideOption(option.key)}
373
+ />
374
+ <span>${option.label}</span>
375
+ </label>
376
+ `,
377
+ )}
378
+ </div>
379
+ `
380
+ : ""
381
+ }
380
382
  </div>
381
383
  <button
382
384
  class="control-button ${this._physicsEnabled ? "" : "active"}"
@@ -388,13 +390,17 @@ class MatterNetworkView extends LitElement {
388
390
  </div>
389
391
  </div>
390
392
  </div>
391
- ${this._threadAddressSearchStatus === "idle"
392
- ? ""
393
- : html`<div class="thread-search-status ${this._threadAddressSearchStatus}">
394
- ${this._threadAddressSearchStatus === "found"
395
- ? "Node highlighted."
396
- : "No matching device found."}
397
- </div>`}
393
+ ${
394
+ this._threadAddressSearchStatus === "idle"
395
+ ? ""
396
+ : html`<div class="thread-search-status ${this._threadAddressSearchStatus}">
397
+ ${
398
+ this._threadAddressSearchStatus === "found"
399
+ ? "Node highlighted."
400
+ : "No matching device found."
401
+ }
402
+ </div>`
403
+ }
398
404
  <thread-graph
399
405
  .nodes=${this.nodes}
400
406
  .borderRouters=${this._borderRouterStore.entries}
@@ -83,14 +83,20 @@ class MatterNodeView extends LitElement {
83
83
  <div class="node-title-bar">
84
84
  <ha-svg-icon class="node-icon" .path=${getDeviceIcon(this.node)}></ha-svg-icon>
85
85
  <h2>Node ${this.node.node_id} <span class="node-id-hex">${nodeHex}</span></h2>
86
- ${showGraphButton
87
- ? html`
88
- <a href=${graphUrl} class="show-in-graph-button" title="Show in ${graphViewType} graph">
89
- <ha-svg-icon .path=${mdiGraphOutline}></ha-svg-icon>
90
- <span class="button-text">Show in graph</span>
91
- </a>
92
- `
93
- : ""}
86
+ ${
87
+ showGraphButton
88
+ ? html`
89
+ <a
90
+ href=${graphUrl}
91
+ class="show-in-graph-button"
92
+ title="Show in ${graphViewType} graph"
93
+ >
94
+ <ha-svg-icon .path=${mdiGraphOutline}></ha-svg-icon>
95
+ <span class="button-text">Show in graph</span>
96
+ </a>
97
+ `
98
+ : ""
99
+ }
94
100
  </div>
95
101
  <node-details .node=${this.node}></node-details>
96
102
  </div>