From 75c06e7bbba79ddceb8fd551edca7d90dbfff99a Mon Sep 17 00:00:00 2001 From: Lucy Cifferello <12953208+elvece@users.noreply.github.com> Date: Mon, 7 Oct 2024 16:40:55 -0400 Subject: [PATCH] fix line animations --- src/assets/js/appearance-animation.js | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/assets/js/appearance-animation.js b/src/assets/js/appearance-animation.js index bc4a7ae..97a14bb 100644 --- a/src/assets/js/appearance-animation.js +++ b/src/assets/js/appearance-animation.js @@ -128,6 +128,30 @@ if (document.querySelector("#infographics .subsection--control")) { }); } +// line animation +gsap.from("#bitcoin-to-be path:first-child", { + drawSVG: 0, + ease: "none", + scrollTrigger: { + trigger: "#bitcoin-to-be", + scrub: true, + start: "top 75%", + end: "bottom 75%", + }, +}); + +// line animation +gsap.from("#be-to-powered path", { + drawSVG: 0, + ease: "none", + scrollTrigger: { + trigger: "#be-to-powered path", + scrub: true, + start: "top 75%", + end: "bottom 75%", + }, +}); + ////////////////////////////////////////// // POWERED