Skip to content

Commit

Permalink
make each item of document-urls a link (#270)
Browse files Browse the repository at this point in the history
  • Loading branch information
colmjude authored Jul 24, 2024
1 parent ab9991d commit 2b1c7ee
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions application/templates/components/entity-value/macro.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@
<span class="app-u-breakword">
<a class="govuk-link" href="{{ value }}">{{value}}</a>
</span>
{% elif field_spec[field]['field'] == 'document-urls' %}
{%- set urls = value.split(';') %}
<ul class="govuk-list">
{%- for url in urls %}
<li>
<span class="app-u-breakword">
<a class="govuk-link" href="{{ url }}">{{url}}</a>
</span>
</li>
{% endfor -%}
</ul>
{% elif field_spec[field]['datatype'] == 'wkt' %}
<div class="app-code-block">{{ value }}</div>
{% elif field in ["organisation-entity"] %}
Expand Down

0 comments on commit 2b1c7ee

Please sign in to comment.