{ let scriptID = 'js-sneak-peek-may-2021'; let data = { title: 'May 2021 Edition', text: 'Joining the Scupltura collection this month is a more approachable version of the Valo L Necklace. We call her Valo 11 because she sports 11 geometrical beads on a simple link chain — all handcrafted from solid 22 karat gold. Don’t get us wrong. Our Valo L Necklace is all that. However, if you enjoy a sculptural look. But you want a bit more play and a little less potency, then check out the 11. By the way, if you want to know more about upcoming launches, news and happenings, then join our mailing list (the AUList) right now!', slides: [ { image: '/content/revamp/sneak-peek/may2021/valo_small_11_necklace_satin_02.png', textColor: 'black', formPosition: 'form-right', customClass: 'may2021-first', productName: 'VALO 11 NECKLACE', productKarats: '22 karat gold', productCollection: 'Sculptura Collection', }, { image: '/content/revamp/sneak-peek/may2021/Sneak-Peek.jpg', textColor: 'black', formPosition: 'form-right', customClass: 'may2021-second', productName: 'VALO 11 NECKLACE', productKarats: '22 karat gold', productCollection: 'Sculptura Collection', }, ], }; let generateHTML = _.template(`

Sneak peek!

Preview select new pieces coming soon

{ %>

Wait! There's more! Get on the au. list!

Be the first to know about our monthly drops

`); // NOTE: Code below this should never have to be changed let html = generateHTML(data); document.querySelector('#' + scriptID).outerHTML = html; setTimeout(() => { let prevArrow = document.querySelector('.slider-arrow-left-js'); let nextArrow = document.querySelector('.slider-arrow-right-js'); prevArrow.classList.remove('hidden'); nextArrow.classList.remove('hidden'); let sneakPeekImagesContainers = document.querySelectorAll('.js-sneak-peek-images-container'); [].forEach.call(sneakPeekImagesContainers, sneakPeekImagesContainer => { let dummyPrev = document.createElement('span'); sneakPeekImagesContainer.insertBefore(dummyPrev, sneakPeekImagesContainer.firstChild); dummyPrev.outerHTML = prevArrow.outerHTML; let dummyNext = document.createElement('span'); sneakPeekImagesContainer.appendChild(dummyNext); dummyNext.outerHTML = nextArrow.outerHTML; setTimeout(() => { let slider = sneakPeekImagesContainer.querySelector('.js-sneak-peek-slider:not(.slick-initialized)'); $(slider).slick({ slidesToShow: 1, slidesToScroll: 1, nextArrow: $(slider).parent().find(".slider-arrow-right-js"), prevArrow: $(slider).parent().find(".slider-arrow-left-js"), responsive: [ { breakpoint: 992, settings: { arrows: false, dots: true } } ] }); }, 100); }); prevArrow.classList.add('hidden'); nextArrow.classList.add('hidden'); }, 100); } //