mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-23 02:35:17 +01:00
make tag name clickable in repo-tag-stack view
This commit is contained in:
parent
1d543c9212
commit
f981415b5b
@ -27,7 +27,7 @@ export const TAG_TEMPLATE = `
|
||||
<button class="action-item" (click)="showDigestId(t)">{{'REPOSITORY.COPY_DIGEST_ID' | translate}}</button>
|
||||
<button class="action-item" [hidden]="!hasProjectAdminRole" (click)="deleteTag(t)">{{'REPOSITORY.DELETE' | translate}}</button>
|
||||
</clr-dg-action-overflow>
|
||||
<clr-dg-cell>{{t.name}}</clr-dg-cell>
|
||||
<clr-dg-cell><a href="javascript:void(0)" (click)="onTagClick(t)">{{t.name}}</a></clr-dg-cell>
|
||||
<clr-dg-cell>docker pull {{registryUrl}}/{{repoName}}:{{t.name}}</clr-dg-cell>
|
||||
<clr-dg-cell *ngIf="withNotary" [ngSwitch]="t.signature !== null">
|
||||
<clr-icon shape="check" *ngSwitchCase="true" style="color: #1D5100;"></clr-icon>
|
||||
|
@ -51,6 +51,7 @@ export class TagComponent implements OnInit {
|
||||
@Input() withNotary: boolean;
|
||||
|
||||
@Output() refreshRepo = new EventEmitter<boolean>();
|
||||
@Output() tagClickEvent = new EventEmitter<Tag>();
|
||||
|
||||
tags: Tag[];
|
||||
|
||||
@ -161,7 +162,14 @@ export class TagComponent implements OnInit {
|
||||
this.showTagManifestOpened = true;
|
||||
}
|
||||
}
|
||||
|
||||
selectAndCopy($event: any) {
|
||||
$event.target.select();
|
||||
}
|
||||
|
||||
onTagClick(tag: Tag): void {
|
||||
if (tag) {
|
||||
this.tagClickEvent.emit(tag);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user