vendor/store.shopware.com/tanmarnginfinitescrolling/src/Resources/views/storefront/base.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/base.html.twig' %}
  2. {% block base_body_classes %}{{ parent() }}{% set TanmarNgInfiniteScrollingData = context.context.extensions.TanmarNgInfiniteScrolling %}{% if TanmarNgInfiniteScrollingData.active %} is-tanmar-infinite-scrolling {% endif %}{% endblock %}
  3. {% block base_body_script %}
  4.     {{ parent() }}
  5.     {% set TanmarNgInfiniteScrollingData = context.context.extensions.TanmarNgInfiniteScrolling %}
  6.     {% if TanmarNgInfiniteScrollingData.active %}
  7.         <script>
  8.             ;(function(){
  9.                 var _pages = parseInt('{{ TanmarNgInfiniteScrollingData.pages }}',10);
  10.                 window._tanmarInfiniteScrolling = {
  11.                     pages: isNaN(_pages) ? 0 : _pages,
  12.                     snippets: {
  13.                         prev: {
  14.                             btn: '{{ "tanmar-infinite-scrolling.prev.btn"|trans }}',
  15.                             navi: '{{ "tanmar-infinite-scrolling.prev.navi"|trans }}'
  16.                         },
  17.                         next: {
  18.                             btn: '{{ "tanmar-infinite-scrolling.next.btn"|trans }}',
  19.                             navi: '{{ "tanmar-infinite-scrolling.next.navi"|trans }}'
  20.                         }
  21.                     },
  22.                     customProduct: '{{ TanmarNgInfiniteScrollingData.customProduct }}',
  23.                     customPrepend: '{{ TanmarNgInfiniteScrollingData.customPrepend }}',
  24.                     customAppend: '{{ TanmarNgInfiniteScrollingData.customAppend }}',
  25.                     rootMargin: '{{ TanmarNgInfiniteScrollingData.rootMargin }}',
  26.                     threshold: '{{ TanmarNgInfiniteScrollingData.threshold }}',
  27.                     debug: {% if TanmarNgInfiniteScrollingData.debug %}true{% else %}false{% endif %},
  28.                     triggerAfterRenderResponseEvent: {% if TanmarNgInfiniteScrollingData.triggerAfterRenderResponseEvent %}true{% else %}false{% endif %},
  29.                     onlyObserveWithinListingWrapper: {% if TanmarNgInfiniteScrollingData.onlyObserveWithinListingWrapper %}true{% else %}false{% endif %},
  30.                     customPaginationSelector: '{{ TanmarNgInfiniteScrollingData.customPaginationSelector }}'
  31.                 };
  32.                 
  33.             })();
  34.         </script>
  35.     {% endif %}
  36. {% endblock %}