aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCaleb Forbes Davis V <caldavis@gmail.com>2011-08-21 01:03:02 -0500
committerCaleb Forbes Davis V <caldavis@gmail.com>2011-08-21 01:03:02 -0500
commit0a100476b24d81355342cae5320e1a5a6c83014d (patch)
treeb7ce2a9c008eef8c88652e0f30b5bfecf24e58aa
parente3df834a8a22a45ba77940efbd083c7d5a23764e (diff)
downloadmediagoblin-0a100476b24d81355342cae5320e1a5a6c83014d.tar.lz
mediagoblin-0a100476b24d81355342cae5320e1a5a6c83014d.tar.xz
mediagoblin-0a100476b24d81355342cae5320e1a5a6c83014d.zip
only remove the inert Xs when the user has one item
-rw-r--r--mediagoblin/templates/mediagoblin/utils/prev_next.html12
1 files changed, 12 insertions, 0 deletions
diff --git a/mediagoblin/templates/mediagoblin/utils/prev_next.html b/mediagoblin/templates/mediagoblin/utils/prev_next.html
index f8a746d9..8c0cee02 100644
--- a/mediagoblin/templates/mediagoblin/utils/prev_next.html
+++ b/mediagoblin/templates/mediagoblin/utils/prev_next.html
@@ -22,15 +22,27 @@
{% if prev_entry_url or next_entry_url %}
<div class="grid_5 alpha omega">
+ {# There are no previous entries for the very first media entry #}
{% if prev_entry_url %}
<a class="navigation_button navigation_left" href="{{ prev_entry_url }}">
<img src="/mgoblin_static/images/navigation_left.png" alt="Previous image" />
</a>
+ {% else %}
+ {# This is the first entry. display greyed-out 'previous' image #}
+ <p class="navigation_button navigation_left">
+ <img src="/mgoblin_static/images/navigation_end.png" alt="No previous images" />
+ </p>
{% endif %}
+ {# Likewise, this could be the very last media entry #}
{% if next_entry_url %}
<a class="navigation_button" href="{{ next_entry_url }}">
<img src="/mgoblin_static/images/navigation_right.png" alt="Next image" />
</a>
+ {% else %}
+ {# This is the last entry. display greyed-out 'next' image #}
+ <p class="navigation_button">
+ <img src="/mgoblin_static/images/navigation_end.png" alt="No following images" />
+ </p>
{% endif %}
</div>
{% endif %}