Skip to content
This repository has been archived by the owner on Aug 3, 2022. It is now read-only.

Commit

Permalink
Merge branch '1061/icon-tooltip'
Browse files Browse the repository at this point in the history
  • Loading branch information
brew committed Apr 27, 2017
2 parents 6126fc1 + 61f11f2 commit 3433d16
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 86 deletions.
18 changes: 6 additions & 12 deletions census/static/scripts/site/table.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,33 +49,27 @@ define(['jquery', 'bootstrap', 'chroma', 'tablesorter', 'stickykit'],
headers: {
2: {sorter: false},
3: {sorter: false},
4: {sorter: false},
6: {sorter: false}
5: {sorter: false}
}
},
tablesorterSliceIndexOptions = {
sortList: [[0, 0]],
headers: {
2: {sorter: false},
3: {sorter: false},
4: {sorter: false},
6: {sorter: false}
2: {sorter: false}
}
},
tablesorterPlaceSliceOptions = {
sortList: [[4, 1]],
sortList: [[3, 1]],
headers: {
1: {sorter: false},
2: {sorter: false},
3: {sorter: false},
5: {sorter: false}
4: {sorter: false}
}
},
tablesorterPlaceSliceIndexOptions = {
sortList: [[3, 1]],
sortList: [[2, 1]],
headers: {
1: {sorter: false},
2: {sorter: false}
1: {sorter: false}
}
},
sortFlag = true;
Expand Down
37 changes: 1 addition & 36 deletions census/views/includes/dataviews/table_slice_dataset.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,13 @@
<col style="width:6%">
<col style="width:24%">
<col style="width:23%">
<col style="width:5%">
<col style="width:6%">
</colgroup>
{% else %}
<colgroup>
<col style="width:6%">
<col style="width:20%">
<col style="width:23%">
<col style="width:5%">
<col style="width:8%">
<col style="width:6%">
<col style="width:4%">
Expand All @@ -35,7 +33,6 @@
<th class="clickable">{{ gettext("Rank") }}</th>
<th class="clickable">{{ gettext("Place") }}</th>
<th>{{ gettext("Breakdown") }}</th>
<th>{{ gettext("Info") }}</th>
{% if not is_index %}
<th>{{ gettext("Year") }}</th>
{% endif %}
Expand All @@ -59,15 +56,10 @@
{% set answer = entry.getAnswerValueForQuestion(question) %}
{% set pass = 'yes' if question.pass(answer) else 'no' %}
{% endif %}
<li class="{{ pass }}" title="{{ question.question }}" data-toggle="popover" data-content="{{ popovers.popover_slice_content(question.description)|escape }}"><i class="fa fa-{{ question.icon }}"></i>&nbsp;</li>
<li class="{{ pass }}" title="{{ question.questionshort }}" data-toggle="tooltip"><i class="fa fa-{{ question.icon }}"></i>&nbsp;</li>
{% endfor %}
</ul>
</td>
<td class="info-expander" title="Click for full details">
<a aria-expanded="false" data-toggle="collapse" data-target="#detail-{{place.id}}" class="collapsed">
<i class="fa fa-info-circle"></i>
</a>
</td>
{% if not is_index %}
<td class="year">
{% if entry %}
Expand All @@ -88,18 +80,6 @@
</td>
{% endif %}
</tr>
{% if entry.details %}
<tr id="detail-{{ place.id }}" class="details collapse">
<td>{# hack around tablesorter and our row toggler #}<span style="visibility: hidden">{{ place.rank }}</span></td>
<td colspan="6">
{# hack around tablesorter and our row toggler #}<span style="visibility: hidden;">{{ place.name }}</span>
{% if entry.details %}
{{ entry.details|marked }}
{% endif %}
<br />
</td>
</tr>
{% endif %}

{% if not is_index %}
{% for submission in submissions %}
Expand Down Expand Up @@ -129,11 +109,6 @@ <h6><span class="icon">&#8627;</span> {{ gettext("Awaiting review") }}</h6>
{% endfor %}
</ul>
</td>
<td class="info-expander" title="Click for full details">
<a data-toggle="collapse" data-target="#detail-submission-{{place.id}}-{{loop.index}}" class="collapsed">
<i class="fa fa-info-circle"></i>
</a>
</td>
{% if not is_index %}
<td class="year">
{% if submission %}
Expand All @@ -148,16 +123,6 @@ <h6><span class="icon">&#8627;</span> {{ gettext("Awaiting review") }}</h6>
</td>
{% endif %}
</tr>
<tr id="detail-submission-{{place.id}}-{{loop.index}}" class="details collapse">
<td>{# hack around tablesorter and our row toggler #}<span style="visibility: hidden">{{ place.rank }}</span></td>
<td colspan="6">
{# hack around tablesorter and our row toggler #}<span style="visibility: hidden;">{{ place.name }}</span>
{% if submission.details %}
{{ submission.details|marked }}
{% endif %}
<br />
</td>
</tr>
{% endfor %}
{% endif %}

Expand Down
39 changes: 1 addition & 38 deletions census/views/includes/dataviews/table_slice_place.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,12 @@
<colgroup>
<col style="width:24%">
<col style="width:23%">
<col style="width:5%">
<col style="width:6%">
</colgroup>
{% else %}
<colgroup>
<col style="width:20%">
<col style="width:23%">
<col style="width:5%">
<col style="width:8%">
<col style="width:6%">
<col style="width:4%">
Expand All @@ -32,7 +30,6 @@
<tr>
<th class="clickable">{{ gettext("Dataset") }}</th>
<th>{{ gettext("Breakdown") }}</th>
<th>{{ gettext("Info") }}</th>
{% if not is_index %}
<th>{{ gettext("Year") }}</th>
{% endif %}
Expand Down Expand Up @@ -64,15 +61,10 @@
{% set answer = entry.getAnswerValueForQuestion(question) %}
{% set pass = 'yes' if question.pass(answer) else 'no' %}
{% endif %}
<li class="{{ pass }}" title="{{ question.question }}" data-toggle="popover" data-content="{{ popovers.popover_slice_content(question.description)|escape }}"><i class="fa fa-{{ question.icon }}"></i>&nbsp;</li>
<li class="{{ pass }}" title="{{ question.questionshort }}" data-toggle="tooltip"><i class="fa fa-{{ question.icon }}"></i>&nbsp;</li>
{% endfor %}
</ul>
</td>
<td class="info-expander" title="Click for full details">
<a aria-expanded="false" data-toggle="collapse" data-target="#detail-{{ dataset.id }}" class="collapsed">
<i class="fa fa-info-circle"></i>
</a>
</td>
{% if not is_index %}
<td class="year">
{% if entry %}
Expand All @@ -93,21 +85,6 @@
</td>
{% endif %}
</tr>
{% if entry.details %}
<tr id="detail-{{ dataset.id }}" class="details collapse">
{% if is_index %}
<td colspan="4">
{% else %}
<td colspan="6">
{% endif %}
{# hack around tablesorter and our row toggler #}<span style="visibility: hidden;">{{ dataset.name }}</span>
{% if entry.details %}
{{ entry.details|marked }}
{% endif %}
<br />
</td>
</tr>
{% endif %}

{% if not is_index %}
{% for submission in submissions %}
Expand Down Expand Up @@ -136,11 +113,6 @@ <h6><span class="icon">&#8627;</span> {{ gettext("Awaiting review") }}</h6>
{% endfor %}
</ul>
</td>
<td class="info-expander" title="Click for full details">
<a data-toggle="collapse" data-target="#detail-submission-{{dataset.id}}-{{loop.index}}" class="collapsed">
<i class="fa fa-info-circle"></i>
</a>
</td>
{% if not is_index %}
<td class="year">
{% if submission %}
Expand All @@ -155,15 +127,6 @@ <h6><span class="icon">&#8627;</span> {{ gettext("Awaiting review") }}</h6>
</td>
{% endif %}
</tr>
<tr id="detail-submission-{{dataset.id}}-{{loop.index}}" class="details collapse">
<td colspan="6">
{# hack around tablesorter and our row toggler #}<span style="visibility: hidden;">{{ dataset.name }}</span>
{% if submission.details %}
{{ submission.details|marked }}
{% endif %}
<br />
</td>
</tr>
{% endfor %}
{% endif %}

Expand Down

0 comments on commit 3433d16

Please sign in to comment.