Skip to content

Commit 2a15cd7

Browse files
crisbetojelbourn
authored andcommitted
fix(tabs): dynamic tab scrollbar showing while animating (#4524)
Fixes an issue that caused a scrollbar to be shown only while a tab inside a dynamic height tab group is animating. Relates to #4035.
1 parent af48bb0 commit 2a15cd7

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

src/lib/tabs/tab-body.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
.mat-tab-body-content {
22
height: 100%;
33
overflow: auto;
4+
5+
.mat-tab-group-dynamic-height & {
6+
overflow: hidden;
7+
}
48
}

src/lib/tabs/tab-body.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import {
88
ElementRef,
99
Optional,
1010
AfterViewChecked,
11+
ViewEncapsulation,
1112
} from '@angular/core';
1213
import {
1314
trigger,
@@ -50,6 +51,7 @@ export type MdTabBodyOriginState = 'left' | 'right';
5051
selector: 'md-tab-body, mat-tab-body',
5152
templateUrl: 'tab-body.html',
5253
styleUrls: ['tab-body.css'],
54+
encapsulation: ViewEncapsulation.None,
5355
host: {
5456
'[class.mat-tab-body]': 'true',
5557
},

0 commit comments

Comments
 (0)