1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2710],{44385:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/verticalVideoEmbed",function(){return a(65952)}])},65952:(e,t,a)=>{"use strict";a.r(t),a.d(t,{UnwrappedVerticalVideoEmbedPage:()=>H,default:()=>B});var i=a(37876),r=a(14232),s=a(48011),n=a(77328),o=a.n(n),d=a(15039),l=a.n(d),c=a(19081),p=a(51845),u=a(7885),m=a(11426),v=a(37635),y=a(45881),b=a(22239),g=a(6281),h=a(85358),_=a(31586),x=a(77828),f=a(18410),E=a(74455),j=a(65508),C=a(72872),N=a(96926),P=a(39194),S=a(21350),w=a(39200),V=a(61697),k=a(56004),I=a(95737),O=a(21346),T=a(42340);a(45361),a(64712);var A=a(67657),q=a.n(A),F=a(41201),M=a.n(F);let W="embedded-vertical-video",R={aspectratio:"9:16",controls:!0,controlBar:{layout:[{name:"time"}]},stretching:"uniform",displayPlaybackLabel:!0,playbackRateControls:!0,renderCaptionsNatively:!1,repeat:!1,skin:{name:"gamma",active:x.wN,inactive:"#FFFFFF"}},H=({layout:e,autoPlay:t=!1,nowPlaying:a,vertical:s="",statusCode:n=200,disableContinuousPlay:d,appliedEntitlements:u="",associatedPlaylists:m=[],setCurrentVideo:v})=>{let x=(0,y.S)(),{publicRuntimeConfig:{PREVIEW_MODE:O=!1}={}}=(0,c.Ay)()||{},[A,F]=r.useState(!1);r.useEffect(()=>{F(!0),void 0!==p.stub&&(0,p.stub)("register","ramen_VerticalVideoActions")},[]);let H=r.useMemo(()=>!O&&x.isContentSubscriberOnly(a),[a,O,x]),B=A?x.shouldRenderPlaceholder(a):H,L=(0,_.hZ)(e=>e.showAuthenticationModal),{state:Z}=(0,V.q)(),{subscriptionCompleted:U,subscriberLoggedIn:Y}=(0,g.M)(!!H);(0,b.M)({contentRequiresEntitlements:H,appliedEntitlements:u});
1let D=U||Y,X=Z?.display==="preferences";r.useEffect(()=>{!D||L||X||window.location.reload()},[D,L,X]),(0,h.a)({dateCreated:a?.dateCreated,contentSection:a?.unibrow?.text,tags:a?.taxonomy?.additionalTerms?.map(e=>e?.slug).filter(Boolean),contentIsNative:a?.nativeAd,pageType:W});let $=r.useMemo(()=>{let[e]=m;return(e?.videos??[]).filter(f.h)},[m]),J=r.useMemo(()=>$.findIndex(e=>String(e.id)===String(a?.id)),[$,a?.id]),K=d||-1===J?void 0:$[J+1],[z,G]=r.useState(!1),Q=r.useCallback(()=>{K&&(void 0!==p.stub&&(0,p.stub)("track","ramen_VerticalVideoActions",{action:"playlist_autoplay",packageType:"embed",videoId:K.id,subscriberTag:x.isContentSubscriberOnly(K)?"SUBSCRIBER_ONLY":""}),G(!0),v(K))},[K,x,v]);return a?.error?((0,E.vV)("verticalVideoNowPlayingError",a.error),(0,i.jsx)(T.default,{statusCode:404===n?404:500,vertical:s,layout:e})):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(o(),{children:[(0,i.jsx)("meta",{name:"robots",content:"noindex"},"robots"),(0,i.jsx)("meta",{name:"googlebot",content:"indexifembedded"}),(0,i.jsx)(k.A,{})]}),(0,i.jsx)(I.N,{videos:[a],vertical:s}),(0,i.jsx)(C.W,{vertical:s}),(0,i.jsx)("div",{className:l()(M().container),children:(0,i.jsx)("div",{className:`df items-center justify-center ${q().embeddedWrapper}`,children:(0,i.jsx)("div",{className:q().playerWrapper,"data-testid":"vertical-video-embed__player",children:D?(0,i.jsx)("div",{className:q().loadingSlate,"data-testid":"vertical-video-embed__loading-slate",children:(0,i.jsx)(S.q,{})}):B?(0,i.jsx)(w.C,{video:a,vertical:s,packageType:"embed"}):(0,i.jsx)(P.Y,{autoPlay:t||z,video:a,config:R,useEmbeddedAds:!0,enableAds:!0,isInlineVideo:!0,alwaysShowControls:!0,showPlayIconWhenPaused:!1,continuousPlay:!d,onVideoEnd:K?Q:void 0,playlistIndex:J>-1?J:void 0,playlistId:a?.associatedVideoPlaylist?.id||"",className:"embedded-vertical-video-player",skipViewTracking:!0})})})}),(0,i.jsx)(N.I,{}),(0,i.jsx)(j.A,{})]})};H.getInitialProps=async e=>{let t,{req:{headers:{cookie:a}={},params:{id:i,vertical:r},query:{autoplay:s,disableContinuousPlay:n}},store:o,res:{locals:{vertical:d,logger:l,correlationId:c}}}=e,p="",y=[o.dispatch((0,u.mc)(i,r,a,!1,{...c&&{"x-correlation-id":c}})).then(e=>{t=e?.headers?.get("x-applied-entitlements")??"",p=e?.headers?.get("x-entitlement-resolution")??""}),o.dispatch((0,m.r3)(W))];r&&y.push(o.dispatch((0,m.Zk)(r))),await Promise.all(y);let b=o.getState(),{current:g}=b.video,{status:h}=g.error?g.error:{status:200},_=b?.video?.current?.taxonomy?.primaryVertical?.slug??d;if(r||await o.dispatch((0,m.Zk)(_)),(0,v.n)(e.res,_),e.req&&e.res){let{universalCookies:a}=e.req,i=a?.get("edge_entitlements",{doNotParse:!0}),r=!!a?.get("SESSION",{doNotParse:!0});void 0!==t&&(0,O.hasEntitlementMismatch)(t,i,r)&&(l?.info("Entitlement mismatch detected. Setting Cache-Control header to no-store.",{appliedEntitlements:t,edgeEntitlements:(0,O.getCanonicalEntitlementsFromEdgeCookie)(i),sessionCookiePresent:r,entitlementResolution:p}),e.res.setHeader("Cache-Control","no-store"),e.res.setHeader("x-cache-no-store-reason","entitlement-mismatch"))}return{autoPlay:"true"===s,statusCode:h,vertical:d,disableContinuousPlay:"true"===n,appliedEntitlements:t??""}};let B=(0,s.Ng)(({video:e})=>({nowPlaying:e.current,associatedPlaylists:e.associatedPlaylists}),e=>({setCurrentVideo:t=>e((0,u.iY)(t))}))(H)},67657:e=>{e.exports={embeddedWrapper:"verticalVideoEmbed_embeddedWrapper__OUcqH",playerWrapper:"verticalVideoEmbed_playerWrapper__Z3DaH",loadingSlate:"verticalVideoEmbed_loadingSlate__6ktp9"}},95737:(e,t,a)=>{"use strict";a.d(t,{N:()=>l});var i=a(37876);a(14232);var r=a(77328),s=a.n(r),n=a(95062),o=a(92213),d=a(57934);function l({videos:e=[],vertical:t="",section:a=""}){return(0,i.jsx)(s(),{children:e.map(e=>(0,i.jsx)("script",{type:"application/ld+json",dangerouslySetInnerHTML:{__html:JSON.stringify((0,o.jo)({video:e,vertical:t,section:a}))}},`VideoObjectLD-${e.id}`))})}l.propTypes={videos:(0,n.arrayOf)(d.Ki),vertical:n.string,section:n.string}}},e=>{e.O(0,[8513,7319,3364,2945,7929,9e3,2724,9747,1852,2954,129,5780,4232,1684,4646,2842,6693,7970,908,3169,636,8974,8792],()=>e(e.s=44385)),_N_E=e.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.