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

Commit

Permalink
Fix vertical alignment of default avatar font (#11582)
Browse files Browse the repository at this point in the history
(cherry picked from commit 0ee2eac)
  • Loading branch information
t3chguy authored and github-actions[bot] committed Sep 8, 2023
1 parent 708537d commit 04c5238
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
3 changes: 2 additions & 1 deletion res/css/views/avatars/_BaseAvatar.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ limitations under the License.
}

button.mx_BaseAvatar {
/* The user agent stylesheet overrides the font-size in this scenario
/* The user agent stylesheet overrides the font-size & line-height in this scenario
And that breaks the alignment, emojis, and all sorts of things
*/
font-size: inherit;
line-height: inherit;
}
10 changes: 10 additions & 0 deletions res/css/views/right_panel/_UserInfo.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,11 @@ limitations under the License.
margin: 0 auto;
transition: 0.5s;

.mx_BaseAvatar {
/* Override the calculated font-size so that the letter isn't tiny */
font-size: 4rem;
}

.mx_BaseAvatar,
.mx_BaseAvatar img {
width: 100%;
Expand Down Expand Up @@ -250,6 +255,11 @@ limitations under the License.
max-width: 72px;
margin: 0 auto;
}

.mx_BaseAvatar {
/* Override the calculated font-size so that the letter isn't tiny */
font-size: 2rem;
}
}
}
}

0 comments on commit 04c5238

Please sign in to comment.