(function(window, undefined) { var snize_search_results_page = '/pages/search-results-page'; if (window.location.pathname.indexOf(snize_search_results_page) !== -1 && typeof window.Shopify !== 'undefined') { var snize_search_results_page_classes = ' snize-results-page'; var theme_name = Shopify.theme.name.toLowerCase(); var theme_store_id = typeof Shopify.theme.theme_store_id !== 'undefined' && Shopify.theme.theme_store_id; var themes_for_css_hacking = Array( Array('alchemy', 657), Array('artisan', 856), Array('atlantic', 566), Array('athens', 1608), Array('avenue', 865), Array('baseline', 910), Array('be-yours', 1399), Array('blockshop', 606), Array('boost', 863), Array('boundless', 766), Array('brooklyn', 730), Array('broadcast', 868), Array('california', 691), Array('canopy', 732), Array('capital', 812), Array('cascade', 859), Array('colors', 757), Array('colorblock', 1499), Array('combine', 1826), Array('context', 870), Array('champion', 2010), Array('crave', 1363), Array('craft', 1368), Array('dawn', 887), Array('debut', 796), Array('district', 735), Array('editions', 457), Array('editorial', 827), Array('envy', 411), Array('empire', 838), Array('effortless', 1743), Array('expression', 230), Array('expanse', 902), Array('fashionopolism', 141), Array('flow', 801), Array('focal', 714), Array('galleria', 851), Array('grid', 718), Array('habitat', 1581), Array('handy', 826), Array('icon', 686), Array('impulse', 857), Array('impact', 1190), Array('ira', 790), Array('jumpstart', 782), Array('kagami', 747), Array('kingdom', 725), Array('label', 773), Array('launch', 793), Array('local', 833), Array('loft', 846), Array('lorenza', 798), Array('maker', 765), Array('masonry', 450), Array('minimal', 380), Array('minion', 1571), Array('mobilia', 464), Array('modular', 849), Array('motion', 847), Array('mr-parker', 567), Array('narrative', 829), Array('north', 1460), Array('origin', 1841), Array('pacific', 705), Array('parallax', 688), Array('palo-alto', 777), Array('pipeline', 739), Array('pop', 719), Array('prestige', 855), Array('providence', 587), Array('publisher', 1864), Array('pursuit', 1654), Array('ride', 1500), Array('reach', 853), Array('retina', 601), Array('refresh', 1567), Array('reformation', 1762), Array('responsive', 304), Array('sahara', 1926), Array('sense', 1356), Array('showcase', 677), Array('showtime', 687), Array('spark', 911), Array('split', 842), Array('startup', 652), Array('stiletto', 1621), Array('simple', 578), Array('story', 864), Array('studio', 1431), Array('supply', 679), Array('sunrise', 57), Array('shapes', 1535), Array('streamline', 872), Array('symmetry', 568), Array('taste', 1434), Array('testament', 623), Array('trademark', 816), Array('vantage', 459), Array('venture', 775), Array('venue', 836), Array('viola', 1701), Array('vendy', null), Array('vogue', 808), Array('warehouse', 871), Array('xtra', 1609), Array('yuva', 1615) ); var theme_name_for_hacking = ''; themes_for_css_hacking.forEach(function(theme_array) { theme_array.forEach(function(value, index) { if ( (index === 0 && theme_name.indexOf(value) !== -1) || (index === 1 && value === theme_store_id) ) { theme_name_for_hacking = theme_array.shift(); } }); }); if (theme_name_for_hacking.length > 0) { snize_search_results_page_classes += ' snize-' + theme_name_for_hacking.replace(/ /g, '-') + '-css-fix'; } document.body.className += snize_search_results_page_classes; } var snize_results = document.getElementById('snize_results'); if (snize_results != null && snize_results != undefined && snize_results.innerHTML != '') { return; } sInterval = setInterval(function() { var snize_results = document.getElementById('snize_results'); if (snize_results != null && snize_results != undefined && snize_results.innerHTML != '') { clearInterval(sInterval); var skeleton_results = document.getElementById('snize_skeleton_results'); skeleton_results.parentNode.removeChild(skeleton_results); return; } var grid_wrapper = document.getElementById('snize-search-results-wrapper'); if (grid_wrapper.offsetWidth >= 1055) { grid_wrapper.className = grid_wrapper.className.replace(/(?:^| )snize-three-columns(?!S)/g , '').replace(/(?:^| )snize-four-columns(?!S)/g , ''); if (!grid_wrapper.className.match(/(?:^| )snize-five-columns(?!S)/)) { grid_wrapper.className += ' snize-five-columns'; } } else if (grid_wrapper.offsetWidth >= 915) { grid_wrapper.className = grid_wrapper.className.replace(/(?:^| )snize-three-columns(?!S)/g , '').replace(/(?:^| )snize-five-columns(?!S)/g , ''); if (!grid_wrapper.className.match(/(?:^| )snize-four-columns(?!S)/)) { grid_wrapper.className += ' snize-four-columns'; } } else { grid_wrapper.className = grid_wrapper.className.replace(/(?:^| )snize-four-columns(?!S)/g , '').replace(/(?:^| )snize-five-columns(?!S)/g , ''); if (!grid_wrapper.className.match(/(?:^| )snize-three-columns(?!S)/)) { grid_wrapper.className += ' snize-three-columns'; } } }, 30); if (window.location.href.indexOf('collection=') != -1) { var elements = document.getElementsByClassName('snize-search-results-page-title'); var elementsArray = Array.prototype.slice.call(elements); elementsArray.forEach(function(domElement) { domElement.style.display = 'none'; }); } })(window);