Skip to content
This repository was archived by the owner on Jan 13, 2025. It is now read-only.

Commit 3c5bb80

Browse files
authored
fix(list): incorrect item spacing with trailing meta in RTL
Currently if developers use the `mdc-list-item` in RTL mode with `--with-trailing-meta`, `--with-trailing-icon` et all, the horizontal spacing on the start breaks due to the `reflexive-property` incorrectly using `auto` instead of the default `16px` for the start side. The `auto` value accidentally overrides the already-set `16px` horizontal padding resulting in no side padding at the start. Fixes #7024.
1 parent a32fa24 commit 3c5bb80

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

packages/mdc-list/_evolution-mixins.scss

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -696,8 +696,7 @@
696696
@include feature-targeting.targets($feat-structure) {
697697
// Extra specificity needed to override default customizations.
698698
&.mdc-list-item {
699-
// We rely on auto to avoid clobbering the opposite padding.
700-
@include rtl-mixins.reflexive-property(padding, 0, auto);
699+
@include rtl-mixins.reflexive-property(padding, 0, 16px);
701700
}
702701

703702
.mdc-list-item__start {
@@ -715,8 +714,7 @@
715714
@include feature-targeting.targets($feat-structure) {
716715
// Extra specificity needed to override default customizations.
717716
&.mdc-list-item {
718-
// We rely on auto to avoid clobbering the opposite padding.
719-
@include rtl-mixins.reflexive-property(padding, auto, 0);
717+
@include rtl-mixins.reflexive-property(padding, 16px, 0);
720718
}
721719

722720
.mdc-list-item__end {

0 commit comments

Comments
 (0)