Agenda.vue 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261
  1. <template>
  2. <div id="L'agenda opentalent">
  3. <LayoutContainer>
  4. <v-row class="custom-row align-center">
  5. <v-col cols="4">
  6. <h2 class="title">L'agenda Opentalent</h2>
  7. </v-col>
  8. <v-col cols="4">
  9. <div class="d-flex justify-center align-center">
  10. <div class="carousel-button" @click="goPrevious">
  11. <i class="fas fa-chevron-left" />
  12. </div>
  13. <div class="carousel-button" @click="goNext">
  14. <i class="fas fa-chevron-right" />
  15. </div>
  16. </div>
  17. </v-col>
  18. <v-col cols="4">
  19. <v-btn class="btn-news" text> VOIR TOUS LES EVENEMENTS </v-btn>
  20. </v-col>
  21. </v-row>
  22. <v-row class="custom-row">
  23. <p class="agenda-details">
  24. Retrouvez tous les évènements culturels autour de chez vous.
  25. </p>
  26. </v-row>
  27. <v-row class="custom-row">
  28. <v-col cols="12" lg="12" md="12">
  29. <Carousel ref="carousel" :items-to-show="3.2" :items-to-scroll="2">
  30. <Slide
  31. v-for="(event, eventIndex) in events"
  32. :key="eventIndex"
  33. class="slide-card"
  34. >
  35. <v-card>
  36. <div
  37. class="card-img"
  38. :style="{ backgroundImage: 'url(' + event.img + ')' }"
  39. ></div>
  40. <v-card-title>
  41. {{ event.title }}
  42. </v-card-title>
  43. <v-card-text>
  44. {{ event.localisation }}
  45. </v-card-text>
  46. <div class="card-footer">
  47. <v-chip-group active-class="primary--text" column>
  48. <v-chip
  49. v-for="(tag, tagIndex) in event.tags"
  50. :key="tagIndex"
  51. class="ma-2 chip-custom"
  52. :color="tagColor(tag)"
  53. label
  54. >
  55. <span :class="tagTextColor(tag)">{{ tag }}</span>
  56. </v-chip>
  57. </v-chip-group>
  58. </div>
  59. </v-card>
  60. </Slide>
  61. </Carousel>
  62. </v-col>
  63. </v-row>
  64. </LayoutContainer>
  65. </div>
  66. </template>
  67. <script setup>
  68. import { ref } from "vue";
  69. import { Carousel, Slide } from "vue3-carousel";
  70. import "vue3-carousel/dist/carousel.css";
  71. const tagColor = (tag) => {
  72. switch (tag) {
  73. case "Payant":
  74. return "red";
  75. case "Gratuit":
  76. return "green";
  77. default:
  78. return "primary";
  79. }
  80. };
  81. const tagTextColor = (tag) => {
  82. switch (tag) {
  83. case "Payant":
  84. return "red--text";
  85. case "Gratuit":
  86. return "green--text";
  87. default:
  88. return "black--text";
  89. }
  90. };
  91. const events = ref([
  92. {
  93. rdv: "20h00",
  94. title: "LA NUIT DES RÊVES ",
  95. localisation: "FESTIVALDE musique - LONGCHAMP",
  96. date: "21/06/2023",
  97. img: "/images/agenda/agenda2.jpg",
  98. tags: ["Festival", "Musique", "Tout public", "Payant"],
  99. },
  100. {
  101. rdv: "20h00",
  102. title: "LE LAC DES CYGNES",
  103. localisation: "SPECTACLE DE DANSE - PARIS 1",
  104. date: "22/06/2023",
  105. img: "/images/agenda/agenda3.jpg",
  106. tags: ["Festival", "Musique", "Tout public", "Gratuit"],
  107. },
  108. {
  109. rdv: "20h00",
  110. title: "SOLIDAYS 2023 : 23 > 25 juin",
  111. localisation: "ORCHESTRE DE PARIS - PARIS 12",
  112. date: "23/06/2023",
  113. img: "/images/agenda/agenda4.jpg",
  114. tags: ["Festival", "Musique", "Tout public", "Payant"],
  115. },
  116. {
  117. rdv: "20h00",
  118. title: "LE LAC DES CYGNES",
  119. localisation: "FESTIVALDE musique - LONGCHAMP",
  120. date: "24/06/2023",
  121. img: "/images/agenda/agenda5.jpg",
  122. tags: ["Festival", "Musique", "Tout public", "Payant"],
  123. },
  124. {
  125. rdv: "20h00",
  126. title: "SOLIDAYS 2023 : 23 > 25 juin ",
  127. localisation: "SPECTACLE DE DANSE - PARIS 1",
  128. date: "20/06/2023",
  129. img: "/images/agenda/agenda1.jpg",
  130. tags: ["Festival", "Musique", "Tout public", "Payant"],
  131. },
  132. ]);
  133. let carousel;
  134. const goPrevious = () => carousel.prev();
  135. const goNext = () => carousel.next();
  136. </script>
  137. <style scoped>
  138. .card-footer{
  139. text-align: left !important;
  140. }
  141. .v-card {
  142. box-shadow: none !important;
  143. margin-right: 1rem;
  144. text-align: left;
  145. }
  146. .card-img {
  147. width: 100%;
  148. height: 300px;
  149. background-size: cover;
  150. background-position: center;
  151. border-top-left-radius: 20px;
  152. border-top-right-radius: 20px;
  153. }
  154. .green--text {
  155. color: green;
  156. }
  157. .custom-row {
  158. width: 90%;
  159. margin-left: auto;
  160. margin-right: auto;
  161. }
  162. .red--text {
  163. color: red;
  164. }
  165. .black--text {
  166. color: black;
  167. }
  168. .btn-news {
  169. color: #9edbdd;
  170. border-radius: 2rem;
  171. font-family: "Barlow";
  172. background: transparent;
  173. border: 1px solid #9edbdd;
  174. border-radius: 6px;
  175. font-style: normal;
  176. font-weight: 600;
  177. text-transform: uppercase;
  178. display: flex;
  179. flex-direction: row;
  180. align-items: center;
  181. padding: 25px;
  182. font-size: 10px;
  183. line-height: 15px;
  184. }
  185. .chip-custom {
  186. color: white;
  187. border: 1px solid #0e2d32;
  188. border-radius: 3rem;
  189. text-transform: uppercase;
  190. display: flex;
  191. align-items: center;
  192. text-align: center;
  193. }
  194. .carousel-button i {
  195. color: #000000;
  196. }
  197. .card-date {
  198. font-size: 0.8em;
  199. color: #888;
  200. margin-left: 1rem;
  201. }
  202. .card-footer {
  203. display: flex;
  204. }
  205. .title,
  206. .carousel-button,
  207. .btn-news {
  208. margin-top: 2rem;
  209. margin-bottom: 2rem;
  210. }
  211. .agenda-details {
  212. font-family: "Barlow";
  213. font-style: normal;
  214. font-weight: 300;
  215. font-size: 16px;
  216. line-height: 20px;
  217. margin-left: 2rem;
  218. color: #091d20;
  219. margin-bottom: 3rem;
  220. width: 15rem;
  221. }
  222. .title {
  223. font-family: "Barlow";
  224. font-style: normal;
  225. font-weight: 600;
  226. font-size: 42px;
  227. line-height: 42px;
  228. margin-left: 2rem;
  229. color: #071b1f;
  230. }
  231. .carousel-button {
  232. display: flex;
  233. justify-content: center;
  234. align-items: center;
  235. width: 40px;
  236. height: 40px;
  237. background-color: transparent;
  238. border: 2px solid #000000;
  239. cursor: pointer;
  240. margin-right: 1rem;
  241. }
  242. </style>