1function YmEc(t){const s=this;let e={},u={},r=null,c=null,n=!1;window.dataLayer=window.dataLayer||[],this.addData=function(t){if(t){if(t.products&&this.registerProducts(t.products),t.cartItems&&this.registerCartItems(t.cartItems),t.currency&&this.setCurrency(t.currency),t.detailProductId&&this.setDetailProductId(t.detailProductId),t.hasActiveVariation&&(n=!0),t.actions)for(var r in t.actions){r=t.actions[r];this.send(r.type,r.data)}t.purchase&&this.sendPurchase(t.purchase.actionField,t.purchase.products)}},this.registerCartItem=function(t,r){u[t]=r},this.registerProduct=function(t,r){if("string"==typeof r){console.log(r);try{r=JSON.parse(r)}catch(t){return void console.log("ÐÑи ÑегиÑÑÑаÑии ÑоваÑа пÑоизоÑла оÑибка - невеÑÐ½Ð°Ñ JSON ÑÑÑока")}}e[t]=r},this.registerProducts=function(t){for(var r in t)t.hasOwnProperty(r)&&s.registerProduct(r,t[r])},this.registerCartItems=function(t){for(var r in t)t.hasOwnProperty(r)&&s.registerCartItem(r,t[r])},this.isDetail=function(){return!!r},this.hasActiveVariation=function(){return n},this.setDetailProductId=function(t){r=t},this.setCurrency=function(t){c=t},this.getCurrency=function(){return c},this.getDetailProductId=function(){return r},this.getProduct=function(t){return e[t]||null},this.getProductByHash=function(t){if(!u.hasOwnProperty(t))return null;t=u[t].id;return e[t]||null},this.getProducts=function(){return e},this.getCartItems=function(){return u},this.clearCartItems=function(){u={}},this.clearProducts=function(){e={}},this.updateCartItems=function(t){for(var r in u){var e=u[r];void 0===t[r]&&(this.send("remove",r,{quantity:e.quantity}),delete u[r])}for(var n in t){var i=t[n];const o=u[n];var s=Math.abs(i.quantity-o.quantity),c=i.quantity>o.quantity?"add":"remove";0<s&&this.send(c,n,{quantity:s}),o.quantity=i.quantity}},this.send=function(t,r,e){if(r=-1<["string","number"].indexOf(typeof r)?s.getProduct(r):r){for(var n in e=e||{})e.hasOwnProperty(n)&&(r[n]=e[n]);const i={ecommerce:{}};i.ecommerce[t]={products:[r]},c&&(i.ecommerce.currencyCode=c),window.dataLayer.push(i)}else console.log("Ðе ÑдалоÑÑ Ð½Ð°Ð¹Ñи даннÑе ÑоваÑа Ð´Ð»Ñ Ð¾ÑпÑавки в ÑлекÑÑоннÑÑ ÐºÐ¾Ð¼Ð¼ÐµÑÑиÑ",r)},this.sendPurchase=function(t,r){const e={ecommerce:{purchase:{actionField:t,products:r}}};c&&(e.ecommerce.currencyCode=c),window.dataLayer.push(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.