Skip to content

Commit

Permalink
Add Scaling to image
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-priyanka-g committed Sep 15, 2023
1 parent 8f284a3 commit ed41215
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 19 deletions.
38 changes: 21 additions & 17 deletions vue-frontend/src/components/ios-app-development/SuccessStory.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<section>
<section class="tw-mb-20">
<div class="tw-container tw-mb-7 tw-mx-auto tw-text-center">
<span
class="tw-tracking-[-4%] tw-mb-2.5 tw-font-inter-bold tw-text-3xl tw-leading-[2.4375rem] tw-text-black-core/[0.87] md:!tw-mx-0 md:!tw-w-full md:tw-text-[2.65625rem] lg:tw-text-[3.4375rem] md:tw-leading-[3.796875rem] lg:tw-leading-[5.15625rem] xs:tw-mx-auto xs:tw-w-[71%]"
Expand All @@ -8,13 +8,14 @@
>
</div>
<div
class="tw-ml-auto tw-mx-auto tw-h-[28.125rem] tw-relative xll:tw-container"
class="tw-ml-auto tw-mx-auto tw-h-[30rem] tw-relative xll:tw-container tw-overflow-hidden"
>
<img
:src="reviewBackgroundImage"
:srcset="`${reviewBackgroundImage} 400w`"
class="tw-h-full tw-w-full tw-object-cover md:tw-hidden"
class="tw-h-full tw-w-full tw-object-cover md:tw-hidden tw-ease-in-out tw-duration-1000"
alt="ios-review-image"
id="scaling-image"
/>
<div
class="tw-container swiper-content md:tw-hidden tw-absolute tw-p-4 tw-w-full tw-text-center tw-text-[#FFF] tw-transform tw-left-1/2 tw-top-1/2 tw--translate-x-1/2 tw--translate-y-1/2 xl:tw-w-[80%] md:tw-top-[49%] lg:tw-top-[48%] 2xl:tw-w-[49%] xl2:tw-w-[60%] 2xll:tw-w-[50%] xll:tw-w-[65%]"
Expand All @@ -26,6 +27,7 @@
delay: 3000,
disableOnInteraction: false,
}"
:speed="3000"
:loop="true"
:spaceBetween="20"
:pagination="pagination"
Expand Down Expand Up @@ -72,18 +74,15 @@
</template>

<script>
import { Autoplay, Pagination } from "swiper/modules";
import { Autoplay } from "swiper/modules";
import { Swiper, SwiperSlide } from "swiper/vue";
import { FontAwesomeIcon } from "@fortawesome/vue-fontawesome";
import reviewBackgroundImage from "@/assets/images/ios-app-development/review-background-400w.webp";
export default {
data() {
return {
swiper: null,
reading: false,
modules: [Pagination, Autoplay],
modules: [Autoplay],
reviewBackgroundImage,
activeIndex: 0,
clients: [
{
id: 1,
Expand All @@ -98,40 +97,45 @@ export default {
designation: "Product Manager at Luxe, Morocco",
review:
"The Play Store is the hardest app store to get good reviews on, and we've just reached a five-star rating, which has been one of our biggest achievements, partly thanks to Canopas' work.",
classname: "tw-scale-100",
},
{
id: 3,
name: "Rob Eberhard",
designation: "Founder at ActivScout, Canada",
review:
"I was especially impressed with the skills of their backend developer and how well the project manager and she worked with one another to create a high performing iOS app.",
classname: "tw-scale-110",
},
{
id: 4,
name: "Lisa Weinstein",
designation: "Founder at Brickandbatten, USA",
review:
"There is not enough space to say all the wonderful things I would want to share about Canopas. The team is incredibly helpful, stays calm even when we had to deal with tough issues on our app and always found a way to help us fix whatever was needed or roll out any new features for our app in both the iOS and Android stores.",
classname: "tw-scale-125",
},
{
id: 5,
name: "Cyril Trosset",
designation: "CTO at Udini, France",
review:
"Multiple versions of this Android app have been successfully delivered over time. They are always very responsive on bug resolution. They are very efficient at producing complex interfaces and high quality apps",
classname: "tw-scale-150",
},
],
pagination: {
el: ".swiper-pagination",
clickable: true,
},
};
},
mounted() {
const image = document.getElementById("scaling-image");
let scaleCount = 0;
function scaleImage() {
if (scaleCount <= 5) {
image.style.transform = `scale(${1 + scaleCount * 0.1})`;
scaleCount++;
} else {
image.style.transform = "scale(1)";
scaleCount = 0;
}
}
setInterval(scaleImage, 3000);
},
components: {
Swiper,
SwiperSlide,
Expand Down
4 changes: 2 additions & 2 deletions vue-frontend/src/pages/ios-app-development.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
<Header />
<LandingSection ref="iosLanding" />
<DevelopmentSection ref="iosDevelopment" />
<SuccessStorySection ref="iosSuccessstory" />
<FaqSection ref="iosFaq" />
<CtaSection ref="iosCta1" />
<SuccessStorySection ref="iosSuccessstory" />
<CtaSection2 ref="iosCta2" />
<FaqSection ref="iosFaq" />
<NewFooter ref="iosFooter" />
</div>
</template>
Expand Down

0 comments on commit ed41215

Please sign in to comment.