{% block block_newsletter_mini_form %}
<div class="container">
<div class="newsletter-mini-form-container container">
{% set badgeElement = block.slots.getSlot('newsletter-badge') %}
{% set contentElement = block.slots.getSlot('newsletter-content') %}
{% set imageBadgeElement %}
{% block badge_element_image_container %}
{% if badgeElement.data.media.url %}
<div class="cms-image-newsletter-badge">
{% block badge_element_image_media %}
{% set attributes = {
'class': 'cms-image',
'alt': (badgeElement.data.media.translated.alt ?: ''),
'title': (badgeElement.data.media.translated.title ?: '')
} %}
{% sw_thumbnails 'cms-image-thumbnails' with {
media: badgeElement.data.media
} %}
{% endblock %}
</div>
{% endif %}
{% endblock %}
{% endset %}
{{ imageBadgeElement }}
{% set contentElementText %}
{% block badge_element_content_container %}
<div class="newsletter-content-area">
{{ contentElement.data.content|raw }}
</div>
{% endblock %}
{% endset %}
<div id="newsletter-thanks-dialog">
<h3>Thank you</h3>
<div class="newsletter-thanks-container"></div>
</div>
{{ contentElementText }}
<div class="cms-newsletter-form">
<form action="{{ path('frontend.form.newsletter.register.handle') }}"
method="post"
class="newsletter-form"
data-form-csrf-handler="true"
data-form-validation="true"
data-form-ajax-submit="true"
id="newsletter-subscribe-form">
{{ sw_csrf('frontend.form.newsletter.register.handle') }}
{% set formViolations = app.request.get('errors') %}
<input type="hidden" name="option" value="subscribe"/>
<input type="submit" class="submit--hidden d-none">
<input name="email"
type="email"
id="footerNewsletterMail"
placeholder="{{ "account.personalMailPlaceholder"|trans }}{{ "general.required"|trans }}"
required="required"
value="{{ data.get('email') }}"
class="email-field {% if formViolations.getViolations('/email') %} is-invalid{% endif %}"/>
<button type="submit" class="btn btn-primary">ANMELDEN</button>
</form>
</div>
</div>
</div>
{% endblock %}