templates/areas/contact-business-card-brick/view.html.twig line 1

Open in your IDE?
  1. {% embed 'app/area-brick-layout.html.twig' %}
  2.     {% block content %}
  3.         <!-- Locations primary -->
  4.         <section class="{{ sectionClass ?? '' }}">
  5.             <div class="{{ containerClass ?? 'container py-10' }}">
  6.                 <div class="relative {{ widthClass ?? (pimcore_image('image').isEmpty() ? 'lg:w-1/2' : '') }}">
  7.                     <div class="relative {{ gridClass ?? '' }} z-10 w-full grid grid-cols-2 gap-6 p-10 overflow-hidden bg-gray-200 rounded-md {{ pimcore_image('image').isEmpty() ? '' : 'md:mb-10' }}">
  8.                         <div class="col-span-2 {{ pimcore_image('image').isEmpty() ? '' : 'md:col-span-1' }}">
  9.                             <span class="block mb-3 text-lg font-bold">
  10.                                 {{ pimcore_input('subtitle', { placeholder: 'Subtitel' }) }}
  11.                             </span>
  12.                             <h2 class="text-3xl font-bold mb-7">
  13.                                 {{ pimcore_input('title', { placeholder: 'Titel' }) }}
  14.                             </h2>
  15.                             <div class="flex flex-col gap-4">
  16.                                 {% if editmode %}
  17.                                     {{ pimcore_input('phone', { placeholder: 'Telefoonnummer' }) }}
  18.                                 {% elseif not pimcore_input('phone').isEmpty() %}
  19.                                     <a
  20.                                         href="tel:{{ pimcore_input('phone') | phone }}"
  21.                                         class="flex font-bold text-blue hover:underline"
  22.                                     >
  23.                                         <span class="flex items-center justify-center w-6 h-6 mr-2 bg-white rounded-full shadow-md">
  24.                                             <svg xmlns="http://www.w3.org/2000/svg" width="14" height="14"><path fill="currentColor" fill-rule="evenodd" d="m13.47 9.12-2.8-.7a.703.703 0 0 0-.752.292L8.126 11.4A11.959 11.959 0 0 1 2.6 5.874l2.688-1.792a.7.7 0 0 0 .291-.752l-.7-2.8A.7.7 0 0 0 4.2 0H.7a.7.7 0 0 0-.7.7C.01 8.042 5.958 13.99 13.3 14a.7.7 0 0 0 .7-.7V9.8a.7.7 0 0 0-.53-.68Z"/></svg>
  25.                                         </span>
  26.                                         {{ pimcore_input('phone') }}
  27.                                     </a>
  28.                                 {% endif %}
  29.                                 {% if editmode %}
  30.                                     {{ pimcore_input('contact-text', { placeholder: 'Contact pagina tekst' }) }}
  31.                                     {% if not document.getProperty('contactPage') %}
  32.                                         {% embed 'app/editmodenotice.html.twig' %}
  33.                                             {% block title %} Er is nog geen contactpagina ingesteld. {% endblock %}
  34.                                             {% block information %}
  35.                                                 Stel op de hoofdpagina van de huidige taal de 'contactPage' property in.
  36.                                             {% endblock %}
  37.                                         {% endembed %}
  38.                                     {% endif %}
  39.                                 {% elseif document.getProperty('contactPage') and not pimcore_input('contact-text').isEmpty() %}
  40.                                     <a
  41.                                         href="mailto:{{ pimcore_input('contact-text') }}?subject={{ 'Contactaanvraag via website'|trans|url_encode }}"
  42.                                         target="_blank"
  43.                                         class="flex font-bold text-blue hover:underline"
  44.                                     >
  45.                                         <span class="flex items-center justify-center w-6 h-6 mr-2 bg-white rounded-full shadow-md">
  46.                                             <svg xmlns="http://www.w3.org/2000/svg" width="14" height="12"><path fill="currentColor" fill-rule="evenodd" d="M1.4 9.8V3.877l5.316 2.362a.7.7 0 0 0 .568 0L12.6 3.877V9.8H1.4Zm11.2-8.4v.945L7 4.834 1.4 2.345V1.4h11.2ZM14 2.786V.7a.7.7 0 0 0-.7-.7H.7a.7.7 0 0 0-.7.7v9.8a.7.7 0 0 0 .7.7h12.6a.7.7 0 0 0 .7-.7V2.786Z"/></svg>
  47.                                         </span>
  48.                                         {{ pimcore_input('contact-text') }}
  49.                                     </a>
  50.                                 {% endif %}
  51.                                 {% if editmode %}
  52.                                     {{ pimcore_textarea('address', { placeholder: 'Adres' }) }}
  53.                                 {% elseif not pimcore_textarea('address').isEmpty() %}
  54.                                     <a
  55.                                         href="https://maps.google.com/?q={{ pimcore_textarea('address') | replace({ "\n": '%20', ' ': '%20' }) }}"
  56.                                         target="_blank"
  57.                                         class="flex text-blue hover:underline"
  58.                                     >
  59.                                         <span class="mr-3.5">
  60.                                             <svg xmlns="http://www.w3.org/2000/svg" width="18" height="24"><path fill="currentColor" fill-rule="evenodd" d="M9.73.039a8.441 8.441 0 0 1 6.836 4.757 8.986 8.986 0 0 1-.465 8.856l-6.232 9.792a1.2 1.2 0 0 1-2.025 0l-6.231-9.792a8.988 8.988 0 0 1-.465-8.856A8.442 8.442 0 0 1 7.984.039a9.86 9.86 0 0 1 1.746 0Zm-.873 5.96a2.4 2.4 0 1 0 0 4.8 2.4 2.4 0 0 0 0-4.8Z"/></svg>
  61.                                         </span>
  62.                                         {{ pimcore_textarea('address') | nl2br }}
  63.                                     </a>
  64.                                 {% endif %}
  65.                             </div>
  66.                         </div>
  67.                         {% if (imageEnabled ?? true) and editmode or not pimcore_image('image').isEmpty() %}
  68.                             <div class="col-span-2 md:col-span-1">
  69.                                 {{ pimcore_image('image', {
  70.                                     thumbnail: 'contact-business-card',
  71.                                     pictureAttributes: {class: 'block rounded-md overflow-hidden'},
  72.                                     imgAttributes: {class: 'w-full h-full'},
  73.                                     reload: true,
  74.                                 }) }}
  75.                             </div>
  76.                         {% endif %}
  77.                     </div>
  78.                     {% if not pimcore_image('image').isEmpty() %}
  79.                         <div class="hidden md:block flex items-end md:h-[186px] md:absolute -mb-10 md:-mr-10 bg-blue-200 px-8 py-11 w-full placeholder-gray-200 rounded-b-md md:rounded-md md:-bottom-0 md:-right-0"></div>
  80.                     {% endif %}
  81.                 </div>
  82.             </div>
  83.         </section>
  84.     {% endblock %}
  85. {% endembed %}