<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
use Twig\Extension\SandboxExtension;
use Twig\MacroNamespace;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Sandbox\SecurityNotAllowedTestError;
use Twig\Source;
use Twig\Template;
use Twig\TemplateWrapper;
/* page/category/list.html.twig */
class __TwigTemplate_5d2d38c0580d109cd8ece6881ca3cdd7 extends Template
{
private Source $source;
/**
* @var array<string, MacroNamespace>
*/
private array $macros = [];
private \Twig\Runtime\EscaperRuntime $escaper;
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->escaper = $env->getRuntime('Twig\Runtime\EscaperRuntime');
$this->blocks = [
'page_title' => [$this, 'block_page_title'],
'head_custom_stylesheets' => [$this, 'block_head_custom_stylesheets'],
'content' => [$this, 'block_content'],
];
}
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
{
// line 1
return $this->parent ??= $this->load("base.html.twig", 1);
}
protected function doDisplay(array $context, array $blocks = []): iterable
{
$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", "page/category/list.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "page/category/list.html.twig"));
$this->parent = $this->load("base.html.twig", 1);
yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 3
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_page_title(array $context, array $blocks = []): iterable
{
$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_title"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "page_title"));
// line 4
yield " ";
yield (string) $this->escaper->escape(Twig\Extension\CoreExtension::striptags($this->env->getRuntime('App\Twig\TextResolverRuntime')->resolve("storefront.title")), "html", null, true);
yield " | Kategorien
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
return; yield;
}
// line 7
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_head_custom_stylesheets(array $context, array $blocks = []): iterable
{
$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", "head_custom_stylesheets"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "head_custom_stylesheets"));
// line 8
yield " ";
yield (string) $this->extensions['Symfony\WebpackEncoreBundle\Twig\EntryFilesTwigExtension']->renderWebpackLinkTags("hero-header");
yield "
";
// line 9
yield (string) $this->extensions['Symfony\WebpackEncoreBundle\Twig\EntryFilesTwigExtension']->renderWebpackLinkTags("category");
yield "
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
return; yield;
}
// line 12
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_content(array $context, array $blocks = []): iterable
{
$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", "content"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
// line 13
yield " <div class=\"container-3xl my-5 mt-sm-6 mb-sm-4\">
<div class=\"row\">
<div class=\"col-12\">
<h1 class=\"ornament-with-child\">";
// line 16
yield (string) $this->env->getRuntime('App\Twig\TextResolverRuntime')->resolve("category.page.headline");
yield "</h1>
";
// line 17
yield (string) $this->env->getRuntime('App\Twig\TextResolverRuntime')->resolve("category.page.description");
yield "
</div>
</div>
</div>
<div class=\"container-3xl mb-6\">
";
// line 23
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable(Twig\Extension\CoreExtension::batch(CoreExtension::getAttribute($this->env, $this->source, (isset($context["tenant"]) || array_key_exists("tenant", $context) ? $context["tenant"] : (function () { throw new RuntimeError('Variable "tenant" does not exist.', 23, $this->source); })()), "categories", [], "any", false, false, false, 23), 4));
foreach ($context['_seq'] as $context["_key"] => $context["category_batch"]) {
// line 24
yield " <div class=\"row nth-group\">
";
// line 25
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable($context["category_batch"]);
foreach ($context['_seq'] as $context["_key"] => $context["category"]) {
// line 26
yield " <div class=\"col-12 col-md-6 nth-group-item\">
<div class=\"mb-4 nth-group-item-background position-relative d-flex flex-column justify-content-between overflow-hidden p-5 min-h-24\">
";
// line 28
if ((($tmp = CoreExtension::getAttribute($this->env, $this->source, $context["category"], "listImage", [], "any", false, false, false, 28)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
// line 29
yield " <img class=\"d-none d-md-block position-absolute end--2 product-image\" src=\"/images/";
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "listImage", [], "any", false, false, false, 29), "html", null, true);
yield "\" alt=\"";
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 29), "html", null, true);
yield "\" class=\"img-fluid\">
";
} else {
// line 31
yield " <img width=\"64\" class=\"d-none d-md-block position-absolute opacity-25 end--2 product-image\" src=\"";
yield (string) $this->escaper->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("build/images/icons/box.svg"), "html", null, true);
yield "\" alt=\"";
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 31), "html", null, true);
yield "\" class=\"img-fluid\">
";
}
// line 33
yield " <div class=\"row\">
<div class=\"col-12 col-sm-8\">
<h4 class=\"mb-4\">";
// line 35
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 35), "html", null, true);
yield "</h4>
<p class=\"text-break line-clamp clamp-4\">";
// line 36
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "description", [], "any", false, false, false, 36), "html", null, true);
yield "</p>
";
// line 37
if ((($tmp = CoreExtension::getAttribute($this->env, $this->source, $context["category"], "listImage", [], "any", false, false, false, 37)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
// line 38
yield " <img class=\"d-md-none mx-auto w-75 mb-4 mb-sm-0\" src=\"/images/";
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "listImage", [], "any", false, false, false, 38), "html", null, true);
yield "\" alt=\"";
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 38), "html", null, true);
yield "\" class=\"img-fluid\">
";
} else {
// line 40
yield " <img width=\"64\" class=\"d-md-none mx-auto w-75 mb-4 mb-sm-0 opacity-25\" src=\"";
yield (string) $this->escaper->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("build/images/icons/box.svg"), "html", null, true);
yield "\" alt=\"";
yield (string) $this->escaper->escape(CoreExtension::getAttribute($this->env, $this->source, $context["category"], "name", [], "any", false, false, false, 40), "html", null, true);
yield "\" class=\"img-fluid\">
";
}
// line 42
yield " </div>
</div>
<a href=\"";
// line 44
yield (string) $this->escaper->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("products", ["categoryId" => CoreExtension::getAttribute($this->env, $this->source, $context["category"], "id", [], "any", false, false, false, 44)]), "html", null, true);
yield "\" class=\"d-flex justify-content-end align-items-center text-decoration-none fw-bold\"><span class=\"me-2\">Zur Produktübersicht</span><i class=\"fas fa-arrow-right\"></i></a>
</div>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['category'], $context['_parent']);
$context = array_intersect_key($context, $_parent);
$context += $_parent;
// line 48
yield " </div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['category_batch'], $context['_parent']);
$context = array_intersect_key($context, $_parent);
$context += $_parent;
// line 50
yield " </div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
return; yield;
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "page/category/list.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDefaultEscapeStrategy(): string|false
{
return "html";
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 245 => 50, 237 => 48, 226 => 44, 222 => 42, 214 => 40, 206 => 38, 204 => 37, 200 => 36, 196 => 35, 192 => 33, 184 => 31, 176 => 29, 174 => 28, 170 => 26, 166 => 25, 163 => 24, 159 => 23, 150 => 17, 146 => 16, 141 => 13, 128 => 12, 115 => 9, 110 => 8, 97 => 7, 83 => 4, 70 => 3, 47 => 1,);
}
public function getSourceContext(): Source
{
return new Source("{% extends \x27base.html.twig\x27 %}
{% block page_title %}
{{ \x27storefront.title\x27|resolve|striptags }} | Kategorien
{% endblock %}
{% block head_custom_stylesheets %}
{{ encore_entry_link_tags(\x27hero-header\x27) }}
{{ encore_entry_link_tags(\x27category\x27) }}
{% endblock head_custom_stylesheets %}
{% block content %}
<div class=\"container-3xl my-5 mt-sm-6 mb-sm-4\">
<div class=\"row\">
<div class=\"col-12\">
<h1 class=\"ornament-with-child\">{{ \x27category.page.headline\x27|resolve }}</h1>
{{ \x27category.page.description\x27|resolve }}
</div>
</div>
</div>
<div class=\"container-3xl mb-6\">
{% for category_batch in tenant.categories|batch(4) %}
<div class=\"row nth-group\">
{% for category in category_batch %}
<div class=\"col-12 col-md-6 nth-group-item\">
<div class=\"mb-4 nth-group-item-background position-relative d-flex flex-column justify-content-between overflow-hidden p-5 min-h-24\">
{% if category.listImage %}
<img class=\"d-none d-md-block position-absolute end--2 product-image\" src=\"/images/{{ category.listImage }}\" alt=\"{{ category.name }}\" class=\"img-fluid\">
{% else %}
<img width=\"64\" class=\"d-none d-md-block position-absolute opacity-25 end--2 product-image\" src=\"{{ asset(\x27build/images/icons/box.svg\x27) }}\" alt=\"{{ category.name }}\" class=\"img-fluid\">
{% endif %}
<div class=\"row\">
<div class=\"col-12 col-sm-8\">
<h4 class=\"mb-4\">{{ category.name }}</h4>
<p class=\"text-break line-clamp clamp-4\">{{ category.description }}</p>
{% if category.listImage %}
<img class=\"d-md-none mx-auto w-75 mb-4 mb-sm-0\" src=\"/images/{{ category.listImage }}\" alt=\"{{ category.name }}\" class=\"img-fluid\">
{% else %}
<img width=\"64\" class=\"d-md-none mx-auto w-75 mb-4 mb-sm-0 opacity-25\" src=\"{{ asset(\x27build/images/icons/box.svg\x27) }}\" alt=\"{{ category.name }}\" class=\"img-fluid\">
{% endif %}
</div>
</div>
<a href=\"{{ path(\x27products\x27, {categoryId: category.id}) }}\" class=\"d-flex justify-content-end align-items-center text-decoration-none fw-bold\"><span class=\"me-2\">Zur Produktübersicht</span><i class=\"fas fa-arrow-right\"></i></a>
</div>
</div>
{% endfor %}
</div>
{% endfor %}
</div>
{% endblock %}
", "page/category/list.html.twig", "/srv/storefront/templates/page/category/list.html.twig");
}
}