templates/document/areabricks/column-layout-brick/view.html.twig line 1

Open in your IDE?
  1. {% set column = pimcore_select("column").getData() %}
  2. {% set bgColor = pimcore_select("backgroundColor").getData() %}
  3. {% set class1 = 'col-span-6' %}
  4. {% set class2 = 'hidden' %}
  5. {% if column == '50/50' %}
  6.   {% set class1 = 'xl:col-span-3' %}
  7.   {% set class2 = 'xl:col-span-3' %}
  8. {% elseif column == '70/30' %}
  9.   {% set class1 = 'xl:col-span-4' %}
  10.   {% set class2 = 'xl:col-span-2' %}
  11. {% elseif column == '30/70' %}
  12.   {% set class1 = 'xl:col-span-2' %}
  13.   {% set class2 = 'xl:col-span-4' %}
  14. {% endif %}
  15. <div class="mx-auto max-w-8xl {{ bgColor }}">
  16. <section class="{% if editmode %}py-12 border-black border-dashed border{% endif %} mx-auto max-w-screen-3xl container">
  17.     <div class="container py-8 mx-auto md:py-16">
  18.     <div class="flex items-center gap-4 mb-6 text-primary-500">
  19.     {% if editmode %}
  20.       {{pimcore_relation('icon') }}
  21.     {% endif %}
  22.     {% if pimcore_relation('icon').element %}
  23.     {{pimcore_relation('icon').element.thumbnail('reference-icon').html({
  24.       pictureAttributes: {class: 'w-8 '},
  25.       imgAttributes: {class: 'w-8'},
  26.     })|raw}}
  27.   {% endif %}
  28.         <h2 class="uppercase h4">
  29.             {{ pimcore_input('headline', {
  30.                 "placeholder": "Überschrift"
  31.             }) }}
  32.         </h2>
  33.         </div>
  34.         <div class="grid gap-12 xl:grid-cols-6">
  35.             <div class="{{ class1 }}">
  36.             {# Areablocks #}
  37.             {# prettier-ignore #}
  38.             {% include "component/areablock-column-layout.html.twig" ignore missing with {'areablockname': 'pagethreeleft'} %}
  39.             </div>
  40.             <div class="{{ class2 }}">
  41.               {# Areablocks #}
  42.               {# prettier-ignore #}
  43.               {% include "component/areablock-column-layout.html.twig" ignore missing with {'areablockname': 'pagethreeright'} %}
  44.             </div>
  45.         </div>
  46.     </div>
  47. </section>
  48. </div>