Skip to content

Commit dd046be

Browse files
committed
fix presentation open in rating-card
1 parent 49a846b commit dd046be

2 files changed

Lines changed: 12 additions & 1 deletion

File tree

projects/social_platform/src/app/office/program/shared/rating-card/rating-card.component.html

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,12 @@
2828

2929
@if (project.presentationAddress) {
3030
<a class="card__presentation" [href]="project.presentationAddress" target="_blank">
31-
<app-button size="medium" appearance="outline" customTypographyClass="text-body-12">
31+
<app-button
32+
size="medium"
33+
appearance="outline"
34+
customTypographyClass="text-body-12"
35+
(click)="openPresentation(project.presentationAddress)"
36+
>
3237
<span>презентация</span>
3338
<i appIcon icon="arrow-down" appSquare="8"></i>
3439
</app-button>

projects/social_platform/src/app/office/program/shared/rating-card/rating-card.component.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,12 @@ export class RatingCardComponent implements OnInit, AfterViewInit, OnDestroy {
241241
this.locallyRatedByCurrentUser.set(false);
242242
}
243243

244+
openPresentation(url: string) {
245+
if (url) {
246+
window.open(url, "_blank");
247+
}
248+
}
249+
244250
get canEdit(): boolean {
245251
return !this.programDateFinished();
246252
}

0 commit comments

Comments
 (0)