You are here

slick-wrapper.html.twig in Slick Carousel 8.2

Same filename and directory in other branches
  1. 8 templates/slick-wrapper.html.twig

Default theme implementation for a slick wrapper.

Available variables:

  • items: A list of items containing main and thumbnail of slick.html.twig which can be re-position using option Thumbnail position.
  • attributes: HTML attributes to be applied to the list.
  • settings: An array containing the given settings.

File

templates/slick-wrapper.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Default theme implementation for a slick wrapper.
  5. *
  6. * Available variables:
  7. * - items: A list of items containing main and thumbnail of slick.html.twig
  8. * which can be re-position using option Thumbnail position.
  9. * - attributes: HTML attributes to be applied to the list.
  10. * - settings: An array containing the given settings.
  11. *
  12. * @ingroup themeable
  13. */
  14. #}
  15. {%
  16. set classes = [
  17. 'slick-wrapper',
  18. settings.nav ? 'slick-wrapper--asnavfor',
  19. settings.skin ? 'slick-wrapper--' ~ settings.skin|clean_class,
  20. settings.skin_thumbnail ? 'slick-wrapper--' ~ settings.skin_thumbnail|clean_class,
  21. settings.vertical ? 'slick-wrapper--v',
  22. settings.vertical_tn ? 'slick-wrapper--v-tn',
  23. settings.thumbnail_position ? 'slick-wrapper--tn-' ~ settings.thumbnail_position|clean_class,
  24. 'over' in settings.thumbnail_position ? 'slick-wrapper--tn-overlay',
  25. 'over' in settings.thumbnail_position ? 'slick-wrapper--tn-' ~ settings.thumbnail_position|replace({ 'over-' : '' })
  26. ]
  27. %}
  28. {% spaceless %}
  29. {% if settings.nav %}
  30. <div{{ attributes.addClass(classes)|without('id') }}>
  31. {{ items }}
  32. </div>
  33. {% else %}
  34. {{ items }}
  35. {% endif %}
  36. {% endspaceless %}