diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_1-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_1-1600w.webp deleted file mode 100644 index 8997e3511..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_1-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_1-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_1-400w.webp deleted file mode 100644 index 94ce2a2ae..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_1-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_1-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_1-800w.webp deleted file mode 100644 index 763ddc2d1..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_1-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_10-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_10-1600w.webp deleted file mode 100644 index 7ba7ef192..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_10-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_10-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_10-400w.webp deleted file mode 100644 index 55a8feb84..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_10-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_10-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_10-800w.webp deleted file mode 100644 index 0915fb983..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_10-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_11-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_11-1600w.webp deleted file mode 100644 index 26a20cd98..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_11-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_11-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_11-400w.webp deleted file mode 100644 index a381aebfe..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_11-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_11-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_11-800w.webp deleted file mode 100644 index 4e6e20c3d..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_11-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_12-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_12-1600w.webp deleted file mode 100644 index 7a2937882..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_12-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_12-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_12-400w.webp deleted file mode 100644 index fa9b8cd36..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_12-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_12-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_12-800w.webp deleted file mode 100644 index 835473191..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_12-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_2-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_2-1600w.webp deleted file mode 100644 index 605488305..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_2-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_2-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_2-400w.webp deleted file mode 100644 index 405ea729c..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_2-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_2-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_2-800w.webp deleted file mode 100644 index d149c4942..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_2-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_3-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_3-1600w.webp deleted file mode 100644 index 44983e94e..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_3-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_3-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_3-400w.webp deleted file mode 100644 index 52210d5cc..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_3-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_3-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_3-800w.webp deleted file mode 100644 index 40ff8cd4d..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_3-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_4-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_4-1600w.webp deleted file mode 100644 index d3e86e62e..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_4-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_4-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_4-400w.webp deleted file mode 100644 index ac41c93b3..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_4-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_4-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_4-800w.webp deleted file mode 100644 index d237816fa..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_4-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_5-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_5-1600w.webp deleted file mode 100644 index e4eb547e2..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_5-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_5-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_5-400w.webp deleted file mode 100644 index ed7e6c1f1..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_5-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_5-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_5-800w.webp deleted file mode 100644 index ba7e57100..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_5-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_6-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_6-1600w.webp deleted file mode 100644 index 5c141ece9..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_6-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_6-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_6-400w.webp deleted file mode 100644 index 67bc74860..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_6-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_6-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_6-800w.webp deleted file mode 100644 index d644572ea..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_6-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_7-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_7-1600w.webp deleted file mode 100644 index 77ef8ab86..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_7-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_7-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_7-400w.webp deleted file mode 100644 index 08603df7e..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_7-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_7-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_7-800w.webp deleted file mode 100644 index b6c6495a0..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_7-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_8-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_8-1600w.webp deleted file mode 100644 index a38e8275e..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_8-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_8-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_8-400w.webp deleted file mode 100644 index 05f5ee22e..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_8-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_8-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_8-800w.webp deleted file mode 100644 index ed9492323..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_8-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_9-1600w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_9-1600w.webp deleted file mode 100644 index cceac91b6..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_9-1600w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_9-400w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_9-400w.webp deleted file mode 100644 index da8f4fe8a..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_9-400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/life/jobs_canopas_life_9-800w.webp b/nuxt-frontend/assets/images/life/jobs_canopas_life_9-800w.webp deleted file mode 100644 index f47a6f5de..000000000 Binary files a/nuxt-frontend/assets/images/life/jobs_canopas_life_9-800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_1_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_1_400w.webp deleted file mode 100644 index b88b3c5d4..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_1_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_1_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_1_800w.webp deleted file mode 100644 index 7362cf78d..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_1_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_2_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_2_400w.webp deleted file mode 100644 index 70e75a8d9..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_2_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_2_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_2_800w.webp deleted file mode 100644 index cfb03b9a5..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_2_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_3_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_3_400w.webp deleted file mode 100644 index 58762c0a4..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_3_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_3_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_3_800w.webp deleted file mode 100644 index 8a6212fec..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_3_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_4_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_4_400w.webp deleted file mode 100644 index f80872aa5..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_4_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_4_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_4_800w.webp deleted file mode 100644 index d8dd46161..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_4_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_5_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_5_400w.webp deleted file mode 100644 index f60c6caa1..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_5_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_5_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_5_800w.webp deleted file mode 100644 index e75a7f58b..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_5_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_6_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_6_400w.webp deleted file mode 100644 index 57c231861..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_6_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_6_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_6_800w.webp deleted file mode 100644 index eff7488cd..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_6_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_7_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_7_400w.webp deleted file mode 100644 index ac9e8a033..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_7_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_7_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_7_800w.webp deleted file mode 100644 index 4d08acfec..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_7_800w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_8_400w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_8_400w.webp deleted file mode 100644 index 36f09ced6..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_8_400w.webp and /dev/null differ diff --git a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_8_800w.webp b/nuxt-frontend/assets/images/perks/jobs_canopas_perks_8_800w.webp deleted file mode 100644 index d8db230dc..000000000 Binary files a/nuxt-frontend/assets/images/perks/jobs_canopas_perks_8_800w.webp and /dev/null differ diff --git a/nuxt-frontend/components/jobs/LifeAtCanopas.vue b/nuxt-frontend/components/jobs/LifeAtCanopas.vue index 63a7a08f8..7f9a51cf3 100755 --- a/nuxt-frontend/components/jobs/LifeAtCanopas.vue +++ b/nuxt-frontend/components/jobs/LifeAtCanopas.vue @@ -65,116 +65,36 @@ import AspectRatio from "@/components/utils/AspectRatio.vue"; import { Autoplay, Pagination } from "swiper/modules"; import { Swiper, SwiperSlide } from "swiper/vue"; - -import life1_400w from "@/assets/images/life/jobs_canopas_life_1-400w.webp"; -import life1_800w from "@/assets/images/life/jobs_canopas_life_1-800w.webp"; -import life1_1600w from "@/assets/images/life/jobs_canopas_life_1-1600w.webp"; - -import life2_400w from "@/assets/images/life/jobs_canopas_life_2-400w.webp"; -import life2_800w from "@/assets/images/life/jobs_canopas_life_2-800w.webp"; -import life2_1600w from "@/assets/images/life/jobs_canopas_life_2-1600w.webp"; - -import life3_400w from "@/assets/images/life/jobs_canopas_life_3-400w.webp"; -import life3_800w from "@/assets/images/life/jobs_canopas_life_3-800w.webp"; -import life3_1600w from "@/assets/images/life/jobs_canopas_life_3-1600w.webp"; - -import life4_400w from "@/assets/images/life/jobs_canopas_life_4-400w.webp"; -import life4_800w from "@/assets/images/life/jobs_canopas_life_4-800w.webp"; -import life4_1600w from "@/assets/images/life/jobs_canopas_life_4-1600w.webp"; - -import life5_400w from "@/assets/images/life/jobs_canopas_life_5-400w.webp"; -import life5_800w from "@/assets/images/life/jobs_canopas_life_5-800w.webp"; -import life5_1600w from "@/assets/images/life/jobs_canopas_life_5-1600w.webp"; - -import life6_400w from "@/assets/images/life/jobs_canopas_life_6-400w.webp"; -import life6_800w from "@/assets/images/life/jobs_canopas_life_6-800w.webp"; -import life6_1600w from "@/assets/images/life/jobs_canopas_life_6-1600w.webp"; - -import life7_400w from "@/assets/images/life/jobs_canopas_life_7-400w.webp"; -import life7_800w from "@/assets/images/life/jobs_canopas_life_7-800w.webp"; -import life7_1600w from "@/assets/images/life/jobs_canopas_life_7-1600w.webp"; - -import life8_400w from "@/assets/images/life/jobs_canopas_life_8-400w.webp"; -import life8_800w from "@/assets/images/life/jobs_canopas_life_8-800w.webp"; -import life8_1600w from "@/assets/images/life/jobs_canopas_life_8-1600w.webp"; - -import life9_400w from "@/assets/images/life/jobs_canopas_life_9-400w.webp"; -import life9_800w from "@/assets/images/life/jobs_canopas_life_9-800w.webp"; -import life9_1600w from "@/assets/images/life/jobs_canopas_life_9-1600w.webp"; - -import life10_400w from "@/assets/images/life/jobs_canopas_life_10-400w.webp"; -import life10_800w from "@/assets/images/life/jobs_canopas_life_10-800w.webp"; -import life10_1600w from "@/assets/images/life/jobs_canopas_life_10-1600w.webp"; - -import life11_400w from "@/assets/images/life/jobs_canopas_life_11-400w.webp"; -import life11_800w from "@/assets/images/life/jobs_canopas_life_11-800w.webp"; -import life11_1600w from "@/assets/images/life/jobs_canopas_life_11-1600w.webp"; - -import life12_400w from "@/assets/images/life/jobs_canopas_life_12-400w.webp"; -import life12_800w from "@/assets/images/life/jobs_canopas_life_12-800w.webp"; -import life12_1600w from "@/assets/images/life/jobs_canopas_life_12-1600w.webp"; +import axios from "axios"; +import config from "@/config.js"; +import { getDiffrentWidthImages } from "@/utils.js"; export default { data() { return { + getDiffrentWidthImages, modules: [Pagination, Autoplay], - slides: [ - { - id: 2, - image: [life2_400w, life2_800w, life2_1600w], - }, - { - id: 12, - image: [life12_400w, life12_800w, life12_1600w], - }, - { - id: 7, - image: [life7_400w, life7_800w, life7_1600w], - }, - { - id: 1, - image: [life1_400w, life1_800w, life1_1600w], - }, - { - id: 4, - image: [life4_400w, life4_800w, life4_1600w], - }, - { - id: 10, - image: [life10_400w, life10_800w, life10_1600w], - }, - { - id: 3, - image: [life3_400w, life3_800w, life3_1600w], - }, - { - id: 9, - image: [life9_400w, life9_800w, life9_1600w], - }, - { - id: 6, - image: [life6_400w, life6_800w, life6_1600w], - }, - { - id: 8, - image: [life8_400w, life8_800w, life8_1600w], - }, - { - id: 5, - image: [life5_400w, life5_800w, life5_1600w], - }, - { - id: 11, - image: [life11_400w, life11_800w, life11_1600w], - }, - ], - + slides: [], pagination: { el: ".swiper-pagination", clickable: true, }, }; }, + methods: { + async fetchDataFromAPI() { + try { + const response = await axios.get(config.API_BASE + "/api/lifeimages"); + this.slides = getDiffrentWidthImages(response); + } catch (error) { + console.error("Error fetching data from the API", error); + } + }, + }, + created() { + this.fetchDataFromAPI(); + }, + components: { Swiper, SwiperSlide, diff --git a/nuxt-frontend/components/jobs/PerksAndBenefits.vue b/nuxt-frontend/components/jobs/PerksAndBenefits.vue index 8c902c300..7dddc6b6b 100755 --- a/nuxt-frontend/components/jobs/PerksAndBenefits.vue +++ b/nuxt-frontend/components/jobs/PerksAndBenefits.vue @@ -75,23 +75,9 @@ diff --git a/nuxt-frontend/utils.js b/nuxt-frontend/utils.js index c522b7001..992ec897a 100644 --- a/nuxt-frontend/utils.js +++ b/nuxt-frontend/utils.js @@ -34,7 +34,7 @@ function setGithubStars(contributions, githubRepos) { .filter( (repo) => repo.name == - contribution.link.slice(contribution.link.lastIndexOf("/") + 1), + contribution.link.slice(contribution.link.lastIndexOf("/") + 1) ) .map((repo) => repo.stargazers_count.toString())[0]; }); @@ -77,7 +77,7 @@ function getJobDates() { currentDay <= maxDays ? startDateOfMonth : new Date( - startDateOfMonth.setDate(startDateOfMonth.getDate() + maxDays), + startDateOfMonth.setDate(startDateOfMonth.getDate() + maxDays) ); const datePosted = jobPosted.toISOString().split("T")[0]; @@ -91,6 +91,19 @@ function getJobDates() { return { datePosted, validThrough }; } +function getDiffrentWidthImages(response) { + let imageUrls = response.data; + let slides = []; + slides = imageUrls.map((set) => ({ + image: parseImageUrls(set.imageUrls), + })); + return slides; +} + +function parseImageUrls(imageUrls) { + return imageUrls.split(",").map((url) => url.trim()); +} + export { elementInViewPort, handleAnimationOnScroll, @@ -98,4 +111,6 @@ export { openBlog, unescapeHTML, getJobDates, + getDiffrentWidthImages, + parseImageUrls, };