~alcinnz/bureaucromancy

bureaucromancy/tpl/select.html -rw-r--r-- 1.0 KiB
f80f12fd — Adrian Cochrane Clarify how to run, release 0.1.0.2 11 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{% extends "base.html" %}

{%- block main -%}<section>
  <h2>{{ input.label }}</h2>
  {{ input.description }}
  <hr />
  <nav><dl>{% for grp in input.list %}
    {% if grp.label == "" %}{% for opt in grp.opts %}
      {% if opt.disabled %}
        <dt>{{ opt.label }}</dt>
      {% else %}
        <dt {% if opt.selected %}class="checked"{% endif %}>
          {% if opt.selected %}&check;{% endif %}
          <a href="={{opt.value|xURI}}{{Q}}" title="{{opt.value}}">{{opt.label}}</a>
        </dt>
      {% endif %}
    {% endfor %}{% else %}
      <dt>{{ opt.label }}</dt>
      {% for opt in grp.opts %}
        {% if opt.disabled %}
          <dd>{{ opt.label }}</dd>
        {% else %}
          <dd {% if opt.selected %}class="checked"{% endif %}>
            {% if opt.selected %}&check;{% endif %}
            <a href="={{opt.value|xURI}}{{Q}}" title="{{opt.value}}">
              {{opt.label}}</a>
          </dd>
        {% endif %}
      {% endfor %}
    {% endif %}
  {% endfor %}</dl></nav>
</section>{%- endblock -%}