<app-comp-nav></app-comp-nav>
<div class="page">
  <div class="content-left">
    <ul nz-menu nzMode="inline" style="width: 240px">
      @for (item of options; track item.id;let index = $index) { @if(item.child)
      {
      <li nz-submenu [nzTitle]="item.name" nzIcon="api" [nzOpen]="true">
        <ul>
          @for (child of item.child; track child.id;let idx = $index) {
          <li
            nz-menu-item
            [nzSelected]="active == child.id"
            (click)="toUrl('/nav-admin', child.id, { category: child.id })"
          >
            {{ child.name }}
          </li>
          }
        </ul>
      </li>
      } @else {
      <li
        nz-menu-item
        (click)="toUrl('/nav-admin', 'list')"
        [nzSelected]="active == item.id"
      >
        <span nz-icon nzType="home" nzTheme="outline"></span>
        <span>{{ item.name }}</span>
      </li>
      } }
    </ul>
  </div>
  <div class="proview">
    <router-outlet></router-outlet>
  </div>
</div>
