1"object"==typeof Countries&&(Countries.updateProvinceLabel=function(e,r){if("string"==typeof e&&Countries[e]&&Countries[e].provinces){if("object"!=typeof r&&null===(r=document.getElementById("address_province_label")))return;r.innerHTML=Countries[e].label;var t=jQuery(r).parent();t.find("select"),t.find(".custom-style-select-box-inner").html(Countries[e].provinces[0])}}),void 0===Shopify.Cart&&(Shopify.Cart={}),Shopify.Cart.ShippingCalculator=function(){var _config={submitButton:"Calculate shipping",submitButtonDisabled:"Calculating...",templateId:"shipping-calculator-response-template",wrapperId:"wrapper-response",customerIsLoggedIn:!1,moneyFormat:"<span class=money>${{amount}} USD</span>"},_render=function(e){var r=jQuery("#"+_config.templateId),t=jQuery("#"+_config.wrapperId);if(r.length&&t.length){var n=Handlebars.compile(jQuery.trim(r.text()))(e);if(jQuery(n).appendTo(t),"undefined"!=typeof Currency&&"function"==typeof Currency.convertAll){var a="";jQuery("[name=currencies]").length?a=jQuery("[name=currencies]").val():jQuery("#currencies span.selected").length&&(a=jQuery("#currencies span.selected").attr("data-currency")),""!==a&&Currency.convertAll(shopCurrency,a,"#wrapper-response span.money, #estimated-shipping span.money")}}},_enableButtons=function(){jQuery(".get-rates").removeAttr("disabled").removeClass("disabled").val(_config.submitButton)},_disableButtons=function(){jQuery(".get-rates").val(_config.submitButtonDisabled).attr("disabled","disabled").addClass("disabled")},_getCartShippingRatesForDestination=function(e){var r={type:"POST",url:"/cart/prepare_shipping_rates",data:jQuery.param({shipping_address:e}),success:_pollForCartShippingRatesForDestination(e),error:_onError};jQuery.ajax(r)},_pollForCartShippingRatesForDestination=function(e){var r=function(){jQuery.ajax("/cart/async_shipping_rates",{dataType:"json",success:function(t,n,a){200===a.status?_onCartShippingRatesUpdate(t.shipping_rates,e):setTimeout(r,500)},error:_onError})};return r},_fullMessagesFromErrors=function(e){var r=[];return jQuery.each(e,function(e,t){jQuery.each(t,function(t,n){r.push(e+" "+n)})}),r},_onError=function(XMLHttpRequest,textStatus){jQuery("#estimated-shipping").hide(),jQuery("#estimated-shipping em").empty(),_enableButtons();var feedback="",data=eval("("+XMLHttpRequest.responseText+")");feedback=data.message?data.message+"("+data.status+"): "+data.description:"Error : "+_fullMessagesFromErrors(data).join("; ")+".","Error : country is not supported."===feedback&&(feedback="We do not ship to this destination."),_render({rates:[],errorFeedback:feedback,success:!1}),jQuery("#"+_config.wrapperId).show()},_onCartShippingRatesUpdate=function(e,r){_enableButtons();var t="";if(r.zip&&(t+=r.zip+", "),r.province&&(t+=r.province+", "),t+=r.country,e.length){"0.00"==e[0].price?jQuery("#estimated-shipping em").html("FREE"):jQuery("#estimated-shipping em").html(_formatRate(e[0].price));for(var n=0;n<e.length;n++)e[n].price=_formatRate(e[n].price)}_render({rates:e,address:t,success:!0}),jQuery("#"+_config.wrapperId+", #estimated-shipping").fadeIn()},_formatRate=function(e){function r(e,r){return void 0===e?r:e}function t(e,t,n,a){if(t=r(t,2),n=r(n,","),a=r(a,"."),isNaN(e)||null==e)return 0;var i=(e=(e/100).toFixed(t)).split(".");return i[0].replace(/(\d)(?=(\d\d\d)+(?!\d))/g,"$1"+n)+(i[1]?a+i[1]:"")}if("function"==typeof Shopify.formatMoney)return Shopify.formatMoney(e,_config.moneyFormat);"string"==typeof e&&(e=e.replace(".",""));var n="",a=/\{\{\s*(\w+)\s*\}\}/,i=_config.moneyFormat;switch((i=jQuery(i).text()).match(a)[1]){case"amount":n=t(e,2);break;case"amount_no_decimals":n=t(e,0);break;case"amount_with_comma_separator":n=t(e,2,".",",");break;case"amount_no_decimals_with_comma_separator":n=t(e,0,".",",")}return i.replace(a,n)};return _init=function(){new Shopify.CountryProvinceSelector("address_country","address_province",{hideElement:"address_province_container"});var e=jQuery("#address_country"),r=jQuery("#address_province_label").get(0);"undefined"!=typeof Countries&&(Countries.updateProvinceLabel(e.val(),r),e.change(function(){Countries.updateProvinceLabel(e.val(),r)})),jQuery(".get-rates").click(function(){_disableButtons(),jQuery("#"+_config.wrapperId).empty().hide();var e={};e.zip=jQuery("#address_zip").val()||"",e.country=jQuery("#address_country").val()||"",e.province=jQuery("#address_province").val()||"",_getCartShippingRatesForDestination(e)}),_config.customerIsLoggedIn&&jQuery(".get-rates:eq(0)").trigger("click")},{show:function(e){e=e||{},jQuery.extend(_config,e),jQuery(function(){_init()})},getConfig:function(){return _config},formatRate:function(e){return _formatRate(e)}}}();
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.