{% from '@openform_front_templates/_includes/_icons.html.twig' import fullscreen, zoomin, zoomout, sliderprev, slidernext, arrowright, copyrights, infoClose, info %}
{% set ImageSlides = entity.ImageSlide|filterVisibles(app.request.locale) %}
<div class="collections__wrapper " style="width:
{% if entity.textAreaWidth and entity.imageColumnWidth and (entity.textAreaWidth + entity.imageColumnWidth < 100) %}
{{100 - entity.textAreaWidth - entity.imageColumnWidth}}%;
{% elseif entity.textAreaWidth and entity.imageColumnWidth == null %}
{{100 - entity.textAreaWidth - (100 - entity.textAreaWidth - 20)}}%;
{% elseif entity.textAreaWidth == null and entity.imageColumnWidth %}
{{100 - entity.imageColumnWidth - (100 - entity.imageColumnWidth - 20)}}%;
{% else %}
20%;
{% endif %}
">
{% set img = openform_front_util.getImagePathByType(entity.Thumb ?? '','column') %}
{% if img is defined and img %}
<img class="collections__wrapper__fullsize-image" style="{% if entity.imageBorderColor and entity.imageBorderWidth %}outline: {{entity.imageBorderColor}} solid {{entity.imageBorderWidth}}px;{% endif %}" src="{{img}}" alt="{{ entity.Translation[app.request.locale].alt ? entity.Translation[app.request.locale].alt }}">
{% endif %}
</div>
<div class="collections__wrapper" style="background: {{entity.background|default('#F5DB7B') }}; width:
{% if entity.textAreaWidth and entity.imageColumnWidth and (entity.textAreaWidth + entity.imageColumnWidth < 100) %}
{{ entity.textAreaWidth}}%;
{% elseif entity.textAreaWidth and entity.imageColumnWidth == null %}
{{entity.textAreaWidth}}%;
{% elseif entity.textAreaWidth == null and entity.imageColumnWidth %}
{{100 - entity.imageColumnWidth - 20}}%;
{% else %}
25%;
{% endif %}
{% if not entity.showHeader %}padding-top:{{rootParent is defined and rootParent.headerHeight is defined and rootParent.headerHeight ? rootParent.headerHeight : 90}}px;{% endif %}" data-lenis-prevent>
<div class="collections__content">
<div class="collections__content__scroll">
{% if entity.Translation[app.request.locale].titleHtml is defined and entity.Translation[app.request.locale].titleHtml %}
<div class="collections__content__title block__h3">
{{ entity.Translation[app.request.locale].titleHtml|raw }}
</div>
{% endif %}
{% if entity.link is defined and entity.link %}
<a href="{{entity.link}}" class="block-text__btns__btn button-read-more button-read-more--black">
<span>{{('T_RELICT_LINK')|trans({}, 'openform_front', app.request.locale)}}</span>
{{arrowright()}}
</a>
{% endif %}
{% if entity.Translation[app.request.locale].text is defined and entity.Translation[app.request.locale].text %}
<div class="collections__content__text block__text">
{{ entity.Translation[app.request.locale].text|raw }}
</div>
{% endif %}
{% if entity.filePath is defined and entity.filePath and openform_front_util.isMp3File(entity.filePath) %}
<div class="block-image__image__audio">
<div class="block-audio__player">
<audio controls class="js-audio-player block-audio__inner">
<source src="{{ entity.filePath }}">
Your browser does not support the audio element.
</audio>
</div>
</div>
{% endif %}
{% if entity.Translation[app.request.locale].description is defined and entity.Translation[app.request.locale].description %}
<div class="collections__content__text block__text">
{{ entity.Translation[app.request.locale].description|raw }}
</div>
{% endif %}
{% if entity.Translation[app.request.locale].attributesText is defined and entity.Translation[app.request.locale].attributesText %}
<div class="collections__content__text block__text">
{{ entity.Translation[app.request.locale].attributesText|raw }}
</div>
{% endif %}
</div>
<div class="collections__line-2" style="background: {{entity.lineColor2|default('#9B9791') }}; height:{{entity.lineHeight2|default('10') }}px;"></div>
<div class="collections__arrows">
{% for key, Relict in entity.RelictPack.getVisibleRelicts(app.request.locale) %}
{% if entity.id == Relict.id %}
{% if entity.RelictPack.getVisibleRelicts(app.request.locale)[key - 1] is defined %}
{% set prevElement = entity.RelictPack.getVisibleRelicts(app.request.locale)[key - 1] %}
{% set href = toolkit_route_localizer.generate('relict_item',{ slug : prevElement.Translation[app.request.locale].slug }, app.request.locale) %}
<a href="{{href}}" class="slider-nav__btn slider-nav__btn--prev">
{{ sliderprev('PREV_Relict'|trans({}, 'openform_front', app.request.locale)) }}
</a>
{% endif%}
{% if entity.RelictPack.getVisibleRelicts(app.request.locale)[key + 1] is defined %}
{% set nextElement = entity.RelictPack.getVisibleRelicts(app.request.locale)[key + 1] %}
{% set href = toolkit_route_localizer.generate('relict_item',{ slug : nextElement.Translation[app.request.locale].slug }, app.request.locale) %}
<a href="{{href}}" class="slider-nav__btn slider-nav__btn--next">
{{ slidernext('Next_Relict'|trans({}, 'openform_front', app.request.locale)) }}
</a>
{% endif%}
{% endif %}
{% endfor %}
</div>
</div>
</div>
<div class="collections__wrapper {% if ImageSlides|length > 1 %}collections__wrapper--double{% endif %}" style="background: {{entity.imageBackgroundColor|default('#F8F7F0') }}; width:
{% if entity.textAreaWidth and entity.imageColumnWidth and (entity.textAreaWidth + entity.imageColumnWidth < 80) %}
{{ entity.imageColumnWidth}}%;
{% elseif entity.textAreaWidth and entity.imageColumnWidth == null %}
{{100 - entity.textAreaWidth - 20}}%;
{% elseif entity.textAreaWidth == null and entity.imageColumnWidth %}
{{ entity.imageColumnWidth}}%;
{% else %}
55%;
{% endif %}
{% if not entity.showHeader %}padding-top:{{rootParent is defined and rootParent.headerHeight is defined and rootParent.headerHeight ? rootParent.headerHeight : 90}}px;{% endif %}">
{% if ImageSlides|length == 1 %}
{% set image = ImageSlides|length == 1 and ImageSlides is defined and ImageSlides[0] ? ImageSlides[0] %}
{% if image is defined and image %}
{% set img = openform_front_util.getImagePathByType(image.Thumb ?? '','original') %}
{# {% set img = openform_front_util.getImagePathByType(image.Thumb ?? '','imageA') %}
{% set imgPagination = openform_front_util.getImagePathByType(image.Thumb ?? '','list') %} #}
<div class="collections__wrapper__zoom js-zoom" data-alt="{{image.Translation[app.request.locale].alt}}" style="{{image.imageWidth ? 'width:'~ image.imageWidth ~ '%;': 'width: 56%;'}} {{image.imageHeight ? 'height:'~ image.imageHeight + 6 ~ '%;': 'height: 60%;'}}">
<div class="collection-gallery__item collection-gallery__item--o3 " style="{{image.imageBorderWidth ? 'width: calc(100% - ' ~ 2 * image.imageBorderWidth ~ 'px);' : 'width: 100%;'}}
{{image.imageBorderWidth ? 'max-width: calc(100% - ' ~ 2 * image.imageBorderWidth ~ 'px);' : 'max-width: 100%;'}}
{{image.imageBorderWidth ? 'height: calc(100% - ' ~ 2 * image.imageBorderWidth ~ 'px);' : 'height: 100%;'}}
{{image.imageBorderWidth ? 'max-height: calc(100% - ' ~ 2 * image.imageBorderWidth ~ 'px);' : 'max-height: 100%;'}}
">
<div class="my-zoomist" data-zoomist-src="{{img}}" data-alt="{{image.Translation[app.request.locale].alt}}" tabindex="0"></div>
</div>
<div class="collection-gallery__wrap">
<div>
</div>
<div class="collection-gallery__buttons">
{% if image.Translation[app.request.locale].text is defined and image.Translation[app.request.locale].text %}
<div class="object__info-wrap">
<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>
<div class="object__info object__info--info js-info-{{key}}" data-lenis-prevent>
<div class="object__info__text block__text">{{image.Translation[app.request.locale].text|raw}}</div>
<button class="object__info__close js-expanded-close" type="button">{{infoClose()}}</button>
</div>
</div>
{% endif %}
{% if image.Translation[app.request.locale].copyrights %}
<div class="object__info-wrap">
<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>
<div class="object__info object__info--copyright js-copyright-{{key}}" data-lenis-prevent>
<div class="object__info__text block__text">{{image.Translation[app.request.locale].copyrights|raw}}</div>
<button class="object__info__close js-expanded-close" type="button">{{infoClose()}}</button>
</div>
</div>
{% endif %}
<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 }}"
data-image="{{img}}"
data-description="{{image.Translation[app.request.locale].text}}"
data-copyrights="{{image.Translation[app.request.locale].copyrights}}"
data-start="0"
data-imagestyle="{% if image.imageBorderColor and image.imageBorderWidth %}border: {{image.imageBorderColor}} solid {{image.imageBorderWidth}}px;{% endif %}"
>
{{fullscreen(('T_FULLSCREEN')|trans({}, 'openform_front', app.request.locale))}}
</button>
<button class="collection-gallery__buttons__btn js-zoom-out">{{zoomout(('T_ZOOMOUT')|trans({}, 'openform_front', app.request.locale))}}</button>
<button class="collection-gallery__buttons__btn js-zoom-in">{{zoomin(('T_ZOOMIN')|trans({}, 'openform_front', app.request.locale))}}</button>
</div>
</div>
</div>
{% endif %}
{% elseif ImageSlides|length > 1 %}
{% for key, image in ImageSlides|slice(0, 2) %}
{% set img = openform_front_util.getImagePathByType(image.Thumb ?? '','original') %}
{# {% set img = openform_front_util.getImagePathByType(image.Thumb ?? '','imageA') %}
{% set imgPagination = openform_front_util.getImagePathByType(image.Thumb ?? '','list') %} #}
<div class="collections__wrapper__zoom js-zoom" data-alt="{{image.Translation[app.request.locale].alt}}" style="{{image.imageWidth ? 'width:'~ image.imageWidth ~ '%;': 'width: 32%;'}} {{image.imageHeight ? 'height:'~ image.imageHeight + 6 ~ '%;': 'height: 38%;'}}">
<div class="collection-gallery__item collection-gallery__item--o3 " style="width: 100%; max-width: 100%; height: 100%; max-height: 100%;">
<style>
.my-zoomist-{{key}} img{
{% if image.imageBorderColor and image.imageBorderWidth %}border: {{image.imageBorderColor}} solid {{image.imageBorderWidth}}px;{% endif %}"
}
.my-zoomist-{{key}} .zoomist-wrapper{
background:{{image.imageBackgroundColor ? image.imageBackgroundColor : entity.imageBackgroundColor ? entity.imageBackgroundColor : '#F8F7F0' }};
}
</style>
<div class="my-zoomist my-zoomist-{{key}}" data-zoomist-src="{{img}}" tabindex="0"></div>
</div>
<div class="collection-gallery__wrap">
<div>
</div>
<div class="collection-gallery__buttons">
{% if image.Translation[app.request.locale].text is defined and image.Translation[app.request.locale].text %}
<div class="object__info-wrap">
<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>
<div class="object__info object__info--info js-info-{{key}}" data-lenis-prevent>
<div class="object__info__text block__text">{{image.Translation[app.request.locale].text|raw}}</div>
<button class="object__info__close js-expanded-close" type="button">{{infoClose()}}</button>
</div>
</div>
{% endif %}
{% if image.Translation[app.request.locale].copyrights %}
<div class="object__info-wrap">
<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>
<div class="object__info object__info--copyright js-copyright-{{key}}" data-lenis-prevent>
<div class="object__info__text block__text">{{image.Translation[app.request.locale].copyrights|raw}}</div>
<button class="object__info__close js-expanded-close" type="button">{{infoClose()}}</button>
</div>
</div>
{% endif %}
<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 }}"
data-image="{{img}}"
data-description="{{image.Translation[app.request.locale].text}}"
data-copyrights="{{image.Translation[app.request.locale].copyrights}}"
data-start="{{key}}"
data-imagestyle="{% if image.imageBorderColor and image.imageBorderWidth %}border: {{image.imageBorderColor}} solid {{image.imageBorderWidth}}px;{% endif %}"
>
{{fullscreen(('T_FULLSCREEN')|trans({}, 'openform_front', app.request.locale))}}
</button>
<button class="collection-gallery__buttons__btn js-zoom-out">{{zoomout(('T_ZOOMOUT')|trans({}, 'openform_front', app.request.locale))}}</button>
<button class="collection-gallery__buttons__btn js-zoom-in">{{zoomin(('T_ZOOMIN')|trans({}, 'openform_front', app.request.locale))}}</button>
</div>
</div>
</div>
{% endfor %}
{% endif %}
</div>
<div class="collections__line {% if not entity.showHeader %}collections__line--padding{% endif %}" style="background: {{entity.imageBackgroundColor|default('#F8F7F0') }};
width:
{% if entity.textAreaWidth and entity.imageColumnWidth and (entity.textAreaWidth + entity.imageColumnWidth < 100) %}
{{entity.textAreaWidth + entity.imageColumnWidth}}%
{% elseif entity.textAreaWidth and entity.imageColumnWidth == null %}
{{entity.textAreaWidth + (100 - entity.textAreaWidth - 20)}}%
{% elseif entity.textAreaWidth == null and entity.imageColumnWidth %}
{{entity.imageColumnWidth + (100 - entity.imageColumnWidth - 20)}}%
{% else %}
80%
{% endif %}
;">
<div class="collections__line__inner" style="width: 97%; background: {{entity.lineColor|default('#F5DB7B') }}; height:{{entity.lineHeight|default('10') }}px;"></div>
</div>