Fix config panel opening

This commit is contained in:
Yegor Vialov 2020-05-03 10:00:32 +00:00
parent c62e045dae
commit e9ad612fec

View File

@ -28,13 +28,7 @@ class Panel {
}
void handleOpen(BuildContext context) {
if (componentName == "config") {
Navigator.of(context).push(
MaterialPageRoute(
builder: (context) => PanelPage(title: "$title", panel: this),
)
);
} else if (componentName.startsWith('haclient')) {
if (componentName.startsWith('haclient')) {
Navigator.of(context).pushNamed(urlPath);
} else if (componentName == 'lovelace') {
HomeAssistant().lovelaceDashboardUrl = this.urlPath;