@if (selected(); as selectedMetadata) {
} @else {
@if (hasSearched()) {

{{ t('searchResults') }}

{{ t('booksFound', { count: filteredResults().length }) }}
@if (loading()) { {{ t('fetching') }} }
@for (tab of providerTabs(); track tab.provider) {
{{ providerLabelKey(tab.provider) | transloco }} @if (loading() && tab.count === 0) { } @else { {{ tab.count }} }
}
} @else {
@if (noProviders()) {

{{ t('noProviders') }}

} @else {

{{ t('readyToSearch') }}

{{ t('readyToSearchHint') }}

}
} @if (hasSearched() && !loading() && (results().length === 0 || failed())) {
@if (failed()) {

{{ t('searchFailed') }}

} @else {

{{ t('noResultsFound') }}

{{ t('noResultsHint') }}

}
} @if (results().length > 0) {
@for (metadata of filteredResults(); track metadata) { }
}
}