Skip to content

Commit

Permalink
ADD:LottieFile Leaves
Browse files Browse the repository at this point in the history
  • Loading branch information
Pragya Prabir Ranjan Deka committed Mar 28, 2024
1 parent 2f235e6 commit a3291cc
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/Components/Hero/Hero.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React, { useState, useEffect } from "react";
import ScrollerJapi from "../../Pages/Invitation/ScrollerJapi";
import styles from "./Hero.module.scss";
import Leaves from "../LottieHeading/Leaves";

const Hero = () => {
const [stopAnimation, setStopAnimation] = useState(false);
Expand Down Expand Up @@ -41,7 +42,7 @@ const Hero = () => {
>
<img
src="https://res.cloudinary.com/dy55sllug/image/upload/c_pad,b_auto:predominant,fl_preserve_transparency/v1711649093/VectorOuterMostMost_oerg7f_wq2egq.jpg?_s=public-apps"
className={`${styles.jungle_outer1} absolute flex justify-center items-center z-[100] h-[100vh] w-[100vw]`}
className={`${styles.jungle_outer1} absolute flex justify-center items-center z-[100] h-[100vh] w-[100vw]`}
alt=""
/>
<img
Expand Down Expand Up @@ -219,6 +220,7 @@ const Hero = () => {
<div
className={`${styles.landing} h-[100vh] w-[100vw] object-contain flex justify-center items-start absolute top-0`}
>
<Leaves windowSize={windowSize} />
<img
src="https://res.cloudinary.com/dy55sllug/image/upload/c_pad,b_auto:predominant,fl_preserve_transparency/v1711654537/foreground_land_n6iyl8.jpg?_s=public-apps"
className={`${styles.land_bottom} absolute bottom-0 min-h-[100px] ${windowSize < 640 && "object-cover"} z-[90]`}
Expand Down
2 changes: 1 addition & 1 deletion src/Components/Hero/Hero.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@
100% {
width: 100vw;
height: 100vh;
opacity: 0;
opacity: 0.15;
}
}

Expand Down
13 changes: 13 additions & 0 deletions src/Components/LottieHeading/Leaves.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import React from "react";
import { Player } from "@lottiefiles/react-lottie-player";
import leaveslottie from "../../assets/lottie/leaves.json";

const Leaves = () => {
return (
<div className=" right-[-10vw] scale-50 absolute top-0">
<Player autoplay loop src={leaveslottie}></Player>
</div>
);
};

export default Leaves;
1 change: 1 addition & 0 deletions src/assets/lottie/leaves.json

Large diffs are not rendered by default.

0 comments on commit a3291cc

Please sign in to comment.