[llvm-commits] [zorg] r125921 - in /zorg/trunk/llvmlab/llvmlab/ui: static/green.png static/red.png static/style.css static/white.png static/yellow.png templates/dashboard.html
Daniel Dunbar
daniel at zuster.org
Fri Feb 18 08:43:55 PST 2011
Author: ddunbar
Date: Fri Feb 18 10:43:55 2011
New Revision: 125921
URL: http://llvm.org/viewvc/llvm-project?rev=125921&view=rev
Log:
llvmlab: Tidy up look of rev links, mostly by stealing style from buildbot.
Removed:
zorg/trunk/llvmlab/llvmlab/ui/static/green.png
zorg/trunk/llvmlab/llvmlab/ui/static/red.png
zorg/trunk/llvmlab/llvmlab/ui/static/white.png
zorg/trunk/llvmlab/llvmlab/ui/static/yellow.png
Modified:
zorg/trunk/llvmlab/llvmlab/ui/static/style.css
zorg/trunk/llvmlab/llvmlab/ui/templates/dashboard.html
Removed: zorg/trunk/llvmlab/llvmlab/ui/static/green.png
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/llvmlab/llvmlab/ui/static/green.png?rev=125920&view=auto
==============================================================================
Binary files zorg/trunk/llvmlab/llvmlab/ui/static/green.png (original) and zorg/trunk/llvmlab/llvmlab/ui/static/green.png (removed) differ
Removed: zorg/trunk/llvmlab/llvmlab/ui/static/red.png
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/llvmlab/llvmlab/ui/static/red.png?rev=125920&view=auto
==============================================================================
Binary files zorg/trunk/llvmlab/llvmlab/ui/static/red.png (original) and zorg/trunk/llvmlab/llvmlab/ui/static/red.png (removed) differ
Modified: zorg/trunk/llvmlab/llvmlab/ui/static/style.css
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/llvmlab/llvmlab/ui/static/style.css?rev=125921&r1=125920&r2=125921&view=diff
==============================================================================
--- zorg/trunk/llvmlab/llvmlab/ui/static/style.css (original)
+++ zorg/trunk/llvmlab/llvmlab/ui/static/style.css Fri Feb 18 10:43:55 2011
@@ -43,3 +43,63 @@
padding: 10px;
border: 1px solid #AACBE2;
}
+
+/* Dashboard Features */
+
+td.phase-cell {
+ padding: 4px 4px 4px 4px;
+ color: #333333;
+ background-color: #eee;
+}
+
+.phase-cell {
+ text-align: center;
+ height: 20px;
+ padding: 0 2px;
+ line-height: 0;
+ white-space: nowrap;
+}
+
+.phase-cell a {
+ opacity: 0.85;
+ border-width: 1px;
+ border-style: solid;
+ border-radius: 4px;
+ -webkit-border-radius: 4px;
+ -moz-border-radius: 4px;
+ display: block;
+ width: 90%;
+ height: 20px;
+ line-height: 20px;
+ margin-left: auto;
+ margin-right: auto;
+}
+
+
+/* Build Status Indicators */
+.success {
+ color: #FFFFFF;
+ background-color: #8f8;
+ border-color: #4F8530;
+}
+.failure {
+ color: #FFFFFF;
+ background-color: #f99;
+ border-color: #A77272;
+}
+.warnings {
+ color: #FFFFFF;
+ background-color: #ffc343;
+ border-color: #C29D46;
+}
+.running {
+ color: #666666;
+ background-color: #ff6;
+ border-color: #C5C56D;
+}
+.unknown {
+ border-width: 1px;
+ border-style: solid;
+ border-color: #aaa;
+ background-color: #fff;
+}
Removed: zorg/trunk/llvmlab/llvmlab/ui/static/white.png
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/llvmlab/llvmlab/ui/static/white.png?rev=125920&view=auto
==============================================================================
Binary files zorg/trunk/llvmlab/llvmlab/ui/static/white.png (original) and zorg/trunk/llvmlab/llvmlab/ui/static/white.png (removed) differ
Removed: zorg/trunk/llvmlab/llvmlab/ui/static/yellow.png
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/llvmlab/llvmlab/ui/static/yellow.png?rev=125920&view=auto
==============================================================================
Binary files zorg/trunk/llvmlab/llvmlab/ui/static/yellow.png (original) and zorg/trunk/llvmlab/llvmlab/ui/static/yellow.png (removed) differ
Modified: zorg/trunk/llvmlab/llvmlab/ui/templates/dashboard.html
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/llvmlab/llvmlab/ui/templates/dashboard.html?rev=125921&r1=125920&r2=125921&view=diff
==============================================================================
--- zorg/trunk/llvmlab/llvmlab/ui/templates/dashboard.html (original)
+++ zorg/trunk/llvmlab/llvmlab/ui/templates/dashboard.html Fri Feb 18 10:43:55 2011
@@ -1,14 +1,39 @@
{% extends "layout.html" %}
-{% macro phase_popup_link(phase, build) %}
+{% macro phase_popup_link(phase, build, kind) %}
<a href='#'
onclick='show_phase_popup("./phase/{{
phase.number - 1 }}/{{
build.source_stamp }}", event); return false;'
title='Phase {{ phase.number }} {{ phase.name }} - {{ build.source_stamp }}'
+ class='phase-cell {{ kind }}'
target="_blank">{{ caller() }}</a>
{% endmacro %}
+{% macro phase_popup_cell(phase, phase_info, build) %}
+{% if not build %}
+{% set kind = "unknown" %}
+{% elif not build.end_time %}
+{% set kind = "running" %}
+{% elif build.result == 0 %}
+{% set kind = "success" %}
+{% elif build == phase_info.failing %}
+{% set kind = "failing" %}
+{% else %}
+{% set kind = "warnings" %}
+{% endif %}
+
+<td class="phase-cell {{kind}}">
+{% if build %}
+{% call phase_popup_link(phase, build, kind) %}
+r{{ build.source_stamp }}
+{% endcall %}
+{% else %}
+
+{% endif %}
+</td>
+{% endmacro %}
+
{% macro timing_popup_link(phase) -%}
<a href='#'
{% if phase == None %}
@@ -153,6 +178,8 @@
<tr>
<tr>
{% for phase in ci_config.phases %}
+ {% set phase_info = summary[phase.phase_builder] %}
+
<th>{{ phase.name }}<br>(Phase {{ phase.number }})</th>
{% endfor %}
</tr>
@@ -163,20 +190,11 @@
{# First, check if we have no status (no completed builds, or prior phase is
failing). #}
- <td align="center">
{% if not phase_info or not phase_info.completed or is_failing %}
- <img src="/static/white.png" width="45" height="45">
+ {{ phase_popup_cell(phase, phase_info, None) }}
{% else %}
- {% call phase_popup_link(phase, phase_info.completed) %}
- {% if phase_info.completed.result == 0 %}
- <img src="/static/green.png" width="45" height="45">
- {% else %}
- {% set is_failing = true %}
- <img src="/static/red.png" width="45" height="45">
- {% endif %}
- {% endcall %}
+ {{ phase_popup_cell(phase, phase_info, phase_info.completed) }}
{% endif %}
- </td>
{% endfor %}
</tr>
@@ -202,13 +220,9 @@
{% set phase_info = summary[phase.phase_builder] %}
{% if phase_info.current %}
- <td>
- {% call phase_popup_link(phase, phase_info.current[0]) %}
- r{{ phase_info.current[0].source_stamp }}
- {% endcall %}
- </td>
+ {{ phase_popup_cell(phase, phase_info, phase_info.current[0]) }}
{% else %}
- <td>(idle)</td>
+ <td class="phase-cell">(idle)</td>
{% endif %}
{% endfor %}
@@ -219,13 +233,9 @@
{% set phase_info = summary[phase.phase_builder] %}
{% if phase_info.completed %}
- <td>
- {% call phase_popup_link(phase, phase_info.completed) %}
- r{{ phase_info.completed.source_stamp }}
- {% endcall %}
- </td>
+ {{ phase_popup_cell(phase, phase_info, phase_info.completed) }}
{% else %}
- <td>(unknown)</td>
+ <td class="phase-cell">(unknown)</td>
{% endif %}
{% endfor %}
@@ -238,13 +248,9 @@
{% if phase_info.failing and
(not phase_info.passing or
phase_info.failing.number > phase_info.passing.number) %}
- <td>
- {% call phase_popup_link(phase, phase_info.failing) %}
- r{{ phase_info.failing.source_stamp }}
- {% endcall %}
- </td>
+ {{ phase_popup_cell(phase, phase_info, phase_info.failing) }}
{% else %}
- <td></td>
+ <td class="phase-cell"></td>
{% endif %}
{% endfor %}
@@ -255,13 +261,9 @@
{% set phase_info = summary[phase.phase_builder] %}
{% if phase_info.passing %}
- <td>
- {% call phase_popup_link(phase, phase_info.passing) %}
- r{{ phase_info.passing.source_stamp }}
- {% endcall %}
- </td>
+ {{ phase_popup_cell(phase, phase_info, phase_info.passing) }}
{% else %}
- <td>(unknown)</td>
+ <td class="phase-cell">(unknown)</td>
{% endif %}
{% endfor %}
More information about the llvm-commits
mailing list