first commit
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
{% if settings.text is not empty %}
|
||||
{% set classes = settings.classes | merge( [ base_styles.base ] ) | join(' ') %}
|
||||
{% set id_attribute = settings._cssid is not empty ? 'id=' ~ settings._cssid | e('html_attr') : '' %}
|
||||
{% if settings.link.href %}
|
||||
<{{ settings.link.tag | e('html_tag') }}
|
||||
{% set linkAttr = settings.link.tag == 'a' ? 'href' : 'data-action-link' %}
|
||||
{{ linkAttr }}="{{ settings.link.href | raw }}"
|
||||
target="{{ settings.link.target }}"
|
||||
class="{{ classes }}"
|
||||
data-interaction-id="{{ id }}"
|
||||
data-interactions="{{ interactions | json_encode | e('html_attr') }}"
|
||||
{{ id_attribute }} {{ settings.attributes | raw }}
|
||||
>
|
||||
{{ settings.text }}
|
||||
</{{ settings.link.tag | e('html_tag') }}>
|
||||
{% else %}
|
||||
<button class="{{ classes }}" data-interaction-id="{{ id }}" data-interactions="{{ interactions | json_encode | e('html_attr') }}" {{ id_attribute }} {{ settings.attributes | raw }}>
|
||||
{{ settings.text }}
|
||||
</button>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
Reference in New Issue
Block a user