/** * Copyright © 2020 Design Analytics * Version 1.4.7 * All rights reserved. * This file or any portion thereof may not be used by any team other than Dell's Design Analytics dev team without the express written permission of it. **/ var DELL=DELL||{};DELL.tnt=DELL.tnt||{};DELL.tnt.Test=function(b,d,f,h,m,x,z,A,C,D,E,F,G,H,I,J,K,B,l){this.system={isAT:"undefined"!==typeof adobe,uid:"t"+d.split(" ")[0].replace("#",""),domain:-1> "+k+"ms");"undefined"!==typeof console&&console.info&&("Internet Explorer"===this.user.browser||"Edge"===this.user.browser||"Safari"===this.user.browser?console.info("..:: Running code from offer #"+this.campaign.number+"-"+this.campaign.recipe.id):console.info("%c..:: Running code from offer %c#"+this.campaign.number+"-"+this.campaign.recipe.id,this.system.styles.secondary,this.system.styles.secondaryBold));this.system.tntTrack.cookieDays.setTime(this.system.tntTrack.cookieDays.getTime()+12096E5);this.system.tntTrack.tntvarArray=[this.campaign.id+":"+this.campaign.recipe.number+":0"];this.system.tntTrackFire.apply(this);this.init()}catch(L){this.Error("Main thread error!",L)}}else setTimeout(function(){c.system.execute.apply(c,[e])},100);return this}"undefined"!==typeof console&&console.info&&("Internet Explorer"===this.user.browser||"Edge"===this.user.browser||"Safari"===this.user.browser?console.info("..:: Viewport "+this.user.viewport+" is not included on this test."):console.info("%c..:: Viewport %c"+this.user.viewport+" %cis not included on this test.",this.system.styles.secondary,this.system.styles.secondaryBold,this.system.styles.secondary))},wrapFunction:function(a,c,e){var k=this;return function(){try{var b=$(e);return a.apply(b.length?b:k,arguments)}catch(y){k.Error(c,y)}}},wrapTimer:function(a,c){var e=this;return function(){var k=Array.prototype.slice.call(arguments),b=(new Date).getTime();var y=c.apply(e,k);try{for(var d=k.length;d--;)k[d]&&(k[d].selector||k[d].prevObject)&&(k[d]="$("+(k[d].selector||k[d].prevObject.selector)+")");var f=(new Date).getTime()-b;this.runtime.total+=f;this.runtime.details.push(a+"("+JSON.stringify(k).slice(1,-1)+") >> "+f+"ms")}catch(P){}return y}},detectBrowser:function(){var a="Other";switch(!0){case !!window.opr&&!!opr.addons||!!window.opera||0<=navigator.userAgent.indexOf(" OPR/"):a="Opera";break;case "undefined"!==typeof InstallTrigger:a="Firefox";break;case 0c&&768<=c:e="tablet";break;case 768>c:e="mobile"}else switch(!0){case 980<=c:e="desktop";break;case 980>c:e="mobile"}return e},tntTrackFire:function(){var a=this.system.uid;window[a].setTimeout(function(){window[a].system.tntTrackSync.apply(window[a]);if(window[a].system.tntTrack.canRun&&(window[a].system.tntTrack.seenArray.length||window[a].system.tntTrack.clickArray.length)){var c="object"===typeof s_dell&&"function"===typeof s_dell.tl&&"function"===typeof s_dell.lowercaseVars&&"function"===typeof sC,e=-1d.indexOf(a)};for(e=0;earguments.length&&(e=c,c=a,a=null);if(a){var d=function(a){window[b].tntTrack(c,e)};if("function"===typeof $.fn.on)$(document).on("click",a,d);else $(a).bind("click",d)}else c&&-1===c.indexOf(window[b].campaign.number+"_")&&(c=window[b].campaign.number+"_"+c),window[b].system.tntTrackSync.apply(this),e===tntlib.Track.Seen?window[b].system.tntTrack.seenArray.push(c):window[b].system.tntTrack.clickArray.push(c),"undefined"!==typeof console&&console.info&&("Internet Explorer"===this.user.browser||"Edge"===this.user.browser||"Safari"===this.user.browser?console.info("TntTrack event "+e+" registered: "+c):console.info("%cTntTrack event %c"+e+"%c registered: %c"+c,window[b].system.styles.normal,window[b].system.styles.bold,window[b].system.styles.normal,window[b].system.styles.bold)),window[b].cookie.set("tntTrack",JSON.stringify([window[b].system.tntTrack.seenArray,window[b].system.tntTrack.tntvarArray,window[b].system.tntTrack.clickArray]),window[b].system.tntTrack.cookieDays,"/",window[b].system.domain)};this.api=function(a,c,b,d){function e(a,c){if(c&&c.Stack&&c.Stack.ItemIdentifier){a=c.Stack;var b={};b.UniqueId=a.UniqueItemCode;b.Id=a.ItemIdentifier;b.Brand={Name:a.BrandCategoryText,Code:a.BrandCategoryId};b.Message={Rewards:a.ComoRewardsMessage};a.MicroFormat&&(b.Name=a.MicroFormat.Name,b.Image=a.MicroFormat.Image,b.Url=a.MicroFormat.Url,b.Brand.Manufacturer=a.MicroFormat.Brand,b.Message.Description=a.MicroFormat.Description);a.EvalueCode&&(b.eValue=a.EvalueCode.InnerValue);b.Product={};a.ProductCode&&(b.Product.Code=a.ProductCode.InnerValue);a.ProductImage&&(b.Product.Image={Url:a.ProductImage.ImageUri,Alt:a.ProductImage.AltText});b.Category={Path:a.CategoryPath,Id:a.MainCategoryId,Name:a.MainCategoryText};a.CategoryInfo&&(b.Category.Id=b.Category.Id||a.CategoryInfo.Id,b.Category.Name=b.Category.Name||a.CategoryInfo.Name,b.Category.Parent={Id:a.CategoryInfo.TopLevelCategoryId,Name:a.CategoryInfo.TopLevelCategoryName});b.SKUs=a.OrderCodeSkus;b.Price={};a.Pricing&&(a.Pricing.DellPrice&&(b.Price.DellPrice=a.Pricing.DellPrice.InnerValue),a.Pricing.MarketValue&&(b.Price.MarketValue=a.Pricing.MarketValue.InnerValue),a.Pricing.TotalSavings&&(b.Price.TotalSavings=a.Pricing.TotalSavings.InnerValue),a.Pricing.SpecialOffersDetails&&(b.Offers=a.Pricing.SpecialOffersDetails.Details));a.FinanceMarketing&&a.FinanceMarketing.Amount&&a.FinanceMarketing.Amount.length&&(b.Price.AsLowAs=parseInt(a.FinanceMarketing.Amount.substr(1),10));a.Mda&&(b.Mda={Enabled:a.Mda.ShowCaption,Message:a.Mda.MdaCaption});a.PromotionMessage&&(b.Nabisco=a.PromotionMessage.InnerValue);b.Links={};a.Links&&(a.Links.AddToCartLink&&(b.Links.AddToCartLink=a.Links.AddToCartLink.Url),a.Links.CompareLink&&(b.Links.CompareLink=a.Links.CompareLink.Url),a.Links.ViewDetailsLink&&(b.Links.ViewDetailsLink=a.Links.ViewDetailsLink.Url));a.Rewards&&a.Rewards.PrimaryCallToAction&&(b.Links.Rewards=a.Rewards.PrimaryCallToAction.Url);a.IconographySpecs&&(b.Iconography=a.IconographySpecs.Specs);b.OutOfStock=a.ProductOutOfStock;b.SoldOut=a.ProductSoldOut;a.Shipping&&(b.Shipping={FastTrack:a.Shipping.IsFastTrackEligible},a.Shipping.ShippingDate&&(b.Shipping.Date=a.Shipping.ShippingDate.InnerValue));b.Weight={};a.ProductWeightDataModel&&(b.Weight.Value=a.ProductWeightDataModel.ProductWeightText,b.Weight.Enabled=a.ProductWeightDataModel.ShowProductWeight);b.Weight.Value=b.Weight.Value||a.Weight;c.Specs&&(b.Specs=c.Specs.TechSpecs);return b}return null}function k(a,b){var c={};c.Id=a;c.Items={};if(b&&b.Results&&b.Results.Stacks)for(var d=0;du.length&&(u=u[0]),b&&b(u),$(document).trigger("tntlibApiSuccess",[u])))}catch(N){t.Error("API call success callback error!",N)}},error:function(a,b,c){try{d&&d(a,b,c),$(document).trigger("tntlibApiFailure",[a,b,c])}catch(O){t.Error("API call failure callback error!",O)}}})}};this.Bailout=function(a){console&&console.error&&console.error(a);a=this.system.options.iframe?window.location:window.parent.location;a.replace(a.protocol+"//"+a.host+a.pathname+a.search+(a.search?"&":"?")+"ref="+(this.campaign.number+"x"+this.campaign.recipe.id+"&x=1")+a.hash)};this.Error=function(a,b){function c(){for(var a=0;a> "+h+"ms")}else return this.setTimeout(function(){c.system.waitQueue[a]=c.waitForElement.apply(c,[a,b,e])},250,'waitForElement "'+a+'" callback error!')}catch(M){this.Error("WaitForElement function error!",M)}};this.waitForCondition=function(a,b,e){var c=this,d=e||(new Date).getTime();try{if(eval(a)){b.apply(this,arguments);var f=(new Date).getTime()-d;this.runtime.total+=f;this.runtime.details.push("waitForCondition("+a+") >> "+f+"ms")}else return this.setTimeout(function(){c.waitForCondition.apply(c,[a,b,d])},250,'waitForCondition "'+a+'" callback error!')}catch(r){this.Error("WaitForCondition function error!",r)}};this.waitForObject=function(a,b,d){var c=this,e=d||(new Date).getTime();try{if(this.checkNested(a)){b.apply(this,arguments);var f=(new Date).getTime()-e;this.runtime.total+=f;this.runtime.details.push("waitForObject("+a+") >> "+f+"ms")}else return this.setTimeout(function(){c.waitForObject.apply(c,[a,b,d])},250,'waitForObject "'+a+'" callback error!')}catch(r){this.Error("WaitForObject function error!",r)}};this.stopWaitingFor=function(a){clearTimeout(this.system.waitQueue[a]);delete this.system.waitQueue[a]};this.preload=function(a,b){$("#tnt-preload").length||$("body").append('');for(var c="",d=a.length;d--;)c+='';$("#tnt-preload").append(c)};z&&(this.code=z,this.system.extend.apply(this));this.user.browser=this.system.detectBrowser();this.user.viewport=this.system.detectViewport(!0);return this};var tntlib=tntlib||{};tntlib.API=tntlib.API||{OC:1,Model:2,SKUList:3,SKU:4,UserData:5,Delivery:6,Finance:7,Ratings:8,Cart:9,CartItem:10,CartMasthead:11};tntlib.Track=tntlib.Track||{Seen:"Seen",Trigger:"Trigger"};