Fonctionnalite.vue 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198
  1. <template>
  2. <LayoutContainer>
  3. <v-row class="center-90">
  4. <v-col cols="6">
  5. <LayoutUISubTitle>
  6. Découvrez toutes les fonctionnalités de notre solution
  7. </LayoutUISubTitle>
  8. <LayoutUITitle>
  9. Des fonctionnalités adaptées à vos besoins
  10. </LayoutUITitle>
  11. </v-col>
  12. <v-col cols="12" md="6" class="d-flex align-center justify-start">
  13. <v-btn icon="fas fa-chevron-left" @click="previousAction" />
  14. <v-btn icon="fas fa-chevron-right" @click="nextAction" />
  15. </v-col>
  16. </v-row>
  17. <v-row>
  18. <v-col cols="12" md="12">
  19. <Carousel
  20. ref="carousel"
  21. :items-to-show="itemsToShow"
  22. :items-to-scroll="1"
  23. :wrap-around="true"
  24. >
  25. <Slide v-for="(card, index) in cards" :key="index">
  26. <div class="card-container">
  27. <v-card class="inv-theme">
  28. <v-img :src="card.logo" :alt="card.title" class="mx-auto" />
  29. <v-card-title>
  30. <h5>
  31. {{ card.title }}
  32. </h5>
  33. </v-card-title>
  34. <v-card-item>
  35. <v-card-text>
  36. <ul>
  37. <li v-for="item in card.list" :key="item">
  38. <p>{{ item }}</p>
  39. </li>
  40. </ul>
  41. </v-card-text>
  42. </v-card-item>
  43. <div class="footer">
  44. <p v-for="option in card.options" :key="option">
  45. {{ option }}
  46. </p>
  47. </div>
  48. </v-card>
  49. </div>
  50. </Slide>
  51. </Carousel>
  52. </v-col>
  53. </v-row>
  54. </LayoutContainer>
  55. </template>
  56. <script setup lang="ts">
  57. import { useDisplay } from "vuetify";
  58. import { Carousel, Slide } from "vue3-carousel";
  59. import "vue3-carousel/dist/carousel.css";
  60. import type { PropType, Ref } from "vue";
  61. import type { Functionality } from "~/types/interface";
  62. const { lgAndUp, mdAndUp, smAndUp } = useDisplay();
  63. defineProps({
  64. cards: {
  65. type: Array as PropType<Array<Functionality>>,
  66. required: true,
  67. },
  68. });
  69. const carousel: Ref<typeof Carousel | null> = ref(null);
  70. const itemsToShow = computed(() =>
  71. lgAndUp.value ? 5 : mdAndUp.value ? 3 : smAndUp.value ? 2 : 1,
  72. );
  73. const nextAction = () => {
  74. carousel.value!.next();
  75. };
  76. const previousAction = () => {
  77. carousel.value!.prev();
  78. };
  79. </script>
  80. <style scoped lang="scss">
  81. .v-row {
  82. width: 95%;
  83. margin-left: auto;
  84. margin-right: auto;
  85. }
  86. .v-btn {
  87. width: 60px;
  88. height: 60px;
  89. background-color: transparent;
  90. color: var(--on-primary-color);
  91. border: 2px solid;
  92. border-color: var(--on-primary-color);
  93. cursor: pointer;
  94. border-radius: 0;
  95. margin: 6px;
  96. }
  97. .carousel {
  98. margin-left: 2rem;
  99. margin-right: 2rem;
  100. margin-bottom: 2rem;
  101. }
  102. .card-container {
  103. display: flex;
  104. justify-content: center;
  105. align-items: center;
  106. margin-right: 2rem;
  107. width: 100%;
  108. height: 100%;
  109. }
  110. .v-card {
  111. border-radius: 1rem;
  112. transition: transform 0.3s;
  113. font-weight: 300;
  114. width: 100%;
  115. height: 100%;
  116. padding: 0 10% 14px 10%;
  117. .v-img {
  118. width: 5rem;
  119. height: 3rem;
  120. margin-top: 1rem;
  121. margin-bottom: 12px;
  122. fill: #fac20a !important;
  123. }
  124. .v-card-title {
  125. white-space: pre-wrap;
  126. }
  127. .v-card-item {
  128. text-align: left;
  129. }
  130. li {
  131. font-weight: 300;
  132. font-size: 0.9rem;
  133. line-height: 1.2rem;
  134. margin-bottom: 1rem;
  135. color: var(--on-neutral-color);
  136. }
  137. .footer {
  138. position: absolute;
  139. left: 0;
  140. margin-left: 1.3rem;
  141. font-size: 0.9rem;
  142. p {
  143. text-align: left;
  144. }
  145. }
  146. }
  147. //@media (min-width: 1300px) and (max-width: 1800px){
  148. // .v-card{
  149. // min-height: 480px !important;
  150. // max-height: 480px !important;
  151. // min-width: 230px !important;
  152. // max-width: 230px !important;
  153. // }
  154. //}
  155. //
  156. //@media (min-width: 1500px) and (max-width: 1800px){
  157. // .v-card{
  158. // min-height: 420px !important;
  159. // max-height: 420px !important;
  160. // min-width: 260px !important;
  161. // max-width: 260px !important;
  162. // }
  163. //}
  164. //
  165. //@media (min-width: 1800px){
  166. // .v-card{
  167. // min-height: 400px !important;
  168. // max-height: 400px !important;
  169. // min-width: 300px !important;
  170. // max-width: 300px !important;
  171. // }
  172. //}
  173. </style>