import { Component, OnInit, Input } from '@angular/core';
import { NzAvatarModule } from 'ng-zorro-antd/avatar';
import { textbookServer } from "../../services/textbook";
import { MatButtonModule } from '@angular/material/button';
import { MatIconModule } from '@angular/material/icon';
import { RouterModule,Router } from '@angular/router';
import { AuthServr } from '../../services/auth.service'
import { NzPopoverModule } from 'ng-zorro-antd/popover';
@Component({
  selector: 'app-comp-nav',
  standalone: true,
  imports: [
    RouterModule,
    NzAvatarModule,
    MatButtonModule,MatIconModule,NzPopoverModule
  ],
  templateUrl: './comp-nav.component.html',
  styleUrls: ['./comp-nav.component.scss'],
})
export class CompNavComponent implements OnInit {
  visible: boolean = false;
  @Input('viewCollapsed') viewCollapsed:boolean = false;

  constructor(
    public router: Router,
    public tbookSer: textbookServer,
    public authServr:AuthServr
  ) {}

  ngOnInit() {}
  change(value: boolean): void {
    console.log(value);
  }
  clickMe(): void {
    this.visible = false;
  }
  goUrl(path: string) {
    this.router.navigate([
      path,
      {
        // type: this.currentProfile.type,
      },
    ]);
  }
}
