Permalink
Browse files

WIP attempt to make data columns line up. #27

  • Loading branch information...
1 parent f1b356f commit a6d960523803350591065009409c51111a55caa7 @mtigas mtigas committed May 20, 2011
Showing with 15 additions and 6 deletions.
  1. +6 −6 censusweb/api/templates/data.html
  2. +9 −0 censusweb/media/css/census.css
@@ -23,9 +23,9 @@
{% for r in reports %}
<table class="report">
<tr>
- <th rowspan="2">{{ r.table }}<br /><span class="universe">Universe: {{ r.universe }}</span></th>
+ <th rowspan="2" class="labeldef">{{ r.table }}<br /><span class="universe">Universe: {{ r.universe }}</span></th>
{% for c in r.columns %}
- <th colspan="4">
+ <th colspan="4" class="locationdef">
{{ c.name }}
{% if c.sumlev != "040" %}
<span class="button show-family" title="Show items that contain this" data-val="{{ c.geoid }}">F</span>
@@ -52,10 +52,10 @@
>
<td class="label">{{ label.text }} <span class="key">{{ key }}</span></td>
{% for d in data %}
- <td class="code">{{ d.2000 }}</td>
- <td class="code">{{ d.2010 }}</td>
- <td class="code">{{ d.delta }}</td>
- <td class="code {% if forloop.last %}last{% endif %}">{{ d.pct_change|floatformat:-3 }}</td>
+ <td class="code data-cell">{{ d.2000 }}</td>
+ <td class="code data-cell">{{ d.2010 }}</td>
+ <td class="code data-cell">{{ d.delta }}</td>
+ <td class="code data-cell {% if forloop.last %}last{% endif %}">{{ d.pct_change|floatformat:-3 }}</td>
{% endfor %}
</tr>
{% endfor %}
@@ -148,6 +148,15 @@ nav {
text-align: right;
}
+.report th.labeldef {
+ width: 375px !important;
+}
+.report th.locationdef {
+ width: 300px !important;
+}
+.report td.data-cell {
+ width: 75px !important;
+}
.report td.label {
color: #000;
padding: 5px 50px 5px 10px;

0 comments on commit a6d9605

Please sign in to comment.