]> git.openstreetmap.org Git - rails.git/commitdiff
Add dark mode overrides for Bootstrap table variants
authorAnton Khorev <tony29@yandex.ru>
Sun, 14 Apr 2024 14:47:44 +0000 (17:47 +0300)
committerAnton Khorev <tony29@yandex.ru>
Sun, 14 Apr 2024 14:47:44 +0000 (17:47 +0300)
app/assets/stylesheets/common.scss

index 629d26a814be9bf633c582fbdd8dec12c99d47b4..ec91b281884a12e2cf108c598381b0932c574722 100644 (file)
@@ -66,6 +66,21 @@ time[title] {
   color: $blue;
 }
 
+/* Bootstrap contextual table classes overrides in dark mode */
+
+@include color-mode(dark) {
+  .table-primary {
+    --bs-table-bg: rgb(var(--bs-primary-rgb), .25);
+  }
+  .table-secondary {
+    --bs-table-bg: rgb(var(--bs-secondary-rgb), .25);
+  }
+  .table-primary, .table-secondary {
+    --bs-table-color: initial;
+    border-color: inherit;
+  }
+}
+
 /* Rules for the header */
 
 #menu-icon {