{namespace poi=Newland\Toubiz\Poi\Neos\ViewHelpers}
{namespace vh=Newland\NeosViewHelpers\ViewHelpers}

<f:if condition="{article.bookingUri} || ({article.mainAddress.latitude} && {article.mainAddress.longitude})">
    <div {f:if(condition: article.isCity, else: 'class="mb-8"')}>
        <f:if condition="{article.bookingUri}">
            <div class="mb-2">
                <a class="c-button c-button--secondary" href="{article.bookingUri}" target="_blank">
                    {vh:translate(id: 'links.property.bookingUri', package: 'Newland.Toubiz.Poi.Neos', source: 'Views/Show')}
                </a>
            </div>
        </f:if>
        <f:if condition="{article.mainAddress.latitude} && {article.mainAddress.longitude}">
            <div>
                <a 
                    class="c-button c-button--secondary c-button--ghost"
                    href="https://maps.google.com/maps?daddr={article.mainAddress.latitude}%2C{article.mainAddress.longitude}"
                    target="_blank">

                    {vh:translate(id: 'links.property.routePlanner', package: 'Newland.Toubiz.Poi.Neos', source: 'Views/Show')}
                </a>
            </div>
        </f:if>
    </div>
</f:if>
