]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/stylesheets/common.scss
Merge remote-tracking branch 'upstream/pull/4690'
[rails.git] / app / assets / stylesheets / common.scss
index ed79a7cec0d06ffb968d83887294508bc90e6b5a..931d10c8aba5f6fdb74b42310ca59bd941fb93a5 100644 (file)
@@ -81,10 +81,15 @@ time[title] {
   opacity: 0.6;
 }
 
+@include color-mode(dark) {
+  #menu-icon {
+    filter: invert(1);
+  }
+}
+
 header {
   height: $headerHeight;
   position: relative;
-  z-index: 1001;
   font-size: 14px;
 
   h1, nav, nav > ul, nav > ul > li {
@@ -188,7 +193,6 @@ body.small-nav {
     flex-direction: column;
     height: auto;
     min-height: $headerHeight;
-    background: #fff;
 
     &.closed nav {
       display: none;
@@ -324,7 +328,6 @@ body.small-nav {
 
   .overlay-sidebar #sidebar {
     position: absolute;
-    z-index: 1000;
     height: auto;
     overflow: hidden;
 
@@ -378,11 +381,6 @@ body.small-nav {
     width: 250px;
     height: 100%;
     overflow: auto;
-
-    .section {
-      border-bottom: 1px solid $grey;
-      padding: $spacer;
-    }
   }
 }
 
@@ -396,7 +394,6 @@ body.small-nav {
     }
 
     #map-ui {
-      z-index: 9999;
       width: 100%;
       height: 50%;
       overflow-y: scroll;
@@ -418,43 +415,14 @@ body.small-nav {
 }
 
 .layers-ui {
-  .base-layers {
-    .leaflet-container {
-      width: 100%;
-      height: 50px;
-      cursor: pointer;
-    }
-
-    li  {
-      overflow: hidden;
-      border-radius: 3px;
-      border: 2px solid transparent;
-      margin-bottom: 8px;
-      position: relative;
-      transition: border-color 0.08s ease-in;
+  .base-layers > * {
+    height: 56px;
 
-      label {
-        position: absolute;
-        top: 0;
-        left: 0;
-        padding: 2px 6px;
-        border-bottom-right-radius: 3px;
-        cursor: pointer;
-        font-weight: 600;
-        font-size: 16px;
-        background-color: var(--bs-body-bg);
-        opacity: 0.9;
-        z-index: 1000;
-        input[type="radio"] {
-          display: none;
-        }
-      }
-
-      &.active { border-color: darken($green, 10%); }
-      &:hover {
-        border-color: $grey;
-        &.active { border-color: darken($green, 20%); }
-      }
+    > .btn {
+      --bs-btn-border-color: var(--bs-body-bg);
+    }
+    > .btn:hover {
+      --bs-btn-border-color: var(--bs-primary-border-subtle);
     }
   }
 
@@ -545,6 +513,12 @@ header .search_forms,
   display: none;
 }
 
+.search_form {
+  .describe_location {
+    font-size: 10px;
+  }
+}
+
 /* Rules for search sidebar */
 
 #sidebar .search_results_entry {
@@ -569,6 +543,12 @@ div.direction {
 div.direction.i#{$i} { background-position: #{($i)*-20}px 0px; }
 }
 
+@include color-mode(dark) {
+  div.direction {
+    filter: invert(1);
+  }
+}
+
 td.distance {
     font-size: x-small;
 }
@@ -828,25 +808,11 @@ tr.turn:hover {
 /* Rules for messages pages */
 
 .messages {
-  .inbox-row {
-    background: $offwhite;
-  }
-
   .inbox-row-unread td {
     background: #CBEEA7;
   }
 }
 
-.search_form {
-  #query {
-    z-index: 0;
-  }
-
-  .describe_location {
-    font-size: 10px;
-  }
-}
-
 /* Rules for user images */
 
 img.user_image {
@@ -895,8 +861,7 @@ div.secondary-actions {
 
 /* Rules for rich text */
 
-.richtext,
-.prose {
+.richtext {
   code {
     background: var(--bs-secondary-bg);
     padding: 2px 3px;
@@ -981,8 +946,6 @@ div.secondary-actions {
 }
 
 .site-about #content {
-  background-color: $lightgrey;
-
   .content-inner {
     max-width: 760px;
   }
@@ -1056,4 +1019,17 @@ div.secondary-actions {
   margin-bottom: -1px;
 }
 
+/* Rules for traces */
+
+img.trace_image {
+  mix-blend-mode: darken;
+}
+
+@include color-mode(dark) {
+  img.trace_image {
+    filter: invert(1);
+    mix-blend-mode: lighten;
+  }
+}
+
 @import 'browse';