diff --git a/src/components/knx-project-device-tree.ts b/src/components/knx-project-device-tree.ts index 47bc9ff..70086c4 100644 --- a/src/components/knx-project-device-tree.ts +++ b/src/components/knx-project-device-tree.ts @@ -4,6 +4,7 @@ import { customElement, property, state } from "lit/decorators"; import { repeat } from "lit/directives/repeat"; import { consume } from "@lit-labs/context"; +import "@ha/components/ha-alert"; import "@ha/components/ha-svg-icon"; import { KNXProject, CommunicationObject, COFlags, DPT, GroupAddress } from "../types/websocket"; @@ -116,6 +117,9 @@ export class KNXProjectDeviceTree extends LitElement { } private _renderDevices(): TemplateResult { + if (!this.deviceTree.length) { + return html`No suitable device found in project data.`; + } return html`