<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
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;
use Twig\TemplateWrapper;
/* base.html.twig */
class __TwigTemplate_279567a4b0614f275c74f9a2a316a5e9 extends Template
{
private Source $source;
/**
* @var array<string, Template>
*/
private array $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'responsive_header_logo' => [$this, 'block_responsive_header_logo'],
'header_logo' => [$this, 'block_header_logo'],
'content_top_header' => [$this, 'block_content_top_header'],
'header_custom_menu' => [$this, 'block_header_custom_menu'],
'content_footer_wrapper' => [$this, 'block_content_footer_wrapper'],
'body_javascript' => [$this, 'block_body_javascript'],
];
}
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
{
// line 1
return "@!EasyAdmin/layout.html.twig";
}
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", "base.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "base.html.twig"));
$this->parent = $this->loadTemplate("@!EasyAdmin/layout.html.twig", "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_responsive_header_logo(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", "responsive_header_logo"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "responsive_header_logo"));
// line 4
yield " <a class=\"responsive-logo ";
yield (((Twig\Extension\CoreExtension::length($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, (isset($context["ea"]) || array_key_exists("ea", $context) ? $context["ea"] : (function () { throw new RuntimeError('Variable "ea" does not exist.', 4, $this->source); })()), "dashboardTitle", [], "any", false, false, false, 4)) > 14)) ? ("logo-long") : (""));
yield "\" title=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::striptags(CoreExtension::getAttribute($this->env, $this->source, (isset($context["ea"]) || array_key_exists("ea", $context) ? $context["ea"] : (function () { throw new RuntimeError('Variable "ea" does not exist.', 4, $this->source); })()), "dashboardTitle", [], "any", false, false, false, 4)), "html", null, true);
yield "\" href=\"";
yield $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("easyadmin");
yield "\">
<img id=\"responsive-logo\" src=\"/build/images/logo-iveco.png\" alt=\"logo\" />
<span class=\"header-version\">- ";
// line 6
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::upper($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 6, $this->source); })()), "environment", [], "any", false, false, false, 6)), "html", null, true);
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["version"]) || array_key_exists("version", $context) ? $context["version"] : (function () { throw new RuntimeError('Variable "version" does not exist.', 6, $this->source); })()), "html", null, true);
yield "</span>
</a>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 10
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_header_logo(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", "header_logo"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "header_logo"));
// line 11
yield " <a class=\"logo ";
yield (((Twig\Extension\CoreExtension::length($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, (isset($context["ea"]) || array_key_exists("ea", $context) ? $context["ea"] : (function () { throw new RuntimeError('Variable "ea" does not exist.', 11, $this->source); })()), "dashboardTitle", [], "any", false, false, false, 11)) > 14)) ? ("logo-long") : (""));
yield "\" title=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::striptags(CoreExtension::getAttribute($this->env, $this->source, (isset($context["ea"]) || array_key_exists("ea", $context) ? $context["ea"] : (function () { throw new RuntimeError('Variable "ea" does not exist.', 11, $this->source); })()), "dashboardTitle", [], "any", false, false, false, 11)), "html", null, true);
yield "\" href=\"";
yield $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("easyadmin");
yield "\">
<img src=\"/build/images/logo-iveco.png\" alt=\"logo\" />
</a>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 15
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_content_top_header(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_top_header"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content_top_header"));
// line 16
yield " <span class=\"header-version\">- ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::upper($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 16, $this->source); })()), "environment", [], "any", false, false, false, 16)), "html", null, true);
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["version"]) || array_key_exists("version", $context) ? $context["version"] : (function () { throw new RuntimeError('Variable "version" does not exist.', 16, $this->source); })()), "html", null, true);
yield "</span>
<div class=\"navbar-custom-menu ms-auto\">
";
// line 18
yield from $this->unwrap()->yieldBlock('header_custom_menu', $context, $blocks);
// line 21
yield " </div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 18
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_header_custom_menu(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", "header_custom_menu"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "header_custom_menu"));
// line 19
yield " ";
yield from $this->yieldParentBlock("header_custom_menu", $context, $blocks);
yield "
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 24
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_content_footer_wrapper(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_footer_wrapper"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content_footer_wrapper"));
// line 25
yield " <div id=\"modal-confirm\" class=\"modal fade\" tabindex=\"-1\">
<div class=\"modal-dialog\">
<div class=\"modal-content\">
<div class=\"modal-body\">
<p>";
// line 29
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("batch_action_modal.title", [], "EasyAdminBundle"), "html", null, true);
yield "</p>
</div>
<div class=\"modal-footer\">
<button type=\"button\" data-bs-dismiss=\"modal\" class=\"btn btn-secondary\">
<span class=\"btn-label\">";
// line 33
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("action.cancel", [], "EasyAdminBundle"), "html", null, true);
yield "</span>
</button>
<button type=\"button\" data-bs-dismiss=\"modal\" class=\"btn btn-success\" id=\"modal-confirm-button\">
<span class=\"btn-label\">";
// line 37
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Confirm"), "html", null, true);
yield "</span>
</button>
</div>
</div>
</div>
</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 45
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_body_javascript(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", "body_javascript"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "body_javascript"));
// line 46
yield " ";
yield from $this->yieldParentBlock("body_javascript", $context, $blocks);
yield "
<script type=\"text/javascript\">
function applyStylesBasedOnHeaderVisibility() {
const responsiveHeader = document.querySelector('.responsive-header');
const otherElement = document.querySelector('.header-version');
if (window?.getComputedStyle(responsiveHeader)?.display !== 'none') {
// Applica le regole quando responsive-header è visibile
otherElement.style.top = '1%';
otherElement.style.position = 'relative';
// Puoi aggiungere altre regole qui
} else {
// Se responsive-header ha display: none, puoi anche rimuovere le regole o cambiarle
otherElement.style.top = '';
otherElement.style.position = 'fixed';
}
}
// Esegui la funzione quando il DOM è pronto
document.addEventListener(\"DOMContentLoaded\", function() {
applyStylesBasedOnHeaderVisibility();
});
// Esegui la funzione quando la finestra viene ridimensionata
window.addEventListener(\"resize\", function() {
applyStylesBasedOnHeaderVisibility();
});
</script>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "base.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 266 => 46, 253 => 45, 235 => 37, 228 => 33, 221 => 29, 215 => 25, 202 => 24, 188 => 19, 175 => 18, 163 => 21, 161 => 18, 153 => 16, 140 => 15, 120 => 11, 107 => 10, 91 => 6, 81 => 4, 68 => 3, 45 => 1,);
}
public function getSourceContext(): Source
{
return new Source("{% extends '@!EasyAdmin/layout.html.twig' %}
{# {% block responsive_header %} #}
{% block responsive_header_logo %}
<a class=\"responsive-logo {{ ea.dashboardTitle|length > 14 ? 'logo-long' }}\" title=\"{{ ea.dashboardTitle|striptags }}\" href=\"{{ path('easyadmin') }}\">
<img id=\"responsive-logo\" src=\"/build/images/logo-iveco.png\" alt=\"logo\" />
<span class=\"header-version\">- {{ app.environment | upper }} {{ version }}</span>
</a>
{% endblock responsive_header_logo %}
{# {% endblock responsive_header %} #}
{% block header_logo %}
<a class=\"logo {{ ea.dashboardTitle|length > 14 ? 'logo-long' }}\" title=\"{{ ea.dashboardTitle|striptags }}\" href=\"{{ path('easyadmin') }}\">
<img src=\"/build/images/logo-iveco.png\" alt=\"logo\" />
</a>
{% endblock header_logo %}
{% block content_top_header %}
<span class=\"header-version\">- {{ app.environment | upper }} {{ version }}</span>
<div class=\"navbar-custom-menu ms-auto\">
{% block header_custom_menu %}
{{parent()}}
{% endblock header_custom_menu %}
</div>
{% endblock content_top_header %}
{% block content_footer_wrapper %}
<div id=\"modal-confirm\" class=\"modal fade\" tabindex=\"-1\">
<div class=\"modal-dialog\">
<div class=\"modal-content\">
<div class=\"modal-body\">
<p>{{ 'batch_action_modal.title'|trans(domain = 'EasyAdminBundle') }}</p>
</div>
<div class=\"modal-footer\">
<button type=\"button\" data-bs-dismiss=\"modal\" class=\"btn btn-secondary\">
<span class=\"btn-label\">{{ 'action.cancel'|trans([], 'EasyAdminBundle') }}</span>
</button>
<button type=\"button\" data-bs-dismiss=\"modal\" class=\"btn btn-success\" id=\"modal-confirm-button\">
<span class=\"btn-label\">{{ 'Confirm'|trans }}</span>
</button>
</div>
</div>
</div>
</div>
{% endblock %}
{% block body_javascript %}
{{ parent() }}
<script type=\"text/javascript\">
function applyStylesBasedOnHeaderVisibility() {
const responsiveHeader = document.querySelector('.responsive-header');
const otherElement = document.querySelector('.header-version');
if (window?.getComputedStyle(responsiveHeader)?.display !== 'none') {
// Applica le regole quando responsive-header è visibile
otherElement.style.top = '1%';
otherElement.style.position = 'relative';
// Puoi aggiungere altre regole qui
} else {
// Se responsive-header ha display: none, puoi anche rimuovere le regole o cambiarle
otherElement.style.top = '';
otherElement.style.position = 'fixed';
}
}
// Esegui la funzione quando il DOM è pronto
document.addEventListener(\"DOMContentLoaded\", function() {
applyStylesBasedOnHeaderVisibility();
});
// Esegui la funzione quando la finestra viene ridimensionata
window.addEventListener(\"resize\", function() {
applyStylesBasedOnHeaderVisibility();
});
</script>
{% endblock %}", "base.html.twig", "/var/www/html/templates/base.html.twig");
}
}