7b4e78679c9d webui

Add some basic styles so I don't hate looking at this thing.
[view raw] [browse files]
author Steve Losh <steve@stevelosh.com>
date Tue, 13 Oct 2009 20:13:17 -0400
parents 73284798e9e9
children 590fb7bae0a8
branches/tags webui
files review/web_media/style.css review/web_templates/index.html

Changes

--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/review/web_media/style.css	Tue Oct 13 20:13:17 2009 -0400
@@ -0,0 +1,13 @@
+/* Basic layout and typography. */
+div#main-wrap {
+    width: 40em;
+    margin: 3em auto;
+}
+
+/* Tables. */
+table {
+    width: 100%;
+}
+table tr.odd {
+    background: #eee;
+}
\ No newline at end of file
--- a/review/web_templates/index.html	Tue Oct 13 20:06:47 2009 -0400
+++ b/review/web_templates/index.html	Tue Oct 13 20:13:17 2009 -0400
@@ -6,23 +6,26 @@
     <head>
         <title>${ basename(rd.target.root) } / hg-review</title>
         <link rel="stylesheet" href="/media/aal.css" type="text/css" media="screen" />
+        <link rel="stylesheet" href="/media/style.css" type="text/css" media="screen" />
     </head>
     
     <body>
-        <h1>${ basename(rd.target.root) }</h1>
-        
-        <h2>Changesets</h2>
-        <table>
-            $for ctx in revs:
-                $ ctx_node = ctx.node()
-                $ ctx_comments = rd[ctx_node].comments
-                $ ctx_signoffs = rd[ctx_node].signoffs
-                <tr>
-                    <td>${ ctx.rev() }:${ node_short(ctx_node) }</td>
-                    <td>${ ctx.description() }</td>
-                    <td>${ len(ctx_comments) } comments,
-                        ${ len(ctx_signoffs) } signoffs</td>
-                </tr>
-        </table>
+        <div id="main-wrap">
+            <h1>${ basename(rd.target.root) }</h1>
+            
+            <h2>Changesets</h2>
+            <table>
+                $for ctx in revs:
+                    $ ctx_node = ctx.node()
+                    $ ctx_comments = rd[ctx_node].comments
+                    $ ctx_signoffs = rd[ctx_node].signoffs
+                    <tr class="${ loop.parity }">
+                        <td>${ ctx.rev() }:${ node_short(ctx_node) }</td>
+                        <td>${ ctx.description() }</td>
+                        <td>${ len(ctx_comments) } comments,
+                            ${ len(ctx_signoffs) } signoffs</td>
+                    </tr>
+            </table>
+        </div>
     </body>
 </html>
\ No newline at end of file