1"use strict";(self.NiveaXwebpackJsonp=self.NiveaXwebpackJsonp||[]).push([[1870,4794],{11332:(e,t,o)=>{o.r(t),o.d(t,{default:()=>s});var d=o(30938),i=o(23425);const a='[data-module="PromoCode"]';class s extends((0,i.A)(d.default)){static setup(e=a){Array.from(document.querySelectorAll(e)).filter(e=>!e.dataset.moduleInitialized).forEach(e=>{new s(e),e.dataset.moduleInitialized="true"})}constructor(e){super(e),this.element=e,this.trackPromoCodeImpression(),this.codeHolder.addEventListener("click",()=>this.trackPromoCodeClick())}trackPromoCodeImpression(){this.dataLayer.push({event:"promoView",ecommerce:{promoView:{promotions:[{id:this.code,name:this.code,creative:this.dataLayer[0]?this.dataLayer[0].template:"",position:"Promo Code"}]}}})}trackPromoCodeClick(){this.dataLayer.push({event:"promoClick",ecommerce:{promoClick:{promotions:[{id:this.code,name:this.code,creative:this.dataLayer?this.dataLayer[0].template:"",position:"Promo Code"}]}}})}}s.setup(a)},30938:(e,t,o)=>{o.r(t),o.d(t,{default:()=>d});class d{static setup(e='[data-module="PromoCode"]'){Array.from(document.querySelectorAll(e)).filter(e=>!e.dataset.moduleInitialized).forEach(e=>{new d(e),e.dataset.moduleInitialized="true"})}constructor(e){this.element=e,this.codeHolder=this.element.querySelector(".nx-promo-code__holder"),this.promoText=this.element.querySelector(".nx-promo-code__text"),this.code=this.element.getAttribute("data-promo-code"),this.isCodeCopied(),this.codeHolder.addEventListener("click",()=>this.copyDivToClipboard()),document.body.oncopy=()=>this.unsetCodeAsCopied()}copyDivToClipboard(){navigator.clipboard.writeText(this.element.getAttribute("data-promo-code")),this.setCodeAsCopied()}isCodeCopied(){navigator.clipboard.readText().then(e=>this.code==e?this.setCodeAsCopied():null)}setCodeAsCopied(){this.element.classList.add("nx-promo-code--copied"),this.setCopiedText()}unsetCodeAsCopied(){this.element.classList.remove("nx-promo-code--copied"),this.setPromoText()}setPromoText(){this.promoText.innerHTML=this.element.getAttribute("data-promo-code-default-text")}setCopiedText(){this.promoText.innerHTML=`${this.element.getAttribute("data-promo-code-after-click-text")} \n <svg id="a0abceeb-e8e3-4747-8c15-d48a3a83414f" data-name="icons_outline" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32">\n <defs><style>.f146dc11-2ac7-4e61-b077-52b8c0f2d633{fill:#b8e986;}.fd9462b9-5513-4105-b7f4-1fe837fd13ed{fill:none;stroke:#417505;stroke-linecap:round;stroke-width:2px;}</style></defs>\n <title>ok</title>\n <g id="adf38e87-c06f-4935-af39-798290241168" data-name="ok">
1<circle id="a64f1a6e-5282-4af8-8b0b-656c553ef49c" data-name="Oval-2" class="f146dc11-2ac7-4e61-b077-52b8c0f2d633" cx="16" cy="16" r="15"/>\n <path id="b87c261a-5101-4d66-a610-42cc1f98a5a9" data-name="Line" class="fd9462b9-5513-4105-b7f4-1fe837fd13ed" d="M22.2955,10.9268l-7.8441,9.33"/><path id="ef7ddbf2-0877-4143-949c-6e6c458e3378" data-name="Line" class="fd9462b9-5513-4105-b7f4-1fe837fd13ed" d="M14.4514,20.257,10.24,15.9635"/>\n </g>\n </svg>`}}}}]); 2//# sourceMappingURL=/dist/NiveaX/./modules/PromoCode-PromoCodeWithT.c30823bb.js.5e581757.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.