var/cache/dev/twig/69/69f4f4efff987eda8d777c2f60ae5588.php line 38

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. /* modules/search-widget/schedule/stoparea/line_type.html.twig */
  16. class __TwigTemplate_c7ce7a25243aa25e327ac1b5958517da 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", "modules/search-widget/schedule/stoparea/line_type.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", "modules/search-widget/schedule/stoparea/line_type.html.twig"));
  38. // line 1
  39. $context["realtime"] = false;
  40. // line 2
  41. yield "<ul class=\"is-Schedule-Lines\">
  42. <span class=\"is-hide is-stopArea-json\" id=\"stop-area-json\">";
  43. // line 3
  44. yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(json_encode((isset($context["stopArea"]) || array_key_exists("stopArea", $context) ? $context["stopArea"] : (function () { throw new RuntimeError('Variable "stopArea" does not exist.', 3, $this->source); })())), "html", null, true);
  45. yield "</span>
  46. <span class=\"is-hide is-lines-json\" id=\"lines-json\">";
  47. // line 4
  48. yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(json_encode((isset($context["lines"]) || array_key_exists("lines", $context) ? $context["lines"] : (function () { throw new RuntimeError('Variable "lines" does not exist.', 4, $this->source); })())), "html", null, true);
  49. yield "</span>
  50. <span class=\"is-hide is-stopPoints-json\" id=\"stoppoints-json\">";
  51. // line 5
  52. yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(json_encode((isset($context["stopPoints"]) || array_key_exists("stopPoints", $context) ? $context["stopPoints"] : (function () { throw new RuntimeError('Variable "stopPoints" does not exist.', 5, $this->source); })())), "html", null, true);
  53. yield "</span>
  54. ";
  55. // line 6
  56. $context['_parent'] = $context;
  57. $context['_seq'] = CoreExtension::ensureTraversable((isset($context["lines"]) || array_key_exists("lines", $context) ? $context["lines"] : (function () { throw new RuntimeError('Variable "lines" does not exist.', 6, $this->source); })()));
  58. $context['loop'] = [
  59. 'parent' => $context['_parent'],
  60. 'index0' => 0,
  61. 'index' => 1,
  62. 'first' => true,
  63. ];
  64. if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  65. $length = count($context['_seq']);
  66. $context['loop']['revindex0'] = $length - 1;
  67. $context['loop']['revindex'] = $length;
  68. $context['loop']['length'] = $length;
  69. $context['loop']['last'] = 1 === $length;
  70. }
  71. foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  72. // line 7
  73. yield " ";
  74. if ((array_key_exists("groupBySubNetworks", $context) && (true == (isset($context["groupBySubNetworks"]) || array_key_exists("groupBySubNetworks", $context) ? $context["groupBySubNetworks"] : (function () { throw new RuntimeError('Variable "groupBySubNetworks" does not exist.', 7, $this->source); })())))) {
  75. // line 8
  76. yield " ";
  77. $context['_parent'] = $context;
  78. $context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "line", [], "any", false, false, false, 8));
  79. $context['loop'] = [
  80. 'parent' => $context['_parent'],
  81. 'index0' => 0,
  82. 'index' => 1,
  83. 'first' => true,
  84. ];
  85. if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  86. $length = count($context['_seq']);
  87. $context['loop']['revindex0'] = $length - 1;
  88. $context['loop']['revindex'] = $length;
  89. $context['loop']['length'] = $length;
  90. $context['loop']['last'] = 1 === $length;
  91. }
  92. foreach ($context['_seq'] as $context["_key"] => $context["line"]) {
  93. // line 9
  94. yield " ";
  95. yield from $this->load("modules/search-widget/schedule/includes/line_type_item.html.twig", 9)->unwrap()->yield(CoreExtension::merge($context, ["item" => $context["line"]]));
  96. // line 10
  97. yield " ";
  98. ++$context['loop']['index0'];
  99. ++$context['loop']['index'];
  100. $context['loop']['first'] = false;
  101. if (isset($context['loop']['revindex0'], $context['loop']['revindex'])) {
  102. --$context['loop']['revindex0'];
  103. --$context['loop']['revindex'];
  104. $context['loop']['last'] = 0 === $context['loop']['revindex0'];
  105. }
  106. }
  107. $_parent = $context['_parent'];
  108. unset($context['_seq'], $context['_key'], $context['line'], $context['_parent'], $context['loop']);
  109. $context = array_intersect_key($context, $_parent) + $_parent;
  110. // line 11
  111. yield " ";
  112. } else {
  113. // line 12
  114. yield " ";
  115. yield from $this->load("modules/search-widget/schedule/includes/line_type_item.html.twig", 12)->unwrap()->yield(CoreExtension::merge($context, ["item" => CoreExtension::getAttribute($this->env, $this->source, $context["item"], "line", [], "any", false, false, false, 12)]));
  116. // line 13
  117. yield " ";
  118. }
  119. // line 14
  120. yield " ";
  121. ++$context['loop']['index0'];
  122. ++$context['loop']['index'];
  123. $context['loop']['first'] = false;
  124. if (isset($context['loop']['revindex0'], $context['loop']['revindex'])) {
  125. --$context['loop']['revindex0'];
  126. --$context['loop']['revindex'];
  127. $context['loop']['last'] = 0 === $context['loop']['revindex0'];
  128. }
  129. }
  130. $_parent = $context['_parent'];
  131. unset($context['_seq'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  132. $context = array_intersect_key($context, $_parent) + $_parent;
  133. // line 15
  134. yield "</ul>
  135. <div class=\"is-Schedule-NextDeparture-No-More-Item-Line is-Schedule-NextDeparture-No-More-Item is-Alert is-Alert_Warning\" style=\"display: none\">
  136. <p>";
  137. // line 17
  138. yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("schedule.filter.no_more_next_departure"), "html", null, true);
  139. yield "</p>
  140. </div>
  141. ";
  142. // line 19
  143. if (((isset($context["realtime"]) || array_key_exists("realtime", $context) ? $context["realtime"] : (function () { throw new RuntimeError('Variable "realtime" does not exist.', 19, $this->source); })()) === true)) {
  144. // line 20
  145. yield " <ul class=\"is-Schedule-Caption\">
  146. <li>
  147. <i class=\"is-Icon is-Icon-sim-real-time\"><i class=\"is-path1\"></i><i class=\"is-path2\"></i></i>: ";
  148. // line 22
  149. yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("next_departures_panel.realtime"), "html", null, true);
  150. yield "
  151. </li>
  152. </ul>
  153. ";
  154. }
  155. $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  156. $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  157. yield from [];
  158. }
  159. /**
  160. * @codeCoverageIgnore
  161. */
  162. public function getTemplateName(): string
  163. {
  164. return "modules/search-widget/schedule/stoparea/line_type.html.twig";
  165. }
  166. /**
  167. * @codeCoverageIgnore
  168. */
  169. public function isTraitable(): bool
  170. {
  171. return false;
  172. }
  173. /**
  174. * @codeCoverageIgnore
  175. */
  176. public function getDebugInfo(): array
  177. {
  178. return array ( 158 => 22, 154 => 20, 152 => 19, 147 => 17, 143 => 15, 129 => 14, 126 => 13, 123 => 12, 120 => 11, 106 => 10, 103 => 9, 85 => 8, 82 => 7, 65 => 6, 61 => 5, 57 => 4, 53 => 3, 50 => 2, 48 => 1,);
  179. }
  180. public function getSourceContext(): Source
  181. {
  182. return new Source("{% set realtime = false %}
  183. <ul class=\"is-Schedule-Lines\">
  184. <span class=\"is-hide is-stopArea-json\" id=\"stop-area-json\">{{ stopArea | json_encode }}</span>
  185. <span class=\"is-hide is-lines-json\" id=\"lines-json\">{{ lines | json_encode }}</span>
  186. <span class=\"is-hide is-stopPoints-json\" id=\"stoppoints-json\">{{ stopPoints | json_encode }}</span>
  187. {% for item in lines %}
  188. {% if groupBySubNetworks is defined and true == groupBySubNetworks%}
  189. {% for line in item.line %}
  190. {% include \"modules/search-widget/schedule/includes/line_type_item.html.twig\" with {\x27item\x27:line} %}
  191. {% endfor %}
  192. {% else %}
  193. {% include \"modules/search-widget/schedule/includes/line_type_item.html.twig\" with {\x27item\x27:item.line} %}
  194. {% endif %}
  195. {% endfor %}
  196. </ul>
  197. <div class=\"is-Schedule-NextDeparture-No-More-Item-Line is-Schedule-NextDeparture-No-More-Item is-Alert is-Alert_Warning\" style=\"display: none\">
  198. <p>{{ \x27schedule.filter.no_more_next_departure\x27|trans }}</p>
  199. </div>
  200. {% if realtime is same as(true) %}
  201. <ul class=\"is-Schedule-Caption\">
  202. <li>
  203. <i class=\"is-Icon is-Icon-sim-real-time\"><i class=\"is-path1\"></i><i class=\"is-path2\"></i></i>: {{ \x27next_departures_panel.realtime\x27 | trans }}
  204. </li>
  205. </ul>
  206. {% endif %}
  207. ", "modules/search-widget/schedule/stoparea/line_type.html.twig", "/var/www/html/templates/modules/search-widget/schedule/stoparea/line_type.html.twig");
  208. }
  209. }