1import{G as g,Y as w,V as f,q as l,az as P,aA as y,ab as C,P as d,O as v,aj as F,_,r as u,o as c,c as E,l as h,ae as O}from"./index-D-iuxWOd.js";import{E as I}from"./EmbedContent-ehOEB7wE.js";var $=Object.defineProperty,B=Object.getOwnPropertyDescriptor,r=(n,e,s,a)=>{for(var o=a>1?void 0:a?B(e,s):e,m=n.length-1,i;m>=0;m--)(i=n[m])&&(o=(a?i(e,s,o):i(o))||o);return a&&o&&$(e,s,o),o};const S=g("contentPage");let t=class extends f{constructor(){super(...arguments),this.consentManagerVendorId=l.consentManager.vendorIds.contentflow,this.embedContentElement=void 0,this.embedContentHeight=l.thirdParty.contentFlow.height,this.embedContentSource="",this.resizeObserver=null,this.contentFlowVideoPreviewImage=P}beforeUnmount(){this.resizeObserver&&this.embedContentElement&&this.resizeObserver.unobserve(this.embedContentElement)}mounted(){var e;this.embedContentElement=(e=this.$refs.contentFlowEmbed)==null?void 0:e.$el,this.embedContentSource=this.urlWithParameters,this.setEmbedContentHeight()}get urlWithParameters(){return`${l.thirdParty.contentFlow.embedUrl}/${this.embedId}${this.buildParams()}`}get shouldRenderContentFlowPreviewImage(){return this.currentPaywallType!==y.FREE&&this.outputMedium!==C.Embedded}buildParams(){const e={};return this.autoplay&&(e.autoplay=this.autoplay.toString()),this.mute&&(e.muted=this.mute.toString()),this.noBranding&&(e.no_branding=this.noBranding.toString()),`?${new URLSearchParams(e).toString()}`}setEmbedContentHeight(){this.embedContentElement&&(this.resizeObserver=new ResizeObserver(e=>{e.forEach(s=>{const a=s.contentRect.width,o=Math.round(a/l.thirdParty.contentFlow.ratioX*l.thirdParty.contentFlow.ratioY);this.embedContentHeight=`${o}px`})}),this.resizeObserver.observe(this.embedContentElement))}};r([d({type:String,required:!0})],t.prototype,"embedId",2);r([d({type:Boolean,default:!1})],t.prototype,"autoplay",2);r([d({type:Boolean,default:!1})],t.prototype,"mute",2);r([d({type:Boolean,default:!1})],t.prototype,"noBranding",2);r([d({type:Boolean,default:!1})],t.prototype,"withoutPadding",2);r([w("getMedium")],t.prototype,"outputMedium",2);r([S.Getter("currentPaywallType")],t.prototype,"currentPaywallType",2);t=r([v({name:"ContentFlow",components:{EmbedContent:I,DnmPicture:F}})],t);function z(n,e,s,a,o,m){const i=u("DnmPicture"),b=u("EmbedContent");return c(),E("section",{class:O(["contentFlow",{"--withoutPadding":n.withoutPadding}])},[n.shouldRenderContentFlowPreviewImage?(c(),h(i,{key:0,image:n.contentFlowVideoPreviewImage,class:"contentFlow__fallbackImage","data-testid":"contentFlow-fallback-image",height:"100%","keep-original-image-ratio":"",width:"100%"},null,8,["image"])):(c(),h(b,{key:1,"consent-manager-vendor-id":n.consentManagerVendorId,height:n.embedContentHeight,src:n.embedContentSource,allow:"fullscreen","data-testid":"content-flow-embed-content",ref:"contentFlowEmbed"},null,8,["consent-manager-vendor-id","height","src"]))],2)}const H=_(t,[["render",z],["__scopeId","data-v-573b0859"]]);var p;try{"__c"in t&&((p=t.__c).componentFileName??(p.componentFileName=Object.create(null)),Object.defineProperty(t.__c,"componentFileName",{value:"app/components/storyline/contentFlow/ContentFlow.vue"}))}catch(n){console.error("injectFileNamePlugin",n)}export{H as default};
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.