Skip to content

Commit

Permalink
Empty language tabs go to the end
Browse files Browse the repository at this point in the history
CSS changed:
  empty languages = color: #ccc
  available but not currently selected = font-weight: normal
  • Loading branch information
rvikmanis committed Dec 23, 2011
1 parent 9504d80 commit 1ba2d1b
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions nani/templates/admin/nani/change_form.html
Expand Up @@ -12,15 +12,20 @@
position: relative;
left: 0px;
top: 1px;
font-weight: bold;
font-weight: normal;
}
.nani-language-tabs span.current {
border-bottom: 1px solid #fff;
font-weight: bold;
}
.nani-language-tabs span a {
}
.nani-language-tabs span.empty {
opacity: 0.7;
font-weight: normal;
}
.nani-language-tabs span.empty a {
color: #ccc;
}
.nani-language-tabs a.deletelink {
right: -17px;
bottom: 4px;
Expand All @@ -32,12 +37,12 @@
{% block object-tools %}
{{ block.super }}
<div class="nani-language-tabs">
{% for url,name,code,status in language_tabs %}
{% if status == 'current' %}
<span class="current">{{ name }}{% if current_is_translated and allow_deletion %}<a class="deletelink" href="./delete-translation/{{ code }}/" title="{% trans 'Delete Translation' %}">&nbsp;</a>{% endif %}</span>
{% else %}
<span class="{{ status }}"><a href="{{ url }}">{{ name }}</a> {% if status == 'available' and allow_deletion %}<a class="deletelink" href="./delete-translation/{{ code }}/" title="{% trans 'Delete Translation' %}">&nbsp;</a>{% endif %}</span>
{% endif %}
{% for url,name,code,status,primary,current in language_tabs %}
{% if current %}
<span class="current" {% if not current_is_translated %}style="color: #ccc;"{% endif %}>{{ name }}{% if not primary and current_is_translated and allow_deletion %}<a class="deletelink" href="./delete-translation/{{ code }}/" title="{% trans 'Delete Translation' %}">&nbsp;</a>{% endif %}</span>
{% else %}
<span class="{{ status }}"><a href="{{ url }}">{{ name }}</a> {% if not primary and status == 'available' and allow_deletion %}<a class="deletelink" href="./delete-translation/{{ code }}/" title="{% trans 'Delete Translation' %}">&nbsp;</a>{% endif %}</span>
{% endif %}
{% endfor %}
</div>
{% endblock %}

0 comments on commit 1ba2d1b

Please sign in to comment.