1"use strict";(self.NiveaXwebpackJsonp=self.NiveaXwebpackJsonp||[]).push([[160,3227,9429],{11085:(t,e,i)=>{i.r(e),i.d(e,{default:()=>a});var r=i(23076);const n='[data-module="NivTGoogleAnalytics"]';class a{static setup(t=n){Array.from(document.querySelectorAll(t)).filter(t=>!t.dataset.moduleInitialized).forEach(t=>{new a(t),t.dataset.moduleInitialized="true"})}constructor(t){this.element=t,window.NiveaX.IsUAEnabled&&this.init()}init(){let t=document.querySelector(".nx-rating--pdp");t&&t.addEventListener("click",t=>(0,r.sx)("rating_event","scrollToRatings",""));let e=document.querySelector(".nx-write-review__btn");e&&(e.addEventListener("click",t=>(0,r.sx)("rating_event","writeReviewClick","")),document.addEventListener("layer:ShowLayer",t=>{event.detail&&"rating-and-review"==event.detail.layerType&&this.trackAlpacaForm(t,e.parentElement.getAttribute("data-form-url"))}))}trackAlpacaForm(t,e){(0,r.VE)({event:"virtualPageview",virtualPath:decodeURI(e)})}}a.setup(n)},23688:(t,e,i)=>{i.r(e),i.d(e,{default:()=>n});var r=i(98684);class n{constructor(t){var e;this.element=t,this.ratingAndStarsDistributionElement=this.element.querySelector(".nx-product-ratings__rating-and-stars-distribution"),this.productReviewsSectionElement=this.element.querySelector(".nx-product-reviews__section"),this.loadReviewsURL=null===(e=this.ratingAndStarsDistributionElement)||void 0===e?void 0:e.getAttribute("data-filterurl"),this.ratingFilterBtn=this.element.querySelector(".nx-product-ratings__filter"),this.spinner=this.element.querySelector(".nx-product-rating__spinner"),this.init()}init(){var t;this.addListenersToRatingSummaries(),null===(t=this.ratingFilterBtn)||void 0===t||t.addEventListener("click",()=>this.removeActiveFilter())}addListenersToRatingSummaries(){var t;const e=null===(t=this.ratingAndStarsDistributionElement)||void 0===t?void 0:t.querySelectorAll(".nx-product-ratings__rating-wrapper");e&&e.forEach(t=>{const i=t.querySelector(".nx-rating__total"),r=t.querySelector(".nx-rating__total-sum");i&&r&&"0"!=r.getAttribute("data-star-distribution")&&(this.addLinkStyleToRatingWrapper(t),t.addEventListener("click",()=>{const r=t.getAttribute("data-filter-text");t.classList.contains("nx-product-ratings__rating-wrapper--link-active")?(this.loadReviews("",null),this.removeActiveLinkStyleOnRatingWrappers(e)):(this.loadReviews(i.getAttribute("data-rating"),r),this.toggleActiveLinkStyleOnRatingWrappers(t,e))}))})}removeActiveFilter(){var t;const e=null===(t=this.ratingAndStarsDistributionElement)||void 0===t?void 0:t.querySelectorAll(".nx-product-ratings__rating-wrapper");this.loadReviews("",null),this.removeActiveLinkStyleOnRatingWrappers(e)}addLinkStyleToRatingWrapper(t){(0,r.iQ)(t,"nx-product-ratings__rating-wrapper--link")}toggleActiveLinkStyleOnRatingWrappers(t,e){this.removeActiveLinkStyleOnRatingWrappers(e),(0,r.iQ)(t,"nx-product-ratings__rating-wrapper--link-active")}removeActiveLinkStyleOnRatingWrappers(t){t.forEach(t=>{(0,r.vy)(t,"nx-product-ratings__rating-wrapper--link-active")})}showSpinner(){this.spinner.classList.remove("nx-product-rating__spinner--hide")}hideSpinner(){this.spinner.classList.add("nx-product-rating__spinner--hide")}removeLoadMoreCustomEventLister(){document.dispatchEvent(new CustomEvent("NiveaXLoadMoreLoaded:removeEvent"))}loadReviews(t,e){this.showSpinner();let i=decodeURIComponent(this.loadReviewsURL).replace("###",t),n=new XMLHttpRequest;return n.onload=()=>{if(n.status>=200&&n.status<300){const t=(0,r.Uo)(n.responseText);this.productReviewsSectionElement.querySelector(".nx-reviews-wrapper").replaceWith(t),e?(this.ratingFilterBtn.querySelector(".nx-product-ratings__filter-text").textContent=e,this.ratingFilterBtn.style.visibility=""):this.ratingFilterBtn.style.visibility="hidden",this.removeLoadMoreCustomEventLister(),window.NiveaX.initModules(),this.hideSpinner()}else console.error("The request failed!"),this.hideSpinner()},n.open("GET",i),n.send(),this}}},71403:(t,e,i)=>{i.r(e),i.d(e,{default:()=>s});var r=i(11085),n=i(23688);const a='[data-module="NivTBazaarVoice"]';class s{static setup(t=a){Array.from(document.querySelectorAll(t)).filter(t=>
1!t.dataset.moduleInitialized).forEach(t=>{new s(t),t.dataset.moduleInitialized="true"})}constructor(t){this.element=t,this.requestAttempts=0,this.init()}init(){var t,e;new n.default(this.element),new r.default(this.element),this.trackProductPageView(),this.trackingPagination(),null===(t=document.querySelector(".nx-rating--pdp"))||void 0===t||t.addEventListener("click",t=>{let e=t.currentTarget.querySelector(".nx-rating__total");e&&this.trackFeatureUsed("filter","stars",e.dataset.rating)}),null===(e=this.element.querySelector(".nx-write-review__btn"))||void 0===e||e.addEventListener("click",t=>{this.trackFeatureUsed("write","review","")}),NiveaX.addToEventStore("niveax:RatingsAndReviews:sort",t=>this.trackSort(t)),NiveaX.addToEventStore("niveax:RatingsAndReviews:pagination",()=>this.trackingPagination())}trackProductPageView(){if(window.BV||this.requestAttempts>5){if(!window.BV)return;const e=window.BV,i=this.element.dataset.productid,r=this.element.dataset.categoryid,n=this.element.dataset.rootcategoryid,a=this.element.dataset.brand,s=Array.from(document.querySelectorAll(".nx-product-reviews__review")),o={productId:i,bvProduct:"RatingsAndReviews",brand:a,categoryId:r,rootCategoryId:n},d={bvProduct:"RatingsAndReviews",productId:i,brand:a,type:"Product",categoryId:r,rootCategoryId:n,numReviews:this.element.dataset.reviewCount,avgRating:this.element.dataset.averageRating};try{e.pixel.trackPageView(d),e.pixel.trackImpression({contentId:"reviews",productId:i,categoryId:r,contentType:"review",bvProduct:"RatingsAndReviews",brand:a});for(var t=0;t<s.length;t++)e.pixel.trackInView(o,{minPixels:250,containerId:"nx-review-id-"+s[t].dataset.reviewid}),e.pixel.trackViewedCGC(o,{minPixels:250,minTime:2500,containerId:"nx-review-id-"+s[t].dataset.reviewId})}catch(t){console.log(t)}return}this.requestAttempts++,setTimeout(()=>{this.trackProductPageView()},250)}trackSort({detail:{sortOption:t}}){this.trackFeatureUsed("sort",t,""),this.trackingPagination()}trackingPagination(){let t=this.element.querySelector(".nx-btn--load-more");null==t||t.addEventListener("click",t=>{this.trackFeatureUsed("Pagination","pagination","")})}trackFeatureUsed(t,e,i){if(window.BV){var r=window.BV;try{r.pixel.trackEvent("Feature",{type:"Used",name:t,brand:this.element.dataset.brand,productId:this.element.dataset.productid,bvProduct:"RatingsAndReviews",categoryId:this.element.dataset.categoryid,detail1:e,detail2:i})}catch(t){console.log(t)}}}}s.setup(a)}}]); 2//# sourceMappingURL=/dist/NiveaX/./modules/NivTBazaarVoice.b309989f.js.dcd6c284.map
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.