{"version":3,"mappings":"4UAaO,QAMHA,YAAsCC,EACAC,EACnBC,EACAC,EACsBC,EACDC,GALFC,eACAA,eACnBA,aACAA,wBACsBA,iBACDA,UATjCA,oBAAiB,IAAIC,KAUxB,MAAMC,EAAOF,KAEbG,OAAOC,iBAAiB,UAAW,SAAUC,GACrCA,EAAMC,OAAOC,QAAQZ,IAAY,GAC7BO,EAAKM,KACLN,EAAKM,GAAGC,MAAMC,OAASL,EAAMM,KAAO,QAKhDX,KAAKY,MAAMC,YAAYC,MAAK,OAAUd,KAAKe,iBAAiBC,UAAUX,IAC9DA,EAAQY,MACRjB,KAAKkB,uBAAyBb,EAAQY,IACtCjB,KAAKmB,OAASnB,KAAKoB,UAAUC,+BAA+BrB,KAAKsB,QAAUjB,EAAQY,KACnFjB,KAAKuB,iBAAiBC,cAKlCC,WAAQ,CAGRC,OAAOhC,GACHM,KAAKQ,GAAuBd,EAAGiC,OAC/B3B,KAAK4B,YAGTA,YACI,MAAMlC,EAAOM,KACb6B,WAAW,WACPnC,EAAKc,GAAGsB,cAAcC,YAAY,SAAUrC,EAAK4B,UAClD,KAMPU,cACIhC,KAAKe,eAAekB,OACpBjC,KAAKe,eAAemB,kDAnDfC,GAAsBC,MAMX,WAASA,MACT,WAASA,6BAGTC,MAAYD,MACZE,+BAXXH,EAAsBI,wOCbnCH,iBACIA,oBAA8EA,gCAAQzC,aAARyC,CAAuB,2BAC5EzC,gBAAW,SAC2ByC,QACnEA,eAHYA,gGCKL,MAAMI,EAAS,CAClB,CAACC,KAAM,GAAIC,UAAWP,EAAwBQ,UAAW,SAatD,+CAAMC,4DATA,CACLC,KACAC,cAAsBN","names":["constructor","n","i","l","a","U","y","this","C","f","window","addEventListener","o","origin","indexOf","el","style","height","data","route","queryParams","pipe","ngUnsubscribe$","subscribe","url","nowDisplayingTypo3Page","cmsUrl","sanitizer","bypassSecurityTrustResourceUrl","CMS_URL","scrollingService","scrollTo","ngOnInit","onload","target","getHeight","setTimeout","contentWindow","postMessage","ngOnDestroy","next","complete","r","t","d","v","selectors","m","path","component","pathMatch","s","g","h"],"sources":["webpack:///src/app/modules/static-content/static-content.component.ts","webpack:///src/app/modules/static-content/static-content.component.html","webpack:///src/app/modules/static-content/static-content.module.ts"],"sourcesContent":["import {Component, Inject, Input, OnInit} from '@angular/core';\nimport {DomSanitizer, SafeResourceUrl} from '@angular/platform-browser';\nimport {ActivatedRoute, Router} from '@angular/router';\nimport {ScrollingService} from '../../core/services/scrolling.service';\nimport {takeUntil} from 'rxjs/operators';\nimport {Subject} from 'rxjs';\nimport {UserService} from '../../core/services/user.service';\n\n@Component({\n selector: 'static-content',\n templateUrl: './static-content.component.html',\n styleUrls: ['./static-content.component.scss']\n})\nexport class StaticContentComponent implements OnInit {\n public el: HTMLFrameElement;\n public ngUnsubscribe$ = new Subject();\n public nowDisplayingTypo3Page: string;\n public cmsUrl: SafeResourceUrl;\n\n constructor(@Inject('API_URL') public API_URL,\n @Inject('CMS_URL') public CMS_URL,\n public route: ActivatedRoute,\n public scrollingService: ScrollingService,\n @Inject(DomSanitizer) public sanitizer: DomSanitizer,\n @Inject(UserService) public us: UserService) {\n const self = this;\n // this.cmsUrl = sanitizer.bypassSecurityTrustResourceUrl(CMS_URL + this.route.snapshot.queryParamMap.get('url'));\n window.addEventListener('message', function (event) {\n if (event.origin.indexOf(CMS_URL) >= 0) {\n if (self.el) {\n self.el.style.height = event.data + 'px';\n }\n }\n });\n\n this.route.queryParams.pipe(takeUntil(this.ngUnsubscribe$)).subscribe(changed => {\n if (changed.url) {\n this.nowDisplayingTypo3Page = changed.url;\n this.cmsUrl = this.sanitizer.bypassSecurityTrustResourceUrl(this.CMS_URL + changed.url);\n this.scrollingService.scrollTo();\n }\n });\n }\n\n ngOnInit() {\n }\n\n onload(ev: Event) {\n this.el = ev.target;\n this.getHeight();\n }\n\n getHeight() {\n const self = this;\n setTimeout(function () {\n self.el.contentWindow.postMessage('height', self.CMS_URL);\n }, 500);\n }\n\n /**\n * Unsubscribe from all subscriptions.\n */\n ngOnDestroy(): void {\n this.ngUnsubscribe$.next();\n this.ngUnsubscribe$.complete();\n }\n}\n","
\n \n
\n","import {NgModule} from '@angular/core';\nimport {CommonModule} from '@angular/common';\nimport {StaticContentComponent} from './static-content.component';\nimport {WebshopLoaderComponent} from '../webshop/webshop-loader/webshop-loader.component';\nimport {RouterModule} from '@angular/router';\n\nexport const routes = [\n {path: '', component: StaticContentComponent, pathMatch: 'full'}\n];\n\n@NgModule({\n imports: [\n CommonModule,\n RouterModule.forChild(routes),\n ],\n declarations: [\n StaticContentComponent\n ],\n exports: [StaticContentComponent]\n})\nexport class StaticContentModule {\n}\n"]}