Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Tweak timeline card layout (#7743)
Browse files Browse the repository at this point in the history
  • Loading branch information
jryans authored Feb 8, 2022
1 parent 76cafb7 commit 81f2b19
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 5 deletions.
33 changes: 30 additions & 3 deletions res/css/views/right_panel/_TimelineCard.scss
Original file line number Diff line number Diff line change
Expand Up @@ -28,31 +28,43 @@ limitations under the License.

.mx_BaseCard_header {
margin: 5px 0 9px 0;

.mx_BaseCard_close {
margin: 8px;
right: 0;
}
}

.mx_AutoHideScrollbar {
padding-right: 10px;
width: calc(100% - 10px);
}

// Style to optimize the layout for the right panel area
.mx_NewRoomIntro {
margin-left: 36px;
}

.mx_EventTile_content {
margin-right: 0;
}

.mx_EventTile:not([data-layout="bubble"]) .mx_EventTile_line {
padding-left: 36px;
padding-right: 36px;
}

.mx_EventTile:not([data-layout="bubble"]) .mx_ReactionsRow {
padding-left: 36px;
padding-right: 36px;
}

.mx_GroupLayout .mx_EventTile > .mx_SenderProfile {
margin-left: 36px;
}

.mx_EventTile:not([data-layout="bubble"]) .mx_EventTile_avatar {
top: 12px;
left: 0px;
left: -3px;
}

.mx_CallEvent_wrapper {
Expand All @@ -62,6 +74,7 @@ limitations under the License.
margin: 4px;
}
}

.mx_EventTile:not([data-layout="bubble"]) .mx_MessageTimestamp {
right: -4px;
left: auto;
Expand All @@ -70,18 +83,32 @@ limitations under the License.
.mx_EventTile:not([data-layout="bubble"]) .mx_EventTile_msgOption {
margin-right: 2px;
}

.mx_EventListSummary:not([data-layout=bubble]) .mx_EventTile_line {
padding-left: 36px;
}

.mx_GroupLayout .mx_EventTile .mx_EventTile_line {
padding-bottom: 8px;
}

.mx_EventTile_readAvatars {
top: -10px;
}

// mx_EventTile_info
.mx_EventTile:not([data-layout="bubble"]).mx_EventTile_info .mx_EventTile_line {
padding-left: 36px;
}

.mx_EventTile:not([data-layout="bubble"]).mx_EventTile_info .mx_EventTile_avatar {
left: 18px;
}

.mx_WhoIsTypingTile {
margin-left: -12px; // undo padding on the message list
}

.mx_WhoIsTypingTile_avatars {
flex-basis: 48px; // 12 (padding on message list) + 36 (padding on event lines)
}
}
2 changes: 1 addition & 1 deletion res/css/views/rooms/_EventTile.scss
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ $left-gutter: 64px;
}

.mx_EventListSummary:not([data-layout=bubble]) .mx_EventTile_line {
padding-left: calc($left-gutter);
padding-left: $left-gutter;
}

/* all the overflow-y: hidden; are to trap Zalgos -
Expand Down
2 changes: 1 addition & 1 deletion res/css/views/rooms/_WhoIsTypingTile.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ limitations under the License.

/* position the indicator in the same place horizontally as .mx_EventTile_avatar. */
.mx_WhoIsTypingTile_avatars {
flex: 0 0 83px; // 18 + 65
flex: 0 0 82px; // 18 (padding on message list) + 64 (padding on event lines)
text-align: center;
}

Expand Down

0 comments on commit 81f2b19

Please sign in to comment.