Files
opensem/resources/views/Shop/Homepage/partials/sliderByShelve.blade.php
Ludovic CANDELLIER 9698ba54d0 fixes
2022-12-22 01:09:11 +01:00

25 lines
1.0 KiB
PHP

@if ($shelve['articles'])
<div class="mb-3 bg-green-ultra-dark rounded-lg">
<div class="row">
<div class="col-6">
<h1 class="p-2" style="font-size: 2em;">{{ $shelve['name'] }}</h1>
</div>
<div class="col-6 text-right">
<a class="mt-2 btn btn-green-dark" href="{{ route('Shop.Categories.show', ['id' => $shelve['id']]) }}">Découvrir la sélection</a>
<a class="mt-2 green-dark btn" href="{{ route('Shop.Categories.show', ['id' => $shelve['id']]) }}">Tout voir</a>
</div>
</div>
<div class="row">
<div class="col-11 mx-auto shelve_slider_{{ $shelve['id'] }} slider">
@foreach ($shelve['articles'] as $name => $article)
<div class="text-center pr-2 pl-2">
<a class="green-fluo" href="{{ route('Shop.Articles.show', ['id' => $article['id']]) }}">
<img data-lazy="{{ App\Repositories\Shop\Articles::getPreviewSrc($article['image'] ?? false) }}" class="d-block w-100 rounded" alt="{{ $name }}"/>
{{ $name }}
</a>
</div>
@endforeach
</div>
</div>
</div>
@endif