[llvm-commits] [LNT] r162183 - in /lnt/trunk/lnt/server/ui: static/style.css templates/layout.html templates/v4_recent_activity.html
Daniel Dunbar
daniel at zuster.org
Sat Aug 18 19:44:07 PDT 2012
Author: ddunbar
Date: Sat Aug 18 21:44:07 2012
New Revision: 162183
URL: http://llvm.org/viewvc/llvm-project?rev=162183&view=rev
Log:
UI: Tighten up the shared header.
Added:
lnt/trunk/lnt/server/ui/templates/v4_recent_activity.html
Modified:
lnt/trunk/lnt/server/ui/static/style.css
lnt/trunk/lnt/server/ui/templates/layout.html
Modified: lnt/trunk/lnt/server/ui/static/style.css
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/server/ui/static/style.css?rev=162183&r1=162182&r2=162183&view=diff
==============================================================================
--- lnt/trunk/lnt/server/ui/static/style.css (original)
+++ lnt/trunk/lnt/server/ui/static/style.css Sat Aug 18 21:44:07 2012
@@ -1,27 +1,115 @@
-/* General Styles */
+/* Body and Top-Level Containers */
body {
- color:#000000;
- background-color:#ffffff
+ font-family: Helvetica, sans-serif;
+ font-size: 9pt;
+ background-color : #FFFFFF;
+ margin: 0;
+ padding: 0;
}
-body {
- font-family: Helvetica, sans-serif;
- font-size:9pt
+.container {
+ padding: 0px 10px 0px 10px;
}
-h1 {
- font-size: 14pt;
+#content {
+ margin: 5px;
}
-h2 {
- font-size: 12pt;
+.clearfix {
+ display: block;
+}
+.clearfix::after {
+ content: ".";
+ display: block;
+ height: 0;
+ clear: both;
+ visibility: hidden;
}
-table {
- font-size:9pt
+/* Top-Level Content */
+
+.top-level-content { }
+
+footer {
+ padding : 5px 0px 5px 0px;
+ border-top: 2px solid #DFE0E3;
+ position : relative;
+ line-height: 0.3em;
+}
+
+#footer-content {
+ padding-left: 10px;
+ margin: 0 auto;
+}
+
+/* Page Header */
+
+#header {
+ font-family: "Lucida Grande", "Lucida Sans Unicode", Arial, Verdana, Helvetica, sans-serif;
+ font-size: small;
+
+ background: #DFE0E3;
+ background: -moz-linear-gradient(#DFE0E3,#CFCFCF);
+ background: -webkit-linear-gradient(#DFE0E3,#CFCFCF);
+ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr='#DFE0E3',endColorstr='#CFCFCF')";
+ position: relative;
+ border-bottom: 1px solid #DFE0E3;
+ box-shadow: 0 0px,0 0 5px rgba(0, 0, 0, 0.2)
+}
+#header a {
+ color: #000;
+ text-decoration: none;
+}
+
+#header .header-title {
+ float: left;
+ position: relative;
+ padding: 9px 0 0 0;
+ zoom: 1;
+}
+#header .header-title h2 {
+ font-size: 2em;
+ position: absolute;
+ margin: 0;
+ padding: 0;
+ top: 0;
+ left: 0;
+}
+
+#nav-breadcrumbs {
+ float: left;
+ clear: none;
+ width: auto;
+ border-left: 1px solid #DFE0E3;
+ box-shadow: -1px 0 0 #BFC3C3;
+ padding: 3px 10px 3px 10px;
+ margin: 0 0 0 71px;
+}
+
+#nav-dbselector {
+ float: right;
+ line-height: 20px;
+ padding: 3px 10px 3px 10px;
+}
+
+.nav {
+ float: left;
+ margin: 0 0 0 20px;
+ list-style: none;
+ line-height: 26px;
+}
+#navlist {
+ margin: 0;
+ padding: 0;
+}
+.nav li {
+ float: left;
+ margin: 0 10px 0 0;
}
+/* Content */
+
table {
border-spacing: 0px;
border: 1px solid black
@@ -50,6 +138,8 @@
overflow:auto
}
+/* Popups */
+
.hideable {
border-width:thin;
border-color:background;
@@ -58,35 +148,6 @@
padding:8px;
}
-/* Nav Header Styles */
-nav.zorg_navheader {
- background-color: #cccccc;
- width: 100%;
- height: 2.5em;
- font-weight: bolder;
-
- border-style: solid;
- border-width: 1px;
- padding-top: 0.5em;
-}
-
-span.zorg_navheader_dbname {
- float: left;
- margin-top: 0.35em;
- margin-left: 1em;
-}
-span.zorg_navheader_dbselector {
- float: right;
- margin-right: 1em;
-}
-
-/* Footer Styles */
-footer {
- line-height: 0.3em;
-}
-
-/* Nested popups */
-
.hideable_1 {
border-width:thin;
border-color:background;
Modified: lnt/trunk/lnt/server/ui/templates/layout.html
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/server/ui/templates/layout.html?rev=162183&r1=162182&r2=162183&view=diff
==============================================================================
--- lnt/trunk/lnt/server/ui/templates/layout.html (original)
+++ lnt/trunk/lnt/server/ui/templates/layout.html Sat Aug 18 21:44:07 2012
@@ -1,7 +1,8 @@
<!DOCTYPE html>
<html>
<head>
- <META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+ <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
+ <meta name="viewport" content="width=device-width" />
<link rel="icon" type="image/png"
href="{{ url_for('.static', filename='favicon.ico') }}">
<title>{{old_config.name}}{%
@@ -19,53 +20,64 @@
{% else %}
<body>
{% endif %}
-
-{# Header #}
-
-{# Database selection header. #}
-<nav class="zorg_navheader">
- <span class="zorg_navheader_dbname">[{{ g.db_name }}]</span>
- <span class="zorg_navheader_dbselector">
- <form method="get" action="{{ url_for('select_db') }}">
- <input type="hidden" name="path" value="{{ request.path }}"/>
- <label>Database:</label>
- <select name="db" onchange="submit()">
- {% for name in old_config.databases.keys()|sort %}
- <option{{" selected" if name == g.db_name else ""}}>{{ name }}</option>
- {% endfor %}
- </select>
- <input type="submit" value="Go"/>
- </form>
- </span>
-</nav>
-
-{# Component links #}
-<h2><a href="{{url_for('index')}}">{{old_config.name}}</a>
-{% for short_name,path in components %}
- : <a href="{{ path }}">{{short_name}}</a>
-{% endfor %}
- - {{ self.title() }}</h2>
-
-{# Actual body #}
-<div class="body">{%
- block body %}{% endblock %}
-</div>
-
-{# Include any database log, if present. #}
-{% if g.db_log is defined %}
-<hr>
-
-<h3>SQL Log</h3>
-<pre>{{g.db_log.getvalue()}}</pre>
-{% endif %}
-
-{# Footer #}
-<hr>
-<footer>
-<p>LNT Version: {{ app.version }}</p>
-<p>Server Started: {{ app.start_time|asusertime }}</p>
-<p>Generated: {{ request.request_time|asusertime }}</p>
-<p>Render Time: {{ "%.2fs" % request.elapsed_time() }}</p>
-</footer>
+ {# Top-Level Content (non-footer) #}
+ <div class="top-level-content">
+ {# Page Header #}
+ <nav id="header" class="clearfix">
+ <div class="container">
+ {# LNT Instance Title #}
+ <a href="{{url_for('index')}}" class="header-title">
+ <h2>{{old_config.name}}</h2>
+ </a>
+
+ {# Navigation Breadcrumbs #}
+ <span id="nav-breadcrumbs">
+ <ul id="navlist" class="nav">
+ {% for short_name,path in components %}
+ <li><a href="{{ path }}">{{short_name}}</a></li>
+ <li>|</li>
+ {% endfor %}
+ <li>{{ self.title() }}</li>
+ </ul>
+ </span>
+
+ {# Database Selector #}
+ <span id="nav-dbselector">
+ <form method="get" action="{{ url_for('select_db') }}" class="nav">
+ <input type="hidden" name="path" value="{{ request.path }}"/>
+ <label>Database:</label>
+ <select name="db" onchange="submit()">
+ {% for name in old_config.databases.keys()|sort %}
+ <option{{" selected" if name == g.db_name else ""}}>{{ name }}</option>
+ {% endfor %}
+ </select>
+ <input type="submit" value="Go"/>
+ </form>
+ </span>
+ </div>
+ </nav>
+
+ {# Page Content #}
+ <div id="content" class="container">{%
+ block body %}{% endblock %}
+ </div>
+ </div>
+
+ {# Page Footer #}
+ <footer class="container clearfix">
+ <div id="footer-content">
+ {# Include any database log, if present. #}
+ {% if g.db_log is defined %}
+ <h3>SQL Log</h3>
+ <pre>{{g.db_log.getvalue()}}</pre>
+ <hr>
+ {% endif %}
+ <p>LNT Version: {{ app.version }}</p>
+ <p>Server Started: {{ app.start_time|asusertime }}</p>
+ <p>Generated: {{ request.request_time|asusertime }}</p>
+ <p>Render Time: {{ "%.2fs" % request.elapsed_time() }}</p>
+ </div>
+ </div>
+ </div>
</body>
</html>
Added: lnt/trunk/lnt/server/ui/templates/v4_recent_activity.html
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/server/ui/templates/v4_recent_activity.html?rev=162183&view=auto
==============================================================================
--- lnt/trunk/lnt/server/ui/templates/v4_recent_activity.html (added)
+++ lnt/trunk/lnt/server/ui/templates/v4_recent_activity.html Sat Aug 18 21:44:07 2012
@@ -0,0 +1,76 @@
+{% set db = request.get_db() %}
+
+{% extends "layout.html" %}
+{% set components = [(testsuite_name, v4_url_for("v4_overview"))] %}
+{% block title %}Overview{% endblock %}
+{% block body %}
+
+<center><h3>Compiler Status Pages</h3></center>
+<a href="{{ v4_url_for('v4_global_status', field=2) }}">Compile Time</a>
+<a href="{{ v4_url_for('v4_global_status', field=3) }}">Execution Time</a>
+
+{# Find recent runs. #}
+<center><h3>Submission Overview</h3></center>
+<table width="100%%">
+ <tr>
+ <td valign="top" width="50%">
+ <center>
+ <h3>Active Machines</h3>
+ <table class="sortable" border=1>
+ <thead>
+ <tr>
+ <th>Latest Submission</th>
+ <th>Machine</th>
+ <th>Results</th>
+ </tr>
+ </thead>
+
+{# Show the most active machines. #}
+{% for machine_name,r in active_machines|dictsort %}
+ <tr>
+ <td>{{r.start_time}}</td>
+ <td align=left><a href="{{v4_url_for('v4_machine', id=r.machine.id)}}">{{
+ r.machine.name}}:{{r.machine.id}}</a></td>
+ <td><a href="{{v4_url_for('v4_run', id=r.id)}}">
+ View Results</a></td>
+ </tr>
+{% endfor %}
+
+ </table>
+ </center>
+ </td>
+ <td valign="top">
+ <center>
+ <h3>Recent Submissions</h3>
+ <table class="sortable" border=1>
+ <thead>
+ <tr>
+ <th>Run Order</th>
+ <th>Start Time</th>
+ <th>Duration</th>
+ <th>Machine</th>
+ <th>Results</th>
+ </tr>
+ </thead>
+
+{# Show the active submissions. #}
+{% for r,run_order in active_submissions %}
+{% set m = r.machine %}
+ <tr>
+ <td><a href="{{v4_url_for('v4_order', id=r.order.id)}}">{{
+ run_order}}</a></td></td>
+ <td>{{r.start_time}}</td>
+ <td>{{r.end_time - r.start_time}}</td>
+ <td align=left><a href="{{v4_url_for('v4_machine',id=m.id)}}">{{
+ m.name}}:{{m.id}}</a></td>
+ <td><a href="{{v4_url_for('v4_run', id=r.id)}}">
+ View Results</a></td>
+ </tr>
+{% endfor %}
+ </table>
+ </center>
+ </td>
+ </tr>
+</table>
+
+{% endblock %}
More information about the llvm-commits
mailing list