(function(e, t, n, o) { var enableTesting = undefined ? true : false; if (!enableTesting) { localStorage.removeItem("SEARCHBOOSTER_V2_AB_TEST_SEGMENT_A"); localStorage.removeItem("SEARCHBOOSTER_V2_AB_TEST_SEGMENT_B"); } var cdnUrl = "https://cdn2.searchbooster.net/scripts/CU-86938d7qd-front/init.js"; var pathCdnUrl = new URL(cdnUrl).pathname; var scriptElement = document.querySelector('[data-sb-init-script]'); var debug = false; var c = cdnUrl; var b = 'https://cdn.searchbooster.io' + pathCdnUrl; var settings = { "apiKey": "b8704c82-6098-4160-8998-dec957d389f8", "apiUrl": "https://api4.searchbooster.io", "optimizeWidget": true, "themes": ["v2"], "locales": { "ru": { "labels": { "notAvailable": "Под заказ" } } }, "completions": { "active": true, "taps": { "mobile": { "active": true, "count": 5 }, "desktop": { "active": true, "count": 5 } } }, "popup": true, "search": { "imageSearchFilter": true, "groupCategories": false }, "layout": { "filterPosition": "left" }, "offer": { "taps": { "mobile": { "active": false, "count": 5 }, "desktop": { "active": false, "count": 5 } } }, "cartCount": { "active": false, "completions": { "count": false }, "offer": { "count": false } }, "completionSettings": { "orders": ["popular", "categories", "brands", "history", "suggestions", "special_offers", "offers"], "totalCompletionCount": 32, "limits": { "brands": 3, "offers": 12, "history": 3, "popular": 5, "categories": 3, "suggestions": 3, "special_offers": 3 } }, "locale": "auto", "initialized": function(sb) { sb.mount({ "selector": "#search-popup, .js-search-booster", "widget": "search-popup", "options": { "cartCount": { "active": false, "completions": { "count": false }, "offer": { "count": false } } } }); sb.on('popup-open', function(payload) { if (window.ym) { ym(9652495, 'reachGoal', 'new-search') }; }); } }; if (scriptElement) { var scriptURL = new URL(scriptElement.src); debug = scriptURL.searchParams.get('debug'); } if (typeof sbRegionId !== "undefined" && sbRegionId) { settings.regionId = sbRegionId; } if (typeof sbSegmentId !== "undefined" && sbSegmentId) { settings.segmentId = sbSegmentId; } if (typeof sbUserId !== "undefined" && sbUserId) { settings.userId = sbUserId; } if (debug) { settings.debug = true; } a = t.getElementsByTagName(n)[0]; function initFu(c, s) { if (s) { if (s.src === b) { s.remove(); return } s.remove(); } e[o] = e[o] || function() { (e[o].a = e[o].a || []).push(arguments) }, e[o].h = c, e[o].n = o, e[o].i = 1 * new Date; s = t.createElement(n); s.async = 1; s.src = c; a.parentNode.insertBefore(s, a); t.body.insertAdjacentHTML('beforeend', ''); function loadScriptFromCDN(s) { s.onerror = function() { initFu(b, s); }; searchbooster(settings); } loadScriptFromCDN(s) } initFu(c); })(window, document, "script", "searchbooster");