Skip to content

Commit f99a8ab

Browse files
crisbetowagnermaciel
authored andcommitted
fix(material/tabs): icons not centered inside tab (#26053)
Fixes that icons projected into a tab were centered anymore. Relates to #26024 (comment).
1 parent 092cb50 commit f99a8ab

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/material/tabs/_tabs-common.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@ $mat-tab-animation-duration: 500ms !default;
5353
pointer-events: none;
5454
}
5555

56+
// We support projecting icons into the tab. These styles ensure that they're centered.
57+
.mdc-tab__text-label {
58+
display: inline-flex;
59+
align-items: center;
60+
}
61+
5662
// Required for `fitInkBarToContent` to work. This used to be included with MDC's `without-ripple`
5763
// mixin, but that no longer appears to be the case with `static-styles`. Since the latter is
5864
// ~10kb smaller, we include this one extra style ourselves.

0 commit comments

Comments
 (0)