[libadwaita/wip/exalm/hc] stylesheet: Add missing borders in hc
- From: Alexander Mikhaylenko <alexm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libadwaita/wip/exalm/hc] stylesheet: Add missing borders in hc
- Date: Sat, 11 Jun 2022 20:00:20 +0000 (UTC)
commit 4e2e3322a15c7db5fbc51510e60ff0011815a927
Author: Alexander Mikhaylenko <alexm gnome org>
Date: Sat Jun 11 23:58:57 2022 +0400
stylesheet: Add missing borders in hc
- Menus
- Sidebars
- Emoji picker
- Emoji completion
- GtkAssistant sidebar
- GtkGridView, GtkFlowBox, GtkIconView
Fixes https://gitlab.gnome.org/GNOME/libadwaita/-/issues/492
src/stylesheet/widgets/_dialogs.scss | 4 ++++
src/stylesheet/widgets/_emoji-chooser.scss | 16 ++++++++++++++++
src/stylesheet/widgets/_menus.scss | 20 ++++++++++++++++++++
src/stylesheet/widgets/_sidebars.scss | 9 +++++++++
src/stylesheet/widgets/_views.scss | 16 ++++++++++++++++
5 files changed, 65 insertions(+)
---
diff --git a/src/stylesheet/widgets/_dialogs.scss b/src/stylesheet/widgets/_dialogs.scss
index c854ca6c..b955d1ab 100644
--- a/src/stylesheet/widgets/_dialogs.scss
+++ b/src/stylesheet/widgets/_dialogs.scss
@@ -38,6 +38,10 @@ window.assistant {
&.highlight {
background-color: $view_selected_color;
+
+ @if $contrast == 'high' {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
}
}
}
diff --git a/src/stylesheet/widgets/_emoji-chooser.scss b/src/stylesheet/widgets/_emoji-chooser.scss
index cfdae27c..29ced4a9 100644
--- a/src/stylesheet/widgets/_emoji-chooser.scss
+++ b/src/stylesheet/widgets/_emoji-chooser.scss
@@ -33,6 +33,14 @@ popover.emoji-picker emoji {
&:active {
background: $view_active_color;
}
+
+ @if $contrast == 'high' {
+ &:focus,
+ &:hover,
+ &:active {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
}
popover.emoji-picker scrolledwindow.view {
@@ -77,4 +85,12 @@ emoji-completion-row {
&:active {
background-color: $view_active_color; // matching buttons
}
+
+ @if $contrast == 'high' {
+ &:focus,
+ &:hover,
+ &:active {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
}
diff --git a/src/stylesheet/widgets/_menus.scss b/src/stylesheet/widgets/_menus.scss
index fa518e40..4f1bb388 100644
--- a/src/stylesheet/widgets/_menus.scss
+++ b/src/stylesheet/widgets/_menus.scss
@@ -136,6 +136,14 @@ popover.menu {
background-color: $view_selected_active_color; // matching buttons
}
+ @if $contrast == 'high' {
+ &:hover,
+ &:selected,
+ &:active {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
+
arrow {
background: none;
min-width: 16px;
@@ -191,6 +199,14 @@ popover.menu {
}
}
+ @if $contrast == 'high' {
+ &:hover,
+ &:active,
+ &.has-open-popup {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
+
> box {
border-spacing: 6px;
}
@@ -225,6 +241,10 @@ menubar {
&:selected { //Seems like it :hover even with keyboard focus
background-color: $view_selected_color;
+
+ @if $contrast == 'high' {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
}
//nested submenus
diff --git a/src/stylesheet/widgets/_sidebars.scss b/src/stylesheet/widgets/_sidebars.scss
index cb9f0f37..12285341 100644
--- a/src/stylesheet/widgets/_sidebars.scss
+++ b/src/stylesheet/widgets/_sidebars.scss
@@ -69,6 +69,15 @@ separator.sidebar {
padding: 0 8px;
border-radius: $menu_radius;
margin: 0 $menu_margin 2px;
+
+ @if $contrast == 'high' {
+ &.activatable:hover,
+ &.activatable:active,
+ &.activatable.has-open-popup,
+ &:selected {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
}
}
diff --git a/src/stylesheet/widgets/_views.scss b/src/stylesheet/widgets/_views.scss
index e5bb1709..caded1ea 100644
--- a/src/stylesheet/widgets/_views.scss
+++ b/src/stylesheet/widgets/_views.scss
@@ -38,6 +38,12 @@ textview {
iconview {
@extend %view;
+ @if $contrast == 'high' {
+ &:selected {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
+
@include focus-ring();
&:drop(active) {
@@ -66,6 +72,10 @@ gridview > child {
&:selected {
background-color: $view_selected_color;
+
+ @if $contrast == 'high' {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
}
}
@@ -79,4 +89,10 @@ gridview > child.activatable {
&:active { background-color: $view_selected_active_color; }
}
+
+ @if $contrast == 'high' {
+ &:hover, &:active {
+ box-shadow: inset 0 0 0 1px $border_color;
+ }
+ }
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]