Allow the user to specify image URL for image live provider.

This commit is contained in:
Dermot Duffy
2023-02-26 19:47:33 -08:00
parent 5e927a23b0
commit 6d2d31f709
9 changed files with 66 additions and 46 deletions
+8 -6
View File
@@ -723,12 +723,14 @@ export class FrigateCardLiveProvider
// If the play call fails, and the media is not already muted, mute it first
// and then try again. This works around some browsers that prevent
// auto-play unless the video is muted.
this._providerRef.value?.play().catch((ev) => {
if (ev.name === 'NotAllowedError' && !this.isMuted()) {
this.mute();
this._providerRef.value?.play().catch();
}
});
if (this._providerRef.value?.play) {
this._providerRef.value?.play().catch((ev) => {
if (ev.name === 'NotAllowedError' && !this.isMuted()) {
this.mute();
this._providerRef.value?.play().catch();
}
});
}
}
public pause(): void {