RTL settings clickable list item fix (#12595)

This commit is contained in:
Yosi Levy 2022-05-10 17:57:18 +03:00 committed by GitHub
parent 8d3132fefc
commit b295bbd706
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 4 deletions

View File

@ -47,10 +47,6 @@ export class HaClickableListItem extends ListItemBase {
padding-left: 0px;
padding-right: 0px;
}
:host([rtl]) span {
margin-left: var(--mdc-list-item-graphic-margin, 20px) !important;
margin-right: 0px !important;
}
:host([graphic="avatar"]:not([twoLine])),
:host([graphic="icon"]:not([twoLine])) {
height: 48px;
@ -64,6 +60,16 @@ export class HaClickableListItem extends ListItemBase {
padding-right: var(--mdc-list-side-padding, 20px);
overflow: hidden;
}
:host-context([style*="direction: rtl;"])
span.material-icons:first-of-type {
margin-left: var(--mdc-list-item-graphic-margin, 16px) !important;
margin-right: 0px !important;
}
:host-context([style*="direction: rtl;"])
span.material-icons:last-of-type {
margin-left: 0px !important;
margin-right: auto !important;
}
`,
];
}