{#if isInitialized} {#if $isAuthenticated && !$isConnected}
You're offline. Some features may be limited.
{#if $pendingSyncCount > 0}
(showPendingSync = true)} class="bg-white/20 hover:bg-white/30 px-2 py-0.5 rounded-full text-xs transition-colors" title="Changes waiting to reach the server" > {$pendingSyncCount} waiting to sync
{/if}
showServerCatalog.update((v) => !v)} class="ml-1 bg-white/20 hover:bg-white/30 px-2 py-0.5 rounded-full text-xs transition-colors" aria-pressed={$showServerCatalog} title={$lastCatalogSync ? `Catalog last synced ${new Date($lastCatalogSync).toLocaleString()}` : 'Catalog not yet synced'} > {$showServerCatalog ? 'Hide server media' : 'Show all server media'}
{/if} {#if routeOwnsLayout}
{@render children()}
{:else} {#if showGlobalHeader}
{/if}
{@render children()}
{/if}
{#if !routeOwnsLayout && (showBottomNav || showGlobalMiniPlayer)}
{/if}
showSleepTimerModal.set(false)} />
(showPendingSync = false)} /> {:else}
{/if}