improve dirListing design
authorRobert Kaiser <kairo@kairo.at>
Sun, 31 May 2015 18:52:31 +0000 (20:52 +0200)
committerRobert Kaiser <kairo@kairo.at>
Sun, 31 May 2015 18:52:31 +0000 (20:52 +0200)
LCARStrek/global/dirListing/dirListing.css
LCARStrek/global/dirListing/up-hover.png [new file with mode: 0644]
LCARStrek/global/in-content/check.svg [new file with mode: 0644]
LCARStrek/global/in-content/common.css

index ee4e1ddbe9dbaa88b6cabf3706f685bf8917c235..c3851e844e7460a3d421a24f56a9d3d380a2484e 100644 (file)
@@ -2,6 +2,8 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
+@import url('chrome://global/skin/in-content/common.css');
+
 :root {
   background-color: #000000;
   color: #FF9F00;
@@ -30,10 +32,14 @@ h1 {
 
 a {
   text-decoration: none;
+  color: #3333FF;
 }
 
-a:hover {
-  background-color: #FFCF00;
+td > a:visited {
+  color: #8050B0;
+}
+
+body > table > tbody > tr:hover a {
   color: #000000;
 }
 
@@ -46,6 +52,13 @@ p {
   float: left;
 }
 
+#UI_goUp:hover {
+  background-color: #FFCF00;
+}
+#UI_goUp:hover > a {
+  color: #000000;
+}
+
 #UI_goUp:-moz-dir(rtl) {
   float: right;
 }
@@ -59,6 +72,15 @@ p {
   float: left;
 }
 
+/* HACK: as the checkbox is inside the label, we need to leave the ugle native checkbox */
+#UI_showHidden > label > input[type="checkbox"] {
+  opacity: 1;
+  position: static;
+}
+#UI_showHidden > label:hover {
+  color: #FFCF00;
+}
+
 table {
   clear: both;
   width: 90%;
@@ -74,14 +96,17 @@ th:first-child {
   text-align: center !important;
 }
 
-th:hover > a {
+th:hover {
   background-color: #FFCF00;
+}
+
+th:hover > a {
   color: #000000;
 }
 
 body > table > tbody > tr:hover {
-  outline: 1px solid #008484;
-  -moz-outline-radius: .3em;
+  background-color: #FFCF00;
+  color: #000000;
 }
 
 /* let 'Size' and 'Last Modified' take only as much space as they need and 'Name' all the rest */
@@ -100,3 +125,7 @@ td:not(:first-child) {
   vertical-align: middle;
   content: url("chrome://global/skin/dirListing/up.png");
 }
+
+#UI_goUp:hover > .up::before {
+  content: url("chrome://global/skin/dirListing/up-hover.png");
+}
diff --git a/LCARStrek/global/dirListing/up-hover.png b/LCARStrek/global/dirListing/up-hover.png
new file mode 100644 (file)
index 0000000..2146432
Binary files /dev/null and b/LCARStrek/global/dirListing/up-hover.png differ
diff --git a/LCARStrek/global/in-content/check.svg b/LCARStrek/global/in-content/check.svg
new file mode 100644 (file)
index 0000000..b05b1d1
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- This Source Code Form is subject to the terms of the Mozilla Public
+   - License, v. 2.0. If a copy of the MPL was not distributed with this
+   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="21" height="21" viewBox="0 0 21 21">
+  <style>
+    use:not(:target) {
+      display: none;
+    }
+    use {
+      fill: #FF9F00;
+    }
+    use[id$="-inverted"] {
+      fill: #FFCF00;
+      stroke: #000000;
+      stroke-width: 0.5;
+    }
+    use[id$="-native"] {
+      fill: #FF9F00;
+    }
+    use[id$="-hover"] {
+      fill: #FFCF00;
+    }
+    use[id$="-disabled"] {
+      fill: #8050B0;
+    }
+  </style>
+  <defs>
+    <path id="check-shape" d="M 9.39,16.5 16.28,6 14.77,4.5 9.37,12.7 6.28,9.2 4.7,10.7 z"/>
+  </defs>
+  <use id="check" xlink:href="#check-shape"/>
+  <use id="check-inverted" xlink:href="#check-shape"/>
+  <use id="check-native" xlink:href="#check-shape"/>
+</svg>
index 4643c06626dc907f3a980a4bca8a377fb5785e7e..a7fda135efbc3aa46ed0a69d98d5a0955b8de98e 100644 (file)
@@ -415,14 +415,13 @@ html|a:hover:active,
 }
 
 /* Checkboxes and radio buttons */
-/*
-/ Hide the actual checkbox /
+/* Hide the actual checkbox */
 html|input[type="checkbox"] {
   opacity: 0;
   position: absolute;
 }
 
-/ Create a box to style as the checkbox /
+/* Create a box to style as the checkbox */
 html|input[type="checkbox"] + html|label:before {
   display: inline-block;
   content: "";
@@ -432,47 +431,56 @@ html|input[type="checkbox"] + html|label:before {
 html|input[type="checkbox"] + html|label {
   line-height: 0px;
 }
-
+/*
 xul|checkbox {
   -moz-margin-start: 0;
 }
-
-xul|*.checkbox-check,
+*/
+/* xul|*.checkbox-check, */
 html|input[type="checkbox"] + html|label:before {
   -moz-appearance: none;
   width: 23px;
   height: 23px;
-  border-radius: 2px;
-  border: 1px solid #c1c1c1;
+  border-radius: 0;
+  border: 1px solid #FF9F00;
   -moz-margin-end: 10px;
-  background-color: #f1f1f1;
-  / !important needed to override toolkit checked !important rule /
-  background-image: linear-gradient(#fff, rgba(255,255,255,0.8)) !important;
+  background-color: #000000;
   background-position: center center;
   background-repeat: no-repeat;
-  box-shadow: 0 1px 1px 0 #fff, inset 0 2px 0 0 rgba(0,0,0,0.03);
 }
 
-xul|checkbox:not([disabled="true"]):hover > xul|*.checkbox-check,
+/* xul|checkbox:not([disabled="true"]):hover > xul|*.checkbox-check, */
 html|input[type="checkbox"]:not(:disabled) + html|label:hover:before {
-  border-color: #0095dd;
+  border-color: #FFCF00;
 }
-
+html|input[type="checkbox"]:not(:disabled) + html|label:hover {
+  color: #FFCF00;
+}
+/*
 xul|*.checkbox-check[checked] {
   background-image: url("chrome://global/skin/in-content/check.png"),
                     / * !important needed to override toolkit !important rule * /
                     linear-gradient(#fff, rgba(255,255,255,0.8)) !important;
 }
-
+*/
 html|input[type="checkbox"]:checked + html|label:before {
-  background-image: url("chrome://global/skin/in-content/check.svg#check"), linear-gradient(#fff, rgba(255,255,255,0.8)) !important;
+  background-image: url("chrome://global/skin/in-content/check.svg#check");
 }
 
-xul|checkbox[disabled="true"] > xul|*.checkbox-check,
+/*xul|checkbox[checked][disabled="true"] > xul|*.checkbox-check,*/
+html|input[type="checkbox"]:checked:disabled + html|label:before {
+  background-image: url("chrome://global/skin/in-content/check.svg#check-disabled");
+}
+html|input[type="checkbox"]:not(:disabled) + html|label:hover:before {
+  background-image: url("chrome://global/skin/in-content/check.svg#check-hover");
+}
+html|input[type="checkbox"]:disabled + html|label:before {
+  border-color: #8050B0;
+}
 html|input[type="checkbox"]:disabled + html|label {
-  opacity: 0.5;
+  color: #8050B0;
 }
-
+/*
 xul|*.checkbox-label-box {
   -moz-margin-start: -1px; / * negative margin for the transparent border * /
   -moz-padding-start: 0;