1"use strict";(self.webpackChunktt_com_www_ng=self.webpackChunktt_com_www_ng||[]).push([["apps_tt-com-www_ng_src_app_pages_mobile-preview-frame_mobile-preview-frame_component_ts"],{37371(M,w,a){a.d(w,{MobilePreviewFrameComponent:()=>f});var s=a(17705),l=a(85802),g=a(32271),h=a(81230),c=a(10750),r=a(52086),e=a(35547);const v=["previewIframe"];function p(o,m){if(1&o){const i=e.RV6();e.j41(0,"in-preview-toggle",9),e.bIt("toggled",function(t){l.eBV(i);const d=e.XpG(2);return l.Njj(d.togglePaywall(t))}),e.k0s()}if(2&o){const i=e.XpG(2);e.Y8G("checked",i.paywallActive())("disabled",i.adsActive())}}function u(o,m){if(1&o){const i=e.RV6();e.j41(0,"in-preview-toggle",10),e.bIt("toggled",function(t){l.eBV(i);const d=e.XpG(2);return l.Njj(d.toggleAds(t))}),e.k0s()}if(2&o){const i=e.XpG(2);e.Y8G("checked",i.adsActive())("disabled",i.paywallActive())}}function b(o,m){if(1&o&&(e.j41(0,"in-preview-toggles",6),e.nVh(1,p,1,2,"in-preview-toggle",7),e.nVh(2,u,1,2,"in-preview-toggle",8),e.k0s()),2&o){const i=e.XpG();e.R7$(),e.vxM(i.showPaywallToggle()?1:-1),e.R7$(),e.vxM(i.showAdsToggle()?2:-1)}}let f=(()=>{class o{constructor(){this.sanitizer=(0,l.WQX)(h.up),this.iframe=(0,s.ebz)("previewIframe"),this.src=s.hFB.required(),this.layoutLink=s.hFB.required(),this.writerUrl=(0,s.hFB)(""),this.showLoginButton=(0,s.hFB)(!1),this.exitMobilePreview=(0,s.CGW)(),this.login=(0,s.CGW)(),this.iframeUrl=(0,g.EW)(()=>this.sanitizer.bypassSecurityTrustResourceUrl(this.src())),this.rowActions=(0,g.EW)(()=>{const i=[{id:"layout",label:"Layout",icon:"article",routerLink:this.layoutLink()}];return this.writerUrl()&&i.push({id:"writer",label:"Im Writer \xf6ffnen",icon:"open_in_new",href:this.writerUrl()}),i}),this.stackedActions=(0,g.EW)(()=>{const i=[{id:"desktop-preview",label:"Desktop-Vorschau",icon:"computer"}];return this.showLoginButton()&&i.push({id:"login",label:"Anmelden",icon:"login"}),i}),this.availableToggles=(0,l.vPA)([]),this.showPaywallToggle=(0,g.EW)(()=>this.availableToggles().includes(r.Tb.Paywall)),this.showAdsToggle=(0,g.EW)(()=>this.availableToggles().includes(r.Tb.Ads)),this.paywallActive=(0,l.vPA)(!1),this.adsActive=(0,l.vPA)(!1)}onPreviewMessage(i){i.origin!==window.location.origin||!(0,r.Af)(i.data)||"available-toggles"===i.data.kind&&(this.availableToggles.set(i.data.toggles),this.paywallActive.set(!1),this.adsActive.set(!1))}onAdminAction(i){"login"===i?this.login.emit():this.exitMobilePreview.emit()}togglePaywall(i){this.paywallActive.set(i),this.postToggle(r.Tb.Paywall,i)}toggleAds(i){this.adsActive.set(i),this.postToggle(r.Tb.Ads,i)}postToggle(i,n){const t={type:r.Pr,kind:"toggle-change",toggle:i,value:n};this.iframe()?.nativeElement.contentWindow?.postMessage(t,window.location.origin)}static{this.\u0275fac=function(n){return new(n||o)}}static{this.\u0275cmp=e.VBU({type:o,selectors:[["tt-mobile-preview-frame"]],viewQuery:function(n,t){1&n&&e.wEZ(t.iframe,v,5),2&n&&e.NyB()},hostBindings:function(n,t){1&n&&e.bIt("message",function(_){return t.onPreviewMessage(_)},e.tSv)},inputs:{src:[1,"src"],layoutLink:[1,"layoutLink"],writerUrl:[1,"writerUrl"],showLoginButton:[1,"showLoginButton"]},outputs:{exitMobilePreview:"exitMobilePreview",login:"login"},decls:7,vars:4,consts:[["previewIframe",""],[1,"emulator"],[3,"actionTriggered","rowActions","stackedActions"],[1,"emulator__stage"],[1,"emulator__device-frame"],["title","Mobile-Vorschau",1,"emulator__iframe",3,"src"],[1,"do-not-print"],["label","Preview mit Paywall",3,"checked","disabled"],["label","Preview mit Werbung",3,"checked","disabled"],["label","Preview mit Paywall",3,"toggled","checked","disabled"],["label","Preview mit Werbung",3,"toggled","checked","disabled"]],template:function(n,t){1&n&&(e.j41(0,"div",1)(1,"in-preview-admin-bar",2),e.bIt("actionTriggered",function(_){return t.onAdminAction(_)}),e.k0s(),e.j41(2,"div",3)(3,"div",4),e.nrm(4,"iframe",5,0),e.k0s()(),e.nVh(6,b,3,2,"in-preview-toggles",6),e.k0s()),2&n&&(e.R7$(),e.Y8G("rowActions",t.rowActions())("stackedActions",t.stackedActions()),e.R7$(3),e.Y8G("src",t.iframeUrl(),e.f$h),e.R7$(2),e.vxM(t.showPaywallToggle()||t.showAdsToggle(
1)?6:-1))},dependencies:[c.kU,c.KD,c.tl],styles:["[_nghost-%COMP%]{display:block}.emulator[_ngcontent-%COMP%]{display:flex;flex-direction:column;min-height:100vh;background:#f8f8f8;color:#333;padding:0 16px}.emulator__stage[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;align-items:center;padding:32px 0}.emulator__device-frame[_ngcontent-%COMP%]{width:390px;height:844px;max-width:calc(100vw - 32px);max-height:calc(100vh - 80px);background:#fff;border-radius:24px;border:10px solid #111;box-shadow:0 12px 40px #0000002e;overflow:hidden}.emulator__iframe[_ngcontent-%COMP%]{display:block;width:100%;height:100%;border:0;background:#fff}"],changeDetection:0})}}return o})()}}]);
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.