|
|
@@ -141,38 +141,34 @@
|
|
|
</v-row>
|
|
|
|
|
|
<!-- Partie 1 : Carrousel logos clients -->
|
|
|
- <div class="content-review">
|
|
|
- <CommonCarouselClients
|
|
|
- :items="items"
|
|
|
- color="#fff"
|
|
|
- />
|
|
|
+ <div class="carousel-clients-container">
|
|
|
+ <CommonCarouselClients :items="items" />
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
<!-- Petits écrans -->
|
|
|
- <div v-else>
|
|
|
+ <div v-else class="container-sm">
|
|
|
<v-row>
|
|
|
<v-col cols="12">
|
|
|
- <Carousel :itemsToShow="1" :wrapAround="true" ref="reviewCaroussel">
|
|
|
+ <Carousel :itemsToShow="1" :wrapAround="true" ref="reviewCarousel">
|
|
|
<Slide v-for="(card, index) in cards" :key="index">
|
|
|
- <div class="card-sm">
|
|
|
- <v-card>
|
|
|
- <v-card-title>
|
|
|
- <span class="review-name">{{ card.name }}</span>
|
|
|
- </v-card-title>
|
|
|
-
|
|
|
- <v-card-text>
|
|
|
- <p class="description-review">
|
|
|
- {{ card.review }}
|
|
|
- </p>
|
|
|
- </v-card-text>
|
|
|
- <div class="card-footer">
|
|
|
- <small>{{ card.status }}</small>
|
|
|
-
|
|
|
- <small>{{ card.structure }}</small>
|
|
|
- </div>
|
|
|
- </v-card>
|
|
|
- </div>
|
|
|
+ <v-card>
|
|
|
+ <v-card-title>
|
|
|
+ <span class="review-name">{{ card.name }}</span>
|
|
|
+ </v-card-title>
|
|
|
+
|
|
|
+ <v-card-text>
|
|
|
+ <p class="description-review">
|
|
|
+ {{ card.review }}
|
|
|
+ </p>
|
|
|
+ </v-card-text>
|
|
|
+
|
|
|
+ <div class="card-footer">
|
|
|
+ <small>{{ card.status }}</small>
|
|
|
+
|
|
|
+ <small>{{ card.structure }}</small>
|
|
|
+ </div>
|
|
|
+ </v-card>
|
|
|
</Slide>
|
|
|
</Carousel>
|
|
|
</v-col>
|
|
|
@@ -180,12 +176,12 @@
|
|
|
|
|
|
<v-row class="justify-center align-center">
|
|
|
<v-col class="d-flex justify-space-around align-center">
|
|
|
- <i
|
|
|
- style="cursor: pointer"
|
|
|
- class="fa-solid fa-arrow-left-long"
|
|
|
- @click="goPrevious"
|
|
|
+ <v-btn
|
|
|
+ icon="fas fa-arrow-left-long"
|
|
|
+ @click="goToPrevious"
|
|
|
/>
|
|
|
- <div class="custom-controls">
|
|
|
+
|
|
|
+ <div class="carousel-controls">
|
|
|
<div
|
|
|
v-for="(item, index) in cards"
|
|
|
:key="index"
|
|
|
@@ -193,10 +189,10 @@
|
|
|
class="ml-6"
|
|
|
/>
|
|
|
</div>
|
|
|
- <i
|
|
|
- style="cursor: pointer"
|
|
|
- class="fa-solid fa-arrow-right-long"
|
|
|
- @click="goNext"
|
|
|
+
|
|
|
+ <v-btn
|
|
|
+ icon="fas fa-arrow-right-long"
|
|
|
+ @click="goToNext"
|
|
|
/>
|
|
|
</v-col>
|
|
|
</v-row>
|
|
|
@@ -205,37 +201,33 @@
|
|
|
</template>
|
|
|
|
|
|
<script setup lang="ts">
|
|
|
-import { ref } from "vue";
|
|
|
import { Carousel, Slide } from "vue3-carousel";
|
|
|
import "vue3-carousel/dist/carousel.css";
|
|
|
import { useDisplay } from "vuetify";
|
|
|
+import { Review } from "~/types/interface";
|
|
|
|
|
|
-const { smAndDown, mdAndUp } = useDisplay();
|
|
|
+const { mdAndUp } = useDisplay();
|
|
|
|
|
|
-const reviewCaroussel = ref(null);
|
|
|
+const reviewCarousel: Ref<typeof Carousel | null> = ref(null);
|
|
|
|
|
|
const state = ref({
|
|
|
activeIndex: 0,
|
|
|
});
|
|
|
|
|
|
-const goNext = () => {
|
|
|
- if (reviewCaroussel.value) {
|
|
|
- reviewCaroussel.value.next();
|
|
|
- state.value.activeIndex = (state.value.activeIndex + 1) % cards.length;
|
|
|
- }
|
|
|
-};
|
|
|
-
|
|
|
-const goPrevious = () => {
|
|
|
- if (reviewCaroussel.value) {
|
|
|
- reviewCaroussel.value.prev();
|
|
|
- state.value.activeIndex =
|
|
|
- state.value.activeIndex - 1 < 0
|
|
|
- ? cards.length - 1
|
|
|
- : state.value.activeIndex - 1;
|
|
|
- }
|
|
|
-};
|
|
|
+const goToNext = () => {
|
|
|
+ reviewCarousel.value!.next();
|
|
|
+ state.value.activeIndex = (state.value.activeIndex + 1) % cards.length;
|
|
|
+}
|
|
|
|
|
|
-const cards = [
|
|
|
+const goToPrevious = () => {
|
|
|
+ reviewCarousel.value!.prev();
|
|
|
+ state.value.activeIndex =
|
|
|
+ state.value.activeIndex - 1 < 0
|
|
|
+ ? cards.length - 1
|
|
|
+ : state.value.activeIndex - 1;
|
|
|
+}
|
|
|
+
|
|
|
+const cards: Array<Review> = [
|
|
|
{
|
|
|
name: "Patrice CATHELIN",
|
|
|
review:
|
|
|
@@ -266,7 +258,7 @@ const cards = [
|
|
|
},
|
|
|
];
|
|
|
|
|
|
-const items = ref([
|
|
|
+const items: Ref<Array<{ src: string }>> = ref([
|
|
|
{ src: "/images/reviews/school/review1.svg" },
|
|
|
{ src: "/images/reviews/school/review2.png" },
|
|
|
{ src: "/images/reviews/school/review3.png" },
|
|
|
@@ -307,6 +299,7 @@ const items = ref([
|
|
|
@media (max-width: 600px) {
|
|
|
margin-bottom: 24px;
|
|
|
}
|
|
|
+
|
|
|
}
|
|
|
|
|
|
.container-2 {
|
|
|
@@ -374,61 +367,53 @@ const items = ref([
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
|
|
|
+ .left {
|
|
|
+ bottom: 12rem;
|
|
|
+ position: relative;
|
|
|
+ }
|
|
|
|
|
|
-.custom-controls div {
|
|
|
- width: 0.6rem;
|
|
|
- height: 0.6rem;
|
|
|
- border-radius: 50%;
|
|
|
- background-color: grey;
|
|
|
- cursor: pointer;
|
|
|
- margin-bottom: 0.5rem;
|
|
|
-}
|
|
|
+ .right {
|
|
|
+ position: relative;
|
|
|
+ bottom: 7rem;
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
-.custom-controls {
|
|
|
- display: flex;
|
|
|
- flex-direction: row;
|
|
|
- justify-content: center;
|
|
|
- align-items: center;
|
|
|
+ .carousel-clients-container {
|
|
|
+ margin-top: -7rem;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
-.custom-controls .active-control {
|
|
|
- background-color: black;
|
|
|
- margin-right: 10px;
|
|
|
-}
|
|
|
+.container-sm {
|
|
|
+ .v-card {
|
|
|
+ width: 300px;
|
|
|
+ display: flex;
|
|
|
+ flex-direction: column;
|
|
|
+ justify-content: center;
|
|
|
+ align-items: center;
|
|
|
+ }
|
|
|
|
|
|
-.card-sm {
|
|
|
- width: 300px;
|
|
|
- height: 800px;
|
|
|
- display: flex;
|
|
|
- justify-content: center;
|
|
|
- align-items: center;
|
|
|
-}
|
|
|
-.v-container {
|
|
|
- padding: 0 !important;
|
|
|
-}
|
|
|
-.content-review {
|
|
|
- margin-top: -7rem;
|
|
|
-}
|
|
|
+ .carousel-controls {
|
|
|
+ display: flex;
|
|
|
+ flex-direction: row;
|
|
|
+ justify-content: center;
|
|
|
+ align-items: center;
|
|
|
|
|
|
-.left {
|
|
|
- bottom: 12rem;
|
|
|
- position: relative;
|
|
|
-}
|
|
|
+ div {
|
|
|
+ width: 0.6rem;
|
|
|
+ height: 0.6rem;
|
|
|
+ border-radius: 50%;
|
|
|
+ background-color: grey;
|
|
|
+ cursor: pointer;
|
|
|
+ margin-bottom: 0.5rem;
|
|
|
+ }
|
|
|
|
|
|
-.right {
|
|
|
- position: relative;
|
|
|
- bottom: 7rem;
|
|
|
+ .active-control {
|
|
|
+ background-color: black;
|
|
|
+ margin-right: 10px;
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
</style>
|