[libadwaita/wip/exalm/oapcity: 13/14] stylesheet: Use smaller opacity for disabled flat buttons
- From: Alexander Mikhaylenko <alexm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libadwaita/wip/exalm/oapcity: 13/14] stylesheet: Use smaller opacity for disabled flat buttons
- Date: Mon, 25 Oct 2021 13:03:40 +0000 (UTC)
commit 81f71fc230c70aa7bcb1573b6d13fc22117dc92b
Author: Alexander Mikhaylenko <alexm gnome org>
Date: Fri Oct 22 12:21:10 2021 +0500
stylesheet: Use smaller opacity for disabled flat buttons
They are hard to tell apart from regular atm. Since they have either icons
with 2px strokes or bold text, and nothing else, they need to be more
transparent than others.
src/stylesheet/_colors.scss | 1 +
src/stylesheet/widgets/_buttons.scss | 4 ++++
2 files changed, 5 insertions(+)
---
diff --git a/src/stylesheet/_colors.scss b/src/stylesheet/_colors.scss
index 7616f13a..a4843f61 100644
--- a/src/stylesheet/_colors.scss
+++ b/src/stylesheet/_colors.scss
@@ -82,6 +82,7 @@ $focus_border_color: gtkalpha($accent_bg_color, $focus_border_opacity);
$dim_label_opacity: 0.55;
$dimmer_opacity: 0.3;
$disabled_opacity: 0.5;
+$strong_disabled_opacity: 0.3;
// High Contrast color overrides
@if $contrast == 'high' {
diff --git a/src/stylesheet/widgets/_buttons.scss b/src/stylesheet/widgets/_buttons.scss
index 66e67f95..06cebdae 100644
--- a/src/stylesheet/widgets/_buttons.scss
+++ b/src/stylesheet/widgets/_buttons.scss
@@ -233,6 +233,10 @@ button {
}
}
+ &:disabled:not(:checked) {
+ filter: opacity($strong_disabled_opacity);
+ }
+
&.suggested-action {
color: $accent_color;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]