tdm91 Posted October 21, 2022 Posted October 21, 2022 Hi all! Link to the page I'm working on: https://www.hooshdesigns.com.au/mango-silk-collective-copy I'm currently trying to have three main images autoplay. Currently it's set to Gallery: Strips, but I'm hoping there's a way to have these three images auto-scroll through. I've tried using the Gallery: Reel, but the images repeat over because there's only three, and I can't seem to get the images in large rectangles with the Reel like I can with the Strips. Essentially, I'm trying to maintain the same appearance with the large Strips but with an autoplay effect - does anyone know if this is possible? Thanks in advance!
Beyondspace Posted October 27, 2022 Posted October 27, 2022 On 10/22/2022 at 6:49 AM, tdm91 said: Hi all! Link to the page I'm working on: https://www.hooshdesigns.com.au/mango-silk-collective-copy I'm currently trying to have three main images autoplay. Currently it's set to Gallery: Strips, but I'm hoping there's a way to have these three images auto-scroll through. I've tried using the Gallery: Reel, but the images repeat over because there's only three, and I can't seem to get the images in large rectangles with the Reel like I can with the Strips. Essentially, I'm trying to maintain the same appearance with the large Strips but with an autoplay effect - does anyone know if this is possible? Thanks in advance! The strips layout looks similar to Grid layout? Can you describe how you want to display images with autoplay effect? It could be better if you can provide some demo/screenshots of the result you want to achieve BeyondSpace - Squarespace Website Developer 🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox - PDF Lightbox popup - ...) </> 🗓️ Delivery Date Picker (Date picker form field) Gallery block 7.1 workaround </> No-code customisations for Squarespace
tuanphan Posted October 31, 2022 Posted October 31, 2022 On 10/22/2022 at 6:49 AM, tdm91 said: Hi all! Link to the page I'm working on: https://www.hooshdesigns.com.au/mango-silk-collective-copy I'm currently trying to have three main images autoplay. Currently it's set to Gallery: Strips, but I'm hoping there's a way to have these three images auto-scroll through. I've tried using the Gallery: Reel, but the images repeat over because there's only three, and I can't seem to get the images in large rectangles with the Reel like I can with the Strips. Essentially, I'm trying to maintain the same appearance with the large Strips but with an autoplay effect - does anyone know if this is possible? Thanks in advance! Add this to Mango Sild Collective Copy Page Header <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.1/jquery.min.js"></script> <script> $(document).ready(() => { let add = '<div class="slider"><div class="slide-track" id="slides">' const interval = setInterval(() => { let imgs = $('section:nth-child(2) img'); if (imgs.length > 0) { for (let j=0; j<3; j++) { for (let i = 0; i<imgs.length; i++) { add += '<div class="slide"><img src="'+ $(imgs[i]).attr('data-src') +'" alt="" /></div>' } } add += '</div></div>' $(add).appendTo('section:nth-child(2)'); clearInterval(interval); } }, 100) }) </script> <style> section:nth-child(2) > .content-wrapper { display: none; } section:nth-child(2) { display: block !important; } @keyframes scroll { 0% { transform: translateX(0); } 100% { transform: translateX(-1687px)} } .slide img { height: 90px; } .slider { background: white; box-shadow: 0 10px 20px -5px rgba(0, 0, 0, .125); height: 100px; margin: auto; overflow:hidden; position: relative; width: 100%; padding: 50px 0; } .slide-track { animation: scroll 25s linear infinite; display: flex; } .slide { height: 100px; padding: 0 40px; } </style> Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)
tdm91 Posted November 6, 2022 Author Posted November 6, 2022 Thank you @bangank36 and @tuanphan for your responses and sorry for my late reply. Tuanphan, what you've provided is essentially what I was after (with the images scrolling across) however when I add your code, the images become tiny (they do slide though) but it seems to break the section - here's a screenshot:
tuanphan Posted November 10, 2022 Posted November 10, 2022 On 11/6/2022 at 7:19 AM, tdm91 said: Thank you for your responses and sorry for my late reply. Tuanphan, what you've provided is essentially what I was after (with the images scrolling across) however when I add your code, the images become tiny (they do slide though) but it seems to break the section - here's a screenshot: this line controls size .slide img { height: 90px; } Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment