Merge branch 'master' into funding
[wolnelektury.git] / apps / funding / templates / funding / tags / funding.html
1 {% load i18n %}
2 {% load time_tags %}
3 {% if offer %}
4 {% spaceless %}
5 <div class="funding" style="">
6     {% if link and is_current %}
7         <a class="call honking" href="{% url 'funding_current' offer.slug %}">
8             {% trans "Support a book!" %}</a>
9     {% endif %}
10     <div class="description {% if link and is_current %}with-button{% endif %}"
11         style="display: inline-block;">
12     {% if link %}<a href="{% if is_current %}{% url 'funding_current' offer.slug %}{% else %}{{ offer.get_absolute_url }}{% endif %}">{% endif %}
13     <strong>
14         {{ offer }}
15     </strong>
16     <div class="progress"
17         style="text-align: center; background-size: {{ percentage|stringformat:'.2f' }}% 1px;"
18     >
19         {% if sum %}
20             <span class="piece" style="float:left">{% trans "collected" %}: <em>{{ sum }} zł</em></span>
21         {% endif %}
22         {% if not is_win %}
23             <span class="piece" style="float: right">{% trans "missing" %}: <em>{{ missing }} zł</em></span>
24         {% endif %}
25         {% if is_current %}
26             <span class="piece" style="display:inline-block;margin-right: 0em;">{% trans "until fundraiser end" %}:
27                 <span class="countdown inline" data-until='{{ offer.end|date_to_utc:True|utc_for_js }}'></span>
28             </span>
29         {% endif %}
30
31         <div style="clear: both"></div>
32     </div>
33     {% if link %}</a>{% endif %}
34     </div>
35 </div>
36 {% endspaceless %}
37 {% endif %}