]> _ Git - sycomore-fondation.git/commitdiff
wip #5812 @2:00
authorsoufiane <soufiane@cubedesigners.com>
Tue, 23 May 2023 11:27:35 +0000 (13:27 +0200)
committersoufiane <soufiane@cubedesigners.com>
Tue, 23 May 2023 11:27:35 +0000 (13:27 +0200)
wp-content/themes/sycomore-fondation/resources/styles/partials/home-carousel.sass
wp-content/themes/sycomore-fondation/resources/styles/widgets/blockText.sass
wp-content/themes/sycomore-fondation/resources/views/widgets/carousel-home.blade.php
wp-content/themes/sycomore-fondation/resources/views/widgets/text-image.blade.php

index e6a62953f1c1b84b4ed13a4ad6f0b83c306f3085..d1651625e505a1dc7fc00f1a8892dac367a1e6c2 100644 (file)
             position: absolute
             width: max-content
             height: max-content
-            bottom: var(--bottom)
             left: var(--left)
-            transition: all 1s
-
-        .rightside.active
-          .thumbnail
-            position: relative
-
-          .text
-            opacity: 1
-            top: 0
 
         &.active
           .thumbnail
             img
-              transition: all 1s
-              bottom: calc(var(--bottom) - 39px)
+              animation-name: img-in
+              animation-duration: 1s
+              animation-fill-mode: forwards
+        &:not(.active)
+          .thumbnail
+            img
+              animation-name: img-out
+              animation-duration: 1.9s
 
       .rightside
         display: flex
           .overlay
             bottom: 0
 
-
+  .counter
+    position: absolute
+    width: 86px
+    height: 86px
+    z-index: 5
+    bottom: 88px
+    left: 21px
+    font-size: 25px
+    +screen-size(desktop)
+      left: calc((100vw - 1344px) / 2)
+    lottie-player:not(.active)
+      display: none
+    .text
+      position: absolute
+      top: 50%
+      left: 50%
+      transform: translate(-50%,-50%)
+      color: #FFFFFF
+    .circle
+      position: absolute
+      width: 73px
+      height: 73px
+      border: 2px solid #FFFFFF
+      top: 6px
+      border-radius: 50px
+      left: 6px
+      z-index: -1
 
 @keyframes fade-out
   0%
   100%
     transform: translateY(0)
 
-@keyframes anime-thumb
+@keyframes img-in
+  0%
+    bottom: var(--bottom)
+  100%
+    bottom: calc(var(--bottom) - 39px)
+
+@keyframes img-out
   0%
-    bottom: calc(var(--bottom) + 39px)
+    bottom: calc(var(--bottom) - 39px)
+  50%
+    bottom: calc(var(--bottom) - 78px)
   100%
     bottom: var(--bottom)
 
+
 .home-carousel-mobile
   overflow: hidden
   .thumbnail,
index e4d057fe70ca943d3304bf1ed61d2227996c3073..9175334c96ede4bb07255e0a802d856fa9369fe4 100644 (file)
       margin-bottom: 38px
       +screen-size(small-desktop)
         margin-bottom: 43px
+    .text-block-image img
+      +screen-size(small-desktop)
+        transform: translateX(-100px)
+        position: relative
+        opacity: 0
+        &.active
+          opacity: 1
+          transition: all .5s ease-out
+          transform: translateX(0)
 
   &.gallery-right
     +screen-size(small-desktop)
           grid-area: 2 / 2 / 4 / 6
         &-body
           grid-area: 4 / 2 / 5 / 6
+    .text-block-image img
+      +screen-size(small-desktop)
+        transform: translateX(100px)
+        position: relative
+        opacity: 0
+        &.active
+          opacity: 1
+          transition: all .5s ease-out
+          transform: translateX(0)
+
 
   &.has-title
     &.gallery-left
     font-size: 20px
 
   &-body
+    top: 50px
+    transition: top .5s
+    position: relative
+    &.active
+      top: 0
     h2
       width: max-content
       margin-top: var(--space-36-86)
index 1c7946f4c12508431800694ed841684e9e258278..549c7de5c995bfb27a57bcc217af722d8508fbe8 100644 (file)
@@ -3,7 +3,7 @@
     @php
       $key += 1;
     @endphp
-    <div class="elementor-repeater-item-{{$slide['_id']}} carousel-slide container {{ $key === 2 ? 'next' : '' }} {{ $key === 1 ? 'active' : '' }}">
+    <div class="elementor-repeater-item-{{$slide['_id']}} carousel-slide container {{ $key === 2 ? 'next' : '' }} {{ $key === 1 ? 'active' : '' }}" data-index="{{ $key }}">
       <div class="leftside {{ $key === 1 ? 'active' : '' }}">
         <div class="overlay overlayside" style="background-image: url({{$slide['background_image']['url']}})"></div>
         @if(array_key_exists('image',$slide))
     </div>
   @endforeach
   <div class="counter">
-
+    <lottie-player class="active" data-slide="1" src="bleu.json" speed="2" style="width: 86px; height: 86px;" loop autoplay></lottie-player>
+    <lottie-player data-slide="2" data-slide="2" src="vert.json" speed="2" style="width: 86px; height: 86px;" loop autoplay></lottie-player>
+    <lottie-player data-slide="3" data-slide="3" src="rose.json" speed="2" style="width: 86px; height: 86px;" loop autoplay></lottie-player>
+    <div class="text">
+      <span class="var">1</span>/<span class="length">{{ sizeof($slides) }}</span>
+    </div>
+    <div class="circle">
+    </div>
   </div>
 </div>
 
index ec9530136f4845a68f77531382f978f38b6f86a0..16d611946831603e41b8fe61eecbc184148b879d 100644 (file)
     </{{$settings['title_tag']}}>
   @endif
 
-  @if($settings['subtitle'])
-    <{{$settings['subtitle_tag']}} class={{implode(' ',$attributes['subtitle']['class'])}}>
+  <div class="{{implode(' ',$attributes['body']['class'])}}">
+    @if($settings['subtitle'])
+      <{{$settings['subtitle_tag']}} class={{implode(' ',$attributes['subtitle']['class'])}}>
       {!! $settings['subtitle'] !!}
-    </{{$settings['subtitle_tag']}}>
-  @endif
-
-  <div class="{{implode(' ',$attributes['body']['class'])}}">{!! $settings['body'] !!}</div>
+      </{{$settings['subtitle_tag']}}>
+    @endif
+    {!! $settings['body'] !!}
+  </div>
 
 </div>