Skip to content

Commit 89ea485

Browse files
crisbetoandrewseguin
authored andcommitted
feat(tabs): support stretched tabs in mat-tab-nav-bar (#10368)
Adds support for stretched tabs in the tab nav bar. Also removes a duplicate selector. Fixes #8871.
1 parent c3a8d0c commit 89ea485

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

src/lib/tabs/tab-group.scss

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
}
3030
}
3131

32-
.mat-tab-group[mat-stretch-tabs] .mat-tab-label,
3332
.mat-tab-group[mat-stretch-tabs] .mat-tab-label {
3433
flex-basis: 0;
3534
flex-grow: 1;

src/lib/tabs/tab-nav-bar/tab-nav-bar.scss

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
.mat-tab-links {
1010
position: relative;
11+
display: flex;
1112
}
1213

1314
// Wraps each link in the header
@@ -17,8 +18,14 @@
1718
text-decoration: none; // Removes anchor underline styling
1819
position: relative;
1920
overflow: hidden; // Keeps the ripple from extending outside the element bounds
21+
22+
[mat-stretch-tabs] & {
23+
flex-basis: 0;
24+
flex-grow: 1;
25+
}
2026
}
2127

28+
2229
@media ($mat-xsmall) {
2330
.mat-tab-link {
2431
min-width: 72px;

0 commit comments

Comments
 (0)