mirror of
https://github.com/home-assistant/frontend.git
synced 2025-04-26 14:27:20 +00:00
Fix ZHA network visualization page navigation (#8994)
* Fix ZHA visualization page navigation * Update src/panels/config/integrations/integration-panels/zha/zha-network-visualization-page.ts Co-authored-by: Bram Kragten <mail@bramkragten.nl> Co-authored-by: Bram Kragten <mail@bramkragten.nl>
This commit is contained in:
parent
4d287a1f83
commit
ac9a881ab5
@ -17,8 +17,8 @@ import {
|
|||||||
refreshTopology,
|
refreshTopology,
|
||||||
ZHADevice,
|
ZHADevice,
|
||||||
} from "../../../../../data/zha";
|
} from "../../../../../data/zha";
|
||||||
import "../../../../../layouts/hass-subpage";
|
import "../../../../../layouts/hass-tabs-subpage";
|
||||||
import type { HomeAssistant } from "../../../../../types";
|
import type { HomeAssistant, Route } from "../../../../../types";
|
||||||
import { Network, Edge, Node, EdgeOptions } from "vis-network";
|
import { Network, Edge, Node, EdgeOptions } from "vis-network";
|
||||||
import "../../../../../common/search/search-input";
|
import "../../../../../common/search/search-input";
|
||||||
import "../../../../../components/device/ha-device-picker";
|
import "../../../../../components/device/ha-device-picker";
|
||||||
@ -29,12 +29,17 @@ import { formatAsPaddedHex } from "./functions";
|
|||||||
import { DeviceRegistryEntry } from "../../../../../data/device_registry";
|
import { DeviceRegistryEntry } from "../../../../../data/device_registry";
|
||||||
import "../../../../../components/ha-checkbox";
|
import "../../../../../components/ha-checkbox";
|
||||||
import type { HaCheckbox } from "../../../../../components/ha-checkbox";
|
import type { HaCheckbox } from "../../../../../components/ha-checkbox";
|
||||||
|
import { zhaTabs } from "./zha-config-dashboard";
|
||||||
|
|
||||||
@customElement("zha-network-visualization-page")
|
@customElement("zha-network-visualization-page")
|
||||||
export class ZHANetworkVisualizationPage extends LitElement {
|
export class ZHANetworkVisualizationPage extends LitElement {
|
||||||
@property({ type: Object }) public hass!: HomeAssistant;
|
@property({ attribute: false }) public hass!: HomeAssistant;
|
||||||
|
|
||||||
@property({ type: Boolean, reflect: true }) public narrow = false;
|
@property({ attribute: false }) public route!: Route;
|
||||||
|
|
||||||
|
@property({ type: Boolean }) public narrow!: boolean;
|
||||||
|
|
||||||
|
@property({ type: Boolean }) public isWide!: boolean;
|
||||||
|
|
||||||
@property()
|
@property()
|
||||||
public zoomedDeviceId?: string;
|
public zoomedDeviceId?: string;
|
||||||
@ -133,9 +138,12 @@ export class ZHANetworkVisualizationPage extends LitElement {
|
|||||||
|
|
||||||
protected render() {
|
protected render() {
|
||||||
return html`
|
return html`
|
||||||
<hass-subpage
|
<hass-tabs-subpage
|
||||||
|
.tabs=${zhaTabs}
|
||||||
.hass=${this.hass}
|
.hass=${this.hass}
|
||||||
.narrow=${this.narrow}
|
.narrow=${this.narrow}
|
||||||
|
.isWide=${this.isWide}
|
||||||
|
.route=${this.route}
|
||||||
.header=${this.hass.localize(
|
.header=${this.hass.localize(
|
||||||
"ui.panel.config.zha.visualization.header"
|
"ui.panel.config.zha.visualization.header"
|
||||||
)}
|
)}
|
||||||
@ -172,7 +180,7 @@ export class ZHANetworkVisualizationPage extends LitElement {
|
|||||||
>
|
>
|
||||||
</div>
|
</div>
|
||||||
<div id="visualization"></div>
|
<div id="visualization"></div>
|
||||||
</hass-subpage>
|
</hass-tabs-subpage>
|
||||||
`;
|
`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user