var/cache/dev/twig/1a/1a4e0507d62f2ffd1fe1fc6bfb9e7062.php line 53

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\CoreExtension;
  6. use Twig\Extension\SandboxExtension;
  7. use Twig\Markup;
  8. use Twig\Sandbox\SecurityError;
  9. use Twig\Sandbox\SecurityNotAllowedTagError;
  10. use Twig\Sandbox\SecurityNotAllowedFilterError;
  11. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  12. use Twig\Source;
  13. use Twig\Template;
  14. use Twig\TemplateWrapper;
  15. /* fe/_pages_header.html.twig */
  16. class __TwigTemplate_7af73a8757c11a7e67c60fd7a34bed84 extends Template
  17. {
  18. private Source $source;
  19. /**
  20. * @var array<string, Template>
  21. */
  22. private array $macros = [];
  23. public function __construct(Environment $env)
  24. {
  25. parent::__construct($env);
  26. $this->source = $this->getSourceContext();
  27. $this->parent = false;
  28. $this->blocks = [
  29. ];
  30. }
  31. protected function doDisplay(array $context, array $blocks = []): iterable
  32. {
  33. $macros = $this->macros;
  34. $__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  35. $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "fe/_pages_header.html.twig"));
  36. $__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  37. $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "fe/_pages_header.html.twig"));
  38. // line 1
  39. $context["addEditCoverPhotoBtn"] = false;
  40. // line 2
  41. if ((($tmp = !array_key_exists("image", $context)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
  42. // line 3
  43. yield " ";
  44. $context["image"] = $this->env->getRuntime('PN\ContentBundle\Twig\VarsRuntime')->getDynamicContentAttribute(8, false);
  45. // line 4
  46. yield " ";
  47. $context["addEditCoverPhotoBtn"] = true;
  48. }
  49. // line 6
  50. yield "
  51. ";
  52. // line 7
  53. if (Twig\Extension\CoreExtension::testEmpty((isset($context["image"]) || array_key_exists("image", $context) ? $context["image"] : (function () { throw new RuntimeError('Variable "image" does not exist.', 7, $this->source); })()))) {
  54. // line 8
  55. yield " ";
  56. $context["image"] = $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("/assets/img/placeholder-landscape.webp");
  57. }
  58. // line 10
  59. yield "<div class=\"l-featured-section ui-featured-section lazyload ";
  60. yield (((array_key_exists("desktopOnly", $context) && ((isset($context["desktopOnly"]) || array_key_exists("desktopOnly", $context) ? $context["desktopOnly"] : (function () { throw new RuntimeError('Variable "desktopOnly" does not exist.', 10, $this->source); })()) == true))) ? ("l-featured-section--desktop-only") : (""));
  61. yield " ";
  62. yield (((array_key_exists("marginBottomZero", $context) && ((isset($context["marginBottomZero"]) || array_key_exists("marginBottomZero", $context) ? $context["marginBottomZero"] : (function () { throw new RuntimeError('Variable "marginBottomZero" does not exist.', 10, $this->source); })()) == true))) ? ("ui-featured-section--spacing-bottom-0") : (""));
  63. yield " \"
  64. data-bg=\"";
  65. // line 11
  66. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["image"]) || array_key_exists("image", $context) ? $context["image"] : (function () { throw new RuntimeError('Variable "image" does not exist.', 11, $this->source); })()), "html", null, true);
  67. yield "\"
  68. data-delay=\"5000\"
  69. >
  70. <div class=\"l-featured-section-content\">
  71. ";
  72. // line 15
  73. if ((($tmp = (isset($context["addEditCoverPhotoBtn"]) || array_key_exists("addEditCoverPhotoBtn", $context) ? $context["addEditCoverPhotoBtn"] : (function () { throw new RuntimeError('Variable "addEditCoverPhotoBtn" does not exist.', 15, $this->source); })())) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
  74. // line 16
  75. yield " ";
  76. yield $this->env->getRuntime('PN\ContentBundle\Twig\VarsRuntime')->editDynamicContentAttribute(8);
  77. yield "
  78. ";
  79. }
  80. // line 18
  81. yield " <div class=\"l-container\">
  82. <div class=\"l-flex-row\">
  83. <div class=\"l-flex-col-lg-12\">
  84. <div class=\"l-featured-section-content-box\">
  85. <div class=\"l-page-title-box\">
  86. ";
  87. // line 23
  88. if (array_key_exists("pageTitle", $context)) {
  89. // line 24
  90. yield " <h1 class=\"l-page-title ui-page-title ";
  91. yield ((( !array_key_exists("description", $context) || Twig\Extension\CoreExtension::testEmpty((isset($context["description"]) || array_key_exists("description", $context) ? $context["description"] : (function () { throw new RuntimeError('Variable "description" does not exist.', 24, $this->source); })())))) ? ("ui-page-title--no-description") : (""));
  92. yield "\">";
  93. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["pageTitle"]) || array_key_exists("pageTitle", $context) ? $context["pageTitle"] : (function () { throw new RuntimeError('Variable "pageTitle" does not exist.', 24, $this->source); })()), "html", null, true);
  94. yield "</h1>
  95. ";
  96. }
  97. // line 26
  98. yield " ";
  99. if ((array_key_exists("description", $context) && !Twig\Extension\CoreExtension::testEmpty((isset($context["description"]) || array_key_exists("description", $context) ? $context["description"] : (function () { throw new RuntimeError('Variable "description" does not exist.', 26, $this->source); })())))) {
  100. // line 27
  101. yield " <div class=\"l-page-desc ui-page-desc\">
  102. ";
  103. // line 28
  104. if ((CoreExtension::inFilter("<", (isset($context["description"]) || array_key_exists("description", $context) ? $context["description"] : (function () { throw new RuntimeError('Variable "description" does not exist.', 28, $this->source); })())) && CoreExtension::inFilter(">", (isset($context["description"]) || array_key_exists("description", $context) ? $context["description"] : (function () { throw new RuntimeError('Variable "description" does not exist.', 28, $this->source); })())))) {
  105. // line 29
  106. yield " ";
  107. yield (isset($context["description"]) || array_key_exists("description", $context) ? $context["description"] : (function () { throw new RuntimeError('Variable "description" does not exist.', 29, $this->source); })());
  108. yield "
  109. ";
  110. } else {
  111. // line 31
  112. yield " ";
  113. yield Twig\Extension\CoreExtension::nl2br($this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["description"]) || array_key_exists("description", $context) ? $context["description"] : (function () { throw new RuntimeError('Variable "description" does not exist.', 31, $this->source); })()), "html", null, true));
  114. yield "
  115. ";
  116. }
  117. // line 33
  118. yield " </div>
  119. ";
  120. }
  121. // line 35
  122. yield " </div>
  123. </div>
  124. </div>
  125. </div>
  126. </div>
  127. </div>
  128. </div>";
  129. $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  130. $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  131. yield from [];
  132. }
  133. /**
  134. * @codeCoverageIgnore
  135. */
  136. public function getTemplateName(): string
  137. {
  138. return "fe/_pages_header.html.twig";
  139. }
  140. /**
  141. * @codeCoverageIgnore
  142. */
  143. public function isTraitable(): bool
  144. {
  145. return false;
  146. }
  147. /**
  148. * @codeCoverageIgnore
  149. */
  150. public function getDebugInfo(): array
  151. {
  152. return array ( 131 => 35, 127 => 33, 121 => 31, 115 => 29, 113 => 28, 110 => 27, 107 => 26, 99 => 24, 97 => 23, 90 => 18, 84 => 16, 82 => 15, 75 => 11, 68 => 10, 64 => 8, 62 => 7, 59 => 6, 55 => 4, 52 => 3, 50 => 2, 48 => 1,);
  153. }
  154. public function getSourceContext(): Source
  155. {
  156. return new Source("{% set addEditCoverPhotoBtn = false %}
  157. {% if image is not defined %}
  158. {% set image = getDCA(8, false) %}
  159. {% set addEditCoverPhotoBtn = true %}
  160. {% endif %}
  161. {% if image is empty %}
  162. {% set image = asset('/assets/img/placeholder-landscape.webp') %}
  163. {% endif %}
  164. <div class=\"l-featured-section ui-featured-section lazyload {{ desktopOnly is defined and desktopOnly == true ? \"l-featured-section--desktop-only\" }} {{ marginBottomZero is defined and marginBottomZero == true ? \"ui-featured-section--spacing-bottom-0\" }} \"
  165. data-bg=\"{{ image }}\"
  166. data-delay=\"5000\"
  167. >
  168. <div class=\"l-featured-section-content\">
  169. {% if addEditCoverPhotoBtn %}
  170. {{ editDCA(8) }}
  171. {% endif %}
  172. <div class=\"l-container\">
  173. <div class=\"l-flex-row\">
  174. <div class=\"l-flex-col-lg-12\">
  175. <div class=\"l-featured-section-content-box\">
  176. <div class=\"l-page-title-box\">
  177. {% if pageTitle is defined %}
  178. <h1 class=\"l-page-title ui-page-title {{ description is not defined or description is empty ? \"ui-page-title--no-description\" }}\">{{ pageTitle }}</h1>
  179. {% endif %}
  180. {% if description is defined and description is not empty %}
  181. <div class=\"l-page-desc ui-page-desc\">
  182. {% if \"<\" in description|raw and \">\" in description|raw %}
  183. {{ description|raw }}
  184. {% else %}
  185. {{ description|nl2br }}
  186. {% endif %}
  187. </div>
  188. {% endif %}
  189. </div>
  190. </div>
  191. </div>
  192. </div>
  193. </div>
  194. </div>
  195. </div>", "fe/_pages_header.html.twig", "/var/www/esorus-shop/templates/fe/_pages_header.html.twig");
  196. }
  197. }