{% set selectStore = [] %} {% for i in 2..29 %} {% set selectStore = selectStore|merge([i]) %} {% endfor %} {% set slidesSelect = pimcore_select('slides', { store: selectStore, reload: true, width: 70 }) %} {% set showPreviewsCheckbox = pimcore_checkbox('showPreviews') %} {% set showPreviews = showPreviewsCheckbox.isChecked and not editmode %} {% set id = 'gallery-carousel-' ~ uniqid() %} {% set slides = slidesSelect.getData()|default(2) %} {% if editmode %}
How many images you want to show? {{ slidesSelect|raw }}
Show Previews {{ showPreviewsCheckbox|raw }}
{% endif %}
    {% for i in 0..(slides-1) %}
  1. {% if showPreviews %} {{ pimcore_image('image_' ~ i, { thumbnail: 'galleryCarouselPreview', }) }} {% endif %}
  2. {% endfor %}
{% for i in 0..(slides-1) %}
{{ pimcore_image('image_' ~ i, { thumbnail: 'galleryCarousel', dropClass: id ~ '-' ~ i, defaultHeight: 200 }) }}
{% set captionTitle = pimcore_input('caption-title-' ~ i, { width: 400 }) %} {% set captionText = pimcore_textarea('caption-text-' ~ i, { width: 400 }) %} {% if editmode or not captionTitle.isEmpty() %}

{{ captionTitle|raw }}

{% endif %} {% if editmode or not captionText.isEmpty() %}

{{ captionText|raw }}

{% endif %}
{% endfor %}