mirror of
https://github.com/block-core/angor-hub-old.git
synced 2026-01-31 07:34:21 +01:00
Use routerLink for linking
This commit is contained in:
@@ -78,7 +78,7 @@
|
||||
<div class="absolute top-2 right-2 flex space-x-2">
|
||||
<div
|
||||
class="flex h-10 w-10 items-center justify-center rounded-full border bg-white shadow-md">
|
||||
<button mat-icon-button (click)="openChat(project.nostrPubKey)">
|
||||
<button mat-icon-button [routerLink]="['/chat', project.nostrPubKey]">
|
||||
<mat-icon class="icon-size-5" [svgIcon]="'heroicons_outline:chat-bubble-left-right'"></mat-icon>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -11,7 +11,7 @@ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
||||
import { MatSelectModule } from '@angular/material/select';
|
||||
import { MatSlideToggleModule } from '@angular/material/slide-toggle';
|
||||
import { MatTooltipModule } from '@angular/material/tooltip';
|
||||
import { Router } from '@angular/router';
|
||||
import { Router, RouterLink } from '@angular/router';
|
||||
import { Project } from 'app/interface/project.interface';
|
||||
import { BookmarkService } from 'app/services/bookmark.service';
|
||||
import { ProjectsService, ProjectStats } from 'app/services/projects.service';
|
||||
@@ -22,6 +22,7 @@ import { catchError, Observable, of, Subject, takeUntil, tap } from 'rxjs';
|
||||
selector: 'app-bookmark',
|
||||
standalone: true,
|
||||
imports: [
|
||||
RouterLink,
|
||||
MatButtonModule,
|
||||
MatIconModule,
|
||||
AngorCardComponent,
|
||||
@@ -152,8 +153,4 @@ export class BookmarkComponent implements OnInit, OnDestroy {
|
||||
})
|
||||
).subscribe();
|
||||
}
|
||||
|
||||
openChat(pubKey: string): void {
|
||||
this._router.navigate(['/chat', pubKey]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user