Home
Code Library
Templates
Contact Us
Gsap horzontal Scroll
Date
: September 29, 2024
Developed By:
Paul Baretto
If GSAP not working then check on
Codepen
Our Team
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
Developer
Ethan Parker
View Source
HTML
CSS
JS
Links
Scripts
HTML
Copy
<p style="margin-left:10px">If GSAP not working then check on <a target="_blank" href="https://codepen.io/PaulBaretto/pen/wvVKGJq"><b>Codepen</b></a></p> <section class="section_wrap" id="our_team"> <div class="ourTeam_section" id="ourTeam_section_id"> <h2 class="section_title">Our Team</h2> <div class="cards_horizontal_holder"> <div class="our_team_card_wrap"> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> <div class="ourteam_single_card"> <div class="member_img_wrap img_wrap"> <img src="https://i.imgur.com/YKIGQ1t.png" alt=""> </div> <div class="member_content"> <div class="member_desig_name_wrap"> <div class="member_desig"><span>Developer</span></div> <div class="member_name">Ethan Parker</div> </div> <div class="member_icons_wrap"> <div class="card_icons_warp"> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-linkedin"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-x-twitter"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-behance"></i></a> <a href="#" target="_blank" class="single_icon"><i class="fa-brands fa-instagram"></i></a> </div> </div> </div> </div> </div> </div> </div> </section>
CSS
Copy
.our_team{ --font-Orbitron:"Orbitron", sans-serif; --font-Bebas-Neue:"Bebas Neue", sans-serif; --font-Poppins: "Poppins", sans-serif; --nav-font-size: 25px; --theme-yellow: #e9e659; --color-white:#dedede; --color-black:#1c1c1c; } .img_wrap img{ width: 100%; } .member_desig{ display: inline-block; padding: 5px; border-radius: 10px; background-color: var(--color-white); color: var(--color-black); font-weight: 600; font-family: var(--font-Poppins); font-size: 12px; } /* our team START */ .gsap_working{ overflow: hidden; } .cards_horizontal_holder{ overflow: hidden; height: auto; } .our_team_card_wrap{ display: flex; column-gap: 20px; margin-left: 280px; } .gsap_working .our_team_card_wrap{ margin-left: 150px; margin-right: 100px; } .ourteam_single_card{ max-width: 350px; background: #d1d0d8; padding: 15px; border-radius: 10px; display: grid; row-gap: 20px; flex-shrink: 0; transition: 0.1s linear; } .member_img_wrap, .member_img_wrap img{ border-radius: inherit; } .member_content{ display: flex; justify-content: space-between; align-items: center; } .member_desig{ display: inline-block; padding: 5px; border-radius: 10px; background-color: var(--color-white); color: var(--color-black); font-weight: 600; font-family: var(--font-Poppins); font-size: 12px; } .member_name{ font-family: var(--font-Bebas-Neue); font-weight: 600; font-size: 45px; } .card_icons_warp{ display: grid; grid-template-columns: repeat(2,1fr); gap: 5px; column-gap: 12px; } .card_icons_warp .single_icon{ display: block; color: var(--color-black); font-size: 18px; } /* our team END */
JS
Copy
gsap.registerPlugin(ScrollTrigger); let horizontalSection = document.querySelector('.our_team_card_wrap'); console.log(horizontalSection.scrollWidth); gsap.to('.our_team_card_wrap', { x: () => horizontalSection.scrollWidth * -1, xPercent: 100, scrollTrigger: { trigger: '.our_team_card_wrap', start: 'center center', end: '+=2000px', pin: '#ourTeam_section_id', scrub: true, invalidateOnRefresh: true } });
Links
Copy
<!-- Google fonts START --> <!-- Bebas Neue --> <!-- Orbitron --> <!-- Poppins --> <!--Google fonts END -->
Scripts
Copy
<!-- Gsap js -->
New
×