[gnome-shell] theme: Define default user-icon sizing in SASS
- From: Marge Bot <marge-bot src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] theme: Define default user-icon sizing in SASS
- Date: Thu, 17 Dec 2020 20:49:59 +0000 (UTC)
commit 6b9f2770814318076c03badedf08012b9e533ce7
Author: Joonas Henriksson <joonas henriksson gmail com>
Date: Sun Nov 1 10:55:45 2020 +0200
theme: Define default user-icon sizing in SASS
The default sizing for user-icon style was not defined in the theme,
but it simply used the default Avatar iconSize from UserWidget.js.
This didn't work with the current fallback avatar styling (i.e. when
the avatar icon is not set for an user account, and a symbolic icon
is displayed in its place), as the fallback StIcon was not scaled
to align inside the circle shaped user-icon properly.
Define the user-icon and corrected fallback StIcon sizes in the
stylesheet to correct this. The default 64px user-icon size is based
on default UserWidget.Avatar iconSize. The sizing for the StIcon is
taken from `.user-widget.horizontal .user-icon` styling, which uses
the same base icon-size.
Additionally, the special `.user-widget.horizontal .user-icon`
styling is removed, as it is now redundant.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1490>
data/theme/gnome-shell-sass/widgets/_misc.scss | 12 +++---------
1 file changed, 3 insertions(+), 9 deletions(-)
---
diff --git a/data/theme/gnome-shell-sass/widgets/_misc.scss b/data/theme/gnome-shell-sass/widgets/_misc.scss
index 96dd4d1dd7..b2f22fc71a 100644
--- a/data/theme/gnome-shell-sass/widgets/_misc.scss
+++ b/data/theme/gnome-shell-sass/widgets/_misc.scss
@@ -10,6 +10,7 @@
color: $osd_fg_color;
border-radius: 99px;
border: 2px $osd_fg_color;
+ icon-size: $base_icon_size * 4; // 64px
&:hover {
color: lighten($osd_fg_color,30%);
}
@@ -17,6 +18,8 @@
& StIcon {
background-color: transparentize($osd_fg_color,0.95);
border-radius: 99px;
+ padding: $base_padding * 2 ; // 12px
+ width: $base_icon_size * 2.5; height: $base_icon_size * 2.5; // 40px;
}
}
@@ -31,15 +34,6 @@
}
}
-.user-widget.horizontal .user-icon {
- icon-size: $base_icon_size * 4; // 64px
-
- & StIcon {
- padding: $base_padding * 2 ; // 12px
- width: $base_icon_size * 2.5; height: $base_icon_size * 2.5; // 40px;
- }
-}
-
.lightbox { background-color: black; }
.flashspot { background-color: white; }
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]