about summary refs log tree commit diff
path: root/templates/tree.html
blob: 77609075d382d2ea0f013478557f7e67af478de7 (plain) (blame)
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
{# SPDX-License-Identifier: AGPL-3.0-or-later WITH GPL-3.0-linking-exception #}
{#- SPDX-FileCopyrightText: 2021 Alyssa Ross <hi@alyssa.is> -#}
{#- SPDX-FileCopyrightText: 2022 Arnout Engelen <arnout@bzzt.net> -#}

<li>
  {% match accepted %}
  {%- when Some with (true) -%}
  <span class="state-accepted"></span>
  {%- when Some with (false) -%}
    <span class="state-pending"></span>
  {%- when None -%}
    <span class="state-unknown"></span>
  {% endmatch %}

  {% match hydra_link %}
  {%- when Some with (link) -%}
    <a href="{{ link }}">{{ branch_name }}</a>
  {%- when None -%}
    {{ branch_name }}
  {% endmatch %}

  {% if !children.is_empty() %}
  <ul>
    {% for child in children %}
    {{ child|safe }}
    {% endfor %}
  </ul>
  {% endif %}
</li>