ldc-theme-default/views/pages/home.blade.php
2023-12-20 11:50:35 +01:00

207 lines
13 KiB
PHP

@extends('theme::layout')
@section('main-class', 'home-page')
@section('content')
{{-- 1st row lots --}}
<section class="row position-relative text-xl-start text-center">
<div class="col d-none d-xl-flex g-0">
<img class="img-fluid object-fit-cover" src="{{ Vite::asset('resources/theme/mounted/assets/images/photo-canoe.png') }}"
title="{{ __('Une famille font du canoe avec leur petite file en gros plan.') }}" alt="{{ __('Une famille en canoe') }}">
</div>
<div class="col g-0 overflow-hidden">
<div class="container-fluid main-rotate mt-5">
<div class="row">
<div class="col">
<h2 class="text-uppercase text-primary fs-2 fw-bold ms-xl-5">{{ __('Jouez et tentez de gagner') }}</h2>
</div>
</div>
@if (collect($prizesGlobal)->count())
<div class="row">
@if (Arr::has($prizesGlobal, 0))
<div class="col-12 col-sm-6">
<div class="d-flex justify-content-center justify-content-xl-start">
<div class="ms-xl-5 me-2">
<span
class="bg-tertiary fs-3 rounded-pill fw-bold px-3 py-1 text-white">{{ Arr::get($prizesGlobal, 0)->quantity }}</span>
</div>
<h3 class="text-tertiary fw-bold fs-3 text-uppercase lh-1">
@if (intval(Arr::get($prizesGlobal, 0)->quantity) > 1)
{{ Str::plural(Arr::get($prizesGlobal, 0)->label) }}
@else
{{ Arr::get($prizesGlobal, 0)->label }}
@endif
</h3>
</div>
<img class="img-fluid anti-rotate" src="{{ asset(Arr::get($prizesGlobal, 0)->picture) }}"
title="{{ Arr::get($prizesGlobal, 0)->picture_title }}" alt="{{ Arr::get($prizesGlobal, 0)->picture_alt }}">
</div>
@endif
@if (Arr::has($prizesGlobal, 1))
<div class="col-12 col-sm-6">
<div class="d-flex justify-content-center justify-content-xl-start">
<div class="ms-xl-5 me-2">
<span
class="bg-tertiary fs-3 rounded-pill fw-bold px-3 py-1 text-white">{{ Arr::get($prizesGlobal, 1)->quantity }}</span>
</div>
<h3 class="text-tertiary fw-bold fs-3 text-uppercase lh-1">
@if (intval(Arr::get($prizesGlobal, 1)->quantity) > 1)
{{ Str::plural(Arr::get($prizesGlobal, 1)->label) }}
@else
{{ Arr::get($prizesGlobal, 1)->label }}
@endif
</h3>
</div>
<img class="img-fluid anti-rotate" src="{{ asset(resize(Arr::get($prizesGlobal, 1)->picture, 'trimlot2')) }}"
title="{{ Arr::get($prizesGlobal, 1)->picture_title }}"
alt="{{ Arr::get($prizesGlobal, 1)->picture_alt }}">
<div class="d-flex align-items-center justify-content-center flex-column flex-lg-row mt-3">
<span class="text-primary fw-bold text-uppercase">{!! clean(nl2br(__("Ou des milliers\n de bons\n de réduction"))) !!}</span>
<img class="img-fluid" src="{{ Vite::asset('resources/theme/mounted/assets/images/br-1-euro.png') }}"
title="{{ __('Réduction de 1 euro') }}" alt="{{ __('Réduction de 1 euro') }}">
</div>
</div>
@endif
</div>
@endif
</div>
<img class="picture-100-win position-absolute img-fluid d-none d-xl-inline top-0 mt-3"
src="{{ Vite::asset('resources/theme/mounted/assets/images/pastille.png') }}" alt="{{ __('Grand jeu 100% gagnant') }}">
</div>
</section>
{{-- BTN JOUER --}}
<div class="row mb-3 mt-5">
<div class="col d-flex justify-content-center">
<a class="btn btn-lg btn-tertiary fs-2 fw-bold text-uppercase px-5 py-1"
href="{{ route('fo.participate') }}">{{ __('Jouer !') }}</a>
</div>
</div>
{{-- 2nd Row how to play --}}
<section class="row text-bg-quad p-md-3 py-3" id="howto">
<div class="col-12 col-md-5 mb-3 pt-2 text-center">
<h2 class="fs-1 fw-bold">{{ __("Comment jouer\u{00A0}?") }}</h2>
<span
class="fs-3 fw-bold">{{ __("Rien de plus simple\u{00A0}! Suivez les 3 étapes décrites à droite et laissez-vous guider.") }}</span>
<div class="d-flex justify-content-center">
<img class="img-fluid picture-products" src="{{ Vite::asset('resources/theme/mounted/assets/images/how-to-play.png') }}"
title="{{ __('Plusieurs produits de la marque :company', ['company' => $settingsGlobal->company]) }}"
alt="{{ __('Plusieurs produits de la marque :company', ['company' => $settingsGlobal->company]) }}">
</div>
</div>
<div class="col d-flex mb-3 flex-row">
<div class="d-flex flex-column justify-content-evenly px-md-3 pe-3">
<div class="rounded-pill badge-vertical bg-white">
<img class="img-fluid" src="{{ Vite::asset('resources/theme/mounted/assets/images/logo-kart.png') }}"
title="{{ __('Achetez un produit :company porteur de l\'offre.', ['company' => Str::title($settingsGlobal->company)]) }}"
alt="{{ __('Un panier de course') }}">
</div>
<div class="rounded-pill badge-vertical bg-white">
<img class="img-fluid" src="{{ Vite::asset('resources/theme/mounted/assets/images/logo-br.png') }}"
title="{{ __('Trouver le code au dos du sticker') }}" alt="{{ __('Un sticker du jeu') }}">
</div>
<div class="rounded-pill badge-vertical bg-white">
<img class="img-fluid" src="{{ Vite::asset('resources/theme/mounted/assets/images/logo-tv.png') }}"
title="{{ __('Inscrivez-vous sur ce site') }}" alt="{{ __('Un écran d\'ordinateur avec un cadeau en son centre') }}">
</div>
</div>
<div class="d-flex justify-content-center flex-column ps-lg-3">
<div class="mb-1">
<span
class="h2">{{ __('Achetez un produit :company porteur de l\'offre.', ['company' => Str::title($settingsGlobal->company)]) }}</span>
</div>
@can('fo.showProducts')
<div class="mb-5 text-center">
<a class="btn btn-quint fw-bold text-uppercase"
href="{{ route('fo.produits-porteurs') }}">{{ __('Voir la liste des produits porteurs') }}</a>
</div>
@endcan
<div class="mb-5">
<span
class="h2">{{ __('Trouvez le code au dos du sticker, soit en le décollant du produit, soit en lisant en transparence.') }}</span>
</div>
<div class="">
<span
class="h2">{{ __("Inscrivez-vous sur ce site, insérez votre code et découvrez ce que vous avez gagné\u{00A0}!") }}</span>
</div>
</div>
</div>
</section>
{{-- 3 row gifts --}}
<section class="row overflow-x-hidden" id="gifts">
<div class="col g-0">
<div class="mt-4 p-1 text-center">
<h2 class="fs-1 text-quint text-uppercase fw-bold">{{ __('Les cadeaux') }}</h2>
</div>
<div class="carousel slide mt-5" id="carousel-lots" data-bs-pause="false" data-bs-touch="true">
<div class="carousel-indicators">
<button class="btn-control btn btn-sm btn-link ms-1 mt-1" id="coupons-carousel-play-btn"
data-stop="{{ __('Arrêter le carousel') }}" data-play="{{ __('Lancer le carousel') }}" type="button"
title="{{ __('Lancer ou arrêter le carousel') }}">
<i class="fa-solid fa-play" aria-hidden="true"></i>
<i class="fa-solid fa-pause d-none" aria-hidden="true"></i>
</button>
@foreach ($prizesGlobal as $prizeIndex => $prizeModel)
<button class="bg-quint @if ($loop->first) active @endif" data-bs-target="#carousel-lots"
data-bs-slide-to="{{ $prizeIndex }}" type="button" aria-label="{{ __('Slide :n', ['n' => $prizeIndex + 1]) }}"
@if ($loop->first) aria-current="true" @endif></button>
@endforeach
</div>
<div class="carousel-inner overflow-visible">
@foreach ($prizesGlobal as $prizeIndex => $prizeModel)
<div class="carousel-item @if ($loop->first) active @endif overflow-visible">
<div class="container-fluid">
<div class="row">
<div class="col-12 col-md-4 col-lg-6 text-md-end text-center">
@if ($loop->index === 0)
{{-- RESIZE FOR SPECIFIC PRIZE PICTURE --}}
<img class="img-fluid" src="{{ asset(resize($prizeModel->picture, 'trimlot1')) }}"
title="{{ $prizeModel->picture_title }}" alt="{{ $prizeModel->picture_alt }}">
@elseif ($loop->index === 1)
{{-- RESIZE FOR SPECIFIC PRIZE PICTURE --}}
<img class="img-fluid" src="{{ asset(resize($prizeModel->picture, 'trimlot2')) }}"
title="{{ $prizeModel->picture_title }}" alt="{{ $prizeModel->picture_alt }}">
@else
<img class="img-fluid" src="{{ asset($prizeModel->picture) }}"
title="{{ $prizeModel->picture_title }}" alt="{{ $prizeModel->picture_alt }}">
@endif
</div>
<div class="col d-flex justify-content-start align-items-center overflow-visible">
<div
class="d-inline-block text-bg-quint main-rotate carousel-text-pannel mx-md-4 p-md-4 mx-lg-5 p-lg-5 mb-5 overflow-visible">
<div class="anti-rotate m-3 p-1">
<h3 class="fs-3 text-md-start text-center">{{ $prizeModel->arg_title }}</h3>
@if ($prizeModel->arg_subtitle)
<h4>{{ $prizeModel->arg_subtitle }}</h4>
@endif
<div class="ck-content">{!! clean($prizeModel->arg_content) !!}</div>
</div>
</div>
</div>
</div>
</div>
</div>
@endforeach
</div>
<button class="carousel-control-prev" data-bs-target="#carousel-lots" data-bs-slide="prev" type="button">
<span class="carousel-control-prev-icon btn btn-primary rounded-pill p-3" aria-hidden="true"></span>
<span class="visually-hidden">{{ __('pagination.previous') }}</span>
</button>
<button class="carousel-control-next" data-bs-target="#carousel-lots" data-bs-slide="next" type="button">
<span class="carousel-control-next-icon btn btn-primary rounded-pill p-3" aria-hidden="true"></span>
<span class="visually-hidden">{{ __('pagination.next') }}</span>
</button>
</div>
</div>
</section>
{{-- BTN JOUER --}}
<div class="row mb-3 mt-5">
<div class="col d-flex justify-content-center">
<a class="btn btn-lg btn-tertiary fs-2 fw-bold text-uppercase px-5 py-1"
href="{{ route('fo.participate') }}">{{ __('Jouer !') }}</a>
</div>
</div>
@endsection