[FFmpeg-devel] [PATCH 4/4] web/style.less: Separate out .table-bordered from .table

Timothy Gu timothygu99 at gmail.com
Fri Nov 7 03:55:56 CET 2014


The only instance of .table in the web source is the download page for the
Git repos. I did not change that page because an unbordered table there is
prettier IMO.

I retained the .table-bordered style in case anyone want to use it in the
future.

Signed-off-by: Timothy Gu <timothygu99 at gmail.com>
---
 src/less/style.less | 61 ++++++++++++++++++++++++++++++++++++++++++++++-------
 1 file changed, 53 insertions(+), 8 deletions(-)

diff --git a/src/less/style.less b/src/less/style.less
index c9ebdc8..ef1a3fc 100644
--- a/src/less/style.less
+++ b/src/less/style.less
@@ -244,19 +244,64 @@ code {
 .table {
     margin: 20px 0;
     border-radius: 4px;
-    th, td, tr {
-        border: 1px solid @Cmaindarkdark;
+    // Stripes
+    > tbody > tr:nth-child(odd) {
+        > td {
+            background-color: @Cmaindark;
+        }
+        > th {
+            background-color: @Cmain;
+        }
+    }
+    // Cells
+    > thead,
+    > tbody,
+    > tfoot {
+        > tr {
+            > th,
+            > td {
+                border-top: 1px solid @Cmaindarkdark;
+            }
+            > th {
+                background-color: @Cmainlight;
+                // Bottom align for column headings
+                border-bottom: 2px solid @Cmainlightlight;
+            }
+        }
     }
-    tr {
-        th {
-            background-color: @Cmainlight;
-            border-bottom: 2px solid @Cinvert;
+    // Account for multiple tbody instances
+    > tbody + tbody {
+        border-top: 2px solid @Cmaindarkdark;
+    }
+    // Nesting
+    .table {
+        background-color: @Cmain;
+    }
+}
+
+// This adds horizontal borders to the table elements. Nothing is using it
+// right now so it is commented out.
+/*
+.table-bordered {
+    border: 1px solid @Cmaindarkdark;
+    > thead,
+    > tbody,
+    > tfoot {
+        > tr {
+            > th,
+            > td {
+                border: 1px solid @Cmaindarkdark;
+            }
         }
     }
-    tr:nth-child(odd) {
-        background-color: @Cmaindark;
+    > thead > tr {
+        > th,
+        > td {
+            border-bottom-width: 2px;
+        }
     }
 }
+*/
 
 // ************************************************************************* //
 // Menu side bar nav
-- 
1.9.1



More information about the ffmpeg-devel mailing list