PageSourceSearch

https://www.minimizer.com/wp-content/uploads/hummingbird-assets/59ed7827cb3bf2185a7ec42b7ab98231.js

js minimizer.com collected 2026-09-29 09:35:18 UTC 5,912 bytes, 2 lines download raw bytes

1/**handles:swatches-and-photos**/
2((c,e,t,a)=>{function d(e,t,a,i){this.recalc_needed=!0,this.all_set_callback=a,this.not_all_set_callback=i,this.variation_attributes=e,this.variations_available=t,this.variations_current={},this.variations_selected={},this.reset_current=function(){for(var e in this.variation_attributes){this.variations_current[e]={};for(var t=0;t<this.variation_attributes[e].length;t++)this.variations_current[e.toString()][this.variation_attributes[e][t].toString()]=0}},this.update_current=function(){this.reset_current();for(var e=0;e<this.variations_available.length;e++)if(this.variations_available[e].variation_is_active){var t=this.variations_available[e].attributes,a;for(a in t){var i=t[a],s=this.variations_selected[a];if(s&&s==i)this.variations_current[a][i]=1;else{var n=!0,r,l,c;for(r in this.variations_selected){r!=a&&(l=this.variations_selected[r],c=t[r],l&&c&&l!=c)&&(n=!1)}if(n)if(""===i)for(var d in this.variations_current[a])this.variations_current[a][d]=1;else this.variations_current[a][i]=1}}}this.recalc_needed=!1},this.get_current=function(){return this.recalc_needed&&this.update_current(),this.variations_current},this.reset_selected=function(){this.recalc_needed=!0,this.variations_selected={}},this.set_selected=function(e,t){this.recalc_needed=!0,this.variations_selected[e]=t},this.get_selected=function(){return this.variations_selected}}c.fn.wc_swatches_form=function(){var a=this,i=parseInt(a.data("product_id"),10),n=null,l=!1,s=null,t=!1;a.on("bind_calculator",function(){var e=a.data("product_variations"),r=((l=!1===e)&&a.block({message:null,overlayCSS:{background:"#fff",opacity:.6}}),{}),t;a.find(".select-option.selected").each(function(e,t){var a=c(this),i=a.closest("div.select").eq(0),s=i.parent().find(".swatch-label").eq(0),i=i.find("select").first(),a=c("<div/>").html(a.data("value")).text(),a;a=(a=a.replace(/'/g,"\\'")).replace(/"/g,'\\"'),s&&s.html(i.children("[value='"+a+"']").eq(0).text())}),a.find(".variations select").each(function(e,t){var t=c(t),a=t.data("attribute_name")||t.attr("name"),i=(r[a]=[],""),i;if((i=t.find("option:gt(0)").get()).length)for(var s=0;s<i.length;s++){var n=i[s];r[a].push(c(n).val())}}),l?(s&&s.abort(),s=c.ajax({url:wc_swatches_params.ajax_url,type:"POST",data:{product_id:i,action:"get_product_variations"}
2,success:function(e){n=new d(r,e.data,null,null),a.unblock()}})):n=new d(r,e,null,null),a.trigger("woocommerce_variation_has_changed")}),a.on("click",".reset_variations",function(){return a.find(".swatch-label").html("&nbsp;"),a.find(".select-option").removeClass("selected"),a.find(".radio-option").prop("checked",!1),!1}).on("reset_data",function(e){var s;null==n||(s=n.get_current(),t)||(a.find("div.select").each(function(e,t){var a=c(t).find("select").first(),a=a.data("attribute_name")||a.attr("name"),i=s[a];c(t).find("div.select-option").each(function(e,t){i[c(t).data("value")]?c(t).removeClass("disabled"):(c(t).removeClass("selected"),c(t).addClass("disabled","disabled"))}),c(t).find("input.radio-option").each(function(e,t){i[c(t).val()]?(c(t).removeAttr("disabled"),c(t).parent().removeClass("disabled")):(c(t).attr("disabled","disabled"),c(t).parent().addClass("disabled","disabled"))})}),t=!0)}).on("click",".select-option",function(e){e.preventDefault();var e=c(this),t=e.closest("div.select").eq(0),a=t.parent().find(".swatch-label").eq(0),i,s,i,t,t;if(e.hasClass("disabled"))return!1;e.hasClass("selected")?(e.removeClass("selected"),(i=t.find("select").first()).children("option:eq(0)").prop("selected","selected").change(),a&&a.html("&nbsp;")):(t.find(".select-option").removeClass("selected"),e.addClass("selected"),s=t.data("selectid"),i=t.find("select").first(),t=(t=(t=c("<div/>").html(e.data("value")).text()).replace(/'/g,"\\'")).replace(/"/g,'\\"'),i.trigger("focusin").children("[value='"+t+"']").prop("selected","selected").change(),a&&a.html(i.children("[value='"+t+"']").eq(0).text()))}).on("change",".radio-option",function(e){var t=c(this),a,i=t.closest("div.select").eq(0).find("select").first(),t=c("<div/>").html(t.val()).text(),t;t=(t=t.replace(/'/g,"\\'")).replace(/"/g,'\\"'),i.trigger("focusin").children("[value='"+t+"']").prop("selected","selected").change()}).on("woocommerce_variation_has_changed",function(){var s;null!==n&&(a.find(".variations select").each(function(){var e=c(this).data("attribute_name")||c(this).attr("name");n.set_selected(e,c(this).val())}),s=n.get_current(),a.find("div.select").each(function(e,t){var a=c(t).find("select").first(),a=a.data("attribute_name")||a.attr("name"),i=s[a];c(t).find("div.select-option").each(function(e,t){i[c(t).data("value")]?c(t).removeClass("disabled"):c(t).addClass("disabled","disabled")}),c(t).find("input.radio-option").each(function(e,t){i[c(t).val()]?(c(t).removeAttr("disabled"),c(t).parent().removeClass("disabled")):(c(t).attr("disabled","disabled"),c(t).parent().addClass("disabled","disabled"))})}),l)&&a.find(".wc-default-select").each(function(e,t){var t=c(t),a=t.data("attribute_name")||t.attr("name"),i=s[a];t.find("option:gt(0)").removeClass("attached"),t.find("option:gt(0)").removeClass("enabled"),t.find("option:gt(0)").removeAttr("disabled"),t.find("option:gt(0)").each(function(e,t){i[c(t).val()]?(c(t).addClass("attached"),c(t).addClass("enabled")):c(t).addClass("disabled","disabled")}),t.find("option:gt(0):not(.enabled)").attr("disabled","disabled")})})};var i=[];c(t).on("wc_variation_form",function(e){var e=c(e.target);i.push(e),e.data("has_swatches_form")&&!e.hasClass("summary_content")||e.find(".swatch-control").length&&(e.data("has_swatches_form",!0),e.wc_swatches_form(),e.trigger("bind_calculator"),e.on("reload_product_variations",function(){for(var e=0;e<i.length;e++)i[e].trigger("woocommerce_variation_has_changed"),i[e].trigger("bind_calculator"),i[e].trigger("woocommerce_variation_has_changed")}),e.trigger("check_variations"))})})(jQuery,window,document);

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.