follow titlebar updates
This commit is contained in:
@@ -12,13 +12,13 @@ import { CommonModule } from '@angular/common';
|
|||||||
export class App {
|
export class App {
|
||||||
|
|
||||||
@ViewChild('homeLink') homeLink!: ElementRef<HTMLAnchorElement>;
|
@ViewChild('homeLink') homeLink!: ElementRef<HTMLAnchorElement>;
|
||||||
@ViewChild('companiesLink') companyLink!: ElementRef<HTMLAnchorElement>;
|
|
||||||
@ViewChild('jobsLink') jobLink!: ElementRef<HTMLAnchorElement>;
|
@ViewChild('jobsLink') jobLink!: ElementRef<HTMLAnchorElement>;
|
||||||
|
@ViewChild('resumesLink') resumeLink!: ElementRef<HTMLAnchorElement>;
|
||||||
|
|
||||||
constructor(public auth: Authentication, private router: Router){}
|
constructor(public auth: Authentication, private router: Router){}
|
||||||
|
|
||||||
ngAfterViewInit(){
|
ngAfterViewInit(){
|
||||||
let ViewLinks = [ this.homeLink, this.companyLink, this.jobLink ];
|
let ViewLinks = [ this.homeLink, this.resumeLink, this.jobLink ];
|
||||||
ViewLinks.forEach(link => {
|
ViewLinks.forEach(link => {
|
||||||
if (new URL(link.nativeElement.href).pathname === new URL(window.location.href).pathname){
|
if (new URL(link.nativeElement.href).pathname === new URL(window.location.href).pathname){
|
||||||
link.nativeElement.classList.add("active");
|
link.nativeElement.classList.add("active");
|
||||||
|
|||||||
Reference in New Issue
Block a user