From bc5bea467aff3aad255a148042fa2435404a4c6d Mon Sep 17 00:00:00 2001 From: Olivier Legat Date: Thu, 1 Apr 2021 13:11:11 +0200 Subject: [PATCH] pages gammes --- public/canard/css/app.css | 144 ++++++++++++++++ resources/views/front/canard/ranges.blade.php | 61 ++++++- resources/views/front/canard/sass/app.scss | 1 + resources/views/front/canard/sass/ranges.scss | 157 ++++++++++++++++++ 4 files changed, 356 insertions(+), 7 deletions(-) create mode 100644 resources/views/front/canard/sass/ranges.scss diff --git a/public/canard/css/app.css b/public/canard/css/app.css index d41d67f5..cec8e1e1 100644 --- a/public/canard/css/app.css +++ b/public/canard/css/app.css @@ -3937,6 +3937,150 @@ blockquote :last-child, li :last-child, p :last-child { font-weight: 500; } +/* main products START */ +.ranges__row { + display: flex; + flex-flow: row wrap; + margin: 0 -12px -15px; +} + +.ranges__row-block { + box-sizing: border-box; + flex: 25%; + padding: 0 12px; + margin-bottom: 25px; +} + +.ranges__row-block_wide { + flex: 35%; +} + +.ranges__item { + box-sizing: border-box; + width: 216px; + width: 100%; + height: 346px; + padding: 20px; + background: #fff; +} + +.range__title { + display: block; + text-align: center; + height: 50px; + overflow: hidden; + margin-bottom: 15px; +} + +.range__title:hover { + text-decoration: underline; +} + +.range__image { + display: flex; + align-items: center; + justify-content: center; + height: 180px; + margin-bottom: 20px; +} + +.range__image img { + max-height: 100%; +} + +.range__bottom { + display: flex; + align-items: center; + justify-content: space-between; +} + +.range__price { + font-size: 18px; + font-weight: 500; + padding-right: 10px; +} + +.range .range__btn { + margin: auto; +} + +.ranges__image { + /*width: 417px;*/ + /*min-height: 346px;*/ + padding: 0; +} + +.ranges__image img { + width: 100%; + height: 100%; + -o-object-fit: cover; + object-fit: cover; + -o-object-position: center center; + object-position: center center; +} + +.ranges-mobile__slider { + position: relative; + margin-bottom: 40px; +} + +.ranges-mobile__slider::before { + content: ""; + display: block; + width: 15%; + height: 100%; + position: absolute; + top: 0; + right: 0; + z-index: 2; + background: linear-gradient(to right, rgba(244, 240, 233, 0) 0%, #f4f0e9 100%); + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr="#00f4f0e9", endColorstr="#f4f0e9",GradientType=1 ); +} + +.ranges-mobile__btn { + margin: 0 auto; +} + +.ranges-mobile__nav .swiper-nav__arrow { + position: absolute; + bottom: 160px; + z-index: 3; +} + +.ranges-mobile__nav .swiper-nav__arrow.disabled { + visibility: hidden; +} + +.ranges-mobile__nav .swiper-nav__arrow_prev { + left: -35px; +} + +.ranges-mobile__nav .swiper-nav__arrow_next { + right: -35px; +} + +.ranges-mobile__slider .swiper-slide { + width: auto; +} + +/* main products END */ +@media screen and (max-width: 1240px) { + .wrapper { + width: 1024px; + } + + .ranges__row-block { + flex: 25%; + } + + .ranges__row-block_wide { + flex: 50%; + } + + .product__ranges .ranges__row-block_wide { + order: 99; + } +} @media screen and (max-width: 1365px) { .wrapper { width: 1240px; diff --git a/resources/views/front/canard/ranges.blade.php b/resources/views/front/canard/ranges.blade.php index 500a9048..b6d3de2a 100644 --- a/resources/views/front/canard/ranges.blade.php +++ b/resources/views/front/canard/ranges.blade.php @@ -4,12 +4,59 @@ @section('content') +
+
+
+
+

{{ __('Des saveurs pour toutes vos envies...') }}

+ @if (Route::current()->getName() != 'ranges') + {{ __('Voir toutes les gammes') }} + @endif +
+ +
+
+
+
+
+ @foreach ($ranges as $range) +
+
+
{{$range->name}}
+
+ @if(isset($range->picture)) + + @else + + @endif +
+ {{ __('Voir la gamme') }} +
+
+ @endforeach + {{-- complément au multiple de 4 car on flex à 25% --}} + @for ($i=0; $i < (4-(count($ranges) % 4));$i++) +
+ @endfor +
+
+
+
+{{-- +
+
+
+
+--}} +
+ +
+ @if (Route::current()->getName() != 'ranges') + {{ __('Voir toutes les gammes') }} + @endif +
+
+
+
- @include('partials.ranges-slider') - {{--

Gammes de produits

- --}} @endsection diff --git a/resources/views/front/canard/sass/app.scss b/resources/views/front/canard/sass/app.scss index 9af9d10e..543df9f6 100644 --- a/resources/views/front/canard/sass/app.scss +++ b/resources/views/front/canard/sass/app.scss @@ -7,6 +7,7 @@ @import 'main'; @import 'cart'; @import 'tunnel'; +@import 'ranges'; @import 'media'; diff --git a/resources/views/front/canard/sass/ranges.scss b/resources/views/front/canard/sass/ranges.scss new file mode 100644 index 00000000..dc74ea21 --- /dev/null +++ b/resources/views/front/canard/sass/ranges.scss @@ -0,0 +1,157 @@ +/* main products START */ + +.ranges__row { + display: flex; + flex-flow: row wrap; + margin: 0 -12px -15px; +} + +.ranges__row-block { + box-sizing: border-box; + flex: 25%; + padding: 0 12px; + margin-bottom: 25px; +} + +.ranges__row-block_wide { + flex: 35%; +} + +.ranges__item { + box-sizing: border-box; + width: 216px; + width: 100%; + height: 346px; + padding: 20px; + background: #fff; +} + +.range__title { + display: block; + text-align: center; + height: 50px; + overflow: hidden; + margin-bottom: 15px; +} + +.range__title:hover { + text-decoration: underline; +} + +.range__image { + display: flex; + align-items: center; + justify-content: center; + height: 180px; + margin-bottom: 20px; +} + +.range__image img { + max-height: 100%; +} + +.range__bottom { + display: flex; + align-items: center; + justify-content: space-between; +} + +.range__price { + font-size: 18px; + font-weight: 500; + padding-right: 10px; +} + +.range .range__btn { + margin: auto; + // flex: 0 0 auto; + // padding: 0; + // width: 52px; + // height: 48px; + // background-image: url(../img/icon_cart-white.png); + // background-repeat: no-repeat; + // background-position: center center; +} + +.ranges__image { + /*width: 417px;*/ + /*min-height: 346px;*/ + padding: 0; +} + +.ranges__image img { + width: 100%; + height: 100%; + object-fit: cover; + object-position: center center; +} + + +.ranges-mobile__slider { + position: relative; + margin-bottom: 40px; +} + +.ranges-mobile__slider::before { + content: ''; + display: block; + width: 15%; + height: 100%; + position: absolute; + top: 0; + right: 0; + z-index: 2; + + background: -moz-linear-gradient(left, rgba(244,240,233,0) 0%, rgba(244,240,233,1) 100%); + background: -webkit-linear-gradient(left, rgba(244,240,233,0) 0%,rgba(244,240,233,1) 100%); + background: linear-gradient(to right, rgba(244,240,233,0) 0%,rgba(244,240,233,1) 100%); + filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#00f4f0e9', endColorstr='#f4f0e9',GradientType=1 ); + +} + +.ranges-mobile__btn { + margin: 0 auto; +} + +.ranges-mobile__nav .swiper-nav__arrow { + position: absolute; + bottom: 160px; + z-index: 3 +} + +.ranges-mobile__nav .swiper-nav__arrow.disabled { + visibility: hidden; +} + +.ranges-mobile__nav .swiper-nav__arrow_prev { + left: -35px; +} + +.ranges-mobile__nav .swiper-nav__arrow_next { + right: -35px; +} + +.ranges-mobile__slider .swiper-slide { + width: auto; +} + +/* main products END */ + + +@media screen and (max-width: 1240px) { + .wrapper { + width: 1024px; + } + + .ranges__row-block { + flex: 25%; + } + + .ranges__row-block_wide { + flex: 50%; + } + + .product__ranges .ranges__row-block_wide { + order: 99; + } +}