PageSourceSearch

https://www.sagroltecidos.com.br/frontend/js/search.min.js

js sagroltecidos.com.br collected 2026-09-29 13:27:11 UTC 2,345 bytes, 1 lines download raw bytes

1$(function(){var a={notify:function(a,e,s){switch(a){case"hint":(function(){var e=this,s="undefined"!=typeof gtag;$(e).hasClass("input-loading")||$(e).addClass("input-loading"),ProductModel.hint(this.value,null,function(a){$(e).removeClass("input-loading"),o(a,e),s&&gtag("event","search",{search_term:e.value})})}).call(e,s);break;case"erase":case"focusOut":(function(){n($(this))}).call(e,s)}}};function n(a){a.removeClass("input-loading").parent().children(".wrapper-advanced-search").remove()}function o(a,e){var n,o,t,c,i,s=$("<div/>",{class:"advanced-search"}),r=$(e).parent(),e=$("<div />",{class:"wrapper-advanced-search"});r.children(".wrapper-advanced-search").remove(),a.CatalogoProduto&&r.append(e.append(s.append([(e=a.CatalogoCategoria,c=a.urlLoja,s=$("<ul/>",{class:"advanced-search-categories"}),i=[],$.each(e,function(a,e){var s=$("<li />",{class:"advanced-search-category-item"}),e=$("<a />",{href:c+"/"+e.CatalogoCategoria.slug,html:"<span>"+e.CatalogoCategoria.nome+"</span>"});i.push(s.append(e))}),s.append(i)),'<div class="advanced-search-header"><span class="advanced-search-title">Produtos Sugeridos</span></div>',(s=a.CatalogoProduto,n=a.urlLoja,o=a.ExibePreco,a=$("<ul/>",{class:"advanced-search-list"}),t=[],$.each(s,function(a,e){void 0===o||o||(e.CatalogoProduto.valor_inicio="");var s=$("<li />",{class:"advanced-search-item"}),e=$("<a />",{href:n+"/"+e.CatalogoProduto.slug,html:"<span class='product-image'><img src='"+base_url_image+"/sku/thumb_"+e.ImagemPerfil.name+"'></span><span class='product-name'>"+e.CatalogoProduto.nome+"</span><span class='product-price'>"+e.CatalogoProduto.valor_inicio+"</span>"});t.push(s.append(e))}),a.append(t))])))}var e,c,t,s=(e=!1,c=0,t={hint:[],erase:[],focusOut:[]},$(".search-field").on("keydown",function(a){keyVal=this.val,i(this,a),e=!e||8!=a.which||(r("erase",this,a),!1)}),{subscribe:function(a,e){if(!t[a])return!1;t[a].push(e)}});function i(e,a){var s,n,o,t;c&&clearTimeout(c),n=a,o=(s=e).value.length,t=String.fromCharCode(n.which).match(/[a-zA-Z0-9-_:\s\b]/),s.value&&3<=o&&!n.ctrlKey&&!n.altKey&&(t||void 0===n.which)&&(c=setTimeout(function(){r("hint",e,a),$(document).click(function(a){r("focusOut",e,a)})},500))}function r(a,e,s){for(var n=t[a].length,o=0;o<n;o++)t[a][o].notify(a,e,s)}s.subscribe("hint",a),s.subscribe("erase",a),s.subscribe("focusOut",a)});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.