{#if catalog.loading}

Searching the catalog for “{catalog.query}”…

{:else if catalog.error}

Catalog search failed: {catalog.error}

{:else if !catalog.results}

Search for an artist, album or song above.

{:else} {#if resolver.active}

● {resolver.label} — finding the best source…

{:else if resolver.error}

{resolver.error}

{/if}
{#if top}

Top result

{/if} {#if tracks.length > 0}

Songs

{#each tracks as t (t.id)}
playSong(t)} onkeydown={(e) => e.key === "Enter" && playSong(t)} > {#if t.cover && !artBroken[t.cover]} markArtBroken(t.cover)} /> {:else}
{/if}
{#if nowPlaying("trackId", t.id)}♫{/if} {t.title}
{t.artist} · {t.album}
{fmtDuration(t.duration_secs)}
{/each}
{/if}
{#if artists.length > 0}

Artists

{#each artists as a (a.id)} {/each}
{/if} {#if albums.length > 0}

Albums

{#each albums as al (al.id)}
{#if nowPlaying("albumId", al.id)} ♫ {/if} {#if al.cover && !artBroken[al.cover]} markArtBroken(al.cover)} /> {:else}
{/if}
{al.title}
{albumMeta(al)}
{/each}
{/if} {/if}