var/cache/dev_h24eaf6979abf10b67456256024eb9e5e/twig/ca/ca759ccb4ab0af95b4c0c75f6bb13231a45eef33ae1dae500a7bf353997a968a.php line 47

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use function Shopware\Core\Framework\Adapter\Twig\sw_get_attribute;
  4. use function Shopware\Core\Framework\Adapter\Twig\sw_escape_filter;
  5. use Twig\Error\LoaderError;
  6. use Twig\Error\RuntimeError;
  7. use Twig\Extension\SandboxExtension;
  8. use Twig\Markup;
  9. use Twig\Sandbox\SecurityError;
  10. use Twig\Sandbox\SecurityNotAllowedTagError;
  11. use Twig\Sandbox\SecurityNotAllowedFilterError;
  12. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  13. use Twig\Source;
  14. use Twig\Template;
  15. /* @Storefront/storefront/page/content/detail.html.twig */
  16. class __TwigTemplate_feed2adf619bd650d6e1c57f1e18d7a7 extends Template
  17. {
  18.     private $source;
  19.     private $macros = [];
  20.     public function __construct(Environment $env)
  21.     {
  22.         parent::__construct($env);
  23.         $this->source $this->getSourceContext();
  24.         $this->parent false;
  25.         $this->blocks = [
  26.             'page_content_sections_inner' => [$this'block_page_content_sections_inner'],
  27.             'page_content_section' => [$this'block_page_content_section'],
  28.         ];
  29.     }
  30.     protected function doDisplay(array $context, array $blocks = [])
  31.     {
  32.         $macros $this->macros;
  33.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  34.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@Storefront/storefront/page/content/detail.html.twig"));
  35.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  36.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@Storefront/storefront/page/content/detail.html.twig"));
  37.         // line 1
  38.         $this->displayBlock('page_content_sections_inner'$context$blocks);
  39.         
  40.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  41.         
  42.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  43.     }
  44.     public function block_page_content_sections_inner($context, array $blocks = [])
  45.     {
  46.         $macros $this->macros;
  47.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  48.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""page_content_sections_inner"));
  49.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  50.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""page_content_sections_inner"));
  51.         // line 2
  52.         echo "    <div class=\"cms-sections\">
  53.         ";
  54.         // line 3
  55.         $context['_parent'] = $context;
  56.         $context['_seq'] = twig_ensure_traversable(sw_get_attribute($this->env$this->source, ($context["cmsPage"] ?? null), "sections", [], "any"falsefalsefalse3));
  57.         $context['loop'] = [
  58.           'parent' => $context['_parent'],
  59.           'index0' => 0,
  60.           'index'  => 1,
  61.           'first'  => true,
  62.         ];
  63.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  64.             $length count($context['_seq']);
  65.             $context['loop']['revindex0'] = $length 1;
  66.             $context['loop']['revindex'] = $length;
  67.             $context['loop']['length'] = $length;
  68.             $context['loop']['last'] = === $length;
  69.         }
  70.         foreach ($context['_seq'] as $context["_key"] => $context["section"]) {
  71.             // line 4
  72.             echo "            ";
  73.             $context["sectionBgColor"] = sw_get_attribute($this->env$this->source$context["section"], "backgroundColor", [], "any"falsefalsefalse4);
  74.             // line 5
  75.             echo "            ";
  76.             $context["sectionBgImg"] = $this->extensions['Shopware\Storefront\Framework\Twig\Extension\UrlEncodingTwigFilter']->encodeMediaUrl(sw_get_attribute($this->env$this->source$context["section"], "backgroundMedia", [], "any"falsefalsefalse5));
  77.             // line 6
  78.             echo "            ";
  79.             $context["sectionBgImgMode"] = sw_get_attribute($this->env$this->source$context["section"], "backgroundMediaMode", [], "any"falsefalsefalse6);
  80.             // line 7
  81.             echo "
  82.             ";
  83.             // line 8
  84.             $context["sectionClasses"] = [=> sw_get_attribute($this->env$this->source$context["section"], "cssClass", [], "any"falsefalsefalse8), => ("pos-" sw_get_attribute($this->env$this->source$context["section"], "position", [], "any"falsefalsefalse8)), => ("cms-section-" sw_get_attribute($this->env$this->source$context["section"], "type", [], "any"falsefalsefalse8))];
  85.             // line 9
  86.             echo "
  87.             ";
  88.             // line 10
  89.             if (($context["sectionBgImg"] ?? null)) {
  90.                 // line 11
  91.                 echo "                ";
  92.                 $context["sectionClasses"] = twig_array_merge([=> "bg-image"], ($context["sectionClasses"] ?? null));
  93.                 // line 12
  94.                 echo "            ";
  95.             }
  96.             // line 13
  97.             echo "
  98.             ";
  99.             // line 14
  100.             if (($context["sectionBgColor"] ?? null)) {
  101.                 // line 15
  102.                 echo "                ";
  103.                 $context["sectionClasses"] = twig_array_merge([=> "bg-color"], ($context["sectionClasses"] ?? null));
  104.                 // line 16
  105.                 echo "            ";
  106.             }
  107.             // line 17
  108.             echo "
  109.             ";
  110.             // line 18
  111.             $this->displayBlock('page_content_section'$context$blocks);
  112.             // line 25
  113.             echo "        ";
  114.             ++$context['loop']['index0'];
  115.             ++$context['loop']['index'];
  116.             $context['loop']['first'] = false;
  117.             if (isset($context['loop']['length'])) {
  118.                 --$context['loop']['revindex0'];
  119.                 --$context['loop']['revindex'];
  120.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  121.             }
  122.         }
  123.         $_parent $context['_parent'];
  124.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['section'], $context['_parent'], $context['loop']);
  125.         $context array_intersect_key($context$_parent) + $_parent;
  126.         // line 26
  127.         echo "    </div>
  128. ";
  129.         
  130.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  131.         
  132.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  133.     }
  134.     // line 18
  135.     public function block_page_content_section($context, array $blocks = [])
  136.     {
  137.         $macros $this->macros;
  138.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  139.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""page_content_section"));
  140.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  141.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""page_content_section"));
  142.         // line 19
  143.         echo "                <div class=\"cms-section ";
  144.         echo sw_escape_filter($this->envtwig_join_filter(($context["sectionClasses"] ?? null), " "), "html"nulltrue);
  145.         echo "\"
  146.                      style=\"";
  147.         // line 20
  148.         if (($context["sectionBgColor"] ?? null)) {
  149.             echo "background-color: ";
  150.             echo sw_escape_filter($this->env, ($context["sectionBgColor"] ?? null), "html"nulltrue);
  151.             echo ";";
  152.         }
  153.         if (($context["sectionBgImg"] ?? null)) {
  154.             echo "background-image: url(";
  155.             echo sw_escape_filter($this->env, ($context["sectionBgImg"] ?? null), "html"nulltrue);
  156.             echo ");background-size: ";
  157.             echo sw_escape_filter($this->envsw_get_attribute($this->env$this->source, ($context["section"] ?? null), "backgroundMediaMode", [], "any"falsefalsefalse20), "html"nulltrue);
  158.             echo ";";
  159.         }
  160.         echo "\">
  161.                     ";
  162.         // line 22
  163.         ((function () use ($context$blocks) {
  164.             $finder $this->env->getExtension('Shopware\Core\Framework\Adapter\Twig\Extension\NodeExtension')->getFinder();
  165.             $includeTemplate $finder->find((("@Storefront/storefront/section/cms-section-" sw_get_attribute($this->env$this->source, ($context["section"] ?? null), "type", [], "any"falsefalsefalse22)) . ".html.twig"));
  166.             return $this->loadTemplate($includeTemplate ?? null"@Storefront/storefront/page/content/detail.html.twig"22);
  167.         })())->display($context);
  168.         // line 23
  169.         echo "                </div>
  170.             ";
  171.         
  172.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  173.         
  174.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  175.     }
  176.     public function getTemplateName()
  177.     {
  178.         return "@Storefront/storefront/page/content/detail.html.twig";
  179.     }
  180.     public function getDebugInfo()
  181.     {
  182.         return array (  189 => 23,  181 => 22,  165 => 20,  160 => 19,  150 => 18,  139 => 26,  125 => 25,  123 => 18,  120 => 17,  117 => 16,  114 => 15,  112 => 14,  109 => 13,  106 => 12,  103 => 11,  101 => 10,  98 => 9,  96 => 8,  93 => 7,  90 => 6,  87 => 5,  84 => 4,  67 => 3,  64 => 2,  45 => 1,);
  183.     }
  184.     public function getSourceContext()
  185.     {
  186.         return new Source("{% block page_content_sections_inner %}
  187.     <div class=\"cms-sections\">
  188.         {% for section in cmsPage.sections %}
  189.             {% set sectionBgColor = section.backgroundColor %}
  190.             {% set sectionBgImg = section.backgroundMedia|sw_encode_media_url %}
  191.             {% set sectionBgImgMode = section.backgroundMediaMode %}
  192.             {% set sectionClasses = [section.cssClass, 'pos-' ~ section.position, 'cms-section-' ~ section.type] %}
  193.             {% if sectionBgImg %}
  194.                 {% set sectionClasses = ['bg-image']|merge(sectionClasses) %}
  195.             {% endif %}
  196.             {% if sectionBgColor %}
  197.                 {% set sectionClasses = ['bg-color']|merge(sectionClasses) %}
  198.             {% endif %}
  199.             {% block page_content_section %}
  200.                 <div class=\"cms-section {{ sectionClasses|join(' ') }}\"
  201.                      style=\"{% if sectionBgColor %}background-color: {{ sectionBgColor }};{% endif %}{% if sectionBgImg %}background-image: url({{ sectionBgImg }});background-size: {{ section.backgroundMediaMode }};{% endif %}\">
  202.                     {% sw_include \"@Storefront/storefront/section/cms-section-\" ~ section.type ~ \".html.twig\" %}
  203.                 </div>
  204.             {% endblock %}
  205.         {% endfor %}
  206.     </div>
  207. {% endblock %}
  208. ""@Storefront/storefront/page/content/detail.html.twig""/var/www/html/htdocs/vendor/shopware/storefront/Resources/views/storefront/page/content/detail.html.twig");
  209.     }
  210. }