PageSourceSearch

https://www.chiadegracia.fi/cdn/shop/t/14/assets/algolia_helpers.js?v=181041548609960212001644090384

js chiadegracia.fi collected 2026-09-26 21:15:08 UTC 4,690 bytes, 2 lines download raw bytes

1(function(algolia){"use strict";var Hogan=algolia.externals.Hogan,formatPrice=function(value){return algolia.formatMoney(Number(value)*100)};function formattedPriceWithComparison(price,compare_at_price,price_ratio){var comparing=Number(compare_at_price)&&Number(compare_at_price)>Number(price),discount_ratio=1-price_ratio,res="<b>"+formatPrice(price)+"</b>";return comparing&&(res+=' <span class="ais-hit--price-striked"><span>'+formatPrice(compare_at_price)+"</span></span> ",res+=' <span class="ais-hit--price-discount" style="font-weight: '+Math.floor(discount_ratio*10)*100+';">-'+Math.floor(discount_ratio*100)+"%</span>"),res}var escapeHtml=function(unsafe){return(unsafe||"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")};algolia.helpers={formatNumber:function(text,render){return Number(render(text)).toLocaleString()},formattedPrice:function(text,render){return formatPrice(render(text))},formattedPriceWithoutDecimals:function(text,render){return formatPrice(render(text)).replace(/\.\d+$/,"")},autocompletePrice:function(){if(this._distinct){var min=this.variants_min_price,max=this.variants_max_price;if(min!==max)return"<b>"+formatPrice(min)+" - "+formatPrice(max)+"</b>"}return formattedPriceWithComparison(this.price,null)},instantsearchPrice:function(){if(this._distinct){var min=this.variants_min_price,max=this.variants_max_price;if(min!==max)return"<b>"+formatPrice(min)+" - "+formatPrice(max)+"</b>"}return formattedPriceWithComparison(this.price,this.compare_at_price,this.price_ratio)},instantsearchLink:function(){var addVariantId=!this._distinct&&this.objectID!==this.id;return"/products/"+this.handle+(addVariantId?"?variant="+this.objectID:"")},fullTitle:function(){var res=this.title;return!this._distinct&&this.variant_title&&this.variant_title!=="Default Title"&&this.variant_title!=="Default"&&(res+=" ("+this.variant_title+")"),escapeHtml(res)},fullHTMLTitle:function(){var res="";return this._highlightResult.title&&this._highlightResult.title.value&&(res=algolia.helpers.fullEscapedAttribute(this._highlightResult.title.value)),!this._distinct&&this.variant_title&&this.variant_title!=="Default Title"&&this.variant_title!=="Default"&&(res+=' <span class="algolia-variant">('+res+")</span>"),res},fullEscapedAttribute(attribute){return new DOMParser().parseFromString(attribute,"text/html").documentElement.textContent},fullEscapedHTMLTitle:function(){var res="";return this._highlightResult.title&&this._highlightResult.title.value&&(res=algolia.helpers.fullEscapedAttribute(this._highlightResult.title.value)),!this._distinct&&this.variant_title&&this.variant_title!=="Default Title"&&this.variant_title!=="Default"&&(res+=' <span class="algolia-variant">('+res+")</span>"),res},fullEscapedHTMLProductType:function(){return this._highlightResult.product_type&&this._highlightResult.product_type.value?algolia.helpers.fullEscapedAttribute(this._highlightResult.product_type.value):""},fullEscapedHTMLVendor:function(){return this._highlightResult.vend
1or&&this._highlightResult.vendor.value?algolia.helpers.fullEscapedAttribute(this._highlightResult.vendor.value):""},floor:function(text,render){return""+Math.floor(Number(render(text)))},ceil:function(text,render){return""+Math.ceil(Number(render(text)))},sizedImage:function(text,render){var image=this._distinct?this.product_image:this.image;if(!image)return"http://cdn.shopify.com/s/images/admin/no-image-compact.gif";var size=render(text).replace(/^\s+|\s+$/g,"");return size==="original"?image:image.replace(/\/(.*)\.(\w{2,4})/g,"/$1_"+size+".$2")}},["pico","icon","thumb","small","compact","medium","large","grande","original"].forEach(function(size){algolia.helpers[size+"Image"]=(function(_size){return function(){var image=this._distinct?this.product_image:this.image;return image?_size==="original"?image:image.replace(/\/(.*)\.(\w{2,4})/g,"/$1_"+_size+".$2"):"http://cdn.shopify.com/s/images/admin/no-image-compact.gif"}})(size)});for(var helpers=algolia.assign({},algolia.helpers,algolia.translation_helpers),helpersNames=Object.keys(helpers),i=helpersNames.length,helpersArray=new Array(i);i--;)helpersArray[i]=[helpersNames[i],helpers[helpersNames[i]]];algolia.hoganHelpers=helpersArray.reduce(function(res,options){var name=options[0],helper=options[1],newRes=algolia.assign({},res);return newRes[name]=function(){return function(text){var render=function(value){return Hogan.compile(value,algolia.hoganOptions).render(this)}.bind(this);return helper.call(this,text,render)}.bind(this)},newRes},{})})(window.algoliaShopify);
2//# sourceMappingURL=/cdn/shop/t/14/assets/algolia_helpers.js.map?v=181041548609960212001644090384

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.