| 1 |
{% if settings.title is not empty %} |
| 2 |
{% set id_attribute = settings._cssid is not empty ? 'id=' ~ settings._cssid | e('html_attr') : '' %} |
| 3 |
<{{ settings.tag | e('html_tag') }} |
| 4 |
data-interaction-id="{{ id }}" |
| 5 |
class="{{ settings.classes | merge( [ base_styles.base ] ) | join(' ') }}" |
| 6 |
{{ id_attribute }} |
| 7 |
{{ settings.attributes | raw }} |
| 8 |
{% if interactions and interactions is not empty %} |
| 9 |
data-interactions="{{ interactions | json_encode | e('html_attr') }}" |
| 10 |
{% endif %} |
| 11 |
> |
| 12 |
{% set allowed_tags = '<b><strong><sup><sub><s><em><i><u><a><del><span><br>' %} |
| 13 |
|
| 14 |
{% if settings.link.href %} |
| 15 |
<{{ settings.link.tag | e('html_tag') }} |
| 16 |
{% set linkAttr = settings.link.tag == 'a' ? 'href' : 'data-action-link' %} |
| 17 |
{{ linkAttr }}="{{ settings.link.href | raw }}" |
| 18 |
target="{{ settings.link.target }}" |
| 19 |
class="{{ base_styles['link-base'] }}"> |
| 20 |
{{ settings.title | striptags(allowed_tags) | raw }} |
| 21 |
</{{ settings.link.tag | e('html_tag') }}> |
| 22 |
{% else %} |
| 23 |
{{ settings.title | striptags(allowed_tags) | raw }} |
| 24 |
{% endif %} |
| 25 |
</{{ settings.tag | e('html_tag') }}> |
| 26 |
{% endif %} |
| 27 |
|