src/Package/Openform/Front/Templates/AntiqueSuit/_templates/_template-10.html.twig line 140

Open in your IDE?
  1. {% from '@openform_front_templates/_includes/_icons.html.twig' import fullscreen, zoomin, zoomout, sliderprev, slidernext, arrowright, arrowdown, copyrights, arrowObjectPrev, arrowObjectNext, infoClose, info  %}
  2. {% set ImageSlides = entity.ImageSlide|filterVisibles(app.request.locale) %}
  3. <section class="object object--{{entity.templateId}} js-collections" style="{% if entity.background is defined or rootParent.background is defined %}background-color: {{rootParent.background is defined and rootParent.background|length > 0 ? rootParent.background}} {% else %}background-color:#F8F7F0{% endif %}">
  4.           <div class="object__item--gallery" style="height:70vh; {{entity.image2Path ? 'background-image: url("' ~ entity.image2Path ~ '"); background-repeat: no-repeat;  background-position: center; background-size: cover;': entity.imageBackgroundColor ? 'background-color:' ~ entity.imageBackgroundColor ~ ';' : 'background-color: #FFFFF2;'}}">
  5.            {% if ImageSlides|length > 0 %}
  6.                     <div class="object__arrows object__arrows--dark">
  7.                         {% for key, Antique in entity.AntiqueSuit.getVisibleAntiques(app.request.locale) %}
  8.                                     {% if entity.id == Antique.id  %}
  9.                                         {% if entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key - 1] is defined %}
  10.                                             {% set prevElement = entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key - 1] %}
  11.                                             {% set href = toolkit_route_localizer.generate('antique_item',{ slug : prevElement.Translation[app.request.locale].slug }, app.request.locale) %}
  12.                                             <a href="{{href}}" class="object__nav__button-white" disabled>
  13.                                                 {{ sliderprev('PREV_Relict'|trans({}, 'openform_front', app.request.locale)) }}
  14.                                             </a>
  15.                                         {% else %}
  16.                                             <div>
  17.                                                 
  18.                                             </div>
  19.                                         {% endif%}
  20.                                         {% if entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key + 1] is defined %}
  21.                                             {% set nextElement = entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key + 1] %}
  22.                                             {% set href = toolkit_route_localizer.generate('antique_item',{ slug : nextElement.Translation[app.request.locale].slug }, app.request.locale) %}
  23.                                             <a href="{{href}}" class="object__nav__button-white object__nav__button-white-next" disabled>
  24.                                                 {{ slidernext('Next_Relict'|trans({}, 'openform_front', app.request.locale)) }}
  25.                                             </a>
  26.                                         {% endif %}
  27.                                     {% endif %}
  28.                         {% endfor %}
  29.                     </div>
  30.                     <div class="object__gallery__splide object-gallery js-collection-gallery-standard" style="height: 100%;">
  31.                         <div class="splide js-collections-gallery9 collection-gallery__gallery" aria-label="Galeria" style="height: 100%;">
  32.                             <div class="splide__track" style="height: 100%;">
  33.                                 <ul class="splide__list" style="height: 100%;">
  34.                                     {% for key, image in ImageSlides %}
  35.                                         <li class="splide__slide" style="height: 100%;">
  36.                                            {% set img = openform_front_util.getImagePathByType(image.Thumb ?? '','original') %}
  37.                                     {# {% set imgSmall = openform_front_util.getImagePathByType(image.Thumb ?? '','detal') %} #}
  38.                                     <div class="js-zoom" data-alt="{{image.Translation[app.request.locale].alt}}"  style=" height: 100%;">
  39.                                                <div style="width:100%; height:100%; display:flex; justify-content: center; align-items: center;">
  40.                                                     <div class="collection-gallery__item" style="{% if entity.imageWidthPercent %}width: {{entity.imageWidthPercent}}%; max-width: {{entity.imageWidthPercent}}%;{% endif %} max-height: {{entity.imageHeight ? entity.imageHeight ~ 'px' : '100%'}}; height:100%;" >
  41.                                                         <style>
  42.                                                             .my-zoomist-{{key}} img{
  43.                                                                 {% if image.imageBorderColor and image.imageBorderWidth %}border: {{image.imageBorderColor}} solid {{image.imageBorderWidth}}px;{% endif %}"
  44.                                                             }
  45.                                                             .my-zoomist-{{key}} .zoomist-wrapper{
  46.                                                                 background:{{image.imageBackgroundColor ? image.imageBackgroundColor : entity.imageBackgroundColor ? entity.imageBackgroundColor : '#F8F7F0' }};
  47.                                                             }
  48.                                                         </style>
  49.                                                         <div class="my-zoomist my-zoomist-{{key}}" style="{% if entity.imageHeight %} height: {{entity.imageHeight}}px;{% endif %}" data-zoomist-src="{{img}}" tabindex="0"></div>
  50.                                                     </div>
  51.                                                 </div>
  52.                                                 
  53.                                                 <div class="collection-gallery__wrap">
  54.                                                     <div class="collection-gallery__buttons">
  55.                                                         {% if image.Translation[app.request.locale].text is defined and image.Translation[app.request.locale].text %}
  56.                                                             <div class="object__info-wrap">
  57.                                                                 <button class="collection-gallery__buttons__btn" type="button" aria-expanded="false" data-expanded="js-info-{{key}}" tabindex="0">{{info(('T_INFO')|trans({}, 'openform_front', app.request.locale))}}</button>
  58.                                                                 <div class="object__info object__info--info js-info-{{key}}" data-lenis-prevent>
  59.                                                                     <div class="object__info__text block__text">{{image.Translation[app.request.locale].text|raw}}</div>
  60.                                                                     <button class="object__info__close js-expanded-close" type="button">{{infoClose()}}</button>
  61.                                                                 </div>
  62.                                                             </div>
  63.                                                         {% endif %}
  64.                                                         {% if image.Translation[app.request.locale].copyrights %}
  65.                                                             <div class="object__info-wrap">
  66.                                                                 <button class="collection-gallery__buttons__btn" type="button" aria-expanded="false" data-expanded="js-copyright-{{key}}" tabindex="0">{{copyrights(('T_INFO')|trans({}, 'openform_front', app.request.locale))}}</button>
  67.                                                                 <div class="object__info object__info--copyright js-copyright-{{key}}" data-lenis-prevent>
  68.                                                                     <div class="object__info__text block__text">{{image.Translation[app.request.locale].copyrights|raw}}</div>
  69.                                                                     <button class="object__info__close js-expanded-close" type="button">{{infoClose()}}</button>
  70.                                                                 </div>
  71.                                                             </div>
  72.                                                         {% endif %}
  73.                                                         <button class="collection-gallery__buttons__btn js-fullscreen" data-alt="{{image.Translation[app.request.locale].alt}}" tabindex="0" data-color="{{image.imageBackgroundColor is defined and image.imageBackgroundColor ? image.imageBackgroundColor }}"
  74.                                                             data-image="{{img}}"
  75.                                                             data-description="{{image.Translation[app.request.locale].text}}"
  76.                                                             data-copyrights="{{image.Translation[app.request.locale].copyrights}}"
  77.                                                             data-start="{{key}}"
  78.                                                                         data-imagestyle="{% if image.imageBorderColor and image.imageBorderWidth %}border: {{image.imageBorderColor}} solid {{image.imageBorderWidth}}px;{% endif %}"
  79.                                                         >
  80.                                                             {{fullscreen(('T_FULLSCREEN')|trans({}, 'openform_front', app.request.locale))}}
  81.                                                         </button>
  82.                                                         <button class="collection-gallery__buttons__btn js-zoom-out" tabindex="0">{{zoomout(('T_ZOOMOUT')|trans({}, 'openform_front', app.request.locale))}}</button>
  83.                                                         <button class="collection-gallery__buttons__btn js-zoom-in" tabindex="0">{{zoomin(('T_ZOOMIN')|trans({}, 'openform_front', app.request.locale))}}</button>
  84.                                                     </div>
  85.                                                 </div>
  86.                                             </div>
  87.                                         </li>    
  88.                                        
  89.                                         
  90.                                     {% endfor %}                               
  91.                                 </ul>
  92.                                  <div class="splide__arrows{{ ImageSlides|length < 2 ? ' hide' }}">
  93.                                             <div class="slider-nav object-gallery__nav">
  94.                                                 <button class="splide__arrow splide__arrow--prev slider-nav__btn slider-nav__btn--prev" disabled>
  95.                                                     {{ sliderprev('PREV_SLIDE'|trans({}, 'openform_front', app.request.locale)) }}
  96.                                                 </button>
  97.                                                 <button class="splide__arrow splide__arrow--next slider-nav__btn slider-nav__btn--next">
  98.                                                     {{ slidernext('NEXT_SLIDE'|trans({}, 'openform_front', app.request.locale)) }}
  99.                                                 </button>
  100.                                             </div>
  101.                                 </div>
  102.                             </div>
  103.                         </div>
  104.                         
  105.                     </div>
  106.                 {% endif %}
  107.             </div>
  108.             <div class="container" style=" padding-left: 9vw; padding-right: 9vw; background-color: {{entity.background is defined and entity.background|length > 0 and entity.background ? entity.background : '#FFFFF2'}}">
  109.                 <div class="object__item object__item--header">
  110.                     {% set href = toolkit_route_localizer.generate('antique_suit_item', {
  111.                                         'slug': entity.AntiqueSuit.Translation[app.request.locale].slug
  112.                                         }, app.request.locale) %} 
  113.                 <a href="{{href}}" class="object__item__collection">{{ entity.AntiqueSuit.Translation[app.request.locale].title }}</a>
  114.                 <div class="object__item__title">{{ entity.Translation[app.request.locale].titleHtml|raw }}</div>
  115.                     <div class="object__item__section">
  116.                         <div class="object__wrapper__list">
  117.                             {% if entity.AntiqueSuit and entity.AntiqueSuit.AntiqueFormDesign == constant('\\App\\Package\\Openform\\Entity\\AntiqueSuit::ANTIQUE_FORM_DESIGN_MUSEUM') %}
  118.                                 {% if entity.Artist|length > 0 %}
  119.                                     <div class="object__item-wrap object__item-wrap--author">
  120.                                         <h3 class="object__item-wrap__title">{{('T_ANTIQUE_AUTHOR')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  121.                                         <div class="object__item-wrap__text">
  122.                                             {% for artist in entity.Artist %}
  123.                                                 <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?artist={{ artist.fullName }}">
  124.                                                     {{artist.fullName ? artist.fullName }}
  125.                                                 </a>{{entity.Artist|length > 1 ? ', '}}
  126.                                             {% endfor %}
  127.                                         </div>
  128.                                     </div>
  129.                                 {% endif %}
  130.                                 {% if (entity.date or entity.dateTo or entity.age or  entity.ageTo or entity.year or entity.yearTo) %}
  131.                                     <div class="object__item-wrap">
  132.                                         <h3 class="object__item-wrap__title">{{('T_ANTIQUE_DATE')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  133.                                         <div class="object__item-wrap__text">
  134.                                             {% include('@openform_front_templates/AntiqueSuit/_templates/_fields/_dates_and_ages.html.twig') with {
  135.                                                 'dateFrom': entity.date, 
  136.                                                 'dateTo': entity.dateTo,
  137.                                                 'ageFrom': entity.age, 
  138.                                                 'ageTo': entity.ageTo,
  139.                                                 'yearFrom': entity.year ?? entity.shownObjectYear, 
  140.                                                 'yearTo': entity.yearTo ?? entity.shownObjectAge,
  141.                                             } %}
  142.                                         </div>
  143.                                     </div>
  144.                                 {% endif %}
  145.                                 {% if entity.AntiqueType|length > 0 %}
  146.                                     <div class="object__item-wrap">
  147.                                         <h3 class="object__item-wrap__title">{{('T_OBJECT_TYPE')|trans({}, 'openform_front', app.request.locale) ~ ': ' }}</h3>
  148.                                         <div class="object__item-wrap__text">
  149.                                             {% for key, item in entity.AntiqueType %}
  150.                                                 <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?antiqueType={{ item.Translation[app.request.locale].title }}">
  151.                                                     {{ item.Translation[app.request.locale].title }}
  152.                                                 </a>{% if not loop.last %}, {% endif %}
  153.                                             {% endfor %}
  154.                                         </div>
  155.                                     </div>
  156.                                 {% endif %}
  157.                                 {% if entity.AntiqueTechnique|length > 0 %}
  158.                                     <div class="object__item-wrap">
  159.                                         <h3 class="object__item-wrap__title">{{('T_MATERIALS_AND_TECHNIQUES')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  160.                                         <div class="object__item-wrap__text">
  161.                                             {% for item in entity.AntiqueTechnique %}
  162.                                                 <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?antiqueTechnique={{ item.Translation[app.request.locale].title }}">
  163.                                                     {{item.Translation[app.request.locale].title ? item.Translation[app.request.locale].title}}
  164.                                                 </a>{% if not loop.last %}, {% endif %}
  165.                                             {% endfor %}
  166.                                         </div>
  167.                                     </div>
  168.                                 {% endif %}
  169.                             {% else %}
  170.                                 {% if entity.Translation[app.request.locale].descPlace %}
  171.                                     <div class="object__item-wrap">
  172.                                         <h3 class="object__item-wrap__title">{{('T_ANTIQUE_PLACE_DESC')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  173.                                         <div class="object__item-wrap__text">
  174.                                             {{entity.Translation[app.request.locale].descPlace}}
  175.                                         </div>
  176.                                     </div>
  177.                                 {% endif %}
  178.                                 {% if entity.AntiquePlace %}
  179.                                     <div class="object__item-wrap">
  180.                                         <h3 class="object__item-wrap__title">{{('T_ANTIQUE_OBJECT_PLACE')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  181.                                         <div class="object__item-wrap__text">
  182.                                             {{entity.AntiquePlace.Translation[app.request.locale].title}}
  183.                                         </div>
  184.                                     </div>
  185.                                 {% endif %}
  186.                                 {% if entity.documentDate or entity.documentAge or entity.documentYear %}
  187.                                     <div class="object__item-wrap">
  188.                                         <h3 class="object__item-wrap__title">{{('T_ANTIQUE_DOCUMENT_DATE')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  189.                                         <div class="object__item-wrap__text">
  190.                                             {% include('@openform_front_templates/AntiqueSuit/_templates/_fields/_date_and_age_search.html.twig') with {
  191.                                                 'date': entity.documentDate,
  192.                                                 'age': entity.documentAge,
  193.                                                 'year': entity.documentYear,
  194.                                             } %}
  195.                                         </div>
  196.                                     </div>
  197.                                 {% endif %}
  198.                                 {% if entity.Artist|length > 0 %}
  199.                                     <div class="object__item-wrap">
  200.                                         <h3 class="object__item-wrap__title">{{('T_ANTIQUE_AUTHOR_OF_THE_PHOTOGRAPH_OR_DOCUMENT')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  201.                                         <div class="object__item-wrap__text">
  202.                                             {% for artist in entity.Artist %}
  203.                                                 <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?artist={{ artist.fullName }}">
  204.                                                     {{artist.fullName ? artist.fullName }} {{ artist.authorNickName ? '"' ~ artist.authorNickName ~ '"'}}
  205.                                                 </a>{{entity.Artist|length > 1 ? ', '}}
  206.                                             {% endfor %}
  207.                                         </div>
  208.                                     </div>
  209.                                 {% endif %}
  210.                                 {% if entity.AntiqueType|length > 0 %}
  211.                                     <div class="object__item-wrap">
  212.                                         <h3 class="object__item-wrap__title">{{('T_OBJECT_TYPE')|trans({}, 'openform_front', app.request.locale) ~ ': ' }}</h3>
  213.                                         <div class="object__item-wrap__text">
  214.                                             {% for key, item in entity.AntiqueType %}
  215.                                                 <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?antiqueType={{ item.Translation[app.request.locale].title }}">
  216.                                                     {{ item.Translation[app.request.locale].title }}
  217.                                                 </a>{% if not loop.last %}, {% endif %}
  218.                                             {% endfor %}
  219.                                         </div>
  220.                                     </div>
  221.                                 {% endif %}
  222.                                 {% if entity.AntiqueTechnique|length > 0 %}
  223.                                     <div class="object__item-wrap">
  224.                                         <h3 class="object__item-wrap__title">{{('T_MATERIALS_AND_TECHNIQUES')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  225.                                         <div class="object__item-wrap__text">
  226.                                             {% for item in entity.AntiqueTechnique %}
  227.                                                 <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?antiqueTechnique={{ item.Translation[app.request.locale].title }}">
  228.                                                     {{item.Translation[app.request.locale].title ? item.Translation[app.request.locale].title}}
  229.                                                 </a>{% if not loop.last %}, {% endif %}
  230.                                             {% endfor %}
  231.                                         </div>
  232.                                     </div>
  233.                                 {% endif %}
  234.                             {% endif %}
  235.                         </div>
  236.                     </div>
  237.                     <div class="object__item__section">
  238.                         {% if entity.AntiqueSuit and entity.AntiqueSuit.AntiqueFormDesign == constant('\\App\\Package\\Openform\\Entity\\AntiqueSuit::ANTIQUE_FORM_DESIGN_MUSEUM') %}
  239.                             {% if entity.Translation[app.request.locale].text %}
  240.                                 <div class="object__item-wrap object__item-wrap--description object__item-wrap--description-master js-text-dropdown" data-limit="6" data-lineHeight="22">
  241.                                     <h3 class="object__item-wrap__title">{{('T_ANTIQUE_DESCRIPTION')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  242.                                     <div class="object__item-wrap__text">
  243.                                     <span class="js-text-dropdown-content">{{entity.Translation[app.request.locale].text|raw}}</span> <button class="js-text-dropdown-btn hide"><span>{{('T_TEXT_SHOW_MORE')|trans({}, 'openform_front', app.request.locale) }} ▼</span><span>{{('T_TEXT_SHOW_LESS')|trans({}, 'openform_front', app.request.locale) }} ▲</span></button>
  244.                                         
  245.                                     </div>
  246.                                 </div>
  247.                             {% endif %}
  248.                             {% if entity.AntiqueCopyrights|length > 0 %}
  249.                                 <div class="object__item-wrap">
  250.                                     <h3 class="object__item-wrap__title">{{('T_ANTIQUE_COPYRIGHTS')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  251.                                     <div class="object__item-wrap__text object__item-wrap__copyright">
  252.                                         {% for key, item in entity.AntiqueCopyrights %}
  253.                                             <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?antiqueCopyrights={{ item.Translation[app.request.locale].title }}">
  254.                                                 {{ item.Translation[app.request.locale].title }}
  255.                                             </a>{% if not loop.last %}, {% endif %}
  256.                                         {% endfor %}
  257.                                     </div>
  258.                                 </div>
  259.                             {% endif %}
  260.                         {% else %}
  261.                             {% if entity.Translation[app.request.locale].text %}
  262.                                 <div class="object__item-wrap object__item-wrap--description object__item-wrap--description-master js-text-dropdown" data-limit="6" data-lineHeight="22">
  263.                                     <h3 class="object__item-wrap__title">{{('T_ANTIQUE_DESCRIPTION')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  264.                                     <div class="object__item-wrap__text">
  265.                                     <span class="js-text-dropdown-content">{{entity.Translation[app.request.locale].text|raw}}</span> <button class="js-text-dropdown-btn hide"><span>{{('T_TEXT_SHOW_MORE')|trans({}, 'openform_front', app.request.locale) }} ▼</span><span>{{('T_TEXT_SHOW_LESS')|trans({}, 'openform_front', app.request.locale) }} ▲</span></button>
  266.                                         
  267.                                     </div>
  268.                                 </div>
  269.                             {% endif %}
  270.                             {% if entity.AntiqueCopyrights|length > 0 %}
  271.                                 <div class="object__item-wrap">
  272.                                     <h3 class="object__item-wrap__title">{{('T_ANTIQUE_COPYRIGHTS')|trans({}, 'openform_front', app.request.locale) }}:</h3>
  273.                                     <div class="object__item-wrap__text object__item-wrap__copyright">
  274.                                         {% for key, item in entity.AntiqueCopyrights %}
  275.                                             <a href="{{ toolkit_route_localizer.generate('search', {}, app.request.locale) }}?antiqueCopyrights={{ item.Translation[app.request.locale].title }}">
  276.                                                 {{ item.Translation[app.request.locale].title }}
  277.                                             </a>{% if not loop.last %}, {% endif %}
  278.                                         {% endfor %}
  279.                                     </div>
  280.                                 </div>
  281.                             {% endif %}
  282.                         {% endif %}        
  283.                     </div>
  284.                 </div>
  285.             </div>
  286.             <div class="object__content container" style="{{entity.background2 ? 'background-color: ' ~ entity.background2 }}">
  287.                 {% include '@openform_front_templates/AntiqueSuit/_templates/_sections/_all-sections.html.twig' with {design: entity.colsDesign} %}
  288.     
  289.                 {% include "@openform_front_templates/_blocks_sections/block.html.twig" with { sections: openform_front_util.getSections(entity) } %}
  290.             </div>
  291.             <div class="object__nav container" style="{% if entity.naviBackgroundColor %}background-color: {{entity.naviBackgroundColor}};{% endif %}">
  292.                 {% for key, Antique in entity.AntiqueSuit.getVisibleAntiques(app.request.locale) %}
  293.                     {% if entity.id == Antique.id  %}
  294.                         {% if entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key - 1] is defined %}
  295.                             {% set prevElement = entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key - 1] %}
  296.                             {% set href = toolkit_route_localizer.generate('antique_item',{ slug : prevElement.Translation[app.request.locale].slug }, app.request.locale) %}
  297.                             <a href="{{href}}" class="object__nav__button">{{arrowObjectPrev(('T_OBJECT_PREV')|trans({}, 'openform_front', app.request.locale))}}{{ ('T_OBJECT_PREV')|trans({}, 'openform_front', app.request.locale) }}</a>
  298.                         {% endif%}
  299.                         {% if entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key + 1] is defined %}
  300.                             {% set nextElement = entity.AntiqueSuit.getVisibleAntiques(app.request.locale)[key + 1] %}
  301.                             {% set href = toolkit_route_localizer.generate('antique_item',{ slug : nextElement.Translation[app.request.locale].slug }, app.request.locale) %}
  302.                             <a href="{{href}}" class="object__nav__button object__nav__button--next">{{ ('T_OBJECT_NEXT')|trans({}, 'openform_front', app.request.locale) }}{{arrowObjectNext(('T_OBJECT_NEXT')|trans({}, 'openform_front', app.request.locale))}}</a>
  303.                         {% endif%}
  304.                     {% endif %}
  305.                 {% endfor %}    
  306.             </div>
  307.             
  308.     </section>
  309.     
  310.     
  311.     
  312.