<core-navbar-buttons slot="end" prepend>
    <ion-button *ngIf="searchEnabled" (click)="openSearch()" [attr.aria-label]="'core.courses.searchcourses' | translate">
        <ion-icon name="fas-magnifying-glass" slot="icon-only" aria-hidden="true" />
    </ion-button>
</core-navbar-buttons>
<ion-content>
    <ion-refresher slot="fixed" [disabled]="!loaded" (ionRefresh)="refreshDashboard($event.target)">
        <ion-refresher-content pullingText="{{ 'core.pulltorefresh' | translate }}" />
    </ion-refresher>

    <core-loading [hideUntil]="loaded">
        <ion-list class="list-item-limited-width" *ngIf="hasMainBlocks">
            <ng-container *ngFor="let block of blocks">
                <core-block *ngIf="block.visible" [block]="block" contextLevel="user" [instanceId]="userId" />
            </ng-container>
        </ion-list>

        <core-block-side-blocks-button slot="fixed" *ngIf="hasSideBlocks" contextLevel="user" [instanceId]="userId" />

        <core-empty-box *ngIf="!hasMainBlocks" icon="fas-cubes" [message]="'core.course.nocontentavailable' | translate" />
    </core-loading>
</ion-content>
