fix: Improve media background image (#1635)

* fix: Improve media background image

* Simplify loading spinner.

This is slightly less fancy, but removes code. I'm guessing no-one will notice or care enough to raise it! (BMFW).
This commit is contained in:
Dermot Duffy
2024-10-12 14:31:26 -07:00
committed by GitHub
parent b3602c3809
commit 9ca56d061f
10 changed files with 66 additions and 92 deletions
+2 -6
View File
@@ -339,9 +339,8 @@ class FrigateCard extends LitElement {
const actions = this._controller.getActionsManager().getMergedActions();
const cameraManager = this._controller.getCameraManager();
const renderLoadingSpinner =
this._config?.performance?.features.animated_progress_indicator !== false;
const showLoadingSpinner =
this._config?.performance?.features.animated_progress_indicator !== false &&
!this._controller.getInitializationManager().wasEverInitialized() &&
!this._controller.getMessageManager().hasMessage();
@@ -372,10 +371,7 @@ class FrigateCard extends LitElement {
}
@frigate-card:focus=${() => this.focus()}
>
${renderLoadingSpinner
? html`<frigate-card-loading .show=${showLoadingSpinner}>
</frigate-card-loading>`
: ''}
${showLoadingSpinner ? html`<frigate-card-loading></frigate-card-loading>` : ''}
${this._renderMenuStatusContainer('top')}
${this._renderMenuStatusContainer('overlay')}
<div ${ref(this._refMain)} class="${classMap(mainClasses)}">