]> git.0d.be Git - panikweb.git/blob - panikweb_templates/templates/combo/gallery.html
factorize gallery js
[panikweb.git] / panikweb_templates / templates / combo / gallery.html
1 {% load thumbnail %}
2 {% if cell.title %}<h3>{{ cell.title }}</h3>{% endif %}
3 <div class="gallery" id="gallery-{{cell.id}}">
4 {% for image in cell.image_set.all %}
5   {% if forloop.first %}
6 <div class="first" style="display: none;">
7 <img src="#"/>
8 </div>
9 <div>
10   {% endif %}
11 {% thumbnail image.image "200x100" crop="50% 25%" as im %}
12 {% thumbnail image.image "640x480" crop="50% 25%" as im_large %}
13 <span data-image-large="{{ im_large.url }}"><img src="{{ im.url }}"
14         {% if image.title %} title="{{image.title}}" {% endif %}/></span>
15 {% endthumbnail %}
16 {% endthumbnail %}
17 {% endfor %}
18 </div>
19 </div>