Files
amare/resources/views/pages/portfolio/show.blade.php

72 lines
4.0 KiB
PHP

@extends('layouts.public')
@section('content')
<article>
<x-public.photo-hero :image-path="$case->cover_image_path" :image-alt="$case->cover_image_alt" :eyebrow="$case->event_type" :title="$case->title" :summary="$case->summary" :metadata="collect([$case->city, $case->venue, $case->event_date?->format('d/m/Y')])->filter()->implode(' · ')" />
<div class="border-b border-amare-border bg-amare-bg-deep">
<div class="container-amare grid gap-10 py-16 md:grid-cols-3" data-reveal-group>
<section class="space-y-3" data-reveal data-reveal-from="up">
<h2 class="text-xs font-semibold uppercase tracking-[0.14em] text-amare-accent">Desafio</h2>
<p class="text-amare-muted">{!! nl2br(e($case->challenge)) !!}</p>
</section>
<section class="space-y-3" data-reveal data-reveal-from="up">
<h2 class="text-xs font-semibold uppercase tracking-[0.14em] text-amare-accent">Solução</h2>
<p class="text-amare-muted">{!! nl2br(e($case->solution)) !!}</p>
</section>
@if (filled($case->result))
<section class="space-y-3" data-reveal data-reveal-from="up">
<h2 class="text-xs font-semibold uppercase tracking-[0.14em] text-amare-accent">Resultado</h2>
<p class="text-amare-muted">{!! nl2br(e($case->result)) !!}</p>
</section>
@endif
</div>
</div>
@if ($case->images->isNotEmpty())
<section aria-labelledby="gallery-heading" class="bg-amare-bg">
<div class="container-amare space-y-8 py-16">
<h2 id="gallery-heading" class="text-3xl font-medium text-amare-text">Galeria</h2>
<div class="grid gap-6 md:grid-cols-12 md:gap-x-8 md:gap-y-12" data-editorial-gallery data-reveal-group>
@foreach ($case->images as $image)
@php
$isFeature = $loop->first;
$isOffset = ! $isFeature && $loop->even;
@endphp
<figure
@class([
'space-y-2',
'md:col-span-7' => $isFeature,
'md:col-span-5 md:col-start-8 md:pt-12' => $isOffset,
'md:col-span-5' => ! $isFeature && ! $isOffset,
])
data-editorial-gallery-item="{{ $isFeature ? 'feature' : ($isOffset ? 'offset' : 'standard') }}"
data-reveal
data-reveal-from="up"
data-reveal-media
>
<x-media.image
:path="$image->path"
:alt="$image->alt_text"
sizes="(max-width: 768px) calc(100vw - 3rem), 50vw"
@class([
'img-editorial w-full object-cover',
'aspect-[5/4]' => $isFeature,
'aspect-[4/5]' => $isOffset,
'aspect-[4/3]' => ! $isFeature && ! $isOffset,
])
/>
@if (filled($image->caption))
<figcaption class="text-sm text-amare-muted">{{ $image->caption }}</figcaption>
@endif
</figure>
@endforeach
</div>
</div>
</section>
@endif
</article>
<x-home.final-cta :settings="$siteSettings" />
@endsection