{% set breakindex = breakindex|default(2) %}
<div class="{{ styleModifier | default(null) }} teaser-slider js-scrolling-row">
{# tour-teaser-row should only contain 4 teasers
teasers are displayed with scrollbar mobile
#}
<div class="{{ items|length < 4 ? 'justify-content-md-center' : '' }} row scrolling-row scrolling-row--invisible-scrollbar js-scrolling-row__row">
{% set break = false %}
{% for item in items %}
{% if not break %}
<div class="col-md-3 col-5 scrolling-row__item js-scrolling-row__item">
{{ include('/Tour/teaser.html.twig', {tour: item}) }}
</div>
{% if loop.index > breakindex %}
{% set break = true %}
{% endif %}
{% endif %}
{% endfor %}
<div class="col-md-3 col-10 scrolling-row__item js-scrolling-row__item">
{% if editmode %}
<div class="editmode-box editmode-box--info mb-5 text-left">
<div class="editmode-box__header">Text Teaser Settings</div>
<div>
<strong>Text: </strong>
{{ pimcore_input('teaser_row-snippet-text') }}
<label>Link </label>
{{ pimcore_link('teaser_row-snippet-link') }}
</div>
</div>
{% else %}
{{ include('Includes/Teaser/simple-text-snippet.html.twig', {
"text": pimcore_input('teaser_row-snippet-text').data,
"button": {
href: pimcore_link('teaser_row-snippet-link').href,
text: pimcore_link('teaser_row-snippet-link').text,
},
"color": "default"
}) }}
{% endif %}
</div>
</div>
{% if items|length > 4 %}
<div class="scrolling-row-navigation">
<button class="teaser-slider__btn scrolling-row__button scrolling-row__button--prev js-scrolling-row__prev scrolling-row__button--disabled"><span class="icon icon-arrow-right" aria-label="Previous"></span></button>
<button class="teaser-slider__btn scrolling-row__button scrolling-row__button--next js-scrolling-row__next"><span class="icon icon-arrow-right" aria-label="Next"></span></button>
</div>
{% endif %}
</div>