mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-27 04:35:16 +01:00
Merge pull request #6472 from pureshine/filter-tag
Remove the default label when filtering images by label
This commit is contained in:
commit
f2a9e8ae9b
@ -27,7 +27,7 @@
|
|||||||
<div class="row flex-items-xs-right rightPos">
|
<div class="row flex-items-xs-right rightPos">
|
||||||
<div id="filterArea">
|
<div id="filterArea">
|
||||||
<div class='filterLabelPiece' *ngIf="!withAdmiral" [hidden]="!openLabelFilterPiece" [style.left.px]='filterLabelPieceWidth'>
|
<div class='filterLabelPiece' *ngIf="!withAdmiral" [hidden]="!openLabelFilterPiece" [style.left.px]='filterLabelPieceWidth'>
|
||||||
<hbr-label-piece [hidden]='!filterOneLabel' [label]="filterOneLabel" [labelWidth]="130"></hbr-label-piece>
|
<hbr-label-piece *ngIf="showlabel" [hidden]='!filterOneLabel' [label]="filterOneLabel" [labelWidth]="130"></hbr-label-piece>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex-xs-middle">
|
<div class="flex-xs-middle">
|
||||||
<hbr-filter [withDivider]="true" filterPlaceholder="{{'TAG.FILTER_FOR_TAGS' | translate}}" (filterEvt)="doSearchTagNames($event)"
|
<hbr-filter [withDivider]="true" filterPlaceholder="{{'TAG.FILTER_FOR_TAGS' | translate}}" (filterEvt)="doSearchTagNames($event)"
|
||||||
|
@ -103,6 +103,7 @@ export class TagComponent implements OnInit, AfterViewInit {
|
|||||||
openLabelFilterPanel: boolean;
|
openLabelFilterPanel: boolean;
|
||||||
openLabelFilterPiece: boolean;
|
openLabelFilterPiece: boolean;
|
||||||
retagSrcImage: string;
|
retagSrcImage: string;
|
||||||
|
showlabel: boolean;
|
||||||
|
|
||||||
createdComparator: Comparator<Tag> = new CustomComparator<Tag>("created", "date");
|
createdComparator: Comparator<Tag> = new CustomComparator<Tag>("created", "date");
|
||||||
|
|
||||||
@ -394,8 +395,10 @@ export class TagComponent implements OnInit, AfterViewInit {
|
|||||||
if (labelInfo) {
|
if (labelInfo) {
|
||||||
if (!labelInfo.iconsShow) {
|
if (!labelInfo.iconsShow) {
|
||||||
this.filterLabel(labelInfo);
|
this.filterLabel(labelInfo);
|
||||||
|
this.showlabel = true;
|
||||||
} else {
|
} else {
|
||||||
this.unFilterLabel(labelInfo);
|
this.unFilterLabel(labelInfo);
|
||||||
|
this.showlabel = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user