From 38f700e8f12d98f48dd5f77ad81e6558fe0a07d2 Mon Sep 17 00:00:00 2001 From: Dermot Duffy Date: Tue, 3 May 2022 22:39:32 -0700 Subject: [PATCH] Update view for new lazyload signature. --- src/components/viewer.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/viewer.ts b/src/components/viewer.ts index e5862b97..823c33d7 100644 --- a/src/components/viewer.ts +++ b/src/components/viewer.ts @@ -274,9 +274,9 @@ export class FrigateCardViewerCarousel extends FrigateCardMediaCarousel { return [ ...super._getPlugins(), Lazyload({ - lazyloadCallback: this.viewerConfig?.lazy_load - ? this._lazyloadSlide.bind(this) - : undefined, + ...(this.viewerConfig?.lazy_load && { + lazyLoadCallback: this._lazyloadSlide.bind(this), + }), }), AutoMediaPlugin({ playerSelector: 'frigate-card-ha-hls-player',