<?php
use Twig\Environment;
use function Shopware\Core\Framework\Adapter\Twig\sw_get_attribute;
use function Shopware\Core\Framework\Adapter\Twig\sw_escape_filter;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
/* @FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig */
class __TwigTemplate_626f6da4b9a40145ee4c29c87b1885b6 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'page_product_detail_media' => [$this, 'block_page_product_detail_media'],
'fourtwosixAttributeBadges_product_detail_media' => [$this, 'block_fourtwosixAttributeBadges_product_detail_media'],
];
}
protected function doGetParent(array $context)
{
// line 2
return "@fourtwosixAttributeBadges/storefront/page/product-detail/index.html.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig"));
$this->parent = $this->loadTemplate("@fourtwosixAttributeBadges/storefront/page/product-detail/index.html.twig", "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig", 2);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 3
public function block_page_product_detail_media($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "page_product_detail_media"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "page_product_detail_media"));
// line 4
echo "\t";
// line 5
echo "\t";
$context["galleryWidthConfig"] = (($this->extensions['Shopware\Storefront\Framework\Twig\Extension\ConfigExtension']->theme($context, "zen-product-gallery-slider-width")) ? ($this->extensions['Shopware\Storefront\Framework\Twig\Extension\ConfigExtension']->theme($context, "zen-product-gallery-slider-width")) : (7));
// line 6
echo "\t";
// line 7
echo "
\t";
// line 9
echo "\t\t<div class=\"col-lg-7 product-detail-media col-xl-";
echo sw_escape_filter($this->env, ($context["galleryWidthConfig"] ?? null), "html", null, true);
echo "\"> ";
$this->displayBlock('fourtwosixAttributeBadges_product_detail_media', $context, $blocks);
// line 95
echo "\t</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 9
public function block_fourtwosixAttributeBadges_product_detail_media($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "fourtwosixAttributeBadges_product_detail_media"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "fourtwosixAttributeBadges_product_detail_media"));
// line 10
echo "
\t\t\t";
// line 12
$context["listPrice"] = sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "product", [], "any", false, false, false, 12), "calculatedPrice", [], "any", false, false, false, 12), "listPrice", [], "any", false, false, false, 12);
// line 13
echo "\t\t\t";
$context["isListPrice"] = (($context["listPrice"] ?? null) && (sw_get_attribute($this->env, $this->source, ($context["listPrice"] ?? null), "percentage", [], "any", false, false, false, 13) > 0));
// line 14
echo "\t\t\t";
if (($context["isListPrice"] ?? null)) {
// line 15
echo "\t\t\t\t<div class=\"product-badges\">
\t\t\t\t\t<div class=\"badge badge-danger badge-discount\">
\t\t\t\t\t\t";
// line 17
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "product", [], "any", false, false, false, 17), "calculatedPrice", [], "any", false, false, false, 17), "listPrice", [], "any", false, false, false, 17), "percentage", [], "any", false, false, false, 17), "html", null, true);
echo "
\t\t\t\t\t\t<span>%</span>
\t\t\t\t\t</div>
\t\t\t\t</div>
\t\t\t";
}
// line 22
echo "\t\t\t
\t\t\t";
// line 23
if (sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "product", [], "any", false, false, false, 23), "media", [], "any", false, false, false, 23)) {
// line 24
echo "\t\t\t\t
\t\t\t\t";
// line 25
$this->loadTemplate("@zenitPlatformStratus/storefront/element/cms-element-image-gallery.html.twig", "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig", 25)->display(twig_array_merge($context, ["mediaItems" => // line 26
($context["mediaItems"] ?? null), "zoom" => true, "zoomModal" => true, "displayMode" => "contain", "gutter" => 5, "minHeight" => "430px", "navigationArrows" => "inside", "navigationDots" => "inside", "galleryPosition" => "left", "isProduct" => true, "fallbackImageTitle" => sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, // line 36
($context["page"] ?? null), "product", [], "any", false, false, false, 36), "translated", [], "any", false, false, false, 36), "name", [], "any", false, false, false, 36), "startIndexThumbnails" => 1, "startIndexSlider" => 1, "keepAspectRatioOnZoom" => false]));
// line 41
echo "\t\t\t";
}
// line 42
echo "
\t\t\t<div class=\"d-flex justify-content-center fourtwosix-badges\">
\t\t\t\t";
// line 44
$context["badgesMediaIds"] = [];
// line 45
echo "\t\t\t\t";
$context["propertiesBadge"] = [];
// line 46
echo "\t\t\t\t";
$context["configDefaultMedia"] = $this->extensions['Shopware\Storefront\Framework\Twig\Extension\ConfigExtension']->config($context, "fourtwosixAttributeBadges.config.defaultMedia");
// line 47
echo "
\t\t\t\t";
// line 49
echo "\t\t\t\t";
if ((sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "product", [], "any", false, false, false, 49), "sortedProperties", [], "any", false, false, false, 49) != null)) {
// line 50
echo "\t\t\t\t\t";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable($this->extensions['Swag\Security\Fixes\NEXT24667\SecurityExtension']->filter(sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, ($context["page"] ?? null), "product", [], "any", false, false, false, 50), "sortedProperties", [], "any", false, false, false, 50), function ($__x__) use ($context, $macros) { $context["x"] = $__x__; return (sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["x"], "translated", [], "any", false, false, false, 50), "customFields", [], "any", false, false, false, 50), "attribute_badges", [], "any", false, false, false, 50) == true); }));
foreach ($context['_seq'] as $context["_key"] => $context["x"]) {
// line 51
$context["propertiesBadge"] = twig_array_merge(($context["propertiesBadge"] ?? null), sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["x"], "options", [], "any", false, false, false, 51), "elements", [], "any", false, false, false, 51));
// line 52
echo "\t\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['x'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 53
echo "
\t\t\t\t\t";
// line 54
if (($context["propertiesBadge"] ?? null)) {
// line 55
echo "\t\t\t\t\t\t";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(($context["propertiesBadge"] ?? null));
foreach ($context['_seq'] as $context["_key"] => $context["badge"]) {
// line 56
echo "\t\t\t\t\t\t\t";
if ((sw_get_attribute($this->env, $this->source, $context["badge"], "mediaId", [], "any", false, false, false, 56) != null)) {
// line 57
echo "\t\t\t\t\t\t\t\t";
$context["badgesMediaIds"] = twig_array_merge(($context["badgesMediaIds"] ?? null), [0 => sw_get_attribute($this->env, $this->source, $context["badge"], "mediaId", [], "any", false, false, false, 57)]);
// line 58
echo "\t\t\t\t\t\t\t";
} else {
// line 59
echo "\t\t\t\t\t\t\t\t";
$context["badgesMediaIds"] = twig_array_merge(($context["badgesMediaIds"] ?? null), [0 => ($context["configDefaultMedia"] ?? null)]);
// line 60
echo "\t\t\t\t\t\t\t";
}
// line 61
echo "\t\t\t\t\t\t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['badge'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 62
echo "
\t\t\t\t\t\t";
// line 63
$context["mediaCollection"] = $this->extensions['Shopware\Core\Framework\Adapter\Twig\Extension\MediaExtension']->searchMedia(($context["badgesMediaIds"] ?? null), sw_get_attribute($this->env, $this->source, ($context["context"] ?? null), "context", [], "any", false, false, false, 63));
// line 64
echo "
\t\t\t\t\t\t";
// line 65
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_slice($this->env, $this->extensions['Swag\Security\Fixes\NEXT24667\SecurityExtension']->sort(($context["propertiesBadge"] ?? null), function ($__a__, $__b__) use ($context, $macros) { $context["a"] = $__a__; $context["b"] = $__b__; return (sw_get_attribute($this->env, $this->source, ($context["a"] ?? null), "position", [], "any", false, false, false, 65) <=> sw_get_attribute($this->env, $this->source, ($context["b"] ?? null), "position", [], "any", false, false, false, 65)); }), 0, 8));
$context['loop'] = [
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
];
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["_key"] => $context["badge"]) {
// line 66
echo "\t\t\t\t\t\t\t";
if ((sw_get_attribute($this->env, $this->source, $context["badge"], "mediaId", [], "any", false, false, false, 66) != null)) {
// line 67
echo "\t\t\t\t\t\t\t\t";
$context["badgeMedia"] = sw_get_attribute($this->env, $this->source, ($context["mediaCollection"] ?? null), "get", [0 => sw_get_attribute($this->env, $this->source, $context["badge"], "mediaId", [], "any", false, false, false, 67)], "method", false, false, false, 67);
// line 68
echo "
\t\t\t\t\t\t\t\t";
// line 69
((function () use ($context, $blocks) {
$finder = $this->env->getExtension('Shopware\Core\Framework\Adapter\Twig\Extension\NodeExtension')->getFinder();
$includeTemplate = $finder->find("@Storefront/storefront/utilities/thumbnail.html.twig");
return $this->loadTemplate($includeTemplate ?? null, "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig", 69);
})())->display(twig_array_merge($context, ["media" => // line 70
($context["badgeMedia"] ?? null), "attributes" => ["class" => "img-fluid badgeImg", "data-toggle" => "tooltip", "title" => ((sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, // line 74
$context["badge"], "group", [], "any", false, false, false, 74), "translated", [], "any", false, false, false, 74), "name", [], "any", false, false, false, 74) . ": ") . sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 74), "name", [], "any", false, false, false, 74))], "name" => "product-detail-badge-thumbnails"]));
// line 77
echo "\t\t\t\t\t\t\t";
} elseif (sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "group", [], "any", false, false, false, 77), "translated", [], "any", false, false, false, 77), "customFields", [], "any", false, false, false, 77), "fts_property_group_custom_graphics_option", [], "any", false, false, false, 77)) {
// line 78
echo "\t\t\t\t\t\t\t\t<div class=\"dynamic-badge-box arrow-badge badgeImg\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"";
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "group", [], "any", false, false, false, 78), "translated", [], "any", false, false, false, 78), "name", [], "any", false, false, false, 78), "html", null, true);
echo ": ";
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 78), "name", [], "any", false, false, false, 78), "html", null, true);
echo "\">
\t\t\t\t\t\t\t\t\t<div class=\"option-label\">
\t\t\t\t\t\t\t\t\t\t";
// line 80
echo sw_escape_filter($this->env, (((twig_length_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 80), "name", [], "any", false, false, false, 80)) > 5)) ? ((twig_slice($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 80), "name", [], "any", false, false, false, 80), 0, 3) . "...")) : (sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 80), "name", [], "any", false, false, false, 80))), "html", null, true);
echo "
\t\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t";
} else {
// line 84
echo "\t\t\t\t\t\t\t\t<div class=\"dynamic-badge-box badgeImg\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"";
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "group", [], "any", false, false, false, 84), "translated", [], "any", false, false, false, 84), "name", [], "any", false, false, false, 84), "html", null, true);
echo ": ";
echo sw_escape_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 84), "name", [], "any", false, false, false, 84), "html", null, true);
echo "\">
\t\t\t\t\t\t\t\t\t<div class=\"option-label\">
\t\t\t\t\t\t\t\t\t\t";
// line 86
echo sw_escape_filter($this->env, (((twig_length_filter($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 86), "name", [], "any", false, false, false, 86)) > 5)) ? ((twig_slice($this->env, sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 86), "name", [], "any", false, false, false, 86), 0, 3) . "...")) : (sw_get_attribute($this->env, $this->source, sw_get_attribute($this->env, $this->source, $context["badge"], "translated", [], "any", false, false, false, 86), "name", [], "any", false, false, false, 86))), "html", null, true);
echo "
\t\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t";
}
// line 90
echo "\t\t\t\t\t\t";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['badge'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 91
echo "\t\t\t\t\t";
}
// line 92
echo "\t\t\t\t";
}
// line 93
echo "\t\t\t</div>
\t\t";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 303 => 93, 300 => 92, 297 => 91, 283 => 90, 276 => 86, 268 => 84, 261 => 80, 253 => 78, 250 => 77, 248 => 74, 247 => 70, 240 => 69, 237 => 68, 234 => 67, 231 => 66, 214 => 65, 211 => 64, 209 => 63, 206 => 62, 200 => 61, 197 => 60, 194 => 59, 191 => 58, 188 => 57, 185 => 56, 180 => 55, 178 => 54, 175 => 53, 169 => 52, 167 => 51, 162 => 50, 159 => 49, 156 => 47, 153 => 46, 150 => 45, 148 => 44, 144 => 42, 141 => 41, 139 => 36, 138 => 26, 137 => 25, 134 => 24, 132 => 23, 129 => 22, 121 => 17, 117 => 15, 114 => 14, 111 => 13, 109 => 12, 105 => 10, 95 => 9, 84 => 95, 79 => 9, 76 => 7, 74 => 6, 71 => 5, 69 => 4, 59 => 3, 36 => 2,);
}
public function getSourceContext()
{
return new Source("{% sw_extends '@fourtwosixAttributeBadges/storefront/page/product-detail/index.html.twig' %}
{% block page_product_detail_media %}
\t{# @fourtwosix-edit: FV added Zenit stratus config for PDP #}
\t{% set galleryWidthConfig = theme_config('zen-product-gallery-slider-width') ?: 7 %}
\t{# @fourtwosix-edit: end #}
\t{# @fourtwosix-edit: FV This is new col-xl-{{ galleryWidthConfig }} #}
\t\t<div class=\"col-lg-7 product-detail-media col-xl-{{ galleryWidthConfig }}\"> {% block fourtwosixAttributeBadges_product_detail_media %}
\t\t\t{% set listPrice = page.product.calculatedPrice.listPrice %}
\t\t\t{% set isListPrice = listPrice and listPrice.percentage > 0 %}
\t\t\t{% if isListPrice %}
\t\t\t\t<div class=\"product-badges\">
\t\t\t\t\t<div class=\"badge badge-danger badge-discount\">
\t\t\t\t\t\t{{ page.product.calculatedPrice.listPrice.percentage }}
\t\t\t\t\t\t<span>%</span>
\t\t\t\t\t</div>
\t\t\t\t</div>
\t\t\t{% endif %}
\t\t\t
\t\t\t{% if page.product.media %}
\t\t\t\t
\t\t\t\t{% sw_include '@Storefront/storefront/element/cms-element-image-gallery.html.twig' with {
\t\t\t\t\t'mediaItems': mediaItems,
\t\t\t\t\t'zoom': true,
\t\t\t\t\t'zoomModal': true,
\t\t\t\t\t'displayMode': 'contain',
\t\t\t\t\t'gutter': 5,
\t\t\t\t\t'minHeight': '430px',
\t\t\t\t\t'navigationArrows': 'inside',
\t\t\t\t\t'navigationDots': 'inside',
\t\t\t\t\t'galleryPosition': 'left',
\t\t\t\t\t'isProduct': true,
\t\t\t\t\t'fallbackImageTitle': page.product.translated.name,
\t\t\t\t\t'startIndexThumbnails': 1,
\t\t\t\t\t'startIndexSlider': 1,
\t\t\t\t\t'keepAspectRatioOnZoom': false
\t\t\t\t} %}
\t\t\t{% endif %}
\t\t\t<div class=\"d-flex justify-content-center fourtwosix-badges\">
\t\t\t\t{% set badgesMediaIds = [] %}
\t\t\t\t{% set propertiesBadge = [] %}
\t\t\t\t{% set configDefaultMedia = config('fourtwosixAttributeBadges.config.defaultMedia') %}
\t\t\t\t{# @fourtwosix-edit: RD addedd triangles badge }} #}
\t\t\t\t{% if page.product.sortedProperties != null %}
\t\t\t\t\t{% for x in page.product.sortedProperties|filter(x => x.translated.customFields.attribute_badges == true) -%}
\t\t\t\t\t\t{% set propertiesBadge = propertiesBadge|merge(x.options.elements) %}
\t\t\t\t\t{% endfor %}
\t\t\t\t\t{% if propertiesBadge %}
\t\t\t\t\t\t{% for badge in propertiesBadge %}
\t\t\t\t\t\t\t{% if badge.mediaId != null %}
\t\t\t\t\t\t\t\t{% set badgesMediaIds = badgesMediaIds|merge([badge.mediaId]) %}
\t\t\t\t\t\t\t{% else %}
\t\t\t\t\t\t\t\t{% set badgesMediaIds = badgesMediaIds|merge([configDefaultMedia]) %}
\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t{% endfor %}
\t\t\t\t\t\t{% set mediaCollection = searchMedia(badgesMediaIds, context.context) %}
\t\t\t\t\t\t{% for badge in propertiesBadge|sort((a, b) => a.position <=> b.position)|slice(0,8) %}
\t\t\t\t\t\t\t{% if badge.mediaId != null %}
\t\t\t\t\t\t\t\t{% set badgeMedia = mediaCollection.get(badge.mediaId) %}
\t\t\t\t\t\t\t\t{% sw_thumbnails 'product-detail-badge-thumbnails' with {
\t\t\t\t\t\t\t\t\tmedia: badgeMedia,
\t\t\t\t\t\t\t\t\tattributes: {
\t\t\t\t\t\t\t\t\t\t'class': 'img-fluid badgeImg',
\t\t\t\t\t\t\t\t\t\t'data-toggle' : 'tooltip',
\t\t\t\t\t\t\t\t\t\t'title': badge.group.translated.name ~ ': ' ~ badge.translated.name
\t\t\t\t\t\t\t\t\t}
\t\t\t\t\t\t\t\t} %}
\t\t\t\t\t\t\t{% elseif badge.group.translated.customFields.fts_property_group_custom_graphics_option %}
\t\t\t\t\t\t\t\t<div class=\"dynamic-badge-box arrow-badge badgeImg\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"{{ badge.group.translated.name }}: {{ badge.translated.name }}\">
\t\t\t\t\t\t\t\t\t<div class=\"option-label\">
\t\t\t\t\t\t\t\t\t\t{{ badge.translated.name|length > 5 ? badge.translated.name|slice(0, 3) ~ '...' : badge.translated.name }}
\t\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t{% else %}
\t\t\t\t\t\t\t\t<div class=\"dynamic-badge-box badgeImg\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"{{ badge.group.translated.name }}: {{ badge.translated.name }}\">
\t\t\t\t\t\t\t\t\t<div class=\"option-label\">
\t\t\t\t\t\t\t\t\t\t{{ badge.translated.name|length > 5 ? badge.translated.name|slice(0, 3) ~ '...' : badge.translated.name }}
\t\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t\t</div>
\t\t\t\t\t\t\t{% endif %}
\t\t\t\t\t\t{% endfor %}
\t\t\t\t\t{% endif %}
\t\t\t\t{% endif %}
\t\t\t</div>
\t\t{% endblock %}
\t</div>
{% endblock %}
", "@FourtwosixThemeExtension/storefront/page/product-detail/index.html.twig", "/var/www/dev.artecon.426.agency/custom/plugins/FourtwosixThemeExtension/src/Resources/views/storefront/page/product-detail/index.html.twig");
}
}