header.html 2.36 KB
Newer Older
Hiro's avatar
Hiro committed
1 2 3
{% if this.color == 'primary' %}
<div class="container-fluid bg-primary">
{% else %}
Hiro's avatar
Hiro committed
4
<div class="container-fluid {% if this.header_color %} bg-{{ this.header_color }} {% else %} bg-dark {% endif %}">
Hiro's avatar
Hiro committed
5 6 7
{% endif %}
  <div class="row flex-xl-nowrap {{ bag('alternatives', this.alt, 'order') }}">
    {% if this.color == 'primary' %}
Hiro's avatar
Hiro committed
8
    <div class="container bg-primary pt-1 pt-sm-0">
Hiro's avatar
Hiro committed
9
    {% else %}
Antonela's avatar
Antonela committed
10
    <div class="container {% if this.header_color %} bg-{{ this.header_color }} {% else %} bg-dark {% endif %}git py-4">
Hiro's avatar
Hiro committed
11 12
    {% endif %}
      <div class="row">
13
        {% if this.html == 'donate-form.html' and this.header_image|length %}
Hiro's avatar
Hiro committed
14 15 16 17 18 19
        <div class="col-12 content-center pt-1 pt-sm-0 donate-has-image">
            <h2 class="mx-auto display-3 text-white text-capitalize donate-title">{{ this.title }}</h2>
            <img src="{{ this.header_image | asseturl }}" class="donate-header-image img-fluid" />
            {% set idx = this.header_image.index(".png") %}
            {% set header_mobile = this.header_image[:idx] + "-mobile" + this.header_image[idx:] %}
            <img src="{{ header_mobile | asseturl }}" class="donate-header-image-mobile img-fluid" />
Antonela's avatar
Antonela committed
20 21 22 23 24
            
            <div class="text-center py-3">
              <a href="https://blog.torproject.org/friends-of-tor-match-2020" target="_blank" title="Friends of Tor" class="match">{{ _('Your donation will be matched by Friends of Tor.') }}</a>
            </div>  

Hiro's avatar
Hiro committed
25
        </div>
26
        {% else %}
Hiro's avatar
Hiro committed
27 28
        <div class="col-12 content-center pt-5">
          <div class="row">
Antonela's avatar
Antonela committed
29
            <h6 class="mx-auto text-white text-capitalize">{% block section %}{{ this.section }}{% endblock %}</h6>
Hiro's avatar
Hiro committed
30 31
          </div>
          <div class="row pb-5">
Antonela's avatar
Antonela committed
32
            <h2 class="mx-auto display-3 text-white text-capitalize">{% block title %}{{ this.title }}{% endblock %}</h2>
Hiro's avatar
Hiro committed
33
          </div>
34 35 36 37 38 39 40 41 42
          {% if this.header_description_alignment == 'center' %}
          <div class="row text-center header-description">
          {% elif this.header_description_alignment == 'right' %}
          <div class="row text-right header-description">
          {% else %}
          <div class="row header-description">
          {% endif %}
            {{ this.header_description }}
          </div>
Hiro's avatar
Hiro committed
43
        </div>
44
        {% endif %}
Hiro's avatar
Hiro committed
45 46 47 48 49 50 51
      </div>
    </div>
  </div>
</div>
{% if this.section_id == 'about' %}
  {% include 'pagenav.html' %}
{% endif %}