]> git.draconx.ca Git - homepage.git/blobdiff - content/style.scss
Use special SCSS comments for source and copyright info.
[homepage.git] / content / style.scss
index 524077925c5f788c62a9b0972764b65cfc2c3b64..dd666c009fa671761d214e2a3c79170c65d4e64b 100644 (file)
@@ -1,4 +1,4 @@
-/*
+/*!
  * Nick's web site: default stylesheet
  *
  * Copyright © 2018-2021 Nick Bowler
@@ -240,7 +240,7 @@ $clickynames: name, date, size;
             }
         }
 
-        &:focus ~ table th.clicky-#{$col}>label~label>span {
+        &:focus ~ table th.clicky-#{$col}>label~label>span:first-child {
             border-color: $foregroundcolour;
         }
 
@@ -256,15 +256,15 @@ $clickynames: name, date, size;
         &:checked ~ table {
             // Update table header state
             & th.clicky-#{$col} {
-                img+img {
+                .svg+.svg {
                     display: -moz-inline-box !important;
                     display: inline-block !important;
                 }
-                img { display: none; }
+                .svg { display: none; }
             }
         }
 
-        &:focus ~ table th.clicky-#{$col}>label~label>img {
+        &:focus ~ table th.clicky-#{$col}>label~label .svg {
             border-color: $foregroundcolour;
         }
 
@@ -273,48 +273,60 @@ $clickynames: name, date, size;
         opacity: 0;
         z-index: -2;
     }
+}
 
-    th.clicky-#{$col}>label {
-        &, &>* {
-            white-space: nowrap;
-            vertical-align: middle;
-            display: -moz-inline-box;
-            display: inline-block;
-            cursor: pointer;
-        }
+thead.clicky label {
+    white-space: nowrap;
+    line-height: 1.5em;
+    cursor: pointer;
 
-        &>* { border: 1px dotted transparent; }
+    &>* {
+        display: -moz-inline-box;
+        display: inline-block;
+        border: 1px dotted transparent;
+        vertical-align: middle;
+    }
 
-        // Expand the first label a bit so the table (hopefully)
-        // does not reshape as columns are selected.
-        &:first-child {
-            margin-right: 1.75em;
-            padding-right: 2px;
-        }
+    // Expand the first label a bit so the table (hopefully)
+    // does not reshape as columns are selected.
+    &:first-child {
+        margin-right: 1.75em;
+        padding-right: 2px;
+    }
 
-        &:active { color: $linkactivecolour; }
-        &:first-child:active>span, &~label:active>img {
-            border-color: $linkactivecolour;
-        }
+    &:active { color: $linkactivecolour; }
+    &:first-child:active>span, &~label:active>.svg {
+        border-color: $linkactivecolour;
+    }
 
-        img {
-            margin-left: 0.25em;
-            width: 1.5em;
-            height: auto;
-        }
+    .svg {
+        margin-left: 0.25em;
     }
+
+    .svg, svg, img.svgfallback {
+        height: 1.5em;
+        width: auto;
+    }
+    .svg svg { width: 1.5em; }
 }
 
 table.filelist {
-    &>tr>*:first-child, &>*>tr>*:first-child {
-        &+td { min-width: 50%; }
-        width: 0;
+    &>*>tr>*:first-child {
+        &+* { width: 50%; }
+        // chrome doesn't like width: 0 for some reason
+        width: 0.1px;
     }
 
-    tbody img {
-        display: block;
-        height: 1.5em;
-        width: auto;
+    tbody {
+        .svg, svg, img.svgfallback {
+            height: 1.5em;
+            width: auto;
+        }
+
+        .svg {
+            svg { width: 1.5em; }
+            display: inline-block;
+        }
     }
 }
 
@@ -354,6 +366,8 @@ table.filelist {
 #footer p { color: $annotationcolour; }
 #article-info p { font-style: italic; }
 
+.wbr:after { content: "\200b"; }
+
 // "unordered" lists with explicit ordering in content
 ul.ordered > {
     li { list-style: none; }