1(function(root){"use strict";if(root.BareProductPricing)return;function offer(variant,sellingPlanId=null){const allocation=sellingPlanId==null?null:variant?.selling_plan_allocations?.find(item=>String(item.selling_plan_id)===String(sellingPlanId)),valid=!!variant&&(sellingPlanId==null?!variant.requires_selling_plan:!!allocation),price=allocation?.price??variant?.price??0,compareAtPrice=allocation?.compare_at_price??variant?.compare_at_price??0,savings=Math.max(0,compareAtPrice-price);return Object.freeze({valid,price,compareAtPrice,savings,savingsPercent:compareAtPrice>0?Math.round(savings*100/compareAtPrice):0,perDeliveryPrice:allocation?.per_delivery_price??price,unitPrice:allocation?.unit_price??variant?.unit_price??null,sellingPlanId:allocation?.selling_plan_id??null,allocation:allocation??null})}const forms=new WeakMap;function forForm(form){if(!forms.has(form)){let state=null;forms.set(form,{get state(){return state},offer(sellingPlanId=null){return offer(state?.variant,sellingPlanId)},update(variant,sellingPlanId=null,quantity=1){return state=Object.freeze({variant,variantId:variant?.id??null,quantity,oneTime:offer(variant),selected:offer(variant,sellingPlanId)}),state}})}return forms.get(form)}root.BareProductPricing=Object.freeze({offer,forForm})})(typeof window>"u"?globalThis:window); 2//# sourceMappingURL=/cdn/shop/t/186/assets/product-pricing.js.map?v=130275115422814646641790889919
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.