custom/plugins/TrustedShops/src/Resources/views/storefront/section/cms-section-sidebar.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/section/cms-section-sidebar.html.twig' %}
  2. {% block section_sidebar_content_block %}
  3.     {{ parent() }}
  4.     {% if loop.last %}
  5.         {# Trusted Shops Review Sticker - Start #}
  6.         {% if trustedshops.tsId and trustedshops.tsReviewStickerActive %}
  7.             {% if trustedshops.tsReviewStickerExpertMode %}
  8.                 {{ trustedshops.tsExpertReviewStickerCode|replace({'%tsid%': trustedshops.tsId})|raw }}
  9.             {% else %}
  10.                 <script type="text/javascript">
  11.                     (function() {
  12.                         _tsRatingConfig = {
  13.                             tsid: '{{ trustedshops.tsId|escape('js') }}',
  14.                             variant: 'testimonial',
  15.                             theme: 'light',
  16.                             reviews: '{{ trustedshops.tsReviewStickerReviewCount|escape('js') }}',
  17.                             betterThan: '{{ trustedshops.tsReviewStickerMinRating|escape('js') }}',
  18.                             richSnippets: 'off',
  19.                             backgroundColor: '{{ trustedshops.tsReviewStickerBackgroundColor|escape('js') }}',
  20.                             linkColor: '#000000',
  21.                             quotationMarkColor: '#FFFFFF',
  22.                             fontFamily: '{{ trustedshops.tsReviewStickerFontType|escape('js') }}',
  23.                             reviewMinLength: '10'
  24.                         };
  25.                         var scripts = document.getElementsByTagName('SCRIPT'),
  26.                             me = scripts[scripts.length - 1];
  27.                         var _ts = document.createElement('SCRIPT');
  28.                         _ts.type = 'text/javascript';
  29.                         _ts.async = true;
  30.                         _ts.src = '//widgets.trustedshops.com/reviews/tsSticker/tsSticker.js';
  31.                         me.parentNode.insertBefore(_ts, me);
  32.                         _tsRatingConfig.script = _ts;
  33.                     })();
  34.                 </script>
  35.             {% endif %}
  36.         {% endif %}
  37.         {# Trusted Shops Review Sticker - End #}
  38.     {% endif %}
  39. {% endblock %}