056bc0d4f9a265a4a5605055305ba3ad27d5884c3b152201a9921e47a1a573be.php 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. <?php
  2. /* forms/fields/tab/tab.html.twig */
  3. class __TwigTemplate_21bbf8bc5fb09a8e9f91f1d2ed86dbeee555035bc9a47507937cbf078eaa5885 extends Twig_Template
  4. {
  5. public function __construct(Twig_Environment $env)
  6. {
  7. parent::__construct($env);
  8. $this->parent = false;
  9. $this->blocks = array(
  10. );
  11. }
  12. protected function doDisplay(array $context, array $blocks = array())
  13. {
  14. // line 1
  15. if ($this->getAttribute(($context["field"] ?? null), "fields", array())) {
  16. // line 2
  17. echo " <div class=\"form-tab\">
  18. ";
  19. // line 3
  20. $context['_parent'] = $context;
  21. $context['_seq'] = twig_ensure_traversable($this->getAttribute($context["field"], "fields", array()));
  22. $context['loop'] = array(
  23. 'parent' => $context['_parent'],
  24. 'index0' => 0,
  25. 'index' => 1,
  26. 'first' => true,
  27. );
  28. if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof Countable)) {
  29. $length = count($context['_seq']);
  30. $context['loop']['revindex0'] = $length - 1;
  31. $context['loop']['revindex'] = $length;
  32. $context['loop']['length'] = $length;
  33. $context['loop']['last'] = 1 === $length;
  34. }
  35. foreach ($context['_seq'] as $context["_key"] => $context["field"]) {
  36. // line 4
  37. echo " ";
  38. if ($this->getAttribute($context["field"], "type", array())) {
  39. // line 5
  40. echo " ";
  41. $context["value"] = (($this->getAttribute($context["field"], "name", array())) ? ($this->getAttribute(($context["data"] ?? null), "value", array(0 => $this->getAttribute($context["field"], "name", array())), "method")) : ($this->getAttribute(($context["data"] ?? null), "toArray", array())));
  42. // line 6
  43. echo " ";
  44. $this->loadTemplate(array(0 => (((("forms/fields/" . $this->getAttribute($context["field"], "type", array())) . "/") . $this->getAttribute($context["field"], "type", array())) . ".html.twig"), 1 => "forms/fields/text/text.html.twig"), "forms/fields/tab/tab.html.twig", 6)->display($context);
  45. // line 7
  46. echo " ";
  47. }
  48. // line 8
  49. echo " ";
  50. ++$context['loop']['index0'];
  51. ++$context['loop']['index'];
  52. $context['loop']['first'] = false;
  53. if (isset($context['loop']['length'])) {
  54. --$context['loop']['revindex0'];
  55. --$context['loop']['revindex'];
  56. $context['loop']['last'] = 0 === $context['loop']['revindex0'];
  57. }
  58. }
  59. $_parent = $context['_parent'];
  60. unset($context['_seq'], $context['_iterated'], $context['_key'], $context['field'], $context['_parent'], $context['loop']);
  61. $context = array_intersect_key($context, $_parent) + $_parent;
  62. // line 9
  63. echo " </div>
  64. ";
  65. }
  66. }
  67. public function getTemplateName()
  68. {
  69. return "forms/fields/tab/tab.html.twig";
  70. }
  71. public function isTraitable()
  72. {
  73. return false;
  74. }
  75. public function getDebugInfo()
  76. {
  77. return array ( 67 => 9, 53 => 8, 50 => 7, 47 => 6, 44 => 5, 41 => 4, 24 => 3, 21 => 2, 19 => 1,);
  78. }
  79. /** @deprecated since 1.27 (to be removed in 2.0). Use getSourceContext() instead */
  80. public function getSource()
  81. {
  82. @trigger_error('The '.__METHOD__.' method is deprecated since version 1.27 and will be removed in 2.0. Use getSourceContext() instead.', E_USER_DEPRECATED);
  83. return $this->getSourceContext()->getCode();
  84. }
  85. public function getSourceContext()
  86. {
  87. return new Twig_Source("{% if field.fields %}
  88. <div class=\"form-tab\">
  89. {% for field in field.fields %}
  90. {% if field.type %}
  91. {% set value = field.name ? data.value(field.name) : data.toArray %}
  92. {% include [\"forms/fields/#{field.type}/#{field.type}.html.twig\", 'forms/fields/text/text.html.twig'] %}
  93. {% endif %}
  94. {% endfor %}
  95. </div>
  96. {% endif %}
  97. ", "forms/fields/tab/tab.html.twig", "/mnt/data/Sites/static-ethica.net/user/plugins/admin/themes/grav/templates/forms/fields/tab/tab.html.twig");
  98. }
  99. }