<nav mat-tab-nav-bar [tabPanel]="tabPanel">
  @for (tab of tabs; track tab.route) {
    <a
      #link
      mat-tab-link
      [routerLink]="tab.route"
      [routerLinkActive]="'active'"
      [active]="link.elementRef.nativeElement.classList.contains('active')"
      >{{ tab.title }}</a
    >
  }
</nav>
<mat-tab-nav-panel #tabPanel>
  <router-outlet></router-outlet>
</mat-tab-nav-panel>
