Panels error handling

This commit is contained in:
Yegor Vialov
2020-05-01 13:47:41 +00:00
parent ba343fbd98
commit 8a180c4c0e
8 changed files with 57 additions and 53 deletions

View File

@ -24,7 +24,7 @@ class Panel {
icon = Panel.iconsByComponent[componentName];
}
isHidden = (componentName == 'kiosk' || componentName == 'states' || componentName == 'profile' || componentName == 'developer-tools');
isWebView = (componentName != 'config' && componentName != 'lovelace' && !componentName.startsWith('haclient'));
isWebView = (componentName != 'lovelace' && !componentName.startsWith('haclient'));
}
void handleOpen(BuildContext context) {
@ -68,10 +68,6 @@ class Panel {
Widget getWidget() {
switch (componentName) {
case "config": {
return ConfigPanelWidget();
}
default: {
return Text("Unsupported panel component: $componentName");
}