gallery fix
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
@php
|
||||
use App\Banner;
|
||||
$gridV2 = request()->query('grid') === 'v2';
|
||||
@endphp
|
||||
|
||||
@section('content')
|
||||
@@ -94,9 +95,13 @@
|
||||
</div>
|
||||
|
||||
<section class="px-6 pb-10 pt-8 md:px-10" data-nova-gallery data-gallery-type="{{ $gallery_type ?? 'browse' }}">
|
||||
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 force-5" data-gallery-grid>
|
||||
<div class="{{ $gridV2 ? 'gallery' : 'grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6 force-5' }}" data-gallery-grid>
|
||||
@forelse ($artworks as $art)
|
||||
@include('legacy._artwork_card', ['art' => $art])
|
||||
<x-artwork-card
|
||||
:art="$art"
|
||||
:loading="$loop->index < 8 ? 'eager' : 'lazy'"
|
||||
:fetchpriority="$loop->index === 0 ? 'high' : null"
|
||||
/>
|
||||
@empty
|
||||
<div class="panel panel-default effect2">
|
||||
<div class="panel-heading"><strong>No Artworks Yet</strong></div>
|
||||
@@ -112,6 +117,9 @@
|
||||
{{ method_exists($artworks, 'withQueryString') ? $artworks->withQueryString()->links() : $artworks->links() }}
|
||||
@endif
|
||||
</div>
|
||||
<div class="hidden" data-gallery-skeleton-template aria-hidden="true">
|
||||
<x-skeleton.artwork-card />
|
||||
</div>
|
||||
<div class="hidden mt-8" data-gallery-skeleton></div>
|
||||
</section>
|
||||
</main>
|
||||
@@ -122,6 +130,7 @@
|
||||
@endsection
|
||||
|
||||
@push('styles')
|
||||
@if(! $gridV2)
|
||||
<style>
|
||||
[data-nova-gallery].is-enhanced [data-gallery-grid] {
|
||||
display: grid;
|
||||
@@ -206,6 +215,7 @@
|
||||
background: linear-gradient(180deg, rgba(17,24,39,0) 0%, rgba(7,10,15,0.9) 60%, rgba(7,10,15,1) 100%);
|
||||
}
|
||||
</style>
|
||||
@endif
|
||||
@endpush
|
||||
|
||||
@push('scripts')
|
||||
|
||||
Reference in New Issue
Block a user