// --> custom scripts // MAIN NAVIGATION MENU — MOBILE function showMenu(navigationmobile){ var e = document.getElementById('navigationmobile'); var element = document.getElementById("mobtop"); if(e.style.display == 'block') e.style.display = 'none'; else e.style.display = 'block'; document.querySelector('body').style.overflow = 'hidden'; element.classList.toggle("mob-close-icon"); } // HOMEPAGE — RECENTLY ADDED ITEMS GRID $ShowHideMore = $('#home-recent-grid'); $ShowHideMore.each(function() { var $times = $(this).children('.home-recent-items'); if ($times.length > 13) { $ShowHideMore.children(':nth-of-type(n+13)').addClass('moreShown').hide(); $(this).find('span.home-show').addClass('more-times').html('SHOW MORE'); } }); $(document).on('click', '#home-recent-grid > span', function() { var that = $(this); var thisParent = that.closest('#home-recent-grid'); if (that.hasClass('more-times')) { thisParent.find('.moreShown').show(); that.toggleClass('more-times', 'less-times').html('SHOW LESS'); } else { thisParent.find('.moreShown').hide(); that.toggleClass('more-times', 'less-times').html('SHOW MORE'); } }); // SLIDER — ARTWORK TEMPLATE var slider = tns({ container: '.my-slider', items: 1, responsive: { 640: { edgePadding: 20, gutter: 20, items: 1 }, 700: { gutter: 30 }, 900: { items: 1 } } });