templates/areas/glaciervine-facts/view.html.twig line 1

Open in your IDE?
  1. <section class="content-block container container-sm js-fade-in {{ styleModifier | default(null) }}
  2.     {{ not pimcore_input('anchorTitle').empty ? 'js-anchor-nav__item' : '' }}"
  3.          {% if not pimcore_input('anchorTitle').empty %}data-anchor-nav-title="{{ pimcore_input('anchorTitle').frontend }}"{% endif %}>
  4.     {% embed 'Includes/editmode-settings.html.twig' %}
  5.         {% block additionalInfo %}
  6.         {% endblock %}
  7.     {% endembed %}
  8.     {{ include('Includes/title-block-editable.html.twig', {
  9.         isCentered: true
  10.     }) }}
  11.     <div class="js-lightbox lightbox-item">
  12.         <button class="lightbox__zoom-btn">
  13.             <span class="icon icon-search" aria-hidden="true"></span>
  14.         </button>
  15.         {% do jsConfig().add('lightbox', true) %}
  16.         {% set lightBoxSrc = pimcore_image('facts-area', {
  17.             thumbnail: 'lightbox-facts-area',
  18.             path: true
  19.         }) %}
  20.         <a href="{{ lightBoxSrc.src }}"
  21.            class="js-lightbox__item facts-area__img-wrapper d-block">
  22.             {% if editmode %}
  23.             {{ pimcore_image('facts-area', {
  24.                 thumbnail: 'facts-area',
  25.                 class: 'js-lazy-img img-fluid facts-area__img',
  26.                 lowQualityPlaceholder: true,
  27.             })|raw }}
  28.             {% elseif not pimcore_image('facts-area').empty  %}
  29.                 {% set description = getImageDescription(pimcore_image('facts-area').image) %}
  30.                 {{ pimcore_image('facts-area').image.thumbnail('facts-area').html({
  31.                     imgAttributes: {
  32.                         class: 'js-lazy-img img-fluid facts-area__img',
  33.                         title: description|default(''),
  34.                         alt: description|default(''),
  35.                     },
  36.                     lowQualityPlaceholder: true,
  37.                 })|raw }}
  38.             {% endif %}
  39.         </a>
  40.     </div>
  41.     <div class="row vertical-gutter--default justify-content-center">
  42.         {% for i in pimcore_iterate_block(pimcore_block('factsboxblock')) %}
  43.             <div class="{% if editmode %}col-md-12{% else %}col-md-6{% endif %} vertical-gutter__item ">
  44.                 {% if editmode %}
  45.                     <div class="editmode-box editmode-box--info">
  46.                         <div class="editmode-box__heading">
  47.                             Factbox
  48.                         </div>
  49.                         <div>
  50.                             <label>Factbox color: </label>
  51.                             {{ pimcore_select("factbox_color", {
  52.                                 "store": [
  53.                                     ["primary-light", "Dark Green"],
  54.                                     ["green", "Light Green"],
  55.                                 ],
  56.                                 "defaultValue" : "primary-light"
  57.                             }) }}
  58.                         </div>
  59.                     </div>
  60.                 {% endif %}
  61.                 <div class="facts-box facts-box--{{ pimcore_select("factbox_color").data }}">
  62.                     <h3 class="facts-box__title">{{ pimcore_input('factbox_title') }}</h3>
  63.                     <ul class="list-unstyled facts-box__list">
  64.                         {% for i in pimcore_iterate_block(pimcore_block('factsblock')) %}
  65.                             {% if editmode %}
  66.                                 <div class="editmode-box editmode-box--info">
  67.                                     <div>
  68.                                         <label>Icon</label>
  69.                                         {{ pimcore_select("fact_icon", {
  70.                                             "store": [
  71.                                                 ["route-start", "route start"],
  72.                                                 ["distance", "distance"],
  73.                                                 ["stage", "stage"],
  74.                                                 ["route-end", "route-end"],
  75.                                                 ["difficulty", "difficulty"],
  76.                                             ],
  77.                                             "defaultValue" : "route-start"
  78.                                         }) }}<br>
  79.                                         <label>Fact Label: </label>
  80.                                         {{ pimcore_input('fact_label') }}<br>
  81.                                         <label>Fact Text: </label>
  82.                                         {{ pimcore_input('fact_text') }}
  83.                                     </div>
  84.                                 </div>
  85.                             {% else %}
  86.                                 <li class="facts-box__list-item js-fade-in">
  87.                                     <span class="icon icon-{{ pimcore_select("fact_icon").data }} facts-box__icon" aria-hidden="true"></span>
  88.                                     {{ pimcore_input('fact_label').data }}: <strong class="ml-1">{{ pimcore_input('fact_text').data }}</strong>
  89.                                 </li>
  90.                             {% endif %}
  91.                         {% endfor %}
  92.                     </ul>
  93.                 </div>
  94.             </div>
  95.         {% endfor %}
  96.     </div>
  97. </section>