Use query type instead of view.

This commit is contained in:
Dermot Duffy
2023-01-24 19:36:54 -08:00
parent 093925cb40
commit 66ee65f8cc
4 changed files with 20 additions and 53 deletions
+2 -2
View File
@@ -124,7 +124,7 @@ export class FrigateCardViewer extends LitElement {
// search for. When the query *is* specified, the view is not required to
// indicate the media type (e.g. the mixed 'media' view from the
// timeline).
const mediaType = this.view.getMediaType();
const mediaType = this.view.getDefaultMediaType();
if (!browseMediaQueryParameters || !mediaType) {
return;
}
@@ -148,7 +148,7 @@ export class FrigateCardViewer extends LitElement {
this.cameras,
this.view,
{
targetView: mediaType === 'clips' ? 'clip' : 'snapshot',
targetView: 'media',
},
);
}