1"use strict";(self.NiveaXwebpackJsonp=self.NiveaXwebpackJsonp||[]).push([[8791,9384],{37564:(e,t,s)=>{s.r(t),s.d(t,{default:()=>r});var n=s(84444),a=s(21464),i=s(98684);const o=["nx-u-spinner","nx-u-spinner--medium"];class r extends n.default{constructor(e,t={}){super(e,t),this.options=(0,a.$E)(this.element,this.options),this.init()}getDefaultOptions(){const e=super.getDefaultOptions();return Object.assign(Object.assign({},e),{layerModifierClasses:`${e.layerMainClass}--page`,layerCloseBtnModifierClass:`${e.layerMainClass}__close-btn--page`,layerCloseIconClass:`${e.layerCloseIconClass} nx-close-icon--thin`,beforeOpen:async()=>{await window.NiveaX.initModules()},afterOpen:async()=>{},beforeClose:async()=>{},afterClose:async()=>{}})}get isOpen(){return document.body.contains(this.layer)}showSpinner(){return(0,i.gR)(this.layer.querySelector(".nx-layer__wrapper"),...o),this.isOpen||a.LW.prevent(!0),super.open(),this}async open(e=()=>{}){const{layerMainClass:t,beforeOpen:s,afterOpen:n}=this.options;await s(),this.backButton(),this.isOpen||a.LW.prevent(!0),(0,i.jo)(this.layer.querySelector(".nx-layer__wrapper"),...o),super.open(),(0,a.mS)(()=>this.layer.classList.add(`${t}--open`)),window.NiveaX.loadShopPrices(),await n(),e()}async close(e=()=>{}){const{layerMainClass:t,beforeClose:s,afterClose:n}=this.options;await s(),sessionStorage.removeItem("layers"),(0,i.iQ)(this.layer,`${t}--closing`),(0,a.Ys)(()=>{(0,i.jo)(this.layer,`${t}--open`,`${t}--closing`),super.close()},400),(document.body.classList.contains("nx-u-lock-screen")||document.body.classList.contains("nx-u-prevent-scroll"))&&a.LW.allow(),await n(),e()}backButton(){let e,t,s=sessionStorage.getItem("layers");if(s)if(e=JSON.parse(s),e.includes(location.hash)){let s=e.findIndex(e=>e==location.hash)+1;e=e.slice(0,s),t=[...e]}else t=[...e,location.hash];else t=[location.hash];sessionStorage.setItem("layers",`${JSON.stringify(t)}`),t.length>1?this.layer.classList.add("nx-layer--show-back-tbn"):this.layer.classList.remove("nx-layer--show-back-tbn")}}},91950:(e,t,s)=>{s.r(t),s.d(t,{default:()=>b});var n=s(19446),a=s(88692),i=s(8481),o=s(45204),r=s(41445),l=s(60778),c=s(71678),p=s(24329),u=s(24746),h=s(70846);var y=function(){function e(e,t){this.predicate=e,this.inclusive=t}return e.prototype.call=function(e,t){return t.subscribe(new d(e,this.predicate,this.inclusive))},e}(),d=function(e){function t(t,s,n){var a=e.call(this,t)||this;return a.predicate=s,a.inclusive=n,a.index=0,a}return u.C6(t,e),t.prototype._next=function(e){var t,s=this.destination;try{t=this.predicate(e,this.index++)}catch(e){return void s.error(e)}this.nextOrComplete(e,t)},t.prototype.nextOrComplete=function(e,t){var s=this.destination;Boolean(t)?s.next(e):(this.inclusive&&s.next(e),s.complete())},t}(h.v),f=s(37564),m=s(21464),v=s(98684);const C='[data-module="LayerPage"]';class b extends f.default{static setup(e=C){Array.from(document.querySelectorAll(e)).filter(e=>!e.dataset.moduleInitialized).forEach(e=>{new b(e),e.dataset.moduleInitialized="true"})}constructor(e,t={}){super(e,t),this.listenToEvents()}getDefaultOptions(){const e=super.getDefaultOptions();return Object.assign(Object.assign({},e),{layerModifierClasses:`${e.layerMainClass}--page`,layerCloseBtnModifierClass:`${e.layerMainClass}__close-btn--page`,layerCloseIconClass:`${e.layerCloseIconClass} nx-close-icon--thin`,beforeOpen:async()=>{await NiveaX.initModules()},afterOpen:async()=>{},beforeClose:async()=>{},afterClose:async()=>{}})}listenToEvents(){const e=(0,n.R)(this.layerContent,"touchstart",{passive:!0}).pipe((0,o.p)(e=>e.target===e.currentTarget)),t=(0,n.R)(document,"touchend",{passive:!0}).pipe((0,r.M)(()=>requestAnimationFrame(()=>this.wrapper.removeAttribute("style")))),s=(0,n.R)(document,"touchmove",{passive:!0}).pipe((0,l.T)(e=>e.changedTouches[0].clientY)),{layerMainClass:u}=this.options;return e.pipe((0,l.T)(e=>e.changedTouches[0].clientY),(0,c.n)(e=>{return(0,a.zV)((0,i.of)(e),s).pipe((0,p.Q)(t),(n=()=>!(0,v.nB)(this.layer,`${u}--closing`),void 0===o&&(o=!1),function(e){return e.lift(new y(n,o))}));var n,o})).subscribe(([e,t])=>{const s=t-e,n=s/(.3*document.documentElement.offsetHeight),a={transform:`translateY(${Math.max(s,0)}px) scale(${Math.min(1-.2*n,1)})`,transition:"none",overflow:"hidden",opacity:Math.min(1-.6*n,1)};n<1?this.wrapper.setAttribute("style",(0,v.FQ)(a)):(this.close(),(0,m.Ys)(()=>{this.wrapper.removeAttribute("style")},300))}),this}
1getLayerNode(){return this.layer}}b.setup(C)}}]); 2//# sourceMappingURL=/dist/NiveaX/./modules/LayerPage.61b15bda.js.804cd42a.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.