var/cache/dev/twig/d7/d7eacfb3bc491188448a2f3a9511b871.php line 35

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* areas/featurette/view.html.twig */
  14. class __TwigTemplate_be5557253e3471a0a924d60584920051 extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->parent false;
  23.         $this->blocks = [
  24.         ];
  25.         $this->sandbox $this->env->getExtension('\Twig\Extension\SandboxExtension');
  26.         $this->checkSecurity();
  27.     }
  28.     protected function doDisplay(array $context, array $blocks = [])
  29.     {
  30.         $macros $this->macros;
  31.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  32.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""areas/featurette/view.html.twig"));
  33.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  34.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""areas/featurette/view.html.twig"));
  35.         // line 1
  36.         $context["featuretteBlock"] = $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"block""block");
  37.         // line 2
  38.         echo "
  39. <section class=\"area-featurette\">
  40.     ";
  41.         // line 4
  42.         $context['_parent'] = $context;
  43.         $context['_seq'] = twig_ensure_traversable($this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->getBlockIterator((isset($context["featuretteBlock"]) || array_key_exists("featuretteBlock"$context) ? $context["featuretteBlock"] : (function () { throw new RuntimeError('Variable "featuretteBlock" does not exist.'4$this->source); })())));
  44.         foreach ($context['_seq'] as $context["_key"] => $context["i"]) {
  45.             // line 5
  46.             echo "        ";
  47.             $context["positionSelect"] = $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"select""position", ["store" => [["left""left"], ["right""right"]], "reload" => true"class" => "align-middle"]);
  48.             // line 10
  49.             echo "
  50.         ";
  51.             // line 11
  52.             $context["typeSelect"] = $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"select""type", ["reload" => true"store" => [["video""video"], ["image""image"]], "class" => "align-middle"]);
  53.             // line 16
  54.             echo "
  55.         ";
  56.             // line 17
  57.             $context["position"] = ((twig_get_attribute($this->env$this->source, ($context["positionSelect"] ?? null), "getData", [], "method"truetruetrue17)) ? (_twig_default_filter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, ($context["positionSelect"] ?? null), "getData", [], "method"falsefalsetrue17), 17$this->source), "left")) : ("left"));
  58.             // line 18
  59.             echo "        ";
  60.             if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'18$this->source); })())) {
  61.                 // line 19
  62.                 echo "            <div class=\"mb-3\">
  63.                 <span class=\"editmode-label align-middle\">Orientation:</span>
  64.                 ";
  65.                 // line 21
  66.                 echo $this->sandbox->ensureToStringAllowed((isset($context["positionSelect"]) || array_key_exists("positionSelect"$context) ? $context["positionSelect"] : (function () { throw new RuntimeError('Variable "positionSelect" does not exist.'21$this->source); })()), 21$this->source);
  67.                 echo "
  68.             </div>
  69.         ";
  70.             }
  71.             // line 24
  72.             echo "
  73.         <div class=\"row featurette\">
  74.             <div class=\"col-sm-7 ";
  75.             // line 26
  76.             echo ((((isset($context["position"]) || array_key_exists("position"$context) ? $context["position"] : (function () { throw new RuntimeError('Variable "position" does not exist.'26$this->source); })()) == "right")) ? ("order-md-2") : (""));
  77.             echo "\">
  78.                 <h2 class=\"featurette-heading\">
  79.                     ";
  80.             // line 28
  81.             echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""headline");
  82.             echo "
  83.                     <br>
  84.                     <span class=\"text-muted\">";
  85.             // line 30
  86.             echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""subline");
  87.             echo "</span>
  88.                 </h2>
  89.                 <div class=\"lead\">
  90.                     ";
  91.             // line 34
  92.             echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"wysiwyg""content", ["height" => 200]);
  93.             // line 36
  94.             echo "
  95.                 </div>
  96.             </div>
  97.             <div class=\"col-sm-5 ";
  98.             // line 40
  99.             echo ((((isset($context["position"]) || array_key_exists("position"$context) ? $context["position"] : (function () { throw new RuntimeError('Variable "position" does not exist.'40$this->source); })()) == "right")) ? ("order-md-1") : (""));
  100.             echo "\">
  101.                 ";
  102.             // line 42
  103.             if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'42$this->source); })())) {
  104.                 // line 43
  105.                 echo "                    <div class=\"mb-3\">
  106.                         <span class=\"editmode-label align-middle\">Type:</span>
  107.                         ";
  108.                 // line 45
  109.                 echo $this->sandbox->ensureToStringAllowed((isset($context["typeSelect"]) || array_key_exists("typeSelect"$context) ? $context["typeSelect"] : (function () { throw new RuntimeError('Variable "typeSelect" does not exist.'45$this->source); })()), 45$this->source);
  110.                 echo "
  111.                     </div>
  112.                 ";
  113.             }
  114.             // line 48
  115.             echo "
  116.                 ";
  117.             // line 49
  118.             $context["type"] = twig_get_attribute($this->env$this->source, (isset($context["typeSelect"]) || array_key_exists("typeSelect"$context) ? $context["typeSelect"] : (function () { throw new RuntimeError('Variable "typeSelect" does not exist.'49$this->source); })()), "getData", [], "method"falsefalsetrue49);
  119.             // line 50
  120.             echo "
  121.                 ";
  122.             // line 51
  123.             if (((isset($context["type"]) || array_key_exists("type"$context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.'51$this->source); })()) == "video")) {
  124.                 // line 52
  125.                 echo "
  126.                     ";
  127.                 // line 53
  128.                 echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"video""video", ["thumbnail" => "featurerette""attributes" => ["class" => "video-js vjs-default-skin vjs-big-play-centered""data-setup" => "{}"]]);
  129.                 // line 61
  130.                 echo "
  131.                 ";
  132.             } else {
  133.                 // line 64
  134.                 echo "
  135.                     ";
  136.                 // line 65
  137.                 echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"image""image", ["imgAttributes" => ["class" => "featurette-image img-responsive"], "thumbnail" => "featurerette"]);
  138.                 // line 70
  139.                 echo "
  140.                 ";
  141.             }
  142.             // line 73
  143.             echo "
  144.             </div>
  145.         </div>
  146.         ";
  147.             // line 77
  148.             if ((twig_get_attribute($this->env$this->source, (isset($context["featuretteBlock"]) || array_key_exists("featuretteBlock"$context) ? $context["featuretteBlock"] : (function () { throw new RuntimeError('Variable "featuretteBlock" does not exist.'77$this->source); })()), "getCurrent", [], "method"falsefalsetrue77) < (twig_get_attribute($this->env$this->source, (isset($context["featuretteBlock"]) || array_key_exists("featuretteBlock"$context) ? $context["featuretteBlock"] : (function () { throw new RuntimeError('Variable "featuretteBlock" does not exist.'77$this->source); })()), "getCount", [], "method"falsefalsetrue77) - 1))) {
  149.                 // line 78
  150.                 echo "            <hr class=\"featurette-divider\">
  151.         ";
  152.             }
  153.             // line 80
  154.             echo "
  155.     ";
  156.         }
  157.         $_parent $context['_parent'];
  158.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['i'], $context['_parent'], $context['loop']);
  159.         $context array_intersect_key($context$_parent) + $_parent;
  160.         // line 82
  161.         echo "</section>
  162. ";
  163.         
  164.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  165.         
  166.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  167.     }
  168.     /**
  169.      * @codeCoverageIgnore
  170.      */
  171.     public function getTemplateName()
  172.     {
  173.         return "areas/featurette/view.html.twig";
  174.     }
  175.     /**
  176.      * @codeCoverageIgnore
  177.      */
  178.     public function isTraitable()
  179.     {
  180.         return false;
  181.     }
  182.     /**
  183.      * @codeCoverageIgnore
  184.      */
  185.     public function getDebugInfo()
  186.     {
  187.         return array (  176 => 82,  169 => 80,  165 => 78,  163 => 77,  157 => 73,  152 => 70,  150 => 65,  147 => 64,  142 => 61,  140 => 53,  137 => 52,  135 => 51,  132 => 50,  130 => 49,  127 => 48,  121 => 45,  117 => 43,  115 => 42,  110 => 40,  104 => 36,  102 => 34,  95 => 30,  90 => 28,  85 => 26,  81 => 24,  75 => 21,  71 => 19,  68 => 18,  66 => 17,  63 => 16,  61 => 11,  58 => 10,  55 => 5,  51 => 4,  47 => 2,  45 => 1,);
  188.     }
  189.     public function getSourceContext()
  190.     {
  191.         return new Source("{% set featuretteBlock = pimcore_block('block') %}
  192. <section class=\"area-featurette\">
  193.     {% for i in pimcore_iterate_block(featuretteBlock) %}
  194.         {% set positionSelect = pimcore_select('position', {
  195.             store: [[\"left\",\"left\"],[\"right\",\"right\"]],
  196.             reload: true,
  197.             class: 'align-middle'
  198.         }) %}
  199.         {% set typeSelect = pimcore_select('type', {
  200.             reload: true,
  201.             store: [[\"video\",\"video\"], [\"image\",\"image\"]],
  202.             class: 'align-middle'
  203.         }) %}
  204.         {% set position = positionSelect.getData()|default('left') %}
  205.         {% if editmode %}
  206.             <div class=\"mb-3\">
  207.                 <span class=\"editmode-label align-middle\">Orientation:</span>
  208.                 {{ positionSelect | raw }}
  209.             </div>
  210.         {% endif %}
  211.         <div class=\"row featurette\">
  212.             <div class=\"col-sm-7 {{ position == 'right' ? 'order-md-2' : '' }}\">
  213.                 <h2 class=\"featurette-heading\">
  214.                     {{ pimcore_input('headline') }}
  215.                     <br>
  216.                     <span class=\"text-muted\">{{ pimcore_input('subline') }}</span>
  217.                 </h2>
  218.                 <div class=\"lead\">
  219.                     {{ pimcore_wysiwyg('content', {
  220.                         height: 200
  221.                     }) }}
  222.                 </div>
  223.             </div>
  224.             <div class=\"col-sm-5 {{ position == 'right' ? 'order-md-1' : '' }}\">
  225.                 {% if editmode %}
  226.                     <div class=\"mb-3\">
  227.                         <span class=\"editmode-label align-middle\">Type:</span>
  228.                         {{ typeSelect|raw }}
  229.                     </div>
  230.                 {% endif %}
  231.                 {% set type = typeSelect.getData() %}
  232.                 {% if type == 'video' %}
  233.                     {{
  234.                         pimcore_video('video', {
  235.                             thumbnail: 'featurerette',
  236.                             attributes: {
  237.                                 class: 'video-js vjs-default-skin vjs-big-play-centered',
  238.                                 'data-setup': '{}'
  239.                             }
  240.                         })
  241.                     }}
  242.                 {% else %}
  243.                     {{
  244.                         pimcore_image('image', {
  245.                             imgAttributes: {class: 'featurette-image img-responsive'},
  246.                             thumbnail: 'featurerette'
  247.                         })
  248.                     }}
  249.                 {% endif %}
  250.             </div>
  251.         </div>
  252.         {% if featuretteBlock.getCurrent() < (featuretteBlock.getCount() - 1) %}
  253.             <hr class=\"featurette-divider\">
  254.         {% endif %}
  255.     {% endfor %}
  256. </section>
  257. ""areas/featurette/view.html.twig""/var/www/dev-10/templates/areas/featurette/view.html.twig");
  258.     }
  259.     
  260.     public function checkSecurity()
  261.     {
  262.         static $tags = array("set" => 1"for" => 4"if" => 18);
  263.         static $filters = array("default" => 17"raw" => 21);
  264.         static $functions = array("pimcore_block" => 1"pimcore_iterate_block" => 4"pimcore_select" => 5"pimcore_input" => 28"pimcore_wysiwyg" => 34"pimcore_video" => 54"pimcore_image" => 66);
  265.         try {
  266.             $this->sandbox->checkSecurity(
  267.                 ['set''for''if'],
  268.                 ['default''raw'],
  269.                 ['pimcore_block''pimcore_iterate_block''pimcore_select''pimcore_input''pimcore_wysiwyg''pimcore_video''pimcore_image']
  270.             );
  271.         } catch (SecurityError $e) {
  272.             $e->setSourceContext($this->source);
  273.             if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
  274.                 $e->setTemplateLine($tags[$e->getTagName()]);
  275.             } elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
  276.                 $e->setTemplateLine($filters[$e->getFilterName()]);
  277.             } elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
  278.                 $e->setTemplateLine($functions[$e->getFunctionName()]);
  279.             }
  280.             throw $e;
  281.         }
  282.     }
  283. }