[gnome-software/wip/exalm/style-cleanups: 14/25] style: Clean up review styles




commit cfa49f3a4d9d68719d49624c84891b986f8b1a2b
Author: Alexander Mikhaylenko <alexm gnome org>
Date:   Tue Nov 9 19:39:35 2021 +0500

    style: Clean up review styles
    
    Remove redundant style classes, fix the separator between Yes and No
    buttons. Fix histogram colors in dark.

 src/gs-details-page.ui |  2 +-
 src/gs-review-row.ui   |  2 +-
 src/gtk-style-hc.css   |  5 +++++
 src/gtk-style.css      | 29 ++++++++++++-----------------
 4 files changed, 19 insertions(+), 19 deletions(-)
---
diff --git a/src/gs-details-page.ui b/src/gs-details-page.ui
index a352d1503..3c0079dd1 100644
--- a/src/gs-details-page.ui
+++ b/src/gs-details-page.ui
@@ -846,7 +846,7 @@
                                         <property name="selection_mode">none</property>
                                         <property name="valign">start</property>
                                         <style>
-                                          <class name="review-listbox"/>
+                                          <class name="background"/>
                                         </style>
                                       </object>
                                     </child>
diff --git a/src/gs-review-row.ui b/src/gs-review-row.ui
index d75522e10..99d9b246e 100644
--- a/src/gs-review-row.ui
+++ b/src/gs-review-row.ui
@@ -31,7 +31,7 @@
                 <property name="hexpand">True</property>
                 <property name="selectable">True</property>
                 <style>
-                  <class name="review-summary"/>
+                  <class name="heading"/>
                 </style>
               </object>
             </child>
diff --git a/src/gtk-style-hc.css b/src/gtk-style-hc.css
index 564ce912d..e718be12e 100644
--- a/src/gtk-style-hc.css
+++ b/src/gtk-style-hc.css
@@ -26,6 +26,11 @@
        border-color: #000000;
 }
 
+review-bar,
+.review-histogram star-image {
+       color: alpha(@theme_fg_color, .8);
+}
+
 star-image {
        color: #000000;
 }
diff --git a/src/gtk-style.css b/src/gtk-style.css
index 6a43a7eb7..0611e0bd9 100644
--- a/src/gtk-style.css
+++ b/src/gtk-style.css
@@ -203,37 +203,32 @@ clamp.large .category-tile:not(.category-tile-iconless) {
 
 .install-progress:dir(rtl) { background-position: 100% bottom; }
 
-.review-summary {
-       font-weight: bold;
-}
-
-.review-listbox {
-       all: unset;
-}
+.review-row button { font-size: smaller; }
 
-.review-row button, .review-row .button { font-size: smaller; }
-
-/* gtk+ 3.20+ only */
 .review-row .vote-buttons button {
        margin-right: -1px;
-
-       /* restricting transition properties since the hack for the separator*/
-       transition-property: background, box-shadow, border-style;
 }
 
 /* this is the separator between yes and no vote buttons, gtk+ 3.20 only */
-.review-row .vote-buttons button:not(:first-child):not(:hover):not(:active) {
+.review-row .vote-buttons button:not(:first-child) {
        border-image: linear-gradient(to top, @borders, @borders) 0 0 0 1 / 5px 0 5px 1px;
 }
 
+.review-row .vote-buttons button:hover,
+.review-row .vote-buttons button:active,
+.review-row .vote-buttons button:hover + button,
+.review-row .vote-buttons button:active + button {
+       border-image: none;
+}
+
 review-bar {
+       color: alpha(@theme_fg_color, .4);
        background-image: none;
-       background-color: @unfocused_insensitive_color;
-       color: @insensitive_fg_color;
+       background-color: alpha(currentColor, .5);
 }
 
 .review-histogram star-image {
-       color: @insensitive_fg_color;
+       color: alpha(@theme_fg_color, .4);
 }
 
 .version-arrow-label {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]