Skip to content

Commit

Permalink
Merge branch 'feature/lotti-anim-v2' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
sragabor committed Jan 29, 2024
2 parents 2d71465 + 559f405 commit b65aa00
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions src/components/sections/two-column-h2.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,6 @@ const TwoColumnH2 = ({
enterCount === 1 && lottieRef.current && lottieRef.current.play();


const lottieRef = useRef(null);

const myRef = useRef();

const {
inViewport,
enterCount,
leaveCount,
} = useInViewport(
myRef
);

enterCount === 1 && lottieRef.current && lottieRef.current.play();

return (
<section className={`two-column-h2 ${direction}`}>
Expand All @@ -56,8 +43,6 @@ const TwoColumnH2 = ({
<div className={`col col-12 col-lg-6 ${direction === "rtl" ? "order-lg-2" : "order-lg-1"}`}>
{anim && <Lottie lottieRef={lottieRef} style={{transform:'scale(1.2)'}} animationData={anim} loop={false} autoplay={false}/>}
{!anim && <Image alt={title} filename={image} />}
{anim && <Lottie lottieRef={lottieRef} style={{transform:'scale(1.2)'}} animationData={anim} loop={false} autoplay={false}/>}
{!anim && <Image alt={title} filename={image} />}
</div>
<div className={`d-table-cell align-middle col col-12 col-lg-6 ${direction === "rtl" ? "order-lg-1" : "order-lg-2"}`}>
<div className={"text"}>
Expand Down

0 comments on commit b65aa00

Please sign in to comment.