{% sw_extends '@Storefront/storefront/section/cms-section-sidebar.html.twig' %}
{% block section_sidebar_content_block %}
{{ parent() }}
{% if loop.last %}
{# Trusted Shops Review Sticker - Start #}
{% if trustedshops.tsId and trustedshops.tsReviewStickerActive %}
{% if trustedshops.tsReviewStickerExpertMode %}
{{ trustedshops.tsExpertReviewStickerCode|replace({'%tsid%': trustedshops.tsId})|raw }}
{% else %}
<script type="text/javascript">
(function() {
_tsRatingConfig = {
tsid: '{{ trustedshops.tsId|escape('js') }}',
variant: 'testimonial',
theme: 'light',
reviews: '{{ trustedshops.tsReviewStickerReviewCount|escape('js') }}',
betterThan: '{{ trustedshops.tsReviewStickerMinRating|escape('js') }}',
richSnippets: 'off',
backgroundColor: '{{ trustedshops.tsReviewStickerBackgroundColor|escape('js') }}',
linkColor: '#000000',
quotationMarkColor: '#FFFFFF',
fontFamily: '{{ trustedshops.tsReviewStickerFontType|escape('js') }}',
reviewMinLength: '10'
};
var scripts = document.getElementsByTagName('SCRIPT'),
me = scripts[scripts.length - 1];
var _ts = document.createElement('SCRIPT');
_ts.type = 'text/javascript';
_ts.async = true;
_ts.src = '//widgets.trustedshops.com/reviews/tsSticker/tsSticker.js';
me.parentNode.insertBefore(_ts, me);
_tsRatingConfig.script = _ts;
})();
</script>
{% endif %}
{% endif %}
{# Trusted Shops Review Sticker - End #}
{% endif %}
{% endblock %}