Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions docs/simplesamlphp-changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ Released TBD
`admin`

* Fix metadata-viewer to output a valid PHP array
* Fix text-overflow of the metadata-converter output-box

Chores:

* Solved deprecation notices in CI regarding the use of the Twig spaceless-filter (#2229)

## Version 2.3.0

Expand Down
7 changes: 2 additions & 5 deletions modules/admin/templates/metadata_converter.twig
Original file line number Diff line number Diff line change
Expand Up @@ -33,20 +33,17 @@
<h2 id="converted">{{ 'Converted metadata'|trans }}</h2>
{% for type, text in output -%}
{%- if text -%}
{# spaceless is to work around a clipboard.js bug that would add extra whitespace #}
{% apply spaceless %}
<div class="code-box">
<div class="code-box-title">
<h3>{{ type }}</h3>
<button data-clipboard-target="#metadata{{ loop.index }}" id="btn{{ loop.index }}" class="pure-button right clipboard-btn copy">
<i class="fa fa-copy"></i>
</button>
</div>
<div class="code-box-content">
<pre id="metadata{{ loop.index }}">{{ text|escape }}</pre>
<div id="metadata{{ loop.index }}" class="code-box-content">
{{- text|escape -}}
</div>
</div>
{% endapply %}
<br><br>
{%- set i=i+1 %}
{%- endif -%}
Expand Down
17 changes: 8 additions & 9 deletions templates/_table.twig
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,16 @@
<td class="attrname">{{ name }}</td>
{%- endblock %}

<td class="attrvalue">{% apply spaceless %}
{% for value in values %}
{% if loop.length>1 and loop.first %}<ul>{% endif %}
{% if loop.length>1 %}<li>{% endif -%}
<td class="attrvalue">
{% for value in values %}
{% if loop.length>1 and loop.first %}<ul>{% endif -%}
{%- if loop.length>1 %}<li>{% endif -%}

{% block value %}{% endblock %}
{%- block value %}{% endblock -%}

{% if loop.length>1 %}</li>{% endif %}
{% if loop.length>1 and loop.last %}</ul>{% endif %}
{% endfor %}
{% endapply -%}
{%- if loop.length>1 %}</li>{% endif -%}
{%- if loop.length>1 and loop.last %}</ul>{% endif %}
{% endfor %}
</td>
</tr>
{% endfor %}
Expand Down
2 changes: 0 additions & 2 deletions templates/base.twig
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{% apply spaceless %}
<!DOCTYPE html>
<html lang="{{ currentLanguage }}" dir="{{ isRTL ? 'rtl' : 'ltr' }}">
<head>
Expand Down Expand Up @@ -33,4 +32,3 @@
{% block postload %}{% endblock %}
</body>
</html>
{% endapply %}