mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ACS-6140] - search-tab-content does not show when changing tab multiple times (#9332)
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
<mat-tab-group (selectedIndexChange)="onTabIndexChanged($event)">
|
<mat-tab-group (selectedIndexChange)="onTabIndexChanged($event)">
|
||||||
<mat-tab *ngFor="let tabContent of tabsContents; let i = index"
|
<mat-tab *ngFor="let tabContent of tabsContents; let i = index"
|
||||||
[labelClass]='selectedIndex === i ? "adf-search-tab-label-active" : ""'
|
[labelClass]='selectedIndex === i ? "adf-search-tab-label-active" : ""'
|
||||||
|
[bodyClass]='selectedIndex === i ? "adf-search-tab-content-active" : ""'
|
||||||
label="{{tabContent.name | translate}}">
|
label="{{tabContent.name | translate}}">
|
||||||
<ng-container *ngTemplateOutlet="tabContent.templateRef"></ng-container>
|
<ng-container *ngTemplateOutlet="tabContent.templateRef"></ng-container>
|
||||||
</mat-tab>
|
</mat-tab>
|
||||||
|
@@ -2,4 +2,13 @@ adf-search-filter-tabbed {
|
|||||||
.adf-search-tab-label-active {
|
.adf-search-tab-label-active {
|
||||||
border-bottom: 2px solid var(--theme-primary-color);
|
border-bottom: 2px solid var(--theme-primary-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// The important tag is used here as a workaround for a bug in angular material, when MatTabs are used in conjunction with MatMenu
|
||||||
|
// https://github.com/angular/components/issues/27426
|
||||||
|
.adf-search-tab-content-active {
|
||||||
|
& > div {
|
||||||
|
visibility: visible !important;
|
||||||
|
display: block !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user