[gnome-shell/wip/snwh/style-updates] theme: button drawing adjustments
- From: Sam Hewitt <snwh src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/snwh/style-updates] theme: button drawing adjustments
- Date: Thu, 30 Dec 2021 19:26:18 +0000 (UTC)
commit b1b9bfa37f68b5a98e64c00e63f44d8d20385ba7
Author: Sam Hewitt <sam snwh org>
Date: Thu Dec 30 15:56:12 2021 -0330
theme: button drawing adjustments
data/theme/gnome-shell-sass/_common.scss | 35 ++++++++++++++++++++--
data/theme/gnome-shell-sass/_drawing.scss | 9 +++---
.../gnome-shell-sass/widgets/_notifications.scss | 2 +-
3 files changed, 38 insertions(+), 8 deletions(-)
---
diff --git a/data/theme/gnome-shell-sass/_common.scss b/data/theme/gnome-shell-sass/_common.scss
index 8f2ae3e483..4176fc2d4b 100644
--- a/data/theme/gnome-shell-sass/_common.scss
+++ b/data/theme/gnome-shell-sass/_common.scss
@@ -133,18 +133,47 @@ stage {
&:hover { @include button(hover, $shadow: none); }
&:active { @include button(active, $shadow: none); }
+ // radius is 7 pixel less to fit in bubble
+ &:first-child {
+ border-radius: 0 0 0 $modal_radius - 7px;
+ }
+
+ &:last-child {
+ border-right-width: 0;
+ border-radius: 0 0 $modal_radius - 7px 0;
+ }
+
+ &:first-child:last-child {
+ border-radius: 0 0 $modal_radius - 7px $modal_radius - 7px;
+ }
+}
+
+// buttons in notifications
+%notification_button {
+ @include button(normal, $shadow: none);
+ padding: $base_padding * 2;
+ border-style: solid;
+ border-width: 1px;
+ border-left-width: 0;
+ border-bottom-width: 0;
+
+ &:insensitive { @include button(insensitive, $shadow: none); }
+ &:focus { @include button(focus, $shadow: none); }
+ &:hover { @include button(hover, $shadow: none); }
+ &:active { @include button(active, $shadow: none); }
+
// radius is 2 pixel less to fit in bubble
&:first-child {
- border-radius: 0 0 0 $modal_radius - 2px;
+ border-radius: 0 0 0 $base_border_radius - 3px;
}
&:last-child {
border-right-width: 0;
- border-radius: 0 0 $modal_radius - 2px 0;
+ border-radius: 0 0 $base_border_radius - 3px 0;
}
&:first-child:last-child {
- border-radius: 0 0 $modal_radius - 2px $modal_radius - 2px;
+ border-radius: 0 0 $base_border_radius - 3px $base_border_radius - 3px;
}
}
diff --git a/data/theme/gnome-shell-sass/_drawing.scss b/data/theme/gnome-shell-sass/_drawing.scss
index c89dd76ad5..806fcba78d 100644
--- a/data/theme/gnome-shell-sass/_drawing.scss
+++ b/data/theme/gnome-shell-sass/_drawing.scss
@@ -138,11 +138,12 @@
@if $t==normal {
color: $tc;
background-color: lighten($c, 3%);
- border-color: draw_border_color($c);
+ border-color: lighten($c, 3%);
@include draw_shadows($button_shadow);
// box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
text-shadow: 0 1px $text_shadow_color;
icon-shadow: 0 1px $text_shadow_color;
+ border-radius: $base_border_radius - 2px;
}
// focused button
@@ -158,7 +159,7 @@
@else if $t==hover {
color: $tc;
background-color: lighten($c, if($variant == 'light', 8%, 5%));
- border-color: if($variant == 'light', draw_border_color(lighten($c, 7%)), draw_border_color($c));
+ border-color: lighten($c, if($variant == 'light', 8%, 5%));
@include draw_shadows($button_shadow);
text-shadow: 0 1px $text_shadow_color;
icon-shadow: 0 1px $text_shadow_color;
@@ -168,7 +169,7 @@
@else if $t==active {
color: $tc;
background-color: darken($c,3%);
- border-color: draw_border_color(if($variant == 'light', $c, darken($c,7%)));
+ border-color: darken($c,3%);
text-shadow: none;
icon-shadow: none;
box-shadow: none;
@@ -177,7 +178,7 @@
// insensitive button
@else if $t==insensitive {
color: $insensitive_fg_color;
- border-color: $insensitive_borders_color;
+ border-color: $insensitive_bg_color;
background-color: $insensitive_bg_color;
box-shadow: none;
text-shadow: none;
diff --git a/data/theme/gnome-shell-sass/widgets/_notifications.scss
b/data/theme/gnome-shell-sass/widgets/_notifications.scss
index 5ff46a0586..78db9c281c 100644
--- a/data/theme/gnome-shell-sass/widgets/_notifications.scss
+++ b/data/theme/gnome-shell-sass/widgets/_notifications.scss
@@ -13,7 +13,7 @@ $notification_banner_width: 34em;
}
.notification-button {
- @extend %bubble_button;
+ @extend %notification_button;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]