Compare commits

...

No commits in common. "addBanner" and "develop" have entirely different histories.

29 changed files with 350 additions and 118 deletions

View file

@ -1,3 +1,5 @@
ARG PHP_8_5_TAG=latest
FROM composer:2.8 AS vendor FROM composer:2.8 AS vendor
ARG GITLAB_USER ARG GITLAB_USER
@ -33,6 +35,7 @@ RUN npm config set @uwil:registry=https://lab.s-web.fr/api/v4/groups/ldc-web/-/p
RUN npm config set -- '//lab.s-web.fr/api/v4/groups/ldc-web/-/packages/npm/:_authToken' "${GITLAB_PASSWORD}" RUN npm config set -- '//lab.s-web.fr/api/v4/groups/ldc-web/-/packages/npm/:_authToken' "${GITLAB_PASSWORD}"
RUN npm ci && npm run prod RUN npm ci && npm run prod
ARG PHP_8_5_TAG
FROM registry.s-web.fr/ldc-web/projets/ldc-web-images-docker/uwil-production-8.5:${PHP_8_5_TAG} FROM registry.s-web.fr/ldc-web/projets/ldc-web-images-docker/uwil-production-8.5:${PHP_8_5_TAG}
ARG USER=www-data ARG USER=www-data

View file

@ -1,3 +1,5 @@
# LDC
# Table of contents # Table of contents
- [Table of contents](#table-of-contents) - [Table of contents](#table-of-contents)

39
RGPD.md Normal file
View file

@ -0,0 +1,39 @@
# RGPD
## Site
### En base de données
| Table | Colonne | Contenu | Utilisation |
| ----- | ------- | ------- | ----------- |
| activity_logs | user_id | Identifiant de l'utilisateur (back) | Tracer les modifications dans le BO |
| --- | --- | --- | --- |
| companies | responsable | Nom du responsable de la société | Renvoyé via un call API |
| --- | --- | --- | --- |
| users | first_name | Prénom | Affichage à différents endroits du BO |
| users | last_name | Nom | Affichage à différents endroits du BO |
| users | email | Adresse mail | Identifiant, sert à la connexion au BO |
### Formulaire de contact (marketing)
| Donnée | Contenu |
| ------ | ------- |
| Nom | Nom de la personne |
| Prénom | Prénom de la personne |
| Adresse E-mail | Adresse email de la personne |
| Téléphone | Numéro de téléphone de la personne |
| Adresse | Adresse de la personne |
| Code postal | Code postal de la personne |
| Ville | Ville de la personne |
| Pays | Pays de la personne |
| Société | Société de la personne |
| Pièce jointe | Photo renseignée par la personne |
## Cookies
| Service | Utilité |
| ------- | ------- |
| Matomo | Mesure d'audience |
| Google Recaptcha | Empêcher la soumission de formulaire par des robots |
| Vimeo | Visionner du contenu disponible sur la plateforme Vimeo |
| Youtube | Visionner du contenu disponible sur la plateforme Youtube |

View file

@ -105,8 +105,8 @@ class ContactRequest extends FormRequest
ContactFormType::export->equals(ContactFormType::make($typeContactForm)) ContactFormType::export->equals(ContactFormType::make($typeContactForm))
) { ) {
$rules = array_merge($rules, [ $rules = array_merge($rules, [
'type' => ['array', 'min:1'], 'typeExport' => ['array', 'min:1'],
'type.*' => [Rule::enum(ExportAskingType::class)], 'typeExport.*' => [Rule::enum(ExportAskingType::class)],
]); ]);
} }

View file

@ -5,6 +5,7 @@ namespace App\Models;
use App\Enums\Contact\BreedType; use App\Enums\Contact\BreedType;
use App\Enums\Contact\ContactFormType; use App\Enums\Contact\ContactFormType;
use App\Enums\Contact\CustomerAskingType; use App\Enums\Contact\CustomerAskingType;
use App\Enums\Contact\ExportAskingType;
use App\Enums\Contact\PressType; use App\Enums\Contact\PressType;
use App\Enums\Department; use App\Enums\Department;
use Illuminate\Database\Eloquent\Casts\AsEnumArrayObject; use Illuminate\Database\Eloquent\Casts\AsEnumArrayObject;
@ -28,6 +29,7 @@ use Illuminate\Database\Eloquent\Model;
* @property string $postalcode The customer's postalcode. * @property string $postalcode The customer's postalcode.
* @property boolean $newsletter The customer's optin response. * @property boolean $newsletter The customer's optin response.
* @property \App\Enums\Contact\CustomerAskingType[] $type The customer's type asking * @property \App\Enums\Contact\CustomerAskingType[] $type The customer's type asking
* @property \App\Enums\Contact\ExportAskingType[] $typeExport The customer's type asking
* @property \App\Enums\Contact\PressType $subject The message's subject * @property \App\Enums\Contact\PressType $subject The message's subject
* @property-read \Carbon\Carbon $created_at Created date. * @property-read \Carbon\Carbon $created_at Created date.
* @property-read \Carbon\Carbon $updated_at Updated date. * @property-read \Carbon\Carbon $updated_at Updated date.
@ -60,6 +62,7 @@ class MailContactData extends Model
'town', 'town',
'postalcode', 'postalcode',
'type', 'type',
'typeExport',
'subject', 'subject',
'newsletter', 'newsletter',
]; ];
@ -74,6 +77,7 @@ class MailContactData extends Model
'typeelevage' => AsEnumArrayObject::class . ':' . BreedType::class, 'typeelevage' => AsEnumArrayObject::class . ':' . BreedType::class,
'zonegeo' => AsEnumArrayObject::class . ':' . Department::class, 'zonegeo' => AsEnumArrayObject::class . ':' . Department::class,
'type' => AsEnumArrayObject::class . ':' . CustomerAskingType::class, 'type' => AsEnumArrayObject::class . ':' . CustomerAskingType::class,
'typeExport' => AsEnumArrayObject::class . ':' . ExportAskingType::class,
'subject' => PressType::class, 'subject' => PressType::class,
]; ];

View file

@ -20,7 +20,7 @@ return [
| |
*/ */
'driver' => env('SCOUT_DRIVER', null), 'driver' => env('SCOUT_DRIVER'),
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------

View file

@ -57,7 +57,7 @@ return [
'label' => 'Type of breeding desired' 'label' => 'Type of breeding desired'
], ],
'geo_zone' => [ 'geo_zone' => [
'label' => 'Geographic area of ​​your project', 'label' => 'Geographic area of your project',
'placeholder' => 'Drop-down list of departments' 'placeholder' => 'Drop-down list of departments'
], ],
'your_project' => [ 'your_project' => [
@ -72,6 +72,10 @@ return [
'label' => 'Type', 'label' => 'Type',
'placeholder' => 'Dropdown list' 'placeholder' => 'Dropdown list'
], ],
'exportAskingType' => [
'label' => 'Type',
'placeholder' => 'Dropdown list'
],
'company' => [ 'company' => [
'label' => 'Company', 'label' => 'Company',
'placeholder' => 'Your company' 'placeholder' => 'Your company'
@ -152,4 +156,23 @@ return [
'validate' => 'Confirm', 'validate' => 'Confirm',
'policy_message' => 'For any additional information regarding your personal data and your rights, please consult our ' 'policy_message' => 'For any additional information regarding your personal data and your rights, please consult our '
], ],
'finance-maintenance' => 'The stock market prices are currently undergoing maintenance. We apologise for any inconvenience caused. We are working to restore the service as soon as possible.',
'bea_banner' => [
'region_label' => 'Animal welfare and LDC commitments',
'logo_alt' => 'Animal Welfare Logo - Committed Agricultural Chain',
'commitments_intro' => 'Discover our commitments :br on',
'site_url_text' => 'www.bienetreanimal.fr',
'site_link_title' => 'Visit the website www.bienetreanimal.fr (new window)',
'site_link_aria' => 'Visit the website www.bienetreanimal.fr (new window)',
'company' => 'LDC',
'title' => 'Member company of the collective',
'subtitle' => 'Committed Agricultural Chain to elevate Animal Welfare',
'description' => '100% French origin chicken :br raised with RESPECT FOR ANIMAL WELFARE:br by a COMMITTED AGRICULTURAL CHAIN',
'description_html' => '100% French origin chicken :br raised with RESPECT FOR ANIMAL WELFARE:br by a COMMITTED AGRICULTURAL CHAIN',
'ldc_alt' => 'LDC logo',
'cta_text' => 'Discover our commitments here',
'cta_title' => 'Discover our commitments to animal welfare on www.bienetreanimal.fr (new window)',
'cta_aria' => 'Discover our commitments to animal welfare on www.bienetreanimal.fr (new window)',
'new_window' => 'new window',
],
]; ];

View file

@ -73,6 +73,10 @@ return [
'label' => 'Type', 'label' => 'Type',
'placeholder' => 'Liste déroulante' 'placeholder' => 'Liste déroulante'
], ],
'exportAskingType' => [
'label' => 'Type',
'placeholder' => 'Liste déroulante'
],
'company' => [ 'company' => [
'label' => 'Société', 'label' => 'Société',
'placeholder' => 'Votre société' 'placeholder' => 'Votre société'
@ -153,4 +157,23 @@ return [
'validate' => 'Valider', 'validate' => 'Valider',
'policy_message' => 'Pour toute information complémentaire concernant vos données personnelles et vos droits, merci de consulter notre' 'policy_message' => 'Pour toute information complémentaire concernant vos données personnelles et vos droits, merci de consulter notre'
], ],
'finance-maintenance' => 'Affichage du cours de la bourse en cours de maintenance, veuillez nous excuser pour la gêne occasionnée. Nous nous efforçons de rétablir le service dans les meilleurs délais.',
'bea_banner' => [
'region_label' => 'Bien-être animal et engagements Groupe LDC',
'logo_alt' => 'Logo Bien-être Animal - Filière Agricole Engagée',
'commitments_intro' => 'Retrouvez nos engagements :br sur',
'site_url_text' => 'www.bienetreanimal.fr',
'site_link_title' => 'Visiter le site www.bienetreanimal.fr (nouvelle fenêtre)',
'site_link_aria' => 'Visiter le site www.bienetreanimal.fr (nouvelle fenêtre)',
'company' => 'Groupe LDC',
'title' => 'Le Groupe LDC adhère au collectif',
'subtitle' => 'Filière Agricole Engagée pour élever le Bien-être Animal',
'description' => 'Du poulet 100% origine France :br élevé dans le RESPECT DU BIEN-ÊTRE ANIMAL :br par une FILIÈRE AGRICOLE ENGAGÉE',
'description_html' => 'Du poulet 100% origine France :br élevé dans le RESPECT DU BIEN-ÊTRE ANIMAL :br par une FILIÈRE AGRICOLE ENGAGÉE',
'ldc_alt' => 'Logo Groupe LDC',
'cta_text' => 'Retrouvez nos engagements ici',
'cta_title' => 'Retrouvez nos engagements en faveur du bien-être animal sur www.bienetreanimal.fr (nouvelle fenêtre)',
'cta_aria' => 'Retrouvez nos engagements en faveur du bien-être animal sur www.bienetreanimal.fr (nouvelle fenêtre)',
'new_window' => 'nouvelle fenêtre',
],
]; ];

View file

@ -40,6 +40,7 @@ data:
GOOGLE_RECAPTCHA_PUBLIC: "${APP_GOOGLE_RECAPTCHA_PUBLIC}" GOOGLE_RECAPTCHA_PUBLIC: "${APP_GOOGLE_RECAPTCHA_PUBLIC}"
GOOGLE_RECAPTCHA_VERSION: "${APP_GOOGLE_RECAPTCHA_VERSION}" GOOGLE_RECAPTCHA_VERSION: "${APP_GOOGLE_RECAPTCHA_VERSION}"
GOOGLE_MAPS_KEY: "${APP_GOOGLE_MAPS_KEY}" GOOGLE_MAPS_KEY: "${APP_GOOGLE_MAPS_KEY}"
SCOUT_DRIVER: "${APP_SCOUT_DRIVER}"
SCOUT_PREFIX: "${APP_SCOUT_PREFIX}" SCOUT_PREFIX: "${APP_SCOUT_PREFIX}"
SCOUT_QUEUE: "${APP_SCOUT_QUEUE}" SCOUT_QUEUE: "${APP_SCOUT_QUEUE}"
MEILISEARCH_HOST: "meilisearch.common-services:7700" MEILISEARCH_HOST: "meilisearch.common-services:7700"
@ -92,6 +93,9 @@ spec:
containers: containers:
- name: ${CI_PROJECT_PATH_SLUG}-container - name: ${CI_PROJECT_PATH_SLUG}-container
image: $IMAGE_TAG image: $IMAGE_TAG
env:
- name: XDG_CONFIG_HOME # For tinker
value: /tmp
envFrom: envFrom:
- configMapRef: - configMapRef:
name: ${CI_PROJECT_PATH_SLUG}-config-map name: ${CI_PROJECT_PATH_SLUG}-config-map
@ -133,9 +137,9 @@ spec:
imagePullSecrets: imagePullSecrets:
- name: docker-registry-credentials - name: docker-registry-credentials
securityContext: securityContext:
runAsUser: 33 runAsUser: 82
runAsGroup: 33 runAsGroup: 82
fsGroup: 33 fsGroup: 82
fsGroupChangePolicy: "OnRootMismatch" fsGroupChangePolicy: "OnRootMismatch"
volumes: volumes:
- name: storage - name: storage
@ -234,8 +238,8 @@ spec:
persistentVolumeClaim: persistentVolumeClaim:
claimName: ${CI_PROJECT_PATH_SLUG}-pvc-storage claimName: ${CI_PROJECT_PATH_SLUG}-pvc-storage
securityContext: securityContext:
runAsUser: 33 runAsUser: 82
runAsGroup: 33 runAsGroup: 82
fsGroup: 33 fsGroup: 82
fsGroupChangePolicy: "OnRootMismatch" fsGroupChangePolicy: "OnRootMismatch"
restartPolicy: OnFailure restartPolicy: OnFailure

View file

@ -219,7 +219,7 @@ $(document).ready(function () {
var brands_slider_default = new Swiper( var brands_slider_default = new Swiper(
$(".brands-list_default .brands-list__slider"), $(".brands-list_default .brands-list__slider"),
{ {
slidesPerView: 6, slidesPerView: 5,
spaceBetween: 10, spaceBetween: 10,
loop: true, loop: true,
navigation: { navigation: {
@ -229,7 +229,7 @@ $(document).ready(function () {
}, },
breakpoints: { breakpoints: {
1025: { 1025: {
slidesPerView: 6, slidesPerView: 5,
}, },
761: { 761: {
slidesPerView: 3, slidesPerView: 3,

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB

View file

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

View file

@ -8,50 +8,9 @@
// * BASE // * BASE
@use './base/common'; @use './base/common';
@use './base/fonts';
@use './base/tailwind-scope';
// * TAILWIND
//////////////////// Poppins //////////////////// @tailwind components;
@tailwind utilities;
@font-face {
font-display: swap;
font-family: 'Poppins';
font-style: normal;
font-weight: 400;
src: url('&/fonts/Poppins/Poppins-Regular.ttf') format('truetype');
}
@font-face {
font-display: swap;
font-family: 'Poppins';
font-style: normal;
font-weight: 700;
src: url('&/fonts/Poppins/Poppins-Bold.ttf') format('truetype');
}
@font-face {
font-display: swap;
font-family: 'Poppins';
font-style: normal;
font-weight: 300;
src: url('&/fonts/Poppins/Poppins-Light.ttf') format('truetype');
}
@font-face {
font-display: swap;
font-family: 'Poppins';
font-style: italic;
font-weight: 700;
src: url('&/fonts/Poppins/Poppins-BoldItalic.ttf') format('truetype');
}
@font-face {
font-display: swap;
font-family: 'Poppins';
font-style: italic;
font-weight: 300;
src: url('&/fonts/Poppins/Poppins-Italic.ttf') format('truetype');
}
.f-poppins {
font-family: 'Poppins', sans-serif;
}

View file

@ -0,0 +1,86 @@
//////////////////// Poppins ////////////////////
/* Poppins - Light */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: normal;
font-weight: 300;
src: url('&/fonts/Poppins/Poppins-Light.ttf') format('truetype');
}
/* Poppins - Regular */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: normal;
font-weight: 400;
src: url('&/fonts/Poppins/Poppins-Regular.ttf') format('truetype');
}
/* Poppins - Italic */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: italic;
font-weight: 400;
src: url('&/fonts/Poppins/Poppins-Italic.ttf') format('truetype');
}
/* Poppins - Medium */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: normal;
font-weight: 500;
src: url('&/fonts/Poppins/Poppins-Medium.ttf') format('truetype');
}
/* Poppins - Semi Bold */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: normal;
font-weight: 600;
src: url('&/fonts/Poppins/Poppins-SemiBold.ttf') format('truetype');
}
/* Poppins - Bold */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: normal;
font-weight: 700;
src: url('&/fonts/Poppins/Poppins-Bold.ttf') format('truetype');
}
/* Poppins - Bold Italic */
@font-face {
font-display: swap;
font-family: Poppins;
font-style: italic;
font-weight: 700;
src: url('&/fonts/Poppins/Poppins-BoldItalic.ttf') format('truetype');
}
/* Poppins - Black */
@font-face {
font-display: swap;
font-family: 'Poppins Black';
font-style: normal;
font-weight: 900;
src: url('&/fonts/Poppins/Poppins-Black.ttf') format('truetype');
}
/* Poppins - Black Italic */
@font-face {
font-display: swap;
font-family: 'Poppins Black';
font-style: italic;
font-weight: 900;
src: url('&/fonts/Poppins/Poppins-BlackItalic.ttf') format('truetype');
}
.f-poppins {
font-family: Poppins, sans-serif;
}

View file

@ -0,0 +1,16 @@
:where(.tailwind-scope, #bea-encart),
:where(.tailwind-scope, #bea-encart) :where(*, *::before, *::after) {
--tw-border-spacing-x: 0;
--tw-border-spacing-y: 0;
--tw-translate-x: 0;
--tw-translate-y: 0;
--tw-rotate: 0;
--tw-skew-x: 0;
--tw-skew-y: 0;
--tw-scale-x: 1;
--tw-scale-y: 1;
--tw-ring-offset-shadow: 0 0 #0000;
--tw-ring-shadow: 0 0 #0000;
--tw-shadow: 0 0 #0000;
--tw-shadow-colored: 0 0 #0000;
}

View file

@ -1,9 +1,6 @@
// ASSETS
import.meta.glob("../../assets/images/**/*", { eager: true });
// * Packages // * Packages
import Chart from "chart.js/auto";
import axios from "axios"; import axios from "axios";
import Chart from "chart.js/auto";
// * Other // * Other
import "../../sass/front/app.scss"; import "../../sass/front/app.scss";
@ -13,6 +10,9 @@ import CookieNotice from "@ldc-web/cookie-notice";
// LOCAL IMPORTS // LOCAL IMPORTS
import "./base/common"; import "./base/common";
// * ASSETS
import.meta.glob("../../assets/images/**/*", { eager: true });
axios.defaults.headers.common = { axios.defaults.headers.common = {
Accept: "application/json, text/plain, */*", Accept: "application/json, text/plain, */*",
"X-Requested-With": "XMLHttpRequest", "X-Requested-With": "XMLHttpRequest",

View file

@ -6,4 +6,4 @@ interface ImportMetaEnv {
interface ImportMeta { interface ImportMeta {
readonly env: ImportMetaEnv; readonly env: ImportMetaEnv;
} }

View file

@ -23,8 +23,7 @@
<h3 class="finance-api__title subtitle">{{ $bourseSection['string_title'] }}</h3> <h3 class="finance-api__title subtitle">{{ $bourseSection['string_title'] }}</h3>
@endif @endif
<p class="warning-message"> <p class="warning-message">
Affichage du cours de la bourse en cours de maintenance, veuillez nous excuser pour la gêne {{ __('front.finance-maintenance') }}
occasionnée. Nous nous efforçons de rétablir le service dans les meilleurs délais.
</p> </p>
<div class="finance-api__text description"> <div class="finance-api__text description">
@if (isset($bourseSection['wysiwyg_description'])) @if (isset($bourseSection['wysiwyg_description']))

View file

@ -1,15 +1,31 @@
@if(!empty($joinUs)) @if (!empty($joinUs))
<div data-anchor="{{ Str::ucfirst(Str::lower($joinUs['string_title']) . " " . Str::lower($joinUs['string_subtitle'])) }}" id="rejoin_6"> <div data-anchor="{{ Str::ucfirst(Str::lower(data_get($joinUs, 'string_title', '')) . ' ' . Str::lower(data_get($joinUs, 'string_subtitle', ''))) }}"
id="rejoin_6">
<div class="breeders fw fw-container"> <div class="breeders fw fw-container">
<div class="breeders__wrapper wrapper"> <div class="breeders__wrapper wrapper">
<x-front.sections.title title="{{ $joinUs['string_title'] }}" subtitle="{{ $joinUs['string_subtitle'] }}" <x-front.sections.title title="{{ data_get($joinUs, 'string_title', '') }}"
class="breeders__title" secondaryClass="breeders__subtitle" /> subtitle="{{ data_get($joinUs, 'string_subtitle', '') }}" class="breeders__title"
secondaryClass="breeders__subtitle" />
<div class="textblock__container"> <div class="textblock__container">
<div class="textblock__block"> <div class="textblock__block">
<div class="breeders__text description textblock__info-description"> <div class="breeders__text description textblock__info-description">
{!! $joinUs['wysiwyg_content'] !!} {!! data_get($joinUs, 'wysiwyg_content', '') !!}
</div> </div>
@if (!empty(data_get($joinUs, 'list_cta.0.model_cta')) && !empty(data_get($joinUs, 'list_cta.0.reserved_model_cta')))
@php
$targetModel = \App\Models\PageConfig::getModelFromInputModelConfig(
data_get($joinUs, 'list_cta.0.model_cta'),
data_get($joinUs, 'list_cta.0.reserved_model_cta'),
);
$buttonUrl = \App\Helpers\RouteHelper::routeNameChecker(
"front.dynamic-pages.{$targetModel->id_key}",
);
@endphp
<a class="breeders__btn btn"
href="{{ $buttonUrl }}">{{ data_get($joinUs, 'list_cta.0.string_label_cta') }}</a>
@endif
</div> </div>
</div> </div>
<div class="breeders__videos videos-list"> <div class="breeders__videos videos-list">
@if (!empty($joinUs['list_videos'])) @if (!empty($joinUs['list_videos']))
@ -18,11 +34,13 @@
@php @php
$video = [ $video = [
'type_video' => isset($vid['youtubeid_video']) ? 'youtube' : 'vimeo', 'type_video' => isset($vid['youtubeid_video']) ? 'youtube' : 'vimeo',
'video' => isset($vid['youtubeid_video']) ? $vid['youtubeid_video']: $vid['vimeoid_video'] 'video' => isset($vid['youtubeid_video'])
? $vid['youtubeid_video']
: data_get($vid, 'vimeoid_video', ''),
]; ];
@endphp @endphp
<x-front.sections.video :video='$video' class="video__wrap" /> <x-front.sections.video :video='$video' class="video__wrap" />
<div class="video__title">{{ $vid['string_title'] }}</div> <div class="video__title">{{ data_get($vid, 'string_title', '') }}</div>
</div> </div>
@endforeach @endforeach
@endif @endif

View file

@ -20,14 +20,14 @@ Téléphone : {{ $data->phone }}
@endif @endif
@if (\App\Enums\Contact\ContactFormType::breeder->equals($data->enumType)) @if (\App\Enums\Contact\ContactFormType::breeder->equals($data->enumType))
@if (is_array($data->typeelevage)) @if (is_iterable($data->typeelevage))
Type d'élevage : Type d'élevage :
@foreach($data->typeelevage as $breeding) @foreach($data->typeelevage as $breeding)
{{ $breeding->label() }} {{ $breeding->label() }}
@endforeach @endforeach
@endif @endif
@if (is_array($data->zonegeo)) @if (is_iterable($data->zonegeo))
Zone géographique : Zone géographique :
@foreach($data->zonegeo as $zone) @foreach($data->zonegeo as $zone)
{{ $zone->label() }} {{ $zone->label() }}
@ -39,14 +39,20 @@ Zone géographique :
Société : {{ $data->company }} Société : {{ $data->company }}
@endif @endif
@if (is_array($data->type) && \App\Enums\Contact\ContactFormType::restauration->equals($data->enumType) || @if (is_iterable($data->type) && \App\Enums\Contact\ContactFormType::restauration->equals($data->enumType))
\App\Enums\Contact\ContactFormType::export->equals($data->enumType))
Type de demande : Type de demande :
@foreach($data->type as $t) @foreach($data->type as $t)
{{ $t->label() }} {{ $t->label() }}
@endforeach @endforeach
@endif @endif
@if (is_iterable($data->typeExport) && \App\Enums\Contact\ContactFormType::export->equals($data->enumType))
Type de demande :
@foreach($data->typeExport as $t)
{{ $t->label() }}
@endforeach
@endif
@if (\App\Enums\Contact\ContactFormType::press->equals($data->enumType)) @if (\App\Enums\Contact\ContactFormType::press->equals($data->enumType))
Sujet : {{ $data->subject->label() }} Sujet : {{ $data->subject->label() }}
@endif @endif

View file

@ -30,7 +30,7 @@
{{-- BREEDER --}} {{-- BREEDER --}}
@if (\App\Enums\Contact\ContactFormType::breeder->equals($data->enumType)) @if (\App\Enums\Contact\ContactFormType::breeder->equals($data->enumType))
@if (is_array($data->typeelevage)) @if (is_iterable($data->typeelevage))
<p>Type d'élevage : </p> <p>Type d'élevage : </p>
<ul> <ul>
@foreach ($data->typeelevage as $breeding) @foreach ($data->typeelevage as $breeding)
@ -39,7 +39,7 @@
</ul> </ul>
@endif @endif
@if (is_array($data->zonegeo)) @if (is_iterable($data->zonegeo))
<p>Zone géographique : </p> <p>Zone géographique : </p>
<ul> <ul>
@foreach ($data->zonegeo as $zone) @foreach ($data->zonegeo as $zone)
@ -54,7 +54,7 @@
<p>Société : {{ $data->company }}</p> <p>Société : {{ $data->company }}</p>
@endif @endif
@if (is_array($data->type) && \App\Enums\Contact\ContactFormType::restauration->equals($data->enumType)) @if (is_iterable($data->type) && \App\Enums\Contact\ContactFormType::restauration->equals($data->enumType))
<p>Type de demande : </p> <p>Type de demande : </p>
<ul> <ul>
@foreach ($data->type as $t) @foreach ($data->type as $t)
@ -64,10 +64,10 @@
@endif @endif
{{-- Export --}} {{-- Export --}}
@if (is_array($data->type) && \App\Enums\Contact\ContactFormType::export->equals($data->enumType) && $data->type) @if (is_iterable($data->typeExport) && \App\Enums\Contact\ContactFormType::export->equals($data->enumType) && $data->typeExport)
<p>Type de demande : </p> <p>Type de demande : </p>
<ul> <ul>
@foreach ($data->type as $t) @foreach ($data->typeExport as $t)
<li>{{ $t->label() }}</li> <li>{{ $t->label() }}</li>
@endforeach @endforeach
</ul> </ul>

View file

@ -19,8 +19,8 @@
@endif @endif
@if (\App\Enums\Contact\ContactFormType::export->equals($contactFormType)) @if (\App\Enums\Contact\ContactFormType::export->equals($contactFormType))
<x-front.inputs.multi-select placeholder="{{ ucfirst(__('front.contact.inputs.customerAskingType.placeholder')) }}" <x-front.inputs.multi-select placeholder="{{ ucfirst(__('front.contact.inputs.exportAskingType.placeholder')) }}"
label="{{ ucfirst(__('front.contact.inputs.customerAskingType.label')) }}" required="true" name="type" label="{{ ucfirst(__('front.contact.inputs.exportAskingType.label')) }}" required="true" name="typeExport"
:options="collect(\App\Enums\Contact\ExportAskingType::toArray())->map(function ($type) { :options="collect(\App\Enums\Contact\ExportAskingType::toArray())->map(function ($type) {
return [ return [
'value' => $type->value, 'value' => $type->value,

View file

@ -94,13 +94,11 @@
@endphp @endphp
@endforeach @endforeach
@foreach ($sections as $section) @foreach ($sections as $section)
@if($section['title'] === 'bea_content')
@if ($section['title'] === 'banner') @include('front.pages.partials.bea_content')
@include('front.pages.partial.bea-banner') @continue
@break
@else
<x-front.text-block :textBlock="$section" />
@endif @endif
<x-front.text-block :textBlock="$section" />
@endforeach @endforeach
@endif @endif
{{-- Sections numbers --}} {{-- Sections numbers --}}

View file

@ -1,27 +0,0 @@
<div id="bea-banner" class="flex f-poppins">
<div class="w-14 flex-none">
<img src="{{ Vite::asset('resources/assets/images/front/logo_bea.svg') }}" alt="{{ __('Logo BEA') }}" title="{{ __('Logo BEA') }}"/>
<p>{!! clean(__('Retrouvez nos engagements sur :linkUrl', [
'linkUrl' => '<a href="https://www.bienetreanimal.fr" title="Site Bien Etre Animal" target="_blank" rel="noopener nofollow">www.bienetreanimal.fr</a> '
])) !!}</p>
</div>
<div class="w-64 flex-initial">
<h3>
<span>{{ __('LDC') }}</span><br>
<span class="uppercase">{{ __('Entreprise adhérente au collectif') }}</span>
<img src="{{ Vite::asset('resources/assets/images/front/coeur.svg') }}" alt="{{ __('coeur') }}" title="{{ __('coeur') }}"/><br>
<span class="uppercase">{{ __('Fillière Agricole Engagée pour élever le Bien-être Animal') }}</span><br>
</h3>
<p>
<span>{{ __('Du poulet 100% origine France') }}</span><br>
<span>{{ __('élevé dans le') }}</span>
<span class="uppercase">{{ __('respect du bien-être animal') }}</span><br>
<span>{{ __('par une') }}</span>
<span class="uppercase">{{ __('filière agricole engagée') }}</span><br>
</p>
</div>
</div>

View file

@ -0,0 +1,72 @@
<div class="tailwind-scope">
<section class="f-poppins my-6" id="bea-encart" aria-label="{{ __('front.bea_banner.region_label') }}">
<div class="relative overflow-hidden bg-[#2e267b] px-8 pb-14 pt-7 text-white shadow-xl sm:px-12 sm:py-9 lg:px-16 lg:py-10">
<div class="relative flex flex-col items-center justify-between gap-8 md:flex-row md:items-start lg:gap-12">
{{-- Colonne gauche --}}
<div class="flex w-full shrink-0 flex-col items-center text-center md:w-auto">
<img class="w-36 object-contain drop-shadow-md sm:w-44 lg:w-48"
src="{{ Vite::asset('resources/assets/images/front/logo_bea.svg') }}" title="{{ __('front.bea_banner.logo_alt') }}"
alt="{{ __('front.bea_banner.logo_alt') }}" />
<p class="mt-3 text-xs font-[600] leading-snug tracking-wide sm:text-sm">
{!! __('front.bea_banner.commitments_intro', ['br' => '<br />']) !!}
<a class="rounded-sm underline hover:opacity-80 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-white"
href="https://www.bienetreanimal.fr" title="{{ __('front.bea_banner.site_link_title') }}"
aria-label="{{ __('front.bea_banner.site_link_aria') }}" target="_blank"
rel="noopener noreferrer">{{ __('front.bea_banner.site_url_text') }}<span class="sr-only">
({{ __('front.bea_banner.new_window') }})</span></a>
</p>
</div>
{{-- Colonne centrale --}}
<div class="flex-1 text-center md:text-left">
<h2 class="text-xl font-[600] leading-snug tracking-normal sm:text-2xl lg:text-3xl">
<span class="relative inline-flex items-center gap-1.5 uppercase">
<span>{{ __('front.bea_banner.title') }}</span>
<img class="hidden h-8 w-8 rotate-[15deg] object-contain sm:absolute sm:-right-14 sm:-top-8 sm:h-12 sm:w-12 md:inline-block"
src="{{ Vite::asset('resources/assets/images/front/coeur.svg') }}" alt="" role="presentation" aria-hidden="true" />
</span><br />
{{ __('front.bea_banner.subtitle') }}
</h2>
<div class="mb-14 mt-4 flex flex-col items-end md:hidden">
<img class="inline-block h-10 w-10 rotate-[15deg] object-contain pe-4"
src="{{ Vite::asset('resources/assets/images/front/coeur.svg') }}" alt="" role="presentation" aria-hidden="true" />
<img class="w-24 object-contain" src="{{ Vite::asset('resources/assets/images/front/ldc-sign.png') }}"
title="{{ __('front.bea_banner.ldc_alt') }}" alt="{{ __('front.bea_banner.ldc_alt') }}" />
</div>
<p class="mt-4 max-w-xl text-sm font-medium leading-snug text-white sm:text-base lg:text-lg">
{!! __('front.bea_banner.description', ['br' => '<br />']) !!}
</p>
<div class="mt-6 flex justify-center sm:mt-7 md:justify-start">
<a class="bea-cta inline-flex items-center justify-center gap-3 rounded-full bg-[#e60f1d] px-8 py-3.5 text-sm font-bold text-white shadow-md transition-all hover:bg-[#c80510] focus:outline-none focus:ring-2 focus:ring-white focus:ring-offset-2 focus:ring-offset-[#2e267b] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-white focus-visible:ring-offset-2 focus-visible:ring-offset-[#2e267b] active:scale-95 sm:text-base"
href="https://www.bienetreanimal.fr" title="{{ __('front.bea_banner.cta_title') }}"
aria-label="{{ __('front.bea_banner.cta_aria') }}" target="_blank" rel="noopener noreferrer">
<span>{{ __('front.bea_banner.cta_text') }}</span>
<svg class="h-4 w-4 shrink-0 stroke-[3] sm:h-6 sm:w-6" aria-hidden="true" focusable="false" fill="none"
stroke="currentColor" viewBox="0 0 24 24">
<path stroke-linecap="round" stroke-linejoin="round" d="M9 5l7 7-7 7" />
</svg>
<span class="sr-only"> ({{ __('front.bea_banner.new_window') }})</span>
</a>
</div>
</div>
{{-- Signature LDC --}}
<div class="hidden shrink-0 items-start justify-start self-start md:mr-6 md:flex md:self-auto md:pt-12 lg:mr-10 lg:pt-14">
<img class="w-24 object-contain sm:w-32 xl:relative xl:-left-36 xl:top-16 xl:w-36"
src="{{ Vite::asset('resources/assets/images/front/ldc-sign.png') }}" title="{{ __('front.bea_banner.ldc_alt') }}"
alt="{{ __('front.bea_banner.ldc_alt') }}" />
</div>
</div>
{{-- Décoration : Soleil en bas à droite (partiellement tronqué par le conteneur) --}}
<img
class="sm:w-30 pointer-events-none absolute -bottom-10 right-4 w-20 rotate-[26deg] select-none object-contain sm:-bottom-8 sm:right-6 lg:-bottom-28 lg:right-8 lg:w-56"
src="{{ Vite::asset('resources/assets/images/front/soleil.svg') }}" alt="" role="presentation" aria-hidden="true" />
</div>
</section>
</div>

View file

@ -6,9 +6,14 @@ use App\Models\DynamicPage;
use App\Models\News; use App\Models\News;
use Diglactic\Breadcrumbs\Breadcrumbs; use Diglactic\Breadcrumbs\Breadcrumbs;
use Diglactic\Breadcrumbs\Generator; use Diglactic\Breadcrumbs\Generator;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Str; use Illuminate\Support\Str;
use Mcamara\LaravelLocalization\Facades\LaravelLocalization; use Mcamara\LaravelLocalization\Facades\LaravelLocalization;
if (!Schema::hasTable('dynamic_pages')) {
return;
}
$currentLocale = app()->getLocale(); $currentLocale = app()->getLocale();
$supportedLocales = LaravelLocalization::getSupportedLanguagesKeys(); $supportedLocales = LaravelLocalization::getSupportedLanguagesKeys();
$pageHome = DynamicPage::getModelsCached() $pageHome = DynamicPage::getModelsCached()

View file

@ -25,6 +25,10 @@ export default {
sans: [ sans: [
'Figtree', 'Figtree',
...defaultTheme.fontFamily.sans ...defaultTheme.fontFamily.sans
],
poppins: [
'Poppins',
...defaultTheme.fontFamily.sans
] ]
}, },
borderRadius: { borderRadius: {

View file

@ -5,7 +5,6 @@ import path from "path";
import react from '@vitejs/plugin-react'; import react from '@vitejs/plugin-react';
import eslint from 'vite-plugin-eslint'; import eslint from 'vite-plugin-eslint';
import stylelint from "vite-plugin-stylelint"; import stylelint from "vite-plugin-stylelint";
import glob from "glob";
const env = loadEnv("r", process.cwd(), ""); const env = loadEnv("r", process.cwd(), "");
const debugMode = env["APP_DEBUG"] === "true"; const debugMode = env["APP_DEBUG"] === "true";
@ -19,7 +18,6 @@ export default defineConfig({
'resources/sass/back/app.scss', 'resources/sass/back/app.scss',
// FRONT // FRONT
'resources/ts/front/app.ts', 'resources/ts/front/app.ts',
...glob.sync('resources/assets/images/front/**/*.{jpg,png,jpeg}'),
], ],
refresh: true, refresh: true,
}), }),