tokens => {
const feeds = this.videoService.getVideoSubscriptionFeedUrls(user.account.id, tokens.feedToken)
feedUrl = feedUrl + feeds.find(f => f.format === FeedFormat.RSS).url
+
+ this.actions.unshift({
+ label: $localize`Copy feed URL`,
+ iconName: 'syndication',
+ justIcon: true,
+ href: feedUrl,
+ click: e => {
+ e.preventDefault()
+ copyToClipboard(feedUrl)
+ this.activateCopiedMessage()
+ }
+ })
},
err => {
this.notifier.error(err.message)
}
)
-
- this.actions.unshift({
- label: $localize`Feed`,
- iconName: 'syndication',
- justIcon: true,
- click: () => {
- copyToClipboard(feedUrl)
- this.activateCopiedMessage()
- }
- })
}
ngOnDestroy () {
<a *ngIf="action.routerLink" class="ml-2" [routerLink]="action.routerLink" routerLinkActive="active">
<ng-container *ngTemplateOutlet="actionContent; context:{ $implicit: action }"></ng-container>
</a>
- <a *ngIf="!action.routerLink && action.click && !action.clipboard" class="ml-2" (click)="action.click()" (key.enter)="action.click()">
- <ng-container *ngTemplateOutlet="actionContent; context:{ $implicit: action }"></ng-container>
- </a>
- <a *ngIf="!action.routerLink && !action.click && action.clipboard" class="ml-2" [cdkCopyToClipboard]="action.clipboard">
+
+ <a *ngIf="!action.routerLink && !action.href && action.click" class="ml-2" (click)="action.click($event)" (key.enter)="action.click($event)">
<ng-container *ngTemplateOutlet="actionContent; context:{ $implicit: action }"></ng-container>
</a>
- <a *ngIf="!action.routerLink && action.click && action.clipboard" class="ml-2" (click)="action.click()" (key.enter)="action.click()" [cdkCopyToClipboard]="action.clipboard">
+
+ <a *ngIf="!action.routerLink && action.href && action.click" class="ml-2" (click)="action.click($event)" (key.enter)="action.click($event)" [href]="action.href">
<ng-container *ngTemplateOutlet="actionContent; context:{ $implicit: action }"></ng-container>
</a>