debug button

This commit is contained in:
2021-10-15 14:39:41 +02:00
parent 68b5a93be9
commit 45d2ac14be
2 changed files with 13 additions and 16 deletions
+10 -10
View File
@@ -34,16 +34,16 @@ form:
.url:
type: text
label: URL
.primary:
type: toggle
label: Primary
highlight: 1
default: 1
options:
1: 'Yes'
0: 'No'
validate:
type: bool
# .primary:
# type: toggle
# label: Primary
# highlight: 1
# default: 1
# options:
# 1: 'Yes'
# 0: 'No'
# validate:
# type: bool
.pdf:
@@ -10,14 +10,11 @@
<div class="boutons-event">
{% for button in page.header.buttons %}
{% if button.url %}
<a class="bouton {% if button.primary %} primary{% endif %}" href="{{ button.url }}" target="_blank">{{ button.text }}>
<a class="bouton{% if button.primary %} primary{% endif %}" href="{{ button.url }}" target="_blank">{{ button.text }}</a>
{% else %}
<a class="bouton{% if button.primary %} primary{% endif %}" href="{{page.media[button.pdf].url|e }}" target="_blank">{{ button.text }}</a>
{% endif %}
{% if button.pdf %}
<a class="bouton {% if button.primary %} primary{% endif %}" href="{{page.media[button.pdf].url|e }}" target="_blank">{{ button.text }}>
{% endif %}
{% endfor %}
</div>
</div>