Merge pull request #4606 from toddlahman/master

Removed (document).ready from jQuery scripts
This commit is contained in:
Mike Jolley 2014-01-31 04:46:16 -08:00
commit 09f3af799e
33 changed files with 54 additions and 54 deletions

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function(){
jQuery(function(){
jQuery('#the-list').on('click', '.editinline', function(){
inlineEditPost.revert();
@ -113,4 +113,4 @@ jQuery(document).ready(function(){
jQuery(this).closest('li').siblings().find('input:checked').removeAttr('checked');
});
});
});

View File

@ -1 +1 @@
jQuery(document).ready(function(){jQuery("#the-list").on("click",".editinline",function(){inlineEditPost.revert();var e=jQuery(this).closest("tr").attr("id");e=e.replace("post-","");var t=jQuery("#woocommerce_inline_"+e),n=t.find(".sku").text(),r=t.find(".regular_price").text(),i=t.find(".sale_price").text(),s=t.find(".weight").text(),o=t.find(".length").text(),u=t.find(".width").text(),a=t.find(".height").text(),f=t.find(".visibility").text(),l=t.find(".stock_status").text(),c=t.find(".stock").text(),h=t.find(".featured").text(),p=t.find(".manage_stock").text(),d=t.find(".menu_order").text(),v=t.find(".tax_status").text(),m=t.find(".tax_class").text(),g=t.find(".backorders").text();jQuery('input[name="_sku"]',".inline-edit-row").val(n);jQuery('input[name="_regular_price"]',".inline-edit-row").val(r);jQuery('input[name="_sale_price"]',".inline-edit-row").val(i);jQuery('input[name="_weight"]',".inline-edit-row").val(s);jQuery('input[name="_length"]',".inline-edit-row").val(o);jQuery('input[name="_width"]',".inline-edit-row").val(u);jQuery('input[name="_height"]',".inline-edit-row").val(a);jQuery('input[name="_stock"]',".inline-edit-row").val(c);jQuery('input[name="menu_order"]',".inline-edit-row").val(d);jQuery('select[name="_tax_status"] option[value="'+v+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_tax_class"] option[value="'+m+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_visibility"] option, select[name="_stock_status"] option, select[name="_backorders"] option').removeAttr("selected");jQuery('select[name="_visibility"] option[value="'+f+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_stock_status"] option[value="'+l+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_backorders"] option[value="'+g+'"]',".inline-edit-row").attr("selected","selected");h=="yes"?jQuery('input[name="_featured"]',".inline-edit-row").attr("checked","checked"):jQuery('input[name="_featured"]',".inline-edit-row").removeAttr("checked");if(p=="yes"){jQuery(".stock_qty_field",".inline-edit-row").show().removeAttr("style");jQuery('input[name="_manage_stock"]',".inline-edit-row").attr("checked","checked")}else{jQuery(".stock_qty_field",".inline-edit-row").hide();jQuery('input[name="_manage_stock"]',".inline-edit-row").removeAttr("checked")}var y=t.find(".product_type").text(),b=t.find(".product_is_virtual").text();y=="simple"||y=="external"?jQuery(".price_fields",".inline-edit-row").show().removeAttr("style"):jQuery(".price_fields",".inline-edit-row").hide();b=="yes"?jQuery(".dimension_fields",".inline-edit-row").hide():jQuery(".dimension_fields",".inline-edit-row").show().removeAttr("style");y=="grouped"?jQuery(".stock_fields",".inline-edit-row").hide():jQuery(".stock_fields",".inline-edit-row").show().removeAttr("style")});jQuery("#the-list").on("change",'.inline-edit-row input[name="_manage_stock"]',function(){jQuery(this).is(":checked")?jQuery(".stock_qty_field",".inline-edit-row").show().removeAttr("style"):jQuery(".stock_qty_field",".inline-edit-row").hide()});jQuery("#wpbody").on("click","#doaction, #doaction2",function(){jQuery("input.text",".inline-edit-row").val("");jQuery("#woocommerce-fields select").prop("selectedIndex",0);jQuery("#woocommerce-fields-bulk .inline-edit-group .alignright").hide()});jQuery("#wpbody").on("change","#woocommerce-fields-bulk .inline-edit-group .change_to",function(){jQuery(this).val()>0?jQuery(this).closest("div").find(".alignright").show():jQuery(this).closest("div").find(".alignright").hide()});jQuery(".product_shipping_class-checklist input").change(function(){jQuery(this).closest("li").siblings().find("input:checked").removeAttr("checked")})});
jQuery(function(){jQuery("#the-list").on("click",".editinline",function(){inlineEditPost.revert();var e=jQuery(this).closest("tr").attr("id");e=e.replace("post-","");var t=jQuery("#woocommerce_inline_"+e),n=t.find(".sku").text(),r=t.find(".regular_price").text(),i=t.find(".sale_price").text(),s=t.find(".weight").text(),o=t.find(".length").text(),u=t.find(".width").text(),a=t.find(".height").text(),f=t.find(".visibility").text(),l=t.find(".stock_status").text(),c=t.find(".stock").text(),h=t.find(".featured").text(),p=t.find(".manage_stock").text(),d=t.find(".menu_order").text(),v=t.find(".tax_status").text(),m=t.find(".tax_class").text(),g=t.find(".backorders").text();jQuery('input[name="_sku"]',".inline-edit-row").val(n);jQuery('input[name="_regular_price"]',".inline-edit-row").val(r);jQuery('input[name="_sale_price"]',".inline-edit-row").val(i);jQuery('input[name="_weight"]',".inline-edit-row").val(s);jQuery('input[name="_length"]',".inline-edit-row").val(o);jQuery('input[name="_width"]',".inline-edit-row").val(u);jQuery('input[name="_height"]',".inline-edit-row").val(a);jQuery('input[name="_stock"]',".inline-edit-row").val(c);jQuery('input[name="menu_order"]',".inline-edit-row").val(d);jQuery('select[name="_tax_status"] option[value="'+v+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_tax_class"] option[value="'+m+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_visibility"] option, select[name="_stock_status"] option, select[name="_backorders"] option').removeAttr("selected");jQuery('select[name="_visibility"] option[value="'+f+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_stock_status"] option[value="'+l+'"]',".inline-edit-row").attr("selected","selected");jQuery('select[name="_backorders"] option[value="'+g+'"]',".inline-edit-row").attr("selected","selected");h=="yes"?jQuery('input[name="_featured"]',".inline-edit-row").attr("checked","checked"):jQuery('input[name="_featured"]',".inline-edit-row").removeAttr("checked");if(p=="yes"){jQuery(".stock_qty_field",".inline-edit-row").show().removeAttr("style");jQuery('input[name="_manage_stock"]',".inline-edit-row").attr("checked","checked")}else{jQuery(".stock_qty_field",".inline-edit-row").hide();jQuery('input[name="_manage_stock"]',".inline-edit-row").removeAttr("checked")}var y=t.find(".product_type").text(),b=t.find(".product_is_virtual").text();y=="simple"||y=="external"?jQuery(".price_fields",".inline-edit-row").show().removeAttr("style"):jQuery(".price_fields",".inline-edit-row").hide();b=="yes"?jQuery(".dimension_fields",".inline-edit-row").hide():jQuery(".dimension_fields",".inline-edit-row").show().removeAttr("style");y=="grouped"?jQuery(".stock_fields",".inline-edit-row").hide():jQuery(".stock_fields",".inline-edit-row").show().removeAttr("style")});jQuery("#the-list").on("change",'.inline-edit-row input[name="_manage_stock"]',function(){jQuery(this).is(":checked")?jQuery(".stock_qty_field",".inline-edit-row").show().removeAttr("style"):jQuery(".stock_qty_field",".inline-edit-row").hide()});jQuery("#wpbody").on("click","#doaction, #doaction2",function(){jQuery("input.text",".inline-edit-row").val("");jQuery("#woocommerce-fields select").prop("selectedIndex",0);jQuery("#woocommerce-fields-bulk .inline-edit-group .alignright").hide()});jQuery("#wpbody").on("change","#woocommerce-fields-bulk .inline-edit-group .change_to",function(){jQuery(this).val()>0?jQuery(this).closest("div").find(".alignright").show():jQuery(this).closest("div").find(".alignright").hide()});jQuery(".product_shipping_class-checklist input").change(function(){jQuery(this).closest("li").siblings().find("input:checked").removeAttr("checked")})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
function showTooltip(x, y, contents) {
jQuery('<div class="chart-tooltip">' + contents + '</div>').css( {
@ -221,4 +221,4 @@ jQuery(document).ready(function($) {
$(this).attr( 'href', encodeURI( csv_data ) );
return true;
});
});
});

View File

@ -1 +1 @@
jQuery(document).ready(function(e){function t(e,t,n){jQuery('<div class="chart-tooltip">'+n+"</div>").css({top:t-16,left:e+20}).appendTo("body").fadeIn(200)}var n=null,r=null;jQuery(".chart-placeholder").bind("plothover",function(e,i,s){if(s){if(n!=s.dataIndex||r!=s.seriesIndex){n=s.dataIndex;r=s.seriesIndex;jQuery(".chart-tooltip").remove();if(s.series.points.show||s.series.enable_tooltip){var o=s.series.data[s.dataIndex][1];tooltip_content="";s.series.prepend_label&&(tooltip_content=tooltip_content+s.series.label+": ");s.series.prepend_tooltip&&(tooltip_content+=s.series.prepend_tooltip);tooltip_content+=o;s.series.append_tooltip&&(tooltip_content+=s.series.append_tooltip);s.series.pie.show?t(i.pageX,i.pageY,tooltip_content):t(s.pageX,s.pageY,tooltip_content)}}}else{jQuery(".chart-tooltip").remove();n=null}});e(".wc_sparkline.bars").each(function(){var t=e(this).data("sparkline"),n={grid:{show:!1}},r=[{data:t,color:e(this).data("color"),bars:{fillColor:e(this).data("color"),fill:!0,show:!0,lineWidth:1,barWidth:e(this).data("barwidth"),align:"center"},shadowSize:0}],i=e.plot(e(this),r,n)});e(".wc_sparkline.lines").each(function(){var t=e(this).data("sparkline"),n={grid:{show:!1}},r=[{data:t,color:e(this).data("color"),lines:{fill:!1,show:!0,lineWidth:1,align:"center"},shadowSize:0}],i=e.plot(e(this),r,n)});var i=jQuery(".range_datepicker").datepicker({defaultDate:"",dateFormat:"yy-mm-dd",numberOfMonths:1,maxDate:"+0D",showButtonPanel:!0,showOn:"focus",buttonImageOnly:!0,onSelect:function(e){var t=jQuery(this).is(".from")?"minDate":"maxDate",n=jQuery(this).data("datepicker"),r=jQuery.datepicker.parseDate(n.settings.dateFormat||jQuery.datepicker._defaults.dateFormat,e,n.settings);i.not(this).datepicker("option",t,r)}});e(".export_csv").click(function(){var t=e(this).data("exclude_series")||"";t=t.toString();t=t.split(",");var n=e(this).data("xaxes"),r=e(this).data("groupby"),i=e(this).data("export"),s="data:application/csv;charset=utf-8,";if(i=="table"){e(this).closest("div").find("thead tr,tbody tr").each(function(){e(this).find("th,td").each(function(){value=e(this).text();value=value.replace("[?]","");s+='"'+value+'"'+","});s=s.substring(0,s.length-1);s+="\n"});e(this).closest("div").find("tfoot tr").each(function(){e(this).find("th,td").each(function(){value=e(this).text();value=value.replace("[?]","");s+='"'+value+'"'+",";if(e(this).attr("colspan")>0)for(h=1;h<e(this).attr("colspan");h++)s+='"",'});s=s.substring(0,s.length-1);s+="\n"})}else{if(!window.main_chart)return!1;var o=window.main_chart.getData(),u=[];s+=n+",";e.each(o,function(n,r){(!t||e.inArray(n.toString(),t)==-1)&&u.push(r)});for(var a=0;a<u.length;++a)s+=u[a].label+",";s=s.substring(0,s.length-1);s+="\n";var f={};for(var a=0;a<u.length;++a){var l=u[a].data;for(var c=0;c<l.length;++c){f[l[c][0]]=new Array;for(var h=0;h<u.length;++h)f[l[c][0]].push(0)}}for(var a=0;a<u.length;++a){var l=u[a].data;for(var c=0;c<l.length;++c)f[l[c][0]][a]=l[c][1]}e.each(f,function(e,t){var n=new Date(parseInt(e));r=="day"?s+=n.getFullYear()+"-"+parseInt(n.getMonth()+1)+"-"+n.getDate()+",":s+=n.getFullYear()+"-"+parseInt(n.getMonth()+1)+",";for(var i=0;i<t.length;++i){val=t[i];Math.round(val)!=val&&(val=val.toFixed(2));s+=val+","}s=s.substring(0,s.length-1);s+="\n"})}e(this).attr("href",encodeURI(s));return!0})});
jQuery(function(e){function t(e,t,n){jQuery('<div class="chart-tooltip">'+n+"</div>").css({top:t-16,left:e+20}).appendTo("body").fadeIn(200)}var n=null,r=null;jQuery(".chart-placeholder").bind("plothover",function(e,i,s){if(s){if(n!=s.dataIndex||r!=s.seriesIndex){n=s.dataIndex;r=s.seriesIndex;jQuery(".chart-tooltip").remove();if(s.series.points.show||s.series.enable_tooltip){var o=s.series.data[s.dataIndex][1];tooltip_content="";s.series.prepend_label&&(tooltip_content=tooltip_content+s.series.label+": ");s.series.prepend_tooltip&&(tooltip_content+=s.series.prepend_tooltip);tooltip_content+=o;s.series.append_tooltip&&(tooltip_content+=s.series.append_tooltip);s.series.pie.show?t(i.pageX,i.pageY,tooltip_content):t(s.pageX,s.pageY,tooltip_content)}}}else{jQuery(".chart-tooltip").remove();n=null}});e(".wc_sparkline.bars").each(function(){var t=e(this).data("sparkline"),n={grid:{show:!1}},r=[{data:t,color:e(this).data("color"),bars:{fillColor:e(this).data("color"),fill:!0,show:!0,lineWidth:1,barWidth:e(this).data("barwidth"),align:"center"},shadowSize:0}],i=e.plot(e(this),r,n)});e(".wc_sparkline.lines").each(function(){var t=e(this).data("sparkline"),n={grid:{show:!1}},r=[{data:t,color:e(this).data("color"),lines:{fill:!1,show:!0,lineWidth:1,align:"center"},shadowSize:0}],i=e.plot(e(this),r,n)});var i=jQuery(".range_datepicker").datepicker({defaultDate:"",dateFormat:"yy-mm-dd",numberOfMonths:1,maxDate:"+0D",showButtonPanel:!0,showOn:"focus",buttonImageOnly:!0,onSelect:function(e){var t=jQuery(this).is(".from")?"minDate":"maxDate",n=jQuery(this).data("datepicker"),r=jQuery.datepicker.parseDate(n.settings.dateFormat||jQuery.datepicker._defaults.dateFormat,e,n.settings);i.not(this).datepicker("option",t,r)}});e(".export_csv").click(function(){var t=e(this).data("exclude_series")||"";t=t.toString();t=t.split(",");var n=e(this).data("xaxes"),r=e(this).data("groupby"),i=e(this).data("export"),s="data:application/csv;charset=utf-8,";if(i=="table"){e(this).closest("div").find("thead tr,tbody tr").each(function(){e(this).find("th,td").each(function(){value=e(this).text();value=value.replace("[?]","");s+='"'+value+'"'+","});s=s.substring(0,s.length-1);s+="\n"});e(this).closest("div").find("tfoot tr").each(function(){e(this).find("th,td").each(function(){value=e(this).text();value=value.replace("[?]","");s+='"'+value+'"'+",";if(e(this).attr("colspan")>0)for(h=1;h<e(this).attr("colspan");h++)s+='"",'});s=s.substring(0,s.length-1);s+="\n"})}else{if(!window.main_chart)return!1;var o=window.main_chart.getData(),u=[];s+=n+",";e.each(o,function(n,r){(!t||e.inArray(n.toString(),t)==-1)&&u.push(r)});for(var a=0;a<u.length;++a)s+=u[a].label+",";s=s.substring(0,s.length-1);s+="\n";var f={};for(var a=0;a<u.length;++a){var l=u[a].data;for(var c=0;c<l.length;++c){f[l[c][0]]=new Array;for(var h=0;h<u.length;++h)f[l[c][0]].push(0)}}for(var a=0;a<u.length;++a){var l=u[a].data;for(var c=0;c<l.length;++c)f[l[c][0]][a]=l[c][1]}e.each(f,function(e,t){var n=new Date(parseInt(e));r=="day"?s+=n.getFullYear()+"-"+parseInt(n.getMonth()+1)+"-"+n.getDate()+",":s+=n.getFullYear()+"-"+parseInt(n.getMonth()+1)+",";for(var i=0;i<t.length;++i){val=t[i];Math.round(val)!=val&&(val=val.toFixed(2));s+=val+","}s=s.substring(0,s.length-1);s+="\n"})}e(this).attr("href",encodeURI(s));return!0})});

View File

@ -1,8 +1,8 @@
/* Modifided script from the simple-page-ordering plugin */
jQuery(document).ready(function($) {
jQuery(function($) {
$('table.widefat.wp-list-table tbody th, table.widefat tbody td').css('cursor','move');
$("table.widefat.wp-list-table").sortable({
items: 'tbody tr:not(.inline-edit-row)',
cursor: 'move',
@ -17,47 +17,47 @@ jQuery(document).ready(function($) {
ui.item.children('td,th').css('border-bottom-width','0');
ui.item.css( 'outline', '1px solid #aaa' );
},
stop: function(event, ui) {
stop: function(event, ui) {
ui.item.removeAttr('style');
ui.item.children('td,th').css('border-bottom-width','1px');
ui.item.children('td,th').css('border-bottom-width','1px');
},
update: function(event, ui) {
update: function(event, ui) {
var termid = ui.item.find('.check-column input').val(); // this post id
var termparent = ui.item.find('.parent').html(); // post parent
var prevtermid = ui.item.prev().find('.check-column input').val();
var nexttermid = ui.item.next().find('.check-column input').val();
// can only sort in same tree
var prevtermparent = undefined;
if ( prevtermid != undefined ) {
var prevtermparent = ui.item.prev().find('.parent').html();
if ( prevtermparent != termparent) prevtermid = undefined;
}
var nexttermparent = undefined;
if ( nexttermid != undefined ) {
nexttermparent = ui.item.next().find('.parent').html();
if ( nexttermparent != termparent) nexttermid = undefined;
}
// if previous and next not at same tree level, or next not at same tree level and the previous is the parent of the next, or just moved item beneath its own children
}
// if previous and next not at same tree level, or next not at same tree level and the previous is the parent of the next, or just moved item beneath its own children
if ( ( prevtermid == undefined && nexttermid == undefined ) || ( nexttermid == undefined && nexttermparent == prevtermid ) || ( nexttermid != undefined && prevtermparent == termid ) ) {
$("table.widefat.wp-list-table").sortable('cancel');
return;
}
// show spinner
ui.item.find('.check-column input').hide().after('<img alt="processing" src="images/wpspin_light.gif" class="waiting" style="margin-left: 6px;" />');
// go do the sorting stuff via ajax
$.post( ajaxurl, { action: 'woocommerce_term_ordering', id: termid, nextid: nexttermid, thetaxonomy: woocommerce_term_ordering_params.taxonomy }, function(response){
$.post( ajaxurl, { action: 'woocommerce_term_ordering', id: termid, nextid: nexttermid, thetaxonomy: woocommerce_term_ordering_params.taxonomy }, function(response){
if ( response == 'children' ) window.location.reload();
else {
ui.item.find('.check-column input').show().siblings('img').remove();
}
});
// fix cell colors
$( 'table.widefat tbody tr' ).each(function(){
var i = jQuery('table.widefat tbody tr').index(this);

View File

@ -1 +1 @@
/* Modifided script from the simple-page-ordering plugin */jQuery(document).ready(function(e){e("table.widefat.wp-list-table tbody th, table.widefat tbody td").css("cursor","move");e("table.widefat.wp-list-table").sortable({items:"tbody tr:not(.inline-edit-row)",cursor:"move",axis:"y",forcePlaceholderSize:!0,helper:"clone",opacity:.65,placeholder:"product-cat-placeholder",scrollSensitivity:40,start:function(e,t){t.item.hasClass("alternate")||t.item.css("background-color","#ffffff");t.item.children("td,th").css("border-bottom-width","0");t.item.css("outline","1px solid #aaa")},stop:function(e,t){t.item.removeAttr("style");t.item.children("td,th").css("border-bottom-width","1px")},update:function(t,n){var r=n.item.find(".check-column input").val(),i=n.item.find(".parent").html(),s=n.item.prev().find(".check-column input").val(),o=n.item.next().find(".check-column input").val(),u=undefined;if(s!=undefined){var u=n.item.prev().find(".parent").html();u!=i&&(s=undefined)}var a=undefined;if(o!=undefined){a=n.item.next().find(".parent").html();a!=i&&(o=undefined)}if(s==undefined&&o==undefined||o==undefined&&a==s||o!=undefined&&u==r){e("table.widefat.wp-list-table").sortable("cancel");return}n.item.find(".check-column input").hide().after('<img alt="processing" src="images/wpspin_light.gif" class="waiting" style="margin-left: 6px;" />');e.post(ajaxurl,{action:"woocommerce_term_ordering",id:r,nextid:o,thetaxonomy:woocommerce_term_ordering_params.taxonomy},function(e){e=="children"?window.location.reload():n.item.find(".check-column input").show().siblings("img").remove()});e("table.widefat tbody tr").each(function(){var e=jQuery("table.widefat tbody tr").index(this);e%2==0?jQuery(this).addClass("alternate"):jQuery(this).removeClass("alternate")})}})});
/* Modifided script from the simple-page-ordering plugin */jQuery(function(e){e("table.widefat.wp-list-table tbody th, table.widefat tbody td").css("cursor","move");e("table.widefat.wp-list-table").sortable({items:"tbody tr:not(.inline-edit-row)",cursor:"move",axis:"y",forcePlaceholderSize:!0,helper:"clone",opacity:.65,placeholder:"product-cat-placeholder",scrollSensitivity:40,start:function(e,t){t.item.hasClass("alternate")||t.item.css("background-color","#ffffff");t.item.children("td,th").css("border-bottom-width","0");t.item.css("outline","1px solid #aaa")},stop:function(e,t){t.item.removeAttr("style");t.item.children("td,th").css("border-bottom-width","1px")},update:function(t,n){var r=n.item.find(".check-column input").val(),i=n.item.find(".parent").html(),s=n.item.prev().find(".check-column input").val(),o=n.item.next().find(".check-column input").val(),u=undefined;if(s!=undefined){var u=n.item.prev().find(".parent").html();u!=i&&(s=undefined)}var a=undefined;if(o!=undefined){a=n.item.next().find(".parent").html();a!=i&&(o=undefined)}if(s==undefined&&o==undefined||o==undefined&&a==s||o!=undefined&&u==r){e("table.widefat.wp-list-table").sortable("cancel");return}n.item.find(".check-column input").hide().after('<img alt="processing" src="images/wpspin_light.gif" class="waiting" style="margin-left: 6px;" />');e.post(ajaxurl,{action:"woocommerce_term_ordering",id:r,nextid:o,thetaxonomy:woocommerce_term_ordering_params.taxonomy},function(e){e=="children"?window.location.reload():n.item.find(".check-column input").show().siblings("img").remove()});e("table.widefat tbody tr").each(function(){var e=jQuery("table.widefat tbody tr").index(this);e%2==0?jQuery(this).addClass("alternate"):jQuery(this).removeClass("alternate")})}})});

View File

@ -1,6 +1,6 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// Fix Chosen for RTL
$('.chosen_select, .chosen_select_nostd, .product_attributes select.multiselect, select.country_select, select.state_select, select#dropdown_shop_coupon_type, select[name=m], select#dropdown_shop_order_status').addClass('chosen-rtl');
});
});

View File

@ -1 +1 @@
jQuery(document).ready(function(e){e(".chosen_select, .chosen_select_nostd, .product_attributes select.multiselect, select.country_select, select.state_select, select#dropdown_shop_coupon_type, select[name=m], select#dropdown_shop_order_status").addClass("chosen-rtl")});
jQuery(function(e){e(".chosen_select, .chosen_select_nostd, .product_attributes select.multiselect, select.country_select, select.state_select, select#dropdown_shop_coupon_type, select[name=m], select#dropdown_shop_order_status").addClass("chosen-rtl")});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($){
jQuery(function($){
// woocommerce_params is required to continue, ensure the object exists
if (typeof woocommerce_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof woocommerce_params=="undefined")return!1;e("#add_payment_method").on("click init_add_payment_method",".payment_methods input.input-radio",function(){if(e(".payment_methods input.input-radio").length>1){var t=e("div.payment_box."+e(this).attr("ID"));if(e(this).is(":checked")&&!t.is(":visible")){e("div.payment_box").filter(":visible").slideUp(250);e(this).is(":checked")&&e("div.payment_box."+e(this).attr("ID")).slideDown(250)}}else e("div.payment_box").show()}).find("input[name=payment_method]:checked").click();e("#add_payment_method").submit(function(){e("#add_payment_method").block({message:null,overlayCSS:{background:"#fff url("+woocommerce_params.plugin_url+"/assets/images/ajax-loader.gif) no-repeat center",backgroundSize:"16px 16px",opacity:.6}})});e("body").trigger("init_add_payment_method")});
jQuery(function(e){if(typeof woocommerce_params=="undefined")return!1;e("#add_payment_method").on("click init_add_payment_method",".payment_methods input.input-radio",function(){if(e(".payment_methods input.input-radio").length>1){var t=e("div.payment_box."+e(this).attr("ID"));if(e(this).is(":checked")&&!t.is(":visible")){e("div.payment_box").filter(":visible").slideUp(250);e(this).is(":checked")&&e("div.payment_box."+e(this).attr("ID")).slideDown(250)}}else e("div.payment_box").show()}).find("input[name=payment_method]:checked").click();e("#add_payment_method").submit(function(){e("#add_payment_method").block({message:null,overlayCSS:{background:"#fff url("+woocommerce_params.plugin_url+"/assets/images/ajax-loader.gif) no-repeat center",backgroundSize:"16px 16px",opacity:.6}})});e("body").trigger("init_add_payment_method")});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// wc_add_to_cart_params is required to continue, ensure the object exists
if (typeof wc_add_to_cart_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof wc_add_to_cart_params=="undefined")return!1;e(document).on("click",".add_to_cart_button",function(){var t=e(this);if(t.is(".product_type_simple")){if(!t.attr("data-product_id"))return!0;t.removeClass("added");t.addClass("loading");var n={action:"woocommerce_add_to_cart",product_id:t.attr("data-product_id"),quantity:t.attr("data-quantity")};e("body").trigger("adding_to_cart",[t,n]);e.post(wc_add_to_cart_params.ajax_url,n,function(n){if(!n)return;var r=window.location.toString();r=r.replace("add-to-cart","added-to-cart");if(n.error&&n.product_url){window.location=n.product_url;return}if(wc_add_to_cart_params.cart_redirect_after_add=="yes"){window.location=wc_add_to_cart_params.cart_url;return}t.removeClass("loading");fragments=n.fragments;cart_hash=n.cart_hash;fragments&&e.each(fragments,function(t,n){e(t).addClass("updating")});e(".shop_table.cart, .updating, .cart_totals").fadeTo("400","0.6").block({message:null,overlayCSS:{background:"transparent url("+wc_add_to_cart_params.ajax_loader_url+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}});t.addClass("added");!wc_add_to_cart_params.is_cart&&t.parent().find(".added_to_cart").size()==0&&t.after(' <a href="'+wc_add_to_cart_params.cart_url+'" class="added_to_cart wc-forward" title="'+wc_add_to_cart_params.i18n_view_cart+'">'+wc_add_to_cart_params.i18n_view_cart+"</a>");fragments&&e.each(fragments,function(t,n){e(t).replaceWith(n)});e(".widget_shopping_cart, .updating").stop(!0).css("opacity","1").unblock();e(".shop_table.cart").load(r+" .shop_table.cart:eq(0) > *",function(){e("div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)").addClass("buttons_added").append('<input type="button" value="+" id="add1" class="plus" />').prepend('<input type="button" value="-" id="minus1" class="minus" />');e(".shop_table.cart").stop(!0).css("opacity","1").unblock();e("body").trigger("cart_page_refreshed")});e(".cart_totals").load(r+" .cart_totals:eq(0) > *",function(){e(".cart_totals").stop(!0).css("opacity","1").unblock()});e("body").trigger("added_to_cart",[fragments,cart_hash])});return!1}return!0})});
jQuery(function(e){if(typeof wc_add_to_cart_params=="undefined")return!1;e(document).on("click",".add_to_cart_button",function(){var t=e(this);if(t.is(".product_type_simple")){if(!t.attr("data-product_id"))return!0;t.removeClass("added");t.addClass("loading");var n={action:"woocommerce_add_to_cart",product_id:t.attr("data-product_id"),quantity:t.attr("data-quantity")};e("body").trigger("adding_to_cart",[t,n]);e.post(wc_add_to_cart_params.ajax_url,n,function(n){if(!n)return;var r=window.location.toString();r=r.replace("add-to-cart","added-to-cart");if(n.error&&n.product_url){window.location=n.product_url;return}if(wc_add_to_cart_params.cart_redirect_after_add=="yes"){window.location=wc_add_to_cart_params.cart_url;return}t.removeClass("loading");fragments=n.fragments;cart_hash=n.cart_hash;fragments&&e.each(fragments,function(t,n){e(t).addClass("updating")});e(".shop_table.cart, .updating, .cart_totals").fadeTo("400","0.6").block({message:null,overlayCSS:{background:"transparent url("+wc_add_to_cart_params.ajax_loader_url+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}});t.addClass("added");!wc_add_to_cart_params.is_cart&&t.parent().find(".added_to_cart").size()==0&&t.after(' <a href="'+wc_add_to_cart_params.cart_url+'" class="added_to_cart wc-forward" title="'+wc_add_to_cart_params.i18n_view_cart+'">'+wc_add_to_cart_params.i18n_view_cart+"</a>");fragments&&e.each(fragments,function(t,n){e(t).replaceWith(n)});e(".widget_shopping_cart, .updating").stop(!0).css("opacity","1").unblock();e(".shop_table.cart").load(r+" .shop_table.cart:eq(0) > *",function(){e("div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)").addClass("buttons_added").append('<input type="button" value="+" id="add1" class="plus" />').prepend('<input type="button" value="-" id="minus1" class="minus" />');e(".shop_table.cart").stop(!0).css("opacity","1").unblock();e("body").trigger("cart_page_refreshed")});e(".cart_totals").load(r+" .cart_totals:eq(0) > *",function(){e(".cart_totals").stop(!0).css("opacity","1").unblock()});e("body").trigger("added_to_cart",[fragments,cart_hash])});return!1}return!0})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
var locale_json = wc_address_i18n_params.locale.replace(/&quot;/g, '"');
var locale = $.parseJSON( locale_json );
@ -91,4 +91,4 @@ jQuery(document).ready(function($) {
});
});
});

View File

@ -1 +1 @@
jQuery(document).ready(function(e){var t=wc_address_i18n_params.locale.replace(/&quot;/g,'"'),n=e.parseJSON(t),r=' <abbr class="required" title="'+wc_address_i18n_params.i18n_required_text+'">*</abbr>';e("body").bind("country_to_state_changing",function(t,i,s){var o=s;if(typeof n[i]!="undefined")var u=n[i];else var u=n["default"];var a=e.parseJSON(wc_address_i18n_params.locale_fields);e.each(a,function(e,t){var i=o.find(t);if(u[e]){u[e].label&&i.find("label").html(u[e].label);u[e].placeholder&&i.find("input").attr("placeholder",u[e].placeholder);i.find("label abbr").remove();typeof u[e]["required"]=="undefined"&&n["default"][e]["required"]==1?i.find("label").append(r):u[e]["required"]==1&&i.find("label").append(r);e!=="state"&&(u[e]["hidden"]==1?i.hide().find("input").val(""):i.show())}else if(n["default"][e]){n["default"][e]["required"]==1&&i.find("label abbr").size()==0&&i.find("label").append(r);e!=="state"&&(typeof n["default"][e]["hidden"]=="undefined"||n["default"][e]["hidden"]==0?i.show():n["default"][e]["hidden"]==1&&i.hide().find("input").val(""))}});var f=o.find("#billing_postcode_field, #shipping_postcode_field"),l=o.find("#billing_city_field, #shipping_city_field"),c=o.find("#billing_state_field, #shipping_state_field");if(!f.attr("data-o_class")){f.attr("data-o_class",f.attr("class"));l.attr("data-o_class",l.attr("class"));c.attr("data-o_class",c.attr("class"))}if(u.postcode_before_city){f.add(l).add(c).removeClass("form-row-first form-row-last").addClass("form-row-wide");f.insertBefore(l)}else{f.attr("class",f.attr("data-o_class"));l.attr("class",l.attr("data-o_class"));c.attr("class",c.attr("data-o_class"));f.insertAfter(c)}})});
jQuery(function(e){var t=wc_address_i18n_params.locale.replace(/&quot;/g,'"'),n=e.parseJSON(t),r=' <abbr class="required" title="'+wc_address_i18n_params.i18n_required_text+'">*</abbr>';e("body").bind("country_to_state_changing",function(t,i,s){var o=s;if(typeof n[i]!="undefined")var u=n[i];else var u=n["default"];var a=e.parseJSON(wc_address_i18n_params.locale_fields);e.each(a,function(e,t){var i=o.find(t);if(u[e]){u[e].label&&i.find("label").html(u[e].label);u[e].placeholder&&i.find("input").attr("placeholder",u[e].placeholder);i.find("label abbr").remove();typeof u[e]["required"]=="undefined"&&n["default"][e]["required"]==1?i.find("label").append(r):u[e]["required"]==1&&i.find("label").append(r);e!=="state"&&(u[e]["hidden"]==1?i.hide().find("input").val(""):i.show())}else if(n["default"][e]){n["default"][e]["required"]==1&&i.find("label abbr").size()==0&&i.find("label").append(r);e!=="state"&&(typeof n["default"][e]["hidden"]=="undefined"||n["default"][e]["hidden"]==0?i.show():n["default"][e]["hidden"]==1&&i.hide().find("input").val(""))}});var f=o.find("#billing_postcode_field, #shipping_postcode_field"),l=o.find("#billing_city_field, #shipping_city_field"),c=o.find("#billing_state_field, #shipping_state_field");if(!f.attr("data-o_class")){f.attr("data-o_class",f.attr("class"));l.attr("data-o_class",l.attr("class"));c.attr("data-o_class",c.attr("class"))}if(u.postcode_before_city){f.add(l).add(c).removeClass("form-row-first form-row-last").addClass("form-row-wide");f.insertBefore(l)}else{f.attr("class",f.attr("data-o_class"));l.attr("class",l.attr("data-o_class"));c.attr("class",c.attr("data-o_class"));f.insertAfter(c)}})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// wc_cart_fragments_params is required to continue, ensure the object exists
if (typeof wc_cart_fragments_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof wc_cart_fragments_params=="undefined")return!1;$supports_html5_storage="sessionStorage"in window&&window.sessionStorage!==null;$fragment_refresh={url:wc_cart_fragments_params.ajax_url,type:"POST",data:{action:"woocommerce_get_refreshed_fragments"},success:function(t){if(t&&t.fragments){e.each(t.fragments,function(t,n){e(t).replaceWith(n)});if($supports_html5_storage){sessionStorage.setItem(wc_cart_fragments_params.fragment_name,JSON.stringify(t.fragments));sessionStorage.setItem("wc_cart_hash",t.cart_hash)}e("body").trigger("wc_fragments_refreshed")}}};if($supports_html5_storage){e("body").bind("added_to_cart",function(e,t,n){sessionStorage.setItem(wc_cart_fragments_params.fragment_name,JSON.stringify(t));sessionStorage.setItem("wc_cart_hash",n)});try{var t=e.parseJSON(sessionStorage.getItem(wc_cart_fragments_params.fragment_name)),n=sessionStorage.getItem("wc_cart_hash"),r=e.cookie("woocommerce_cart_hash");if(n==null||n==undefined||n=="")n="";if(r==null||r==undefined||r=="")r="";if(!t||!t["div.widget_shopping_cart_content"]||n!=r)throw"No fragment";e.each(t,function(t,n){e(t).replaceWith(n)});e("body").trigger("wc_fragments_loaded")}catch(i){e.ajax($fragment_refresh)}}else e.ajax($fragment_refresh);e.cookie("woocommerce_items_in_cart")>0?e(".hide_cart_widget_if_empty").closest(".widget_shopping_cart").show():e(".hide_cart_widget_if_empty").closest(".widget_shopping_cart").hide();e("body").bind("adding_to_cart",function(){e(".hide_cart_widget_if_empty").closest(".widget_shopping_cart").show()})});
jQuery(function(e){if(typeof wc_cart_fragments_params=="undefined")return!1;$supports_html5_storage="sessionStorage"in window&&window.sessionStorage!==null;$fragment_refresh={url:wc_cart_fragments_params.ajax_url,type:"POST",data:{action:"woocommerce_get_refreshed_fragments"},success:function(t){if(t&&t.fragments){e.each(t.fragments,function(t,n){e(t).replaceWith(n)});if($supports_html5_storage){sessionStorage.setItem(wc_cart_fragments_params.fragment_name,JSON.stringify(t.fragments));sessionStorage.setItem("wc_cart_hash",t.cart_hash)}e("body").trigger("wc_fragments_refreshed")}}};if($supports_html5_storage){e("body").bind("added_to_cart",function(e,t,n){sessionStorage.setItem(wc_cart_fragments_params.fragment_name,JSON.stringify(t));sessionStorage.setItem("wc_cart_hash",n)});try{var t=e.parseJSON(sessionStorage.getItem(wc_cart_fragments_params.fragment_name)),n=sessionStorage.getItem("wc_cart_hash"),r=e.cookie("woocommerce_cart_hash");if(n==null||n==undefined||n=="")n="";if(r==null||r==undefined||r=="")r="";if(!t||!t["div.widget_shopping_cart_content"]||n!=r)throw"No fragment";e.each(t,function(t,n){e(t).replaceWith(n)});e("body").trigger("wc_fragments_loaded")}catch(i){e.ajax($fragment_refresh)}}else e.ajax($fragment_refresh);e.cookie("woocommerce_items_in_cart")>0?e(".hide_cart_widget_if_empty").closest(".widget_shopping_cart").show():e(".hide_cart_widget_if_empty").closest(".widget_shopping_cart").hide();e("body").bind("adding_to_cart",function(){e(".hide_cart_widget_if_empty").closest(".widget_shopping_cart").show()})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// wc_cart_params is required to continue, ensure the object exists
if (typeof wc_cart_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof wc_cart_params==="undefined")return false;e(document).on("click",".shipping-calculator-button",function(){e(".shipping-calculator-form").slideToggle("slow");return false}).on("change","select.shipping_method, input[name^=shipping_method]",function(){var t=[];e("select.shipping_method, input[name^=shipping_method][type=radio]:checked, input[name^=shipping_method][type=hidden]").each(function(n,r){t[e(this).data("index")]=e(this).val()});e("div.cart_totals").block({message:null,overlayCSS:{background:"#fff url("+wc_cart_params.ajax_loader_url+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}});var n={action:"woocommerce_update_shipping_method",security:wc_cart_params.update_shipping_method_nonce,shipping_method:t};e.post(wc_cart_params.ajax_url,n,function(t){e("div.cart_totals").replaceWith(t);e("body").trigger("updated_shipping_method")})});e(".shipping-calculator-form").hide()})
jQuery(function(e){if(typeof wc_cart_params==="undefined")return false;e(document).on("click",".shipping-calculator-button",function(){e(".shipping-calculator-form").slideToggle("slow");return false}).on("change","select.shipping_method, input[name^=shipping_method]",function(){var t=[];e("select.shipping_method, input[name^=shipping_method][type=radio]:checked, input[name^=shipping_method][type=hidden]").each(function(n,r){t[e(this).data("index")]=e(this).val()});e("div.cart_totals").block({message:null,overlayCSS:{background:"#fff url("+wc_cart_params.ajax_loader_url+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}});var n={action:"woocommerce_update_shipping_method",security:wc_cart_params.update_shipping_method_nonce,shipping_method:t};e.post(wc_cart_params.ajax_url,n,function(t){e("div.cart_totals").replaceWith(t);e("body").trigger("updated_shipping_method")})});e(".shipping-calculator-form").hide()})

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// wc_checkout_params is required to continue, ensure the object exists
if (typeof wc_checkout_params === "undefined")

File diff suppressed because one or more lines are too long

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// Frontend Chosen selects
$("select.country_select, select.state_select").chosen( { search_contains: true } );
@ -7,4 +7,4 @@ jQuery(document).ready(function($) {
$("select.state_select").chosen().trigger("chosen:updated");
});
});
});

View File

@ -1 +1 @@
jQuery(document).ready(function(e){e("select.country_select, select.state_select").chosen({search_contains:!0});e("body").bind("country_to_state_changed",function(){e("select.state_select").chosen().trigger("chosen:updated")})});
jQuery(function(e){e("select.country_select, select.state_select").chosen({search_contains:!0});e("body").bind("country_to_state_changed",function(){e("select.state_select").chosen().trigger("chosen:updated")})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// wc_country_select_params is required to continue, ensure the object exists
if (typeof wc_country_select_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof wc_country_select_params=="undefined")return!1;var t=wc_country_select_params.countries.replace(/&quot;/g,'"'),n=e.parseJSON(t);e("select.country_to_state, input.country_to_state").change(function(){var t=e(this).val(),r=e(this).closest("div").find("#billing_state, #shipping_state, #calc_shipping_state"),i=r.parent(),s=r.attr("name"),o=r.attr("id"),u=r.val(),a=r.attr("placeholder");if(n[t])if(n[t].length==0){r.parent().hide().find(".chosen-container").remove();r.replaceWith('<input type="hidden" class="hidden" name="'+s+'" id="'+o+'" value="" placeholder="'+a+'" />');e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}else{var f="",l=n[t];for(var c in l)f=f+'<option value="'+c+'">'+l[c]+"</option>";r.parent().show();if(r.is("input")){r.replaceWith('<select name="'+s+'" id="'+o+'" class="state_select" placeholder="'+a+'"></select>');r=e(this).closest("div").find("#billing_state, #shipping_state, #calc_shipping_state")}r.html('<option value="">'+wc_country_select_params.i18n_select_state_text+"</option>"+f);r.val(u);e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}else if(r.is("select")){i.show().find(".chosen-container").remove();r.replaceWith('<input type="text" class="input-text" name="'+s+'" id="'+o+'" placeholder="'+a+'" />');e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}else if(r.is(".hidden")){i.show().find(".chosen-container").remove();r.replaceWith('<input type="text" class="input-text" name="'+s+'" id="'+o+'" placeholder="'+a+'" />');e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}e("body").trigger("country_to_state_changing",[t,e(this).closest("div")])}).change()});
jQuery(function(e){if(typeof wc_country_select_params=="undefined")return!1;var t=wc_country_select_params.countries.replace(/&quot;/g,'"'),n=e.parseJSON(t);e("select.country_to_state, input.country_to_state").change(function(){var t=e(this).val(),r=e(this).closest("div").find("#billing_state, #shipping_state, #calc_shipping_state"),i=r.parent(),s=r.attr("name"),o=r.attr("id"),u=r.val(),a=r.attr("placeholder");if(n[t])if(n[t].length==0){r.parent().hide().find(".chosen-container").remove();r.replaceWith('<input type="hidden" class="hidden" name="'+s+'" id="'+o+'" value="" placeholder="'+a+'" />');e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}else{var f="",l=n[t];for(var c in l)f=f+'<option value="'+c+'">'+l[c]+"</option>";r.parent().show();if(r.is("input")){r.replaceWith('<select name="'+s+'" id="'+o+'" class="state_select" placeholder="'+a+'"></select>');r=e(this).closest("div").find("#billing_state, #shipping_state, #calc_shipping_state")}r.html('<option value="">'+wc_country_select_params.i18n_select_state_text+"</option>"+f);r.val(u);e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}else if(r.is("select")){i.show().find(".chosen-container").remove();r.replaceWith('<input type="text" class="input-text" name="'+s+'" id="'+o+'" placeholder="'+a+'" />');e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}else if(r.is(".hidden")){i.show().find(".chosen-container").remove();r.replaceWith('<input type="text" class="input-text" name="'+s+'" id="'+o+'" placeholder="'+a+'" />');e("body").trigger("country_to_state_changed",[t,e(this).closest("div")])}e("body").trigger("country_to_state_changing",[t,e(this).closest("div")])}).change()});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// woocommerce_price_slider_params is required to continue, ensure the object exists
if (typeof woocommerce_price_slider_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof woocommerce_price_slider_params=="undefined")return!1;e("input#min_price, input#max_price").hide();e(".price_slider, .price_label").show();var t=e(".price_slider_amount #min_price").data("min"),n=e(".price_slider_amount #max_price").data("max");current_min_price=parseInt(t);current_max_price=parseInt(n);woocommerce_price_slider_params.min_price&&(current_min_price=parseInt(woocommerce_price_slider_params.min_price));woocommerce_price_slider_params.max_price&&(current_max_price=parseInt(woocommerce_price_slider_params.max_price));e("body").bind("price_slider_create price_slider_slide",function(t,n,r){if(woocommerce_price_slider_params.currency_pos=="left"){e(".price_slider_amount span.from").html(woocommerce_price_slider_params.currency_symbol+n);e(".price_slider_amount span.to").html(woocommerce_price_slider_params.currency_symbol+r)}else if(woocommerce_price_slider_params.currency_pos=="left_space"){e(".price_slider_amount span.from").html(woocommerce_price_slider_params.currency_symbol+" "+n);e(".price_slider_amount span.to").html(woocommerce_price_slider_params.currency_symbol+" "+r)}else if(woocommerce_price_slider_params.currency_pos=="right"){e(".price_slider_amount span.from").html(n+woocommerce_price_slider_params.currency_symbol);e(".price_slider_amount span.to").html(r+woocommerce_price_slider_params.currency_symbol)}else if(woocommerce_price_slider_params.currency_pos=="right_space"){e(".price_slider_amount span.from").html(n+" "+woocommerce_price_slider_params.currency_symbol);e(".price_slider_amount span.to").html(r+" "+woocommerce_price_slider_params.currency_symbol)}e("body").trigger("price_slider_updated",n,r)});e(".price_slider").slider({range:!0,animate:!0,min:t,max:n,values:[current_min_price,current_max_price],create:function(t,n){e(".price_slider_amount #min_price").val(current_min_price);e(".price_slider_amount #max_price").val(current_max_price);e("body").trigger("price_slider_create",[current_min_price,current_max_price])},slide:function(t,n){e("input#min_price").val(n.values[0]);e("input#max_price").val(n.values[1]);e("body").trigger("price_slider_slide",[n.values[0],n.values[1]])},change:function(t,n){e("body").trigger("price_slider_change",[n.values[0],n.values[1]])}})});
jQuery(function(e){if(typeof woocommerce_price_slider_params=="undefined")return!1;e("input#min_price, input#max_price").hide();e(".price_slider, .price_label").show();var t=e(".price_slider_amount #min_price").data("min"),n=e(".price_slider_amount #max_price").data("max");current_min_price=parseInt(t);current_max_price=parseInt(n);woocommerce_price_slider_params.min_price&&(current_min_price=parseInt(woocommerce_price_slider_params.min_price));woocommerce_price_slider_params.max_price&&(current_max_price=parseInt(woocommerce_price_slider_params.max_price));e("body").bind("price_slider_create price_slider_slide",function(t,n,r){if(woocommerce_price_slider_params.currency_pos=="left"){e(".price_slider_amount span.from").html(woocommerce_price_slider_params.currency_symbol+n);e(".price_slider_amount span.to").html(woocommerce_price_slider_params.currency_symbol+r)}else if(woocommerce_price_slider_params.currency_pos=="left_space"){e(".price_slider_amount span.from").html(woocommerce_price_slider_params.currency_symbol+" "+n);e(".price_slider_amount span.to").html(woocommerce_price_slider_params.currency_symbol+" "+r)}else if(woocommerce_price_slider_params.currency_pos=="right"){e(".price_slider_amount span.from").html(n+woocommerce_price_slider_params.currency_symbol);e(".price_slider_amount span.to").html(r+woocommerce_price_slider_params.currency_symbol)}else if(woocommerce_price_slider_params.currency_pos=="right_space"){e(".price_slider_amount span.from").html(n+" "+woocommerce_price_slider_params.currency_symbol);e(".price_slider_amount span.to").html(r+" "+woocommerce_price_slider_params.currency_symbol)}e("body").trigger("price_slider_updated",n,r)});e(".price_slider").slider({range:!0,animate:!0,min:t,max:n,values:[current_min_price,current_max_price],create:function(t,n){e(".price_slider_amount #min_price").val(current_min_price);e(".price_slider_amount #max_price").val(current_max_price);e("body").trigger("price_slider_create",[current_min_price,current_max_price])},slide:function(t,n){e("input#min_price").val(n.values[0]);e("input#max_price").val(n.values[1]);e("body").trigger("price_slider_slide",[n.values[0],n.values[1]])},change:function(t,n){e("body").trigger("price_slider_change",[n.values[0],n.values[1]])}})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// wc_single_product_params is required to continue, ensure the object exists
if (typeof wc_single_product_params === "undefined")

View File

@ -1 +1 @@
jQuery(document).ready(function(e){if(typeof wc_single_product_params=="undefined")return!1;e(".woocommerce-tabs .panel").hide();e(".woocommerce-tabs ul.tabs li a").click(function(){var t=e(this),n=t.closest(".woocommerce-tabs");e("ul.tabs li",n).removeClass("active");e("div.panel",n).hide();e("div"+t.attr("href"),n).show();t.parent().addClass("active");return!1});e(".woocommerce-tabs").each(function(){var t=window.location.hash;t.toLowerCase().indexOf("comment-")>=0?e("ul.tabs li.reviews_tab a",e(this)).click():e("ul.tabs li:first a",e(this)).click()});e("a.woocommerce-review-link").click(function(){e(".reviews_tab a").click();return!0});e("#rating").hide().before('<p class="stars"><span><a class="star-1" href="#">1</a><a class="star-2" href="#">2</a><a class="star-3" href="#">3</a><a class="star-4" href="#">4</a><a class="star-5" href="#">5</a></span></p>');e("body").on("click","#respond p.stars a",function(){var t=e(this),n=e(this).closest("#respond").find("#rating");n.val(t.text());t.siblings("a").removeClass("active");t.addClass("active");return!1}).on("click","#respond #submit",function(){var t=e(this).closest("#respond").find("#rating"),n=t.val();if(t.size()>0&&!n&&wc_single_product_params.review_rating_required=="yes"){alert(wc_single_product_params.i18n_required_rating_text);return!1}});e("form.cart").submit(function(){e(this).find(":submit").attr("disabled","disabled")})});
jQuery(function(e){if(typeof wc_single_product_params=="undefined")return!1;e(".woocommerce-tabs .panel").hide();e(".woocommerce-tabs ul.tabs li a").click(function(){var t=e(this),n=t.closest(".woocommerce-tabs");e("ul.tabs li",n).removeClass("active");e("div.panel",n).hide();e("div"+t.attr("href"),n).show();t.parent().addClass("active");return!1});e(".woocommerce-tabs").each(function(){var t=window.location.hash;t.toLowerCase().indexOf("comment-")>=0?e("ul.tabs li.reviews_tab a",e(this)).click():e("ul.tabs li:first a",e(this)).click()});e("a.woocommerce-review-link").click(function(){e(".reviews_tab a").click();return!0});e("#rating").hide().before('<p class="stars"><span><a class="star-1" href="#">1</a><a class="star-2" href="#">2</a><a class="star-3" href="#">3</a><a class="star-4" href="#">4</a><a class="star-5" href="#">5</a></span></p>');e("body").on("click","#respond p.stars a",function(){var t=e(this),n=e(this).closest("#respond").find("#rating");n.val(t.text());t.siblings("a").removeClass("active");t.addClass("active");return!1}).on("click","#respond #submit",function(){var t=e(this).closest("#respond").find("#rating"),n=t.val();if(t.size()>0&&!n&&wc_single_product_params.review_rating_required=="yes"){alert(wc_single_product_params.i18n_required_rating_text);return!1}});e("form.cart").submit(function(){e(this).find(":submit").attr("disabled","disabled")})});

View File

@ -1,4 +1,4 @@
jQuery(document).ready(function($) {
jQuery(function($) {
// Orderby
$('.woocommerce-ordering').on( 'change', 'select.orderby', function() {
@ -54,4 +54,4 @@ jQuery(document).ready(function($) {
// Trigger change event
$qty.trigger('change');
});
});
});

View File

@ -1 +1 @@
jQuery(document).ready(function(e){e(".woocommerce-ordering").on("change","select.orderby",function(){e(this).closest("form").submit()});e("div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)").addClass("buttons_added").append('<input type="button" value="+" class="plus" />').prepend('<input type="button" value="-" class="minus" />');e("input.qty:not(.product-quantity input.qty)").each(function(){var t=parseFloat(e(this).attr("min"));t&&t>0&&parseFloat(e(this).val())<t&&e(this).val(t)});e(document).on("click",".plus, .minus",function(){var t=e(this).closest(".quantity").find(".qty"),n=parseFloat(t.val()),r=parseFloat(t.attr("max")),i=parseFloat(t.attr("min")),s=t.attr("step");if(!n||n==""||n=="NaN")n=0;if(r==""||r=="NaN")r="";if(i==""||i=="NaN")i=0;if(s=="any"||s==""||s==undefined||parseFloat(s)=="NaN")s=1;e(this).is(".plus")?r&&(r==n||n>r)?t.val(r):t.val(n+parseFloat(s)):i&&(i==n||n<i)?t.val(i):n>0&&t.val(n-parseFloat(s));t.trigger("change")})});
jQuery(function(e){e(".woocommerce-ordering").on("change","select.orderby",function(){e(this).closest("form").submit()});e("div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)").addClass("buttons_added").append('<input type="button" value="+" class="plus" />').prepend('<input type="button" value="-" class="minus" />');e("input.qty:not(.product-quantity input.qty)").each(function(){var t=parseFloat(e(this).attr("min"));t&&t>0&&parseFloat(e(this).val())<t&&e(this).val(t)});e(document).on("click",".plus, .minus",function(){var t=e(this).closest(".quantity").find(".qty"),n=parseFloat(t.val()),r=parseFloat(t.attr("max")),i=parseFloat(t.attr("min")),s=t.attr("step");if(!n||n==""||n=="NaN")n=0;if(r==""||r=="NaN")r="";if(i==""||i=="NaN")i=0;if(s=="any"||s==""||s==undefined||parseFloat(s)=="NaN")s=1;e(this).is(".plus")?r&&(r==n||n>r)?t.val(r):t.val(n+parseFloat(s)):i&&(i==n||n<i)?t.val(i):n>0&&t.val(n-parseFloat(s));t.trigger("change")})});

View File

@ -1,5 +1,5 @@
(function($) {
$(document).ready(function() {
$(function() {
// Lightbox
$("a.zoom").prettyPhoto({
@ -20,4 +20,4 @@ $(document).ready(function() {
});
});
})(jQuery);
})(jQuery);

View File

@ -1 +1 @@
(function(e){e(document).ready(function(){e("a.zoom").prettyPhoto({hook:"data-rel",social_tools:!1,theme:"pp_woocommerce",horizontal_padding:20,opacity:.8,deeplinking:!1});e("a[data-rel^='prettyPhoto']").prettyPhoto({hook:"data-rel",social_tools:!1,theme:"pp_woocommerce",horizontal_padding:20,opacity:.8,deeplinking:!1})})})(jQuery);
(function(e){e(function(){e("a.zoom").prettyPhoto({hook:"data-rel",social_tools:!1,theme:"pp_woocommerce",horizontal_padding:20,opacity:.8,deeplinking:!1});e("a[data-rel^='prettyPhoto']").prettyPhoto({hook:"data-rel",social_tools:!1,theme:"pp_woocommerce",horizontal_padding:20,opacity:.8,deeplinking:!1})})})(jQuery);

View File

@ -685,7 +685,7 @@ class WC_Admin_CPT_Shop_Order extends WC_Admin_CPT {
if ( 'shop_order' == $post_type ) {
?>
<script type="text/javascript">
jQuery(document).ready(function() {
jQuery(function() {
jQuery('<option>').val('mark_processing').text('<?php _e( 'Mark processing', 'woocommerce' )?>').appendTo("select[name='action']");
jQuery('<option>').val('mark_processing').text('<?php _e( 'Mark processing', 'woocommerce' )?>').appendTo("select[name='action2']");