mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-16 13:56:35 +00:00
Open more info for camera in picture-glance card. (#1424)
This commit is contained in:
parent
274f8e1b64
commit
bb7dc76996
@ -166,7 +166,7 @@ class HuiPictureGlanceCard extends NavigateMixin(LocalizeMixin(EventsMixin(Polym
|
|||||||
}
|
}
|
||||||
|
|
||||||
_computeImageClass(config) {
|
_computeImageClass(config) {
|
||||||
return config.navigation_path ? 'clickable' : '';
|
return config.navigation_path || config.camera_image ? 'clickable' : '';
|
||||||
}
|
}
|
||||||
|
|
||||||
_openDialog(ev) {
|
_openDialog(ev) {
|
||||||
@ -179,8 +179,14 @@ class HuiPictureGlanceCard extends NavigateMixin(LocalizeMixin(EventsMixin(Polym
|
|||||||
}
|
}
|
||||||
|
|
||||||
_handleImageClick() {
|
_handleImageClick() {
|
||||||
if (!this._config.navigation_path) return;
|
if (this._config.navigation_path) {
|
||||||
this.navigate(this._config.navigation_path);
|
this.navigate(this._config.navigation_path);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (this._config.camera_image) {
|
||||||
|
this.fire('hass-more-info', { entityId: this._config.camera_image });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user