<?php
use Twig\Environment;
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;
/* layout/app.html.twig */
class __TwigTemplate_4e315fb05733068a193df624da7cc29e extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->parent = false;
$this->blocks = [
'PAGE_CSS' => [$this, 'block_PAGE_CSS'],
'CONTENT_MID' => [$this, 'block_CONTENT_MID'],
'PAGE_JS' => [$this, 'block_PAGE_JS'],
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
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", "layout/app.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "layout/app.html.twig"));
// line 1
echo "<!doctype html>
<html lang=\"";
// line 2
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 2, $this->source); })()), "request", [], "any", false, false, true, 2), "locale", [], "any", false, false, true, 2), 2, $this->source), "html", null, true);
echo "\">
<head>
<meta charset=\"utf-8\" />
<meta name=\"viewport\" content=\"width=device-width, initial-scale=1, shrink-to-fit=no\" />
<link rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"";
// line 6
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("build/images/favicon.png"), "html", null, true);
echo "\" />
";
// line 7
if (array_key_exists("product", $context)) {
// line 8
echo " ";
twig_get_attribute($this->env, $this->source, $this->env->getFunction('pimcore_head_title')->getCallable()(), "set", [0 => twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 8, $this->source); })()), "name", [], "any", false, false, true, 8)], "method", false, false, true, 8);
// line 9
echo " ";
}
// line 10
echo "
";
// line 11
twig_get_attribute($this->env, $this->source, $this->env->getFunction('pimcore_head_title')->getCallable()(), "append", [0 => "Hugo Josten"], "method", false, false, true, 11);
// line 12
echo " ";
twig_get_attribute($this->env, $this->source, $this->env->getFunction('pimcore_head_title')->getCallable()(), "setSeparator", [0 => " - "], "method", false, false, true, 12);
// line 13
echo "
";
// line 14
echo $this->env->getFunction('pimcore_head_title')->getCallable()();
echo "
";
// line 16
echo $this->extensions['Symfony\WebpackEncoreBundle\Twig\EntryFilesTwigExtension']->renderWebpackLinkTags("app");
echo "
";
// line 17
echo $this->extensions['Symfony\WebpackEncoreBundle\Twig\EntryFilesTwigExtension']->renderWebpackScriptTags("app");
echo "
";
// line 19
$this->displayBlock('PAGE_CSS', $context, $blocks);
// line 21
echo "</head>
<body class=\"antialiased\">
<div class=\"bg-white\">
";
// line 24
$context["navStartNode"] = twig_get_attribute($this->env, $this->source, (isset($context["document"]) || array_key_exists("document", $context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.', 24, $this->source); })()), "getProperty", [0 => "navigation_root"], "method", false, false, true, 24);
// line 25
echo " ";
if ( !((array_key_exists("otherLanguageUrl", $context)) ? (_twig_default_filter((isset($context["otherLanguageUrl"]) || array_key_exists("otherLanguageUrl", $context) ? $context["otherLanguageUrl"] : (function () { throw new RuntimeError('Variable "otherLanguageUrl" does not exist.', 25, $this->source); })()), null)) : (null))) {
// line 26
echo " ";
$context["otherLanguageUrl"] = twig_get_attribute($this->env, $this->source, (isset($context["document"]) || array_key_exists("document", $context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.', 26, $this->source); })()), "getProperty", [0 => ("page_in_" . (((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 26, $this->source); })()), "request", [], "any", false, false, true, 26), "getLocale", [], "method", false, false, true, 26) == "en")) ? ("de") : ("en")))], "method", false, false, true, 26);
// line 27
echo " ";
if (twig_test_empty((isset($context["otherLanguageUrl"]) || array_key_exists("otherLanguageUrl", $context) ? $context["otherLanguageUrl"] : (function () { throw new RuntimeError('Variable "otherLanguageUrl" does not exist.', 27, $this->source); })()))) {
// line 28
echo " ";
$context["currentPath"] = $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 28, $this->source); })()), "request", [], "any", false, false, true, 28), "attributes", [], "any", false, false, true, 28), "get", [0 => "_route"], "method", false, false, true, 28), 28, $this->source), (( !(null === twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 28, $this->source); })()), "request", [], "any", false, false, true, 28), "attributes", [], "any", false, false, true, 28), "get", [0 => "_route_params"], "method", false, false, true, 28))) ? (twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 28, $this->source); })()), "request", [], "any", false, false, true, 28), "attributes", [], "any", false, false, true, 28), "get", [0 => "_route_params"], "method", false, false, true, 28)) : ([])));
// line 29
echo " ";
$context["otherLanguageUrl"] = twig_replace_filter($this->sandbox->ensureToStringAllowed((isset($context["currentPath"]) || array_key_exists("currentPath", $context) ? $context["currentPath"] : (function () { throw new RuntimeError('Variable "currentPath" does not exist.', 29, $this->source); })()), 29, $this->source), ["/en/" => "/de/", "/de/" => "/en/"]);
// line 30
echo " ";
if (((isset($context["currentPath"]) || array_key_exists("currentPath", $context) ? $context["currentPath"] : (function () { throw new RuntimeError('Variable "currentPath" does not exist.', 30, $this->source); })()) == (isset($context["otherLanguageUrl"]) || array_key_exists("otherLanguageUrl", $context) ? $context["otherLanguageUrl"] : (function () { throw new RuntimeError('Variable "otherLanguageUrl" does not exist.', 30, $this->source); })()))) {
// line 31
echo " ";
$context["otherLanguageUrl"] = (((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 31, $this->source); })()), "request", [], "any", false, false, true, 31), "getLocale", [], "method", false, false, true, 31) == "en")) ? ("/de") : ("/en"));
// line 32
echo " ";
}
// line 33
echo " ";
}
// line 34
echo " ";
}
// line 35
echo "
";
// line 36
$this->loadTemplate("include/header.html.twig", "layout/app.html.twig", 36)->display($context);
// line 37
echo " <div>
";
// line 39
$this->displayBlock('CONTENT_MID', $context, $blocks);
// line 41
echo "
";
// line 42
$this->loadTemplate("include/footer.html.twig", "layout/app.html.twig", 42)->display($context);
// line 43
echo " </div>
</div>
";
// line 46
$this->displayBlock('PAGE_JS', $context, $blocks);
// line 48
echo "</body>
</html>";
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 19
public function block_PAGE_CSS($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_CSS"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "PAGE_CSS"));
// line 20
echo " ";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 39
public function block_CONTENT_MID($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", "CONTENT_MID"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "CONTENT_MID"));
// line 40
echo " ";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 46
public function block_PAGE_JS($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_JS"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "PAGE_JS"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "layout/app.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 208 => 46, 198 => 40, 188 => 39, 178 => 20, 168 => 19, 157 => 48, 155 => 46, 150 => 43, 148 => 42, 145 => 41, 143 => 39, 139 => 37, 137 => 36, 134 => 35, 131 => 34, 128 => 33, 125 => 32, 122 => 31, 119 => 30, 116 => 29, 113 => 28, 110 => 27, 107 => 26, 104 => 25, 102 => 24, 97 => 21, 95 => 19, 90 => 17, 86 => 16, 81 => 14, 78 => 13, 75 => 12, 73 => 11, 70 => 10, 67 => 9, 64 => 8, 62 => 7, 58 => 6, 51 => 2, 48 => 1,);
}
public function getSourceContext()
{
return new Source("<!doctype html>
<html lang=\"{{ app.request.locale }}\">
<head>
<meta charset=\"utf-8\" />
<meta name=\"viewport\" content=\"width=device-width, initial-scale=1, shrink-to-fit=no\" />
<link rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"{{ asset('build/images/favicon.png') }}\" />
{% if product is defined %}
{% do pimcore_head_title().set(product.name) %}
{% endif %}
{% do pimcore_head_title().append('Hugo Josten') %}
{% do pimcore_head_title().setSeparator(' - ') %}
{{ pimcore_head_title() }}
{{ encore_entry_link_tags('app') }}
{{ encore_entry_script_tags('app') }}
{% block PAGE_CSS %}
{% endblock %}
</head>
<body class=\"antialiased\">
<div class=\"bg-white\">
{% set navStartNode = document.getProperty('navigation_root') %}
{% if not otherLanguageUrl|default(null) %}
{% set otherLanguageUrl = document.getProperty(\"page_in_\" ~ (app.request.getLocale() == \"en\" ? 'de' : 'en')) %}
{% if otherLanguageUrl is empty %}
{% set currentPath = path(app.request.attributes.get('_route'), (app.request.attributes.get('_route_params') is not null ? app.request.attributes.get('_route_params') : []) ) %}
{% set otherLanguageUrl = currentPath|replace({'/en/': '/de/', '/de/':'/en/'}) %}
{% if currentPath == otherLanguageUrl %}
{% set otherLanguageUrl = (app.request.getLocale() == \"en\" ? '/de' : '/en') %}
{% endif %}
{% endif %}
{% endif %}
{% include 'include/header.html.twig' %}
<div>
{% block CONTENT_MID %}
{% endblock %}
{% include 'include/footer.html.twig' %}
</div>
</div>
{% block PAGE_JS %}
{% endblock %}
</body>
</html>", "layout/app.html.twig", "/var/www/html/templates/layout/app.html.twig");
}
public function checkSecurity()
{
static $tags = array("if" => 7, "do" => 8, "block" => 19, "set" => 24, "include" => 36);
static $filters = array("escape" => 2, "default" => 25, "replace" => 29);
static $functions = array("asset" => 6, "pimcore_head_title" => 8, "encore_entry_link_tags" => 16, "encore_entry_script_tags" => 17, "path" => 28);
try {
$this->sandbox->checkSecurity(
['if', 'do', 'block', 'set', 'include'],
['escape', 'default', 'replace'],
['asset', 'pimcore_head_title', 'encore_entry_link_tags', 'encore_entry_script_tags', 'path']
);
} catch (SecurityError $e) {
$e->setSourceContext($this->source);
if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
$e->setTemplateLine($tags[$e->getTagName()]);
} elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
$e->setTemplateLine($filters[$e->getFilterName()]);
} elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
$e->setTemplateLine($functions[$e->getFunctionName()]);
}
throw $e;
}
}
}