Fix MessageTimestamp position next to redacted messages on IRC/modern layout (#8591)

This commit is contained in:
Suguru Hirahara 2022-05-14 07:55:52 +00:00 committed by GitHub
parent e6ec01fe86
commit f54d54b3ff
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 2 deletions

View file

@ -20,6 +20,7 @@ limitations under the License.
font-size: $font-12px; font-size: $font-12px;
width: 100%; width: 100%;
overflow-x: auto; // Cancel overflow setting of .mx_EventTile_content overflow-x: auto; // Cancel overflow setting of .mx_EventTile_content
line-height: normal; // Align with avatar and E2E icon
pre, pre,
code { code {

View file

@ -258,8 +258,12 @@ limitations under the License.
} }
&:not([data-layout=bubble]) { &:not([data-layout=bubble]) {
.mx_MessageTimestamp {
top: 2px; // Align with avatar
}
.mx_EventTile_avatar { .mx_EventTile_avatar {
top: 1.5px; top: 0; // Align with hidden event content
left: calc($MessageTimestamp_width + 14px - 4px); // 14px: avatar width, 4px: align with text left: calc($MessageTimestamp_width + 14px - 4px); // 14px: avatar width, 4px: align with text
z-index: 9; // position above the hover styling z-index: 9; // position above the hover styling
} }

View file

@ -116,6 +116,10 @@ $threadInfoLineHeight: calc(2 * $font-12px); // See: _commons.scss
.mx_EventTile_line { .mx_EventTile_line {
padding: 3px 0 2px; // Align with mx_EventTile_avatar and mx_EventTile_e2eIcon padding: 3px 0 2px; // Align with mx_EventTile_avatar and mx_EventTile_e2eIcon
.mx_MessageTimestamp {
top: 0;
}
} }
} }
@ -278,7 +282,6 @@ $threadInfoLineHeight: calc(2 * $font-12px); // See: _commons.scss
.mx_GenericEventListSummary:not([data-layout=bubble]) { .mx_GenericEventListSummary:not([data-layout=bubble]) {
.mx_EventTile_line { .mx_EventTile_line {
padding-left: $left-gutter; padding-left: $left-gutter;
line-height: normal;
.mx_RedactedBody { .mx_RedactedBody {
line-height: 1; // remove spacing between lines line-height: 1; // remove spacing between lines