<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
      xmlns:sms="http://typo3.org/ns/SMS/SmsResponsiveImages/ViewHelpers"
      data-namespace-typo3-fluid="true">


<div class="contact-card contact-card--fullview" itemscope itemtype="http://schema.org/Person" >

    <f:render section="firstImage" partial="Address" arguments="{_all}" />
    <div class="contact-body">
    <f:render section="content" arguments="{_all}"/>
    </div>
</div>

<f:section name="content">

    <div class="contact-position">{address.position}</div>
    <div class="contact-company">{address.company}</div>
    <div class="contact-name">{address.title} {address.firstName} {address.middleName} {address.lastName}</div>



    <f:if condition="{address.description}">
        <div class="contact-description" itemprop="description">
            {address.description -> f:format.nl2br()}
        </div>
    </f:if>

    <f:render section="address" partial="Address" arguments="{_all}"/>

    <f:if condition="{address.building} || {address.room}">
        <ul class="list-inline">
            <f:if condition="{address.building}">
                <li class="list-inline-item">
                    {f:translate(key:'label.building')}: {address.building}
                </li>
            </f:if>

            <f:if condition="{address.room}">
                <li class="list-inline-item">
                    {f:translate(key:'label.room')}: {address.room}
                </li>
            </f:if>
        </ul>
    </f:if>

    <f:render section="contact" partial="Address" arguments="{_all}"/>
    <f:render section="social" partial="Address" arguments="{_all}"/>

    <f:if condition="{address.image -> f:count() > 1}">
        <div class="address-image-rows">
            <div class="row">
                <f:for each="{address.image}" as="img" iteration="iterator">
                    <f:if condition="{iterator.cycle}>1">
                        <div class="col-md-4">
                            <figure class="figure">
                                <a href="{f:uri.image(src:img.originalResource.publicUrl, maxWidth:1000)}"
                                   class="media-object {settings.detail.imageClass}"
                                   rel="images_tt_address_{address.uid}"
                                   alt="{img.originalResource.alt}"
                                   title="{img.originalResource.title}"
                                   target="_blank">
                                    <f:image image="{img}" width="400"
                                             alt="{img.originalResource.alt}"
                                             title="{img.originalResource.title}"
                                             class="figure-img img-fluid img-thumbnail rounded"
                                             additionalAttributes="{itemprop:'image'}"/>
                                </a>
                                <f:if condition="{img.originalResource.description}">
                                    <figcaption class="figure-caption">
                                        {img.originalResource.description -> f:format.nl2br()}
                                    </figcaption>
                                </f:if>
                            </figure>
                        </div>
                    </f:if>
                </f:for>
            </div>
        </div>
    </f:if>

</f:section>
