!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e.SENTRY_RELEASE={id:"substack@538433c"};var t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="7e5965ed-094b-4231-9fec-176ea20b7448",e._sentryDebugIdIdentifier="sentry-dbid-7e5965ed-094b-4231-9fec-176ea20b7448")}catch(e){}}();"use strict";(self.webpackChunksubstack=self.webpackChunksubstack||[]).push([["90651"],{7642:function(e,t,n){n.d(t,{A:()=>i});let i={popover:"popover-Q5L48i",visible:"visible-w2GbD1",mounted:"mounted-xAyTLJ",disabled:"disabled-qyVgYn",explainer:"explainer-FXmc_P",dismissExplainer:"dismissExplainer-ns56FG",mobileFooter:"mobileFooter-CGz8PV",button:"button-r00Nrm"}},91086:function(e,t,n){n.d(t,{A:()=>i});let i={transcriptionStatus:"transcriptionStatus-OyxRN5",transcriptionChunk:"transcriptionChunk-DKBYAw",hoverChunk:"hoverChunk-IPtOLw",rowIndicator:"rowIndicator-jiY8sp",hoverRow:"hoverRow-zMw3pV",activeRow:"activeRow-S2HzS9",rowText:"rowText-T4jYBi",speakerText:"speakerText-lh6QvQ",rowEditableText:"rowEditableText-PLHmec",activeWord:"activeWord-J6YmxG",playCircle:"playCircle-Ech_eu"}},73683:function(e,t,n){n.d(t,{A:()=>i});let i={subscribeButton:"subscribeButton-LcKYi7"}},74213:function(e,t,n){n.d(t,{A:()=>i});let i={postUFI:"postUFI-Oh86n4",postUfi:"postUFI-Oh86n4",hasVoiceover:"hasVoiceover-rbvr3u",editButtonContainer:"editButtonContainer-hWwvUO"}},3526:function(e,t,n){n.d(t,{D:()=>S});var i=n(79785),r=n(4006),o=n(32485),a=n.n(o),l=n(17402),s=n(33764),c=n(84605),d=n(86500),u=n(58418),p=n(35369),h=n(76977),m=n(28911),g=n(63136),f=n(39318),b=n(50963),_=n(57324);let v="ig_modal_logo-jNPKzo",y="logo_substack-xHlM5o";function w(){let e=(0,i._)(["Follow "," in the app"]);return w=function(){return e},e}function Y(){let e=(0,i._)(["Get the Substack app to follow ","'s reading and writing."]);return Y=function(){return e},e}let S=e=>{let{pub:t,slug:n,action:i,platform:o}=e,{iString:S,iTemplate:k}=(0,c.GO)(),[C,I]=(0,u.A)("".concat(o,"_webview_app_upsell"),259200),[D,E]=(0,l.useState)(!C);(0,l.useEffect)(()=>{D&&(0,d.u4)(d.qY.APP_FOOTER_SHEET_CTA_VIEWED,{surface:"post",type:"webview-sheet",platform:o})},[]);let x=(0,f.XV8)(t.subdomain,n,{redirect:"app-store",source:_.VU.postFooter}),T="read"===i?t.logo_url:t.author_photo_url||t.logo_url;return(0,r.Y)(m.aF,{isOpen:D,onClose:()=>{E(!1)},children:(0,r.Y)(m.cw,{children:(0,r.FD)(h.I1,{gap:32,alignItems:"center",paddingY:40,paddingX:24,children:[(0,r.Y)(h.Ye,{alignItems:"center",justifyContent:"center",style:{position:"relative"},children:T?(0,r.FD)(r.FK,{children:[(0,r.Y)(h.pT,{justifyContent:"center",alignItems:"center",className:a()(v,y,"logo_left-HHdifs"),children:(0,r.Y)(s.o,{src:"/img/substack-white.svg",imageIsFixedWidth:!0,useRetinaSizing:!0,maxWidth:44})}),(0,r.Y)(h.pT,{justifyContent:"center",alignItems:"center",className:a()(v,"logo_right-_og3lw"),children:(0,r.Y)(s.o,{className:"ig_image_border-FuLDjr",src:T,imageIsFixedWidth:!0,useRetinaSizing:!0,maxWidth:56})})]}):(0,r.Y)(h.pT,{justifyContent:"center",alignItems:"center",className:a()(v,y),children:(0,r.Y)(s.o,{src:"/img/substack-white.svg",imageIsFixedWidth:!0,useRetinaSizing:!0,maxWidth:44})})}),(0,r.FD)(h.I1,{gap:8,alignItems:"center",children:[(0,r.Y)(g.EY.B1,{align:"center",weight:"semibold",children:"read"===i?S("Read in the Substack app"):k(w(),t.author_name)}),(0,r.Y)(g.EY.B4,{align:"center",fontSize:14,color:"secondary",children:"read"===i?S("Get the Substack app for the best reading experience on the go."):k(Y(),(0,b.$k)(t.author_name))})]}),(0,r.FD)(h.I1,{gap:16,paddingX:16,alignItems:"center",className:"ig_modal_button_container-wKHKdO",children:[(0,r.Y)(p.$n,{priority:"primary",onClick:()=>{(0,d.u4)(d.qY.APP_BANNER_TAPPED,{surface:"post",type:"webview-sheet",platform:o})},href:x,children:S("Open in app")}),(0,r.Y)(p.$n,{priority:"tertiary",onClick:()=>{(0,d.u4)(d.qY.APP_FOOTER_SHEET_CTA_DISMISSED,{surface:"post",type:"webview-sheet",platform:o}),I(),E(!1)},children:S("Maybe later")})]})]})})})}},70997:function(e,t,n){n.d(t,{p:()=>h});var i=n(4006),r=n(87677),o=n(17402),a=n(94794),l=n(86500),s=n(16074),c=n(76977),d=n(63136),u=n(18947),p=n(57324);let h=e=>{let{user:t,isMobile:n,post:h}=e,m=(0,a.aZ)(),g=(null==t?void 0:t.is_contributor)&&!m,f=!n||!g;return((0,o.useEffect)(()=>{f||(0,l.u4)(l.qY.POST_STATS_IN_APP_UPSELL_SEEN,{post_id:h.id,source:"mobile_post_page"})}),f)?null:(0,i.FD)(c.VP,{children:[(0,i.Y)(s.c,{}),(0,i.FD)(c.fI,{className:"statsLink-zUlL_7",alignItems:"center",justifyContent:"space-between",children:[(0,i.Y)(d.EY.B3,{paddingY:16,as:"a",weight:"semibold",translated:!0,href:(0,u.MG)({postId:h.id,params:{utm_source:p.VU.substack,utm_medium:p.Jn.web,utm_campaign:p._9.postStatsUpsellMobilePostPage,redirect:"app-store"}}),onClick:()=>(0,l.u4)(l.qY.POST_STATS_IN_APP_UPSELL_CLICKED,{post_id:h.id,source:"mobile_post_page"}),children:"View stats in the app"}),(0,i.Y)(r.A,{})]}),(0,i.Y)(s.c,{})]})}},76219:function(e,t,n){n.d(t,{u:()=>o});var i=n(4006),r=n(63136);function o(e){let{doiUrl:t,pdfUrl:n}=e;return t&&n?(0,i.FD)(r.EY,{as:"p",children:["Cite as:"," ",(0,i.Y)("a",{href:t,target:"_blank",children:t})," ","•"," ",(0,i.Y)("a",{href:n,target:"_blank",children:"PDF"})]}):null}},71328:function(e,t,n){n.d(t,{k:()=>p});var i=n(69277),r=n(70408),o=n(4006),a=n(60927),l=n(93038),s=n(76977),c=n(63136),d=n(49807);let u={blurb:"blurb-PNfDEK"};function p(e){let{crossPostInfo:{introText:t,crossPostedPub:n,crossPostingByLine:i},postType:r}=e;return(0,o.Y)(s.VP,{paddingTop:8,paddingBottom:24*("podcast"!==r),children:(0,o.FD)(s.VP,{paddingX:20,padding:8,className:u.blurb,gap:12,children:[(0,o.Y)(h,{crossPostedPub:n}),(0,o.Y)(m,{introText:t}),(0,o.Y)(g,{byline:i})]})})}function h(e){let{crossPostedPub:t}=e;return(0,o.FD)(s.fI,{className:u.attribution,gap:8,alignItems:"center",children:[(0,o.Y)(a.A,{stroke:"var(--color-accent)",size:16}),(0,o.FD)(c.EY.Meta,{translated:!0,color:"accent",children:["Cross-posted by ",(0,o.Y)(c.Yq,{href:(0,d.$_T)(t),children:I18N.p(t.name)})]})]})}function m(e){let{introText:t}=e;return t?(0,o.Y)(c.EY.B2,{fontStyle:"italic",children:'"'.concat(t,'"')}):null}function g(e){let{byline:t}=e,n=null==t?void 0:t[0];return n?(0,o.FD)(c.EY.B2,{color:"accent",children:["- ",(0,o.Y)(l.Ay,(0,r._)((0,i._)({},n),{type:"user",uuid:""}))]}):null}},9615:function(e,t,n){n.d(t,{C:()=>h});var i=n(4006),r=n(49802),o=n(71857),a=n(84605),l=n(86500),s=n(35369),c=n(11510),d=n(39318),u=n(55298),p=n(57324);function h(e){let{post:t,pub:n,user:h}=e,{iString:m}=(0,a.GO)(),g=(0,c.Iu)(),f=(0,o.M)(t),b=!!(null==h?void 0:h.reader_installed_at),_=b?(0,d.XV8)(n.subdomain,t.slug,{params:{utm_source:p.VU.web,utm_campaign:p._9.ttsListenButton,action:"play-tts"}}):(0,u.wH)({utm_source:p.VU.web,utm_campaign:p._9.ttsListenButton});return g&&f?(0,i.Y)(s.$n,{priority:"secondary-outline",size:"sm",leading:(0,i.Y)(r.A,{size:14}),href:_,onClick:()=>{(0,l.u4)(l.qY.MOBILE_POST_LISTEN_BUTTON_CLICKED,{post_id:t.id,has_app_installed:b})},"aria-label":m("Listen to this post in the app"),children:m("Listen")}):null}},47789:function(e,t,n){n.d(t,{I:()=>r});var i=n(41935);function r(e){let{post:t,user:n,onChange:r,reaction_token:o,children:a}=e,{toggle:l}=(0,i.Ph)({post:t,user:n,surface:"reader",onChange:r?e=>{let{post:t}=e;return r({post:t})}:void 0,postReactionToken:o});return a(async()=>{await l()})}},3338:function(e,t,n){n.d(t,{V:()=>S});var i=n(4006),r=n(81143),o=n(17402),a=n(15734),l=n.n(a),s=n(47963),c=n(84605),d=n(43294),u=n(86500),p=n(94729),h=n(24078),m=n(35369),g=n(16074),f=n(85329),b=n(76977),_=n(28911),v=n(63136),y=n(11510),w=n(39318),Y=n(57324);let S=e=>{let{post:t,pub:n,freeSignupEmail:a,user:d,magicToken:h,onClose:f,onSubscriptionComplete:v,onUnlockFailed:S,hasCompletedUnlock:I=!1}=e,[D,E]=(0,o.useState)(!0),[x,T]=(0,o.useState)(!1),[P,F]=(0,o.useState)(!d&&!I),[N,A]=(0,o.useState)(I),[O,B]=(0,o.useState)((null==d?void 0:d.email)||a||""),[L,R]=(0,o.useState)(!1),[V,U]=(0,o.useState)(!1),[H,M]=(0,o.useState)(!1),{iString:z}=(0,c.GO)(),W=(0,y.Iu)();(0,o.useEffect)(()=>{(0,u.u4)(u.qY.UNSUBSCRIBED_POST_UNLOCK_MODAL_VIEWED,{post_id:t.id})},[t.id]);let j=()=>{(0,u.u4)(u.qY.UNSUBSCRIBED_POST_UNLOCK_MODAL_DISMISSED,{post_id:t.id,has_reached_max_tokens:L}),E(!1),null==f||f()},q=(0,w.XV8)(n.subdomain,t.slug,{params:{utm_campaign:Y._9.postUnlockUnsubscribedModal,utm_source:Y.VU.post},redirect:"app-store"}),G=async e=>{if((0,u.u4)(u.qY.PAYWALL_UNLOCK_CTA_CLICKED,{post_id:t.id,has_email:!!e||!!(null==d?void 0:d.email),source:"unsubscribed_post_unlock_modal"}),!d&&!e)return void F(!0);let n=e||(null==d?void 0:d.email)||"";if(!n||!n.trim())return void F(!0);B(n),T(!0);try{await l().post("/api/v1/free").send({email:n,source:"post_unlock_upsell"});try{await l().post("/api/v1/post_unlock_token").send({post_id:t.id,token:h,email:n})}catch(n){var i,r,o,a;let e=(null==n||null==(r=n.response)||null==(i=r.body)?void 0:i.error)||(null==n||null==(a=n.response)||null==(o=a.body)?void 0:o.message)||(null==n?void 0:n.message)||"";"Max tokens redeemed"===e?(null==S||S(),R(!0)):U(!0),(0,u.u4)(u.qY.UNSUBSCRIBED_POST_UNLOCK_MODAL_ERROR,{post_id:t.id,error:e,max_redeem_error:"Max tokens redeemed"===e}),console.warn("Failed to create unlock token, user may need to complete setup in app:",n)}null==v||v(),A(!0)}catch(e){console.error("Failed to subscribe or unlock:",e)}finally{T(!1)}},K=async()=>{T(!0);try{await (0,p.x6)("/api/v1/send_app_download_link",{method:"POST",json:{email:O}}),M(!0)}catch(e){console.error("Failed to send app download link:",e)}finally{T(!1)}};return(0,i.Y)(_.aF,{isOpen:D,onClose:j,children:(0,i.Y)(_.cw,{children:N?(0,i.FD)(b.I1,{gap:16,children:[(0,i.Y)(k,{post:t,pub:n,secondaryText:z(W?"Open the Substack app to read this post":"Scan the QR code or receive a link to read this post in the Substack app"),errorText:L?z("You've already redeemed an unlock token"):V?z("Something went wrong. Please try again later."):void 0}),!W&&(0,i.FD)(b.I1,{gap:16,alignItems:"center",children:[(0,i.Y)(s.hj,{size:142,utm_campaign:Y._9.postUnlockUnsubscribedModal,utm_source:Y.VU.post,openUrl:q}),(0,i.Y)(g.v,{}),(0,i.Y)(m.$n,{priority:"primary",onClick:K,disabled:H||x,children:z(H?"Email sent":"Email me a link")})]}),W&&(0,i.Y)(b.I1,{alignItems:"center",paddingBottom:16,children:(0,i.Y)(m.$n,{href:q,style:{width:"80%"},children:z("Install the app")})})]}):P?(0,i.FD)(b.I1,{gap:8,children:[(0,i.Y)(k,{post:t,pub:n}),(0,i.Y)(C,{freeSignupEmail:a,onSubmit:G,isLoading:x})]}):(0,i.FD)(b.I1,{gap:8,children:[(0,i.Y)(k,{post:t,pub:n}),(0,i.Y)(m.$n,{leading:(0,i.Y)(r.A,{}),priority:"primary",paddingY:12,disabled:x,onClick:()=>G(),children:z("Subscribe and unlock")}),(0,i.Y)(m.$n,{priority:"secondary",onClick:j,children:z("Maybe later")})]})})})},k=e=>{var t;let{post:n,pub:r,secondaryText:o,errorText:a}=e,{iString:l}=(0,c.GO)(),s=null==(t=n.publishedBylines)?void 0:t[0],d=s?{id:s.id,name:s.name,photo_url:s.photo_url}:{id:r.author_id,name:r.author_name,photo_url:r.author_photo_url};return(0,i.FD)(b.I1,{gap:16,alignItems:"center",children:[(0,i.Y)(h.tp,{size:96,user:d}),(0,i.FD)(b.I1,{gap:8,alignItems:"center",children:[(0,i.Y)(v.EY.H3,{align:"center",children:l("Unlock this post")}),a&&(0,i.Y)(v.EY.B3,{color:"error",align:"center",children:a}),(0,i.Y)(v.EY.B3,{color:"secondary",align:"center",children:o||l("Get a free subscription and unlock this paid post in the Substack app")})]})]})},C=e=>{let{freeSignupEmail:t,onSubmit:n,isLoading:r}=e,[a,l]=(0,o.useState)(null!=t?t:""),{iString:s}=(0,c.GO)(),u=(0,d.X)();return(0,i.FD)(b.I1,{gap:16,children:[(0,i.Y)(f.j,{name:"email",placeholder:s("Email Address"),ref:u,value:a,onInput:e=>l(e.target.value)}),(0,i.Y)(m.$n,{priority:"primary",onClick:()=>n(a),disabled:r,children:s(r?"Subscribing...":"Subscribe and unlock")}),(0,i.Y)(v.EY.B4,{color:"secondary",weight:"light",align:"center",children:s("Maximum one post unlock per account")})]})}},76185:function(e,t,n){n.d(t,{R:()=>E});var i=n(79785),r=n(4006),o=n(17402),a=n(15734),l=n.n(a),s=n(69277),c=n(48697),d=n(84605),u=n(86500),p=n(69618),h=n(68349),m=n(89490),g=n(35369),f=n(76977),b=n(45974),_=n(63136),v=n(11587),y=n(36372),w=n(82776);function Y(){let e=(0,i._)(["Why do you recommend this Substack?"]);return Y=function(){return e},e}function S(){let e=(0,i._)(["Optional"]);return S=function(){return e},e}let k=e=>{var t;let{pubToRecommendBack:n,recommendingPub:i,recommendedPubs:a,setStep:u,close:k,setLoading:I,source:D}=e,{iString:E,iTemplate:x}=(0,d.GO)(),[T,P]=(0,o.useState)(null),{popToast:F}=(0,y.d)();(0,o.useEffect)(()=>{let e=null==a?void 0:a.find(e=>{let{id:t}=e;return t===n.id});if(null===T&&e){var t;P(null!=(t=e.blurb)?t:null)}},[T,a,n.id]);let N=async()=>{i?(await l().put("/api/v1/recommendations").send((0,s._)({recommended_publication_id:n.id,recommending_publication_id:i.id,source:D||"recommendation_notification_email",suggested:!1},T&&T.trim()?{description:T.trim()}:{})),(null==a?void 0:a.some(e=>{let{id:t}=e;return t!==n.id}))?null==k||k():null==u||u("choose"),I?(I(!0),null==k||k()):((0,h.V2)("/publish/recommendations"),F(()=>(0,r.Y)(y.y,{text:E("Recommendation added")})))):console.warn("No recommending pub")},A=(0,w.getByLine)(n);return(0,r.FD)(r.FK,{children:[(0,r.FD)(f.Ye,{justifyContent:"space-between",alignItems:"center",flex:"grow",paddingX:20,paddingTop:20,paddingBottom:16,borderBottom:"detail",children:[(0,r.Y)(_.EY.H3,{weight:"heavy",flex:"grow",children:E("New recommendation")}),(0,r.Y)(g.K0,{priority:"tertiary",role:"button",size:"sm",title:"Close",onClick:()=>{k&&k()},"aria-label":"close",children:(0,r.Y)(c.A,{size:20})})]}),(0,r.Y)(f.I1,{padding:20,children:(0,r.FD)(f.I1,{gap:24,children:[(0,r.Y)(f.I1,{padding:12,gap:12,bg:"secondary",radius:"sm",shadow:"xs",children:(0,r.FD)(f.Ye,{gap:12,flex:"grow",alignItems:"center",children:[(0,r.Y)(m.az,{radius:"xs",border:"detail",children:(0,r.Y)(b.Nq,{pub:n,size:56,radius:"xs"})}),(0,r.FD)(f.I1,{flex:"grow",minWidth:0,children:[(0,r.Y)(_.EY.B3,{weight:"semibold",ellipsis:!0,children:n.name}),A&&(0,r.Y)(_.EY.B4,{color:"secondary",children:"By ".concat(A)})]})]})}),(0,r.FD)(f.I1,{gap:8,children:[(0,r.FD)(f.Ye,{flex:"grow",justifyContent:"space-between",children:[(0,r.Y)(_.EY.B4,{weight:"semibold",children:x(Y())}),(0,r.Y)(_.EY.B4,{color:"secondary",children:x(S())})]}),(0,r.Y)(v.T,(0,s._)({placeholder:E("Tell your subscribers why they might enjoy ".concat(n.name,"...")),onChange:e=>P(e.currentTarget.value),value:null!=T?T:"",rows:6,maxlength:500},p.b))]}),(0,r.FD)(f.I1,{gap:12,children:[(0,r.Y)(g.$n,{disabled:(null!=(t=null==T?void 0:T.length)?t:0)>500,onClick:N,children:E("Recommend ".concat(n.name))}),(0,r.Y)(C,{})]})]})})]})},C=()=>{let{iString:e}=(0,d.GO)();return(0,r.FD)(_.EY.B4,{color:"secondary",align:"center",children:[e("Recommendations will be shown to people after they subscribe to your Substack.")," ",(0,r.Y)(_.Yq,{href:"https://support.substack.com/hc/en-us/articles/5036794583828-How-can-I-recommend-other-publications-on-Substack-",onClick:()=>{(0,u.u4)(u.qY.MANAGE_RECOMMENDATIONS_LEARN_MORE_CLICKED,{source:"modal-recommend-pub"})},decoration:"underline",children:e("Learn more")})]})};var I=n(28911);function D(){let e=(0,i._)(["Recommend "," to your readers"]);return D=function(){return e},e}let E=e=>{let{pub:t}=e,[n,i]=(0,o.useState)(!0),[a,s]=(0,o.useState)(null),[c,p]=(0,o.useState)(!1),[h,m]=(0,o.useState)(!1),{iString:v,iTemplate:y}=(0,d.GO)();return((0,o.useEffect)(()=>{let e=async()=>{try{let e=(await l().get("/api/v1/publication_user/default")).body;if(s(e),!e||e.id===t.id){p(!0),i(!1);return}let n=await l().get("/api/v1/recommendations/from/".concat(e.id,"/to/").concat(t.id));p(!!n.body),i(!1)}catch(e){console.error("Failed to load recommend cta: ",e)}};!a&&n&&e()},[t,n,a]),n||c||a&&a.invite_only)?null:(0,r.FD)(r.FK,{children:[(0,r.FD)(f.I1,{alignItems:"center",padding:32,gap:20,borderTop:"detail",style:{marginTop:24},"data-testid":"recommendation-footer",children:[(0,r.Y)(b.wg,{pub:t,size:48,openInNewTab:!0}),(0,r.FD)(f.I1,{gap:8,children:[(0,r.Y)(_.EY.H4,{align:"center",children:y(D(),t.name)}),t.hero_text&&(0,r.Y)(_.EY.B3,{color:"secondary",align:"center",clamp:3,children:t.hero_text})]}),(0,r.Y)(g.$n,{onClick:()=>{(0,u.u4)(u.qY.END_OF_POST_RECOMMEND_CTA_CLICKED,{recommended_pub_id:t.id,recommending_pub_id:null==a?void 0:a.id}),m(!0)},children:v("Recommend")})]}),(0,r.Y)(x,{isOpen:h,onClose:()=>m(!1),pubToRecommend:t,recommendingPub:a,setStep:()=>{m(!1)},setLoading:i})]})},x=e=>{let{isOpen:t,onClose:n,pubToRecommend:i,recommendingPub:o,setLoading:a,setStep:l}=e,s=(0,y.d)(),{iString:c}=(0,d.GO)();return(0,r.Y)(I.aF,{isOpen:t,onClose:n,children:(0,r.Y)(k,{pubToRecommendBack:i,recommendingPub:o,setStep:l,close:n,setLoading:e=>{a(e),s.popToast(()=>(0,r.Y)(y.y,{text:c("Recommendation added")}))},source:"end-of-post-recommend-cta"})})}},58925:function(e,t,n){n.d(t,{ut:()=>el,YA:()=>eo});var i=n(20347),r=n(3849),o=n(69277),a=n(4006),l=n(32485),s=n.n(l),c=n(15977),d=n(72170),u=n(17402),p=n(23623),h=n(35426),m=n(89490);let g=(0,m.I4)({className:"backdrop-TSZpWr",height:40,paddingTop:64,paddingBottom:16,paddingLeft:16,paddingRight:16,pointerEvents:"none"}),f="transition-kQjRL0",b="show-SOOiPA",_="hide-xglgl1";function v(e){let{children:t}=e;return(0,a.Y)(h.e.Child,{as:u.Fragment,enter:f,enterFrom:_,enterTo:b,leave:f,leaveFrom:b,leaveTo:_,children:t})}let y="show-RjVr49",w="hide-TYuTf7";function Y(e){let{children:t}=e;return(0,a.Y)(h.e.Child,{as:u.Fragment,enter:"enter-BY7bVS",enterFrom:w,enterTo:y,leave:"leave-AN8v0R",leaveFrom:y,leaveTo:w,children:t})}var S=n(84605),k=n(35369),C=n(10996);function I(e){let{handleQuoteRestack:t,disableRestackButton:n,handleShare:i,isVisible:r,showRestackButton:o}=e;return(0,a.Y)(h.e,{as:u.Fragment,appear:!0,show:r,children:(0,a.Y)(x,{children:(0,a.FD)(C.e$,{children:[(0,a.Y)(v,{children:(0,a.Y)(g,{})}),(0,a.Y)(Y,{children:(0,a.FD)(T,{children:[o&&(0,a.Y)(D,{onClick:t,disabled:n}),(0,a.Y)(E,{onClick:i,showRestackButton:o})]})})]})})})}function D(e){let{onClick:t,disabled:n}=e,{iString:i}=(0,S.GO)();return(0,a.Y)(k.Bj,{onClick:t,leading:(0,a.Y)(c.A,{size:20}),priority:"primary",flex:"grow",disabled:n,children:i("Restack")})}function E(e){let{onClick:t,showRestackButton:n}=e,{iString:i}=(0,S.GO)();return(0,a.Y)(k.Bj,{onClick:t,leading:(0,a.Y)(d.A,{size:20}),priority:"primary",flex:"grow",children:i(n?"Share":"Share quote")})}let x=(0,m.I4)({className:"root-VHsWlA",display:"flex",position:"fixed",padding:16}),T=(0,m.I4)({display:"flex",flex:"grow",justifyContent:"space-between",gap:12,zIndex:1});var P=n(48309),F=n(82853),N=n(49031),A=n(34581),O=n(80548),B=n(9979),L=n(93355),R=n(62870),V=n(98949);let U=e=>{let{pub:t,post:n,style:i,selectionId:r,size:o,hoverOverlay:l=!0}=e,{img:s,imgDownload:c,shareData:d,useNativeShare:p}=(0,L.Y)((0,R.wj)({pub:t,post:n,selectionId:r,style:i})),h=(0,u.useCallback)(async()=>{await (0,R.f3)({post_id:n.id,selection_id:r,aspect_ratio:i.aspectRatio,type:"post_selection",shareData:p?d:void 0,eventName:"SHARE_SELECTION_IMAGE_DOWNLOADED",additionalTrackingData:{interaction:"click"}})},[n.id,r,i.aspectRatio,p,d]);return(0,a.Y)(R.Cs,{onClick:h,href:p?void 0:c,children:(0,a.FD)(R.OK,{size:o,children:[!(0,V.Fr)()&&s&&l&&(0,a.Y)(R.lh,{onClick:h}),(0,a.Y)(R.BB,{img:s})]})})};var H=n(46271),M=n(86500),z=n(94729),W=n(12501),j=n(68349),q=n(76977),G=n(28911),K=n(36372),Q=n(8295),J=n(11510),$=n(39318),X=n(49807),Z=n(57324);let ee=e=>{let{assetStyle:t,aspectRatio:n,loadingSelection:i,post:r,pub:o,themeVariables:l,setAspectRatio:s,assetTheme:c,setAssetTheme:d,selectionId:u}=e,p=[],h=(null==r?void 0:r.cover_image)||(null==o?void 0:o.cover_photo_url);return h&&p.push("image"),l.background_pop&&p.push("accent"),p.push("primary"),(0,a.Y)(G.cw,{children:(0,a.FD)(q.I1,{gap:20,children:[(0,a.Y)(q.pT,{className:"imageContainer-OjAkhl",alignItems:"center",justifyContent:"center",children:r&&u&&!i&&(0,a.Y)(U,{pub:o,post:r,style:t,selectionId:u,size:400,hoverOverlay:!1})}),(0,a.FD)(Q._d,{children:[(0,a.Y)(Q.Jj,{assetThemes:p,assetTheme:c,setAssetTheme:d,theme:l,pubCoverImageUrl:h}),(0,a.Y)(Q.aD,{aspectRatio:n,setAspectRatio:s,includeInstagram:!0})]})]})})},et=e=>{let{pub:t,post:n,isOpen:i,onClose:r,selection:o,selectionId:l,setSelectionId:s,themeVariables:c}=e,{iString:d}=(0,S.GO)(),[p,h]=(0,u.useState)(!1),[m,g]=(0,u.useState)("instagram"),f=(null==n?void 0:n.cover_image)||(null==t?void 0:t.cover_photo_url),[b,_]=(0,u.useState)(f?"image":"accent"),v=(0,H.Jd)(),y=(0,K.d)(),w=(0,J.Iu)(),Y=(0,V.Fr)({checkFirst4:!0}),{result:C}=(0,W.st)({pathname:"/api/v1/publication/".concat(t.id,"/theme"),auto:!!o&&n&&i&&!c,cacheTtl:1/0,initialResult:c,deps:[o,n,i,c]}),I=i&&(!!l||p)&&!!C;(0,u.useEffect)(()=>{I&&(null==n?void 0:n.id)&&(0,M.u4)(M.qY.SHARE_SELECTION_MODAL_OPENED,{post_id:n.id})},[I,n]),(0,u.useEffect)(()=>{o&&n&&i&&(async()=>{h(!0);try{let e=await (0,z.x6)("/api/v1/post_selection",{method:"PUT",json:{postId:n.id,publication_id:t.id,startParagraph:o.startParagraph,endParagraph:o.endParagraph,startOffset:o.startOffset,endOffset:o.endOffset}});if(h(!1),e instanceof Error)throw e;s(e.selection.id.toString())}catch(e){alert((0,z.Qd)(e)),h(!1),r()}})()},[t,n,o,i,s,r]);let D=(e,i)=>{let r=R(),o=(0,B.x5)(null,{pub:t,post:n,selectionId:l,user:v||void 0,medium:"web",utm_campaign:Z._9.postShareSelection,params:{aspectRatio:m,bgColor:r.bgColor,textColor:r.textColor,bgImage:r.bgImage}});(0,B.Q_)(e,i,{shareUrl:o,post:n,pub:t,selectionId:l,utm_campaign:Z._9.postShareSelection})},E=async()=>{D("copy",e=>((0,j.lW)(e),y.popToast(()=>(0,a.Y)(K.y,{text:d("Copied link to clipboard")})),!1))},x=async()=>{D("facebook",e=>(0,X.yRP)("https://www.facebook.com/sharer/sharer.php",{u:e}))},T=async()=>{n&&D("twitter",e=>(0,$.gKg)({url:e,text:n.title}))},L=async()=>{D("linkedin",e=>(0,X.yRP)("https://www.linkedin.com/sharing/share-offsite/",{url:e}))},R=()=>{if(!C)return{aspectRatio:m};switch(b){case"image":return{aspectRatio:m,textColor:"#ffffff",bgImage:!0};case"accent":return{aspectRatio:m,bgColor:C.background_pop,textColor:C.print_on_pop};default:return{aspectRatio:m,bgColor:C.web_bg_color||C.cover_bg_color,textColor:C&&"string"==typeof C.print_on_web_bg_color&&C.print_on_web_bg_color.startsWith("hsl")?C.cover_print_primary||"#1a1a1a":(null==C?void 0:C.print_on_web_bg_color)||"#1a1a1a"}}},U=async()=>{let e=R(),i="Share Selection - ".concat(e.aspectRatio);(0,M.u4)(M.qY.SHARE_SELECTION_IMAGE_DOWNLOADED,{post_id:null==n?void 0:n.id,selection_id:l,type:i,aspect_ratio:m,interaction:"click"});let r=document.createElement("a");r.href=n&&l?(0,$.SAZ)(t,n,l,e,i):"",r.download="Share Selection - ".concat(m),r.target="_blank",r.rel="noopener noreferrer",r.style.display="none",document.body.appendChild(r),r.click(),document.body.removeChild(r)};return(0,a.FD)(G.aF,{isOpen:I,onClose:r,width:640,fullscreenMobile:!0,children:[(0,a.Y)(G.rQ,{title:d("Share quote"),onClose:r,showDivider:!0}),(0,a.Y)(ee,{assetStyle:R(),aspectRatio:m,loadingSelection:p,post:n,pub:t,themeVariables:C,setAspectRatio:g,assetTheme:b,setAssetTheme:_,selectionId:l,setSelectionId:s}),(0,a.Y)(G.jl,{direction:"row",showDivider:!0,primaryButton:Y?void 0:(0,a.Y)(k.$n,{priority:"primary",flex:w?void 0:"grow",disabled:!l,onClick:U,leading:(0,a.Y)(P.A,{size:20}),children:d("Download")}),secondaryButton:(0,a.FD)(q.Ye,{gap:8,children:[(0,a.Y)(k.K0,{priority:"secondary-outline",onClick:E,disabled:!l,children:(0,a.Y)(F.A,{height:20,width:20})}),(0,a.Y)(k.K0,{priority:"secondary-outline",onClick:T,disabled:!l,children:(0,a.Y)(O.A,{size:20})}),(0,a.Y)(k.K0,{priority:"secondary-outline",onClick:x,disabled:!l,children:(0,a.Y)(N.A,{size:20})}),(0,a.Y)(k.K0,{priority:"secondary-outline",onClick:L,disabled:!l,children:(0,a.Y)(A.A,{size:20})})]})})]})};var en=n(63136),ei=n(2481),er=n(7642);function eo(e){var t,n,i;let{post:r,pub:o,selection:l,onClose:s,themeVariables:c,userInteractionDisabled:d}=e,[p,h]=(0,u.useState)(!1),[m,g]=(0,u.useState)(),f=(0,u.useRef)(null),b=(null==l||null==(i=l.text)||null==(n=i.split)||null==(t=n.call(i," "))?void 0:t.length)||0,_=!!(l&&b>=3&&!r.is_draft&&!(null==o?void 0:o.invite_only));(0,u.useEffect)(()=>{l&&(f.current=l)},[l]);let v=l||f.current;return(0,a.FD)(a.FK,{children:[v&&(0,a.Y)(ea,{selection:v,onClose:s,userInteractionDisabled:d,onShowSelectionModal:h,post:r,pub:o,isOpen:_}),(0,a.Y)(et,{selection:l,pub:o,post:r,isOpen:p,onClose:()=>h(!1),selectionId:m,setSelectionId:g,themeVariables:c})]})}function ea(e){let{selection:t,onClose:n,userInteractionDisabled:i,onShowSelectionModal:r,post:o,pub:l,isOpen:s}=e,{iString:h}=(0,S.GO)(),m=(0,J.Iu)(),g=(0,H.Jd)(),f=(0,ei.NP)(),b=(0,K.d)(),_=!o.is_draft&&!!g,[v,y]=(0,u.useState)(!1),[w,Y]=(0,u.useState)(!1);(0,u.useEffect)(()=>{s?Y(!0):Y(!1)},[s]),(0,u.useEffect)(()=>{if(!s)return;let e=()=>{Y(!1),n()};return window.addEventListener("scroll",e,{passive:!0,capture:!0,once:!0}),()=>{window.removeEventListener("scroll",e,{capture:!0})}},[n,s]),(0,u.useEffect)(()=>{let e=()=>{t.y-57*!!m<104?C({top:t.rect.bottom+12}):C({top:t.y-92-12})};return window.addEventListener("resize",e),e(),()=>{window.removeEventListener("resize",e)}},[t,m]);let[k,C]=(0,u.useState)({top:-1}),D=()=>{r(!0)},E=async()=>{y(!0);try{let e=await (0,z.x6)("/api/v1/post_selection",{method:"PUT",json:{postId:o.id,publication_id:l.id,startParagraph:t.startParagraph,endParagraph:t.endParagraph,startOffset:t.startOffset,endOffset:t.endOffset}});if(y(!1),e instanceof Error)throw e;return e.selection.id}catch(e){alert((0,z.Qd)(e)),y(!1)}},x=async()=>{let e=await E();if((0,M.u4)(M.qY.RESTACK_SELECTION_CLICKED,{post_id:o.id}),!g){let t=(0,$.oRR)(document.location.href,{action:"restack-comment",selection:e}),n=(0,$.a7q)({redirect:t});(0,j.V2)(n,{local_navigation:!1,event});return}let t=(0,$.wu9)(l,o,{urlParams:{r:g?g.id.toString(36):null,selection:e,utm_campaign:Z._9.postShareSelection,utm_medium:Z.Jn.web}});await f.open({restackUrl:t}) instanceof Error?b.popToast(()=>(0,a.Y)(K.y,{text:"Failed to post"})):b.popToast(()=>(0,a.Y)(K.y,{text:"Note sent",cta:"View now",href:(0,X.oT5)()}))},T=!_&&!v&&!!g;return -1===k.top?null:m?(0,a.Y)(I,{handleQuoteRestack:x,showRestackButton:!l.hide_post_restacks&&_,disableRestackButton:T,handleShare:D,isVisible:w}):(0,a.Y)(p.a,{children:(0,a.FD)(q.I1,{style:{top:k.top,bottom:k.bottom,left:t.rect.x+t.rect.width/2},justifyContent:"center",outline:"detail",shadow:"md",radius:"md",className:"".concat(er.A.popover," ").concat(w?er.A.visible:""," ").concat(i?er.A.disabled:""),padding:4,gap:4,children:[!l.hide_post_restacks&&_&&(0,a.FD)(el,{onClick:x,disabled:T,children:[(0,a.Y)(c.A,{stroke:"var(--color-utility-white)",size:20}),(0,a.Y)(en.EY.B4,{color:"vibrance-primary",weight:"medium",children:h("Restack")})]}),(0,a.FD)(el,{onClick:D,children:[(0,a.Y)(d.A,{stroke:"var(--color-utility-white)",size:20}),(0,a.Y)(en.EY.B4,{color:"vibrance-primary",weight:"medium",children:h("Share")})]})]})})}function el(e){var t=(0,i._)({},(0,r._)(e));return(0,a.Y)(k.Nm,(0,o._)({className:s()(er.A.button,t.disabled&&er.A.disabled),resetCss:!0},t))}},65207:function(e,t,n){n.d(t,{F:()=>H});var i=n(69277),r=n(79785),o=n(4006),a=n(17402),l=n(15734),s=n.n(l),c=n(24142),d=n(13950),u=n(32485),p=n.n(u),h=n(48697),m=n(63446),g=n(15894),f=n(84605),b=n(86500),_=n(68349),v=n(24078),y=n(76977),w=n(39318);let Y={subscribeDialog:"subscribeDialog-ApxQJS",dismissButton:"dismissButton-gWmS4u",pictureBox:"pictureBox-yO_tQ9",childPublicationIcon:"childPublicationIcon-u5S7bv",signInLink:"signInLink-v__pXF",background:"background-qPxN3C",error:"error-ekhTFi",closeIcon:"closeIcon-pSUQVJ",fp:"fp-sXrGxn",form:"form-mUblsD",subscribeButton:"subscribeButton-GT6UQz",signInLinkWrapper:"signInLinkWrapper-WFxaK4",hed:"hed-pyKjVu",dek:"dek-YOBGIH",emailInput:"emailInput-Znhurz"},S=e=>{let{position:t,offset:n,target:i,left:r,modal:a,pub:l,setDismissed:s,subscribe:c,email:d,setEmail:u,loading:S,errors:k,post:C,opacityOfBackground:I,onBackgroundClicked:D}=e,{iString:E}=(0,f.GO)();return(0,o.FD)(o.FK,{children:[(0,o.Y)(y.I1,{ref:a,alignItems:"center",className:p()(Y.subscribeDialog,Y.fp),style:{top:"absolute"===t?"".concat(n,"px"):"".concat(i,"px"),left:"".concat(r,"px"),position:t},children:(0,o.FD)(o.FK,{children:[(0,o.FD)(y.Ye,{alignItems:"end",justifyContent:"center",paddingBottom:8,children:[(0,o.Y)("div",{className:Y.pictureBox,children:(0,o.Y)(v.eu,{className:Y.authorIcon,size:80,user:{photo_url:l.logo_url}})}),(0,o.Y)("div",{className:Y.closeIcon,onClick:()=>s(!0),children:(0,o.Y)(h.A,{})})]}),(0,o.FD)(g.T,{align:"center",className:Y.hed,preset:"h4-sans-condensed",children:[E("Discover more from"),(0,o.Y)("br",{}),I18N.p(l.name)]}),(0,o.Y)(g.T,{align:"center",className:Y.dek,preset:"body",children:l.hero_text}),(0,o.FD)("form",{className:Y.form,onSubmit:e=>{e.preventDefault(),c(d)},children:[(0,o.Y)("input",{className:Y.emailInput,disabled:S,placeholder:E("Enter your email"),value:d,onChange:e=>{e.stopPropagation(),e.preventDefault(),u(e.currentTarget.value)}}),(0,o.Y)("div",{id:"error-container",children:k&&k.map(e=>(0,o.Y)("div",{className:Y.error,children:e}))}),(0,o.Y)(m.v,{className:Y.subscribeButton,disabled:S,type:"submit",children:E("Subscribe")})]}),(0,o.Y)(m.v,{className:Y.dismissButton,trailingIcon:"chevron-right",variant:"tertiary",onClick:()=>s(!0),children:E("Continue reading")}),(0,o.FD)(g.T,{align:"center",className:Y.signInLinkWrapper,preset:"caption",children:[(0,o.Y)("div",{children:E("Already have an account?")}),(0,o.FD)("div",{children:[(0,o.Y)("a",{className:Y.signInLink,style:{cursor:"pointer"},onClick:()=>{(0,b.u4)(b.qY.SUBSCRIBE_PROMPT_SIGN_IN_CLICKED,{post_id:C.id}),(0,_.V2)((0,w.a7q)({for_pub:l.subdomain,redirect:(0,w.wu9)(l,C)}))},children:E("Sign in")})," "]})]})]})}),I>0&&(0,o.Y)("div",{className:Y.background,style:{opacity:"".concat(I,"%")},onClick:D})]})};var k=n(84565),C=n(94729),I=n(17186),D=n(89490),E=n(35369),x=n(16074),T=n(20500),P=n(84843),F=n(63136),N=n(65842),A=n(62088),O=n(11510),B=n(61554),L=n(16291),R=n(4016),V=n(57324);function U(){let e=(0,r._)(["Discover more from ",""]);return U=function(){return e},e}let H=e=>{var t;let{pub:n,post:r,isTest:l}=e,[u,p]=(0,a.useState)(!1),[h,m]=(0,a.useState)(!1),[g,H]=(0,a.useState)(!1),[M,z]=(0,a.useState)(""),[W,j]=(0,a.useState)([]),[q,G]=(0,a.useState)(200),[K,Q]=(0,a.useState)(0),J=(0,a.useRef)(null),$=(0,O.Iu)(),{getExperimentVariant:X,exposeExperiment:Z,getConfigFor:ee}=(0,k.NQ)(),et=ee("welcome_page_app_button"),en=X("post_page_scrolling_modal_subscribe_in_app"),ei=$&&et&&"treatment"===en,[er,eo]=(0,a.useState)(!1),ea="pub-".concat(n.id,"-subscribe-prompt-next-shown-at"),el="pub-".concat(n.id,"-takeover-next-shown-at"),es="undefined"!=typeof window&&(null==(t=window)?void 0:t.innerHeight)?window.innerHeight:700,ec=document.getElementsByClassName("available-content"),ed=ec.length>0&&ec[0]?ec[0].scrollHeight:0,eu=600;eu=Math.max(Math.min(600,ed-es),600),(()=>{var e;let{height:t,width:n}=(null==(e=J.current)?void 0:e.getBoundingClientRect())||{height:0,width:0};G("undefined"!=typeof window&&window&&J.current?(window.innerHeight-t)/2:200),Q("undefined"!=typeof window&&window&&J.current?(window.innerWidth-n)/2:0)})();let[ep,eh]=(0,a.useState)(es+Math.max(q,eu)),[em,eg]=(0,a.useState)(Math.max(document.documentElement.scrollTop||document.body.scrollTop,0)),[ef,eb]=(0,a.useState)("absolute"),[e_,ev]=(0,a.useState)("fixed"===ef||em>ep-es),ey="fixed"===ef?60:Math.min(Math.max((em-ep+es)/(es-q)*60,0),60),ew=(0,a.useCallback)(()=>{!$&&em>=ep-300&&m(!0)},[em,$,ep,q,m]);(0,a.useEffect)(()=>{var e;if(l)return;ed<=1.5*es&&p(!0);let t=null;if(null==(e=document)?void 0:e.referrer){try{t=new URL(document.referrer)}catch(e){}((null==t?void 0:t.hostname)==="news.ycombinator.com"||(null==t?void 0:t.hostname)==="hckrnews.com")&&p(!0),"undefined"!=typeof navigator&&/Twitter for/i.test(navigator.userAgent)&&p(!0)}(0,I.xm)(ea)>Date.now()&&p(!0)},[]),(0,a.useEffect)(()=>{!e_||u||((0,b.u4)(b.qY.SUBSCRIBE_PROMPT_SHOWN,{post_id:r.id}),$&&et&&Z("post_page_scrolling_modal_subscribe_in_app"),(0,I.X3)(ea,(0,L.A)().add(1,"hour").valueOf()),(0,I.X3)(el,(0,L.A)().add(1,"hour").valueOf()))},[e_,u,$,et,Z]),(0,a.useEffect)(()=>{h&&((0,b.u4)(b.qY.SUBSCRIBE_PROMPT_DISMISSED,{post_id:r.id}),(0,I.X3)(ea,(0,L.A)().add(1,"day").valueOf()),(0,I.X3)(el,(0,L.A)().add(1,"hour").valueOf()))},[h]);let eY=(0,a.useCallback)(async e=>{if(!g){var t,o,a,l,c;H(!0),j([]),(0,b.u4)(b.qY.SUBSCRIBE_PROMPT_SUBMITTED,{post_id:r.id});try{let t=await s().post("/api/v1/free").send({email:e,source:"post-subscribe-prompt"});((0,b.$5)(t.body.requires_confirmation),"enabled"===n.payments_state||n.has_recommendations)?document.location.href=(0,w.eV6)(n,(0,i._)({utm_medium:V.Jn.web,utm_source:V.VU.postSubscribePrompt,utm_content:r&&r.id,simple:!0,just_signed_up:!0,next:(0,w.wu9)(n,r),requires_confirmation:t.body.requires_confirmation?"true":""},t.body.subscription_id&&{subscription_id:t.body.subscription_id},t.body.referral_token&&{referral_token:t.body.referral_token})):window.location.href=(0,w.wu9)(n,r,{urlParams:{subscribe_prompt:"free"}})}catch(e){(null==e||null==(o=e.response)||null==(t=o.body)?void 0:t.error)&&"string"==typeof e.response.body.error?j([e.response.body.error]):(null==e||null==(l=e.response)||null==(a=l.body)?void 0:a.errors)&&Array.isArray(e.response.body.errors)&&e.response.body.errors.length>0&&"string"==typeof(null==(c=e.response.body.errors[0])?void 0:c.msg)&&j(e.response.body.errors.map(e=>e.msg))}finally{H(!1)}}},[r,n,g,H]),eS=(0,a.useCallback)(async()=>{if(!er){eo(!0);try{if((0,b.u4)(b.qY.APP_STORE_LINK_CLICKED,{source:"post_subscribe_prompt_app_upsell",utm_campaign:V._9.postSubscribePromptSubscribeInApp,utm_source:V.VU.postSubscribePrompt}),M)try{await (0,C.x6)("/api/v1/free",{method:"POST",json:{email:M,source:"post_subscribe_prompt_app_upsell"}})}catch(e){console.error("Failed to subscribe user:",e)}try{await (0,C.x6)("/api/v1/app_intended_state",{method:"POST",json:{data:{category:"post",postId:r.id},useIp:!0}}),await (0,C.x6)("/api/v1/onboarding_intended_recommendations",{method:"POST",json:{recommendations:[{publicationId:n.id,isPrechecked:!0,source:"post_subscribe_prompt_app_upsell"}],useIp:!0}})}catch(e){console.error("Failed to set app intended state:",e)}m(!0);let e=(0,w.XV8)(n.subdomain,r.slug,{source:V.VU.postSubscribePrompt,params:{utm_campaign:V._9.postSubscribePromptSubscribeInApp},redirect:"app-store"});(0,_.V2)(e,{local_navigation:!1})}catch(e){console.error("Failed to handle subscribe in app click:",e)}finally{eo(!1)}}},[er,M,r,n,m]);(0,a.useEffect)(()=>{if(u||h)return;let e=()=>{let e=Math.max(document.documentElement.scrollTop||document.body.scrollTop,0),t=e-em;t>0&&"absolute"===ef&&e>ep-q&&eb("fixed"),t<0&&"fixed"===ef&&(eb("absolute"),eh(em+q)),t<0&&"absolute"===ef&&e0&&e>ep-es)&&ev(!0)};return window.addEventListener("scroll",e),window.addEventListener("resize",e),()=>{window.removeEventListener("scroll",e),window.removeEventListener("resize",e)}},[ef,ep,eh,em,eg,ev]),(0,a.useEffect)(()=>{if(u||h)return;let e=e=>{"Escape"===e.key&&m(!0)};return window.addEventListener("keydown",e),()=>{window.removeEventListener("keydown",e)}},[u,h,m]);let{iString:ek,iTemplate:eC}=(0,f.GO)();return u||h?(0,o.Y)(o.FK,{}):(0,R.lu)({pub:n})?(0,o.Y)(S,{position:ef,offset:ep,target:q,left:K,modal:J,pub:n,setDismissed:m,subscribe:eY,email:M,setEmail:z,loading:g,errors:W,post:r,opacityOfBackground:ey,onBackgroundClicked:ew}):(0,o.FD)(d.DH,{children:[(0,o.FD)(y.I1,{ref:J,bg:"primary",border:"detail",radius:"md",shadow:"xl",className:Y.subscribeDialog,style:{top:"absolute"===ef?"".concat(ep,"px"):"".concat(q,"px"),left:"".concat(K,"px"),position:ef},role:"dialog","aria-label":ek("Subscribe modal"),children:[(0,o.FD)(y.I1,{gap:20,position:"relative",padding:20,children:[(0,o.Y)(P.J,{onClose:()=>m(!0)}),(0,o.Y)(D.az,{alignSelf:"center",children:(0,o.Y)(v.eu,{size:64,photoUrl:n.author_photo_url})}),(0,o.FD)(y.I1,{justifyContent:"center",gap:4,alignItems:"center",textAlign:"center",children:[(0,o.Y)(F.EY.B2,{weight:"semibold",color:"primary",children:eC(U(),n.name)}),n.hero_text&&(0,o.Y)(F.EY.B3,{color:"secondary",clamp:3,children:n.hero_text}),n.rankingDetailFreeSubscriberCount&&(0,o.Y)(F.EY.B4,{paddingBottom:24,align:"center",color:"pub-secondary-text",children:n.rankingDetailFreeSubscriberCount})]}),(0,o.Y)("form",{onSubmit:e=>{e.preventDefault(),eY(M)},children:(0,o.FD)(y.I1,{gap:8,children:[(0,o.Y)(N.ks,{placeholder:ek("Enter your email..."),value:M,disabled:g,onChange:e=>{e.stopPropagation(),e.preventDefault(),z(e.currentTarget.value)}}),W.length>0&&(0,o.Y)(y.I1,{gap:4,children:W.map(e=>(0,o.Y)(T.yn,{align:"center",children:e}))}),(0,o.Y)(E.$n,{type:"submit",disabled:g,priority:"primary",children:ek("Subscribe")}),ei&&(0,o.FD)(o.FK,{children:[(0,o.Y)(x.v,{text:ek("or")}),(0,o.Y)(E.$n,{priority:"secondary",width:"100%",onClick:eS,disabled:er,loading:er,leading:(0,o.Y)(c.A,{height:20,fill:"#FF6719"}),children:ek("Subscribe with Substack")})]}),(0,o.Y)(y.VP,{paddingTop:8,opacity:80,children:(0,o.Y)(B.U,{includeCheckbox:!1,addSubscribePreamble:!0,color:"secondary",textAlign:"center",pub:n})})]})})]}),(0,o.Y)(A.dt,{children:(0,o.FD)(o.FK,{children:[ek("Already have an account? "),(0,o.Y)(F.Yq,{color:"accent",decoration:"hover-underline",onClick:()=>{(0,b.u4)(b.qY.SUBSCRIBE_PROMPT_SIGN_IN_CLICKED,{post_id:r.id}),(0,_.V2)((0,w.a7q)({for_pub:n.subdomain,redirect:(0,w.wu9)(n,r)}))},cursor:"pointer",children:ek("Sign in")})]})})]}),ey>0&&(0,o.Y)("div",{className:Y.background,onClick:ew,style:{opacity:"".concat(ey,"%")}})]})}},54014:function(e,t,n){n.d(t,{j:()=>g});var i=n(69277),r=n(70408),o=n(4006),a=n(15734),l=n.n(a),s=n(52077),c=n(84605),d=n(35369),u=n(76977),p=n(88762),h=n(28911),m=n(65842);function g(e){let{isOpen:t,onClose:n,speakers:a,speakerMap:g,onChangeSpeakerMap:f,postId:b}=e,{iString:_}=(0,c.GO)();return(0,o.FD)(h.aF,{isOpen:t,onClose:n,children:[(0,o.Y)(h.rQ,{title:_("Assign Speakers"),description:_("Assign names to each identified speaker to show them on the transcript. If there are too many speakers, you may have to duplicate a name."),onClose:n,showDivider:!0}),(0,o.Y)(h.cw,{children:(0,o.Y)(u.I1,{gap:20,children:a.map(e=>(0,o.FD)(m.A0,{children:[(0,o.Y)(p.JU,{children:(0,s.Ui)(e)}),(0,o.Y)(m.ks,{onChange:t=>{var n;return f((0,r._)((0,i._)({},g),{[e]:null==(n=t.target)?void 0:n.value}))},value:(null==g?void 0:g[e])||"",placeholder:_("Assign a name...")})]}))})}),(0,o.Y)(h.jl,{direction:"column",showDivider:!0,primaryButton:(0,o.Y)(d.$n,{priority:"primary",onClick:()=>{g&&Object.keys(g).length>0&&l().put("/api/v1/drafts/".concat(b,"/transcript")).send({speaker_map:g}).then(e=>{e.body.data&&n()})},children:_("Save changes")})})]})}},76609:function(e,t,n){n.d(t,{g:()=>v});var i=n(4006),r=n(38893),o=n(14506),a=n(48617),l=n(99070),s=n(91461),c=n(76977),d=n(63136);function u(e){let{text:t}=e;return(0,i.FD)(c.ov,{gap:8,flex:"grow",children:[(0,i.Y)(c.ov,{flex:"auto",children:(0,i.Y)(s.A,{size:16,color:"var(--color-fg-secondary)"})}),(0,i.Y)(d.EY.B4,{weight:"medium",color:"secondary",children:t})]})}var p=n(4169),h=n(69277),m=n(70408),g=n(97731);let f=e=>(0,i.FD)(g.A,(0,m._)((0,h._)({},e),{name:"VoiceoverIcon",svgParams:{height:24,width:24,viewBox:"0 0 24 24"},fill:"none",children:[(0,i.Y)("path",{d:"M11.8518 3.31518C12.2459 4.26329 13.551 7.10985 14.4542 8.3467C15.3764 9.60967 12.8285 9.95184 12 10.5",strokeWidth:"1.5",strokeLinecap:"round"}),(0,i.Y)("path",{d:"M12 10.5C12 10.5 12.4662 11.2332 12.7627 11.7326C13.0592 12.232 13 12.5 11.5 13C10.7772 13.2409 9.5 13.5 9.5 13.5C10.3447 13.9272 12.2664 14.1393 12.4041 14.3167C12.763 14.779 12.3241 15.4618 11.8617 15.8208C11.3994 16.1797 12.0724 18.7353 10.5 19.5C8.9276 20.2647 5.70772 19.432 3 18",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,i.Y)("path",{d:"M18.5 6.5L20.3544 4.8526",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,i.Y)("path",{d:"M18.5 15.5L20.3544 17.2545",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),(0,i.Y)("path",{d:"M19.5 11.0326L22 11.0326",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}));var b=n(84605),_=n(11510);function v(e){let{mediaUploadId:t,pub:n,post:s,duration:h,autoPlay:m,href:g,isPaywalled:f,trackingProps:v}=e,{iString:w}=(0,b.GO)(),Y=(0,_.Iu)();return(0,i.Y)(l.A,{src:"/api/v1/audio/upload/".concat(t,"/src"),pub:n,post:s,duration:h,autoPlay:m,href:g,isPaywalled:f,feature:"Add voiceover",metricsPost:s,trackingProps:null!=v?v:{},render:e=>{let{isPaywalled:t,currentTime:n,isPlaying:l,progress:s,progressBarRef:h,progressBarOnMouseDown:m,remainingTime:g,playbackRate:f,setPlaybackRate:b,togglePlayback:_}=e;return(0,i.FD)(c.fI,{gap:8,flex:"grow",children:[!Y&&(0,i.Y)(y,{}),(0,i.FD)(r.ju,{"aria-label":w("Voiceover player"),role:"region",children:[(0,i.Y)(o.e,{isPlaying:l,disabled:t,onClick:_,size:"lg"}),t?(0,i.Y)(u,{text:w("Upgrade to paid to play voiceover")}):(0,i.FD)(r.lC,{children:[(0,i.Y)(d.EY.B4,{weight:"medium",color:"secondary",children:w("Article voiceover")}),(0,i.Y)(p.b,{currentTime:n,remainingTime:g,containerRef:h,progress:s,onMouseDown:m})]}),!t&&(0,i.Y)(a.x,{onSetPlaybackRate:b,playbackRate:f})]})]})}})}function y(){return(0,i.Y)(c.ov,{radius:"sm",height:72,width:72,flex:"auto",border:"detail",children:(0,i.Y)(f,{stroke:"var(--color-fg-secondary)"})})}},95337:function(e,t,n){n.d(t,{K:()=>l});var i=n(4006);let r=e=>{let{children:t,href:n}=e;return(0,i.Y)(i.FK,{children:(0,i.Y)("table",{cellSpacing:"0",cellPadding:"8",border:"0",width:"100%",children:(0,i.Y)("tr",{children:(0,i.Y)("td",{align:"center",children:(0,i.Y)("a",{href:n,className:"tw-font-sans tw-text-[13px] tw-font-semibold tw-text-error",children:t})})})})})};var o=n(98111),a=n(57324);let l=e=>{let{post:t,compAlreadyExpired:n=!1}=e,l="".concat(o.T.CHECKOUT_URL,"&utm_medium=").concat(a.Jn.email,"&utm_campaign=").concat(a._9.continueYourSupport,"&utm_content=").concat(t.id);return(0,i.FD)("table",{width:"100%",cellSpacing:"0",cellPadding:"0",border:"0",className:"tw-bg-error-wash",bgcolor:"#FFFAFA",children:[(0,i.Y)("tr",{children:(0,i.Y)("td",{height:"16"})}),(0,i.Y)("tr",{children:(0,i.FD)("td",{align:"center",className:"tw-leading-5",children:[(0,i.Y)("span",{className:"tw-font-sans tw-text-base tw-font-bold tw-text-error",children:"Continue your support"}),(0,i.Y)("br",{}),n?(0,i.FD)("span",{className:"tw-font-sans tw-text-ssm tw-text-error",children:["Your free trial has ended!",(0,i.Y)("br",{}),"Continue your support to access paid-only content."]}):(0,i.FD)("span",{className:"tw-font-sans tw-text-ssm tw-text-error",children:["Subscribe now to keep your paid status. You won't be",(0,i.Y)("br",{}),"charged until your free trial ends on ",o.T.SUBSCRIPTION_EXPIRY_DATE,"."]})]})}),(0,i.Y)("tr",{children:(0,i.Y)("td",{height:"16"})}),(0,i.Y)("tr",{children:(0,i.Y)("td",{children:(0,i.Y)(r,{href:l,children:"Subscribe now"})})}),(0,i.Y)("tr",{children:(0,i.Y)("td",{height:"16"})})]})}},59821:function(e,t,n){n.d(t,{A:()=>s});var i=n(69277),r=n(70408),o=n(4006),a=n(41181),l=n(97731);let s=e=>(0,o.Y)(l.A,(0,r._)((0,i._)({},e),{name:"LucideRecommend",svgParams:{height:24,width:24,fill:"#000000",strokeWidth:0},children:(0,o.Y)(a.A,{height:24,stroke:e.stroke,fill:e.fill,strokeWidth:e.strokeWidth})}))},15052:function(e,t,n){n.d(t,{A:()=>s});var i=n(69277),r=n(70408),o=n(32641),a=n(4006),l=n(97731);let s=e=>{var{stroke:t="black"}=e,n=(0,o._)(e,["stroke"]);return(0,a.Y)(l.A,(0,r._)((0,i._)({},n),{name:"ThreadIcon",svgParams:{height:19,width:19},children:(0,a.Y)("path",{d:"M10.4286 3H8.57143C5.49441 3 3 5.49441 3 8.57143C3 10.2355 4.16477 12.1934 5.32143 13.2143V16L11.3571 14.1429C14.6071 13.067 16 10.9973 16 8.57143C16 5.49441 13.5056 3 10.4286 3Z",stroke:t,"stroke-linejoin":"round"})}))}},64647:function(e,t,n){n.d(t,{A:()=>c});var i=n(69277),r=n(70408),o=n(32641),a=n(4006),l=n(97731),s=n(57753);let c=e=>{var{isHovered:t}=e,n=(0,o._)(e,["isHovered"]);let c=t?s.Q3.brightOrange.hex:s.Q3.lightGray.hex;return(0,a.FD)(l.A,(0,r._)((0,i._)({},n),{name:"FPCommentIcon",svgParams:{width:24,height:24,viewBox:"0 0 24 24",stroke:"none",fill:"none"},children:[(0,a.Y)("path",{d:"M22.1538 1V2.83333H24V15.6667H22.1538V17.5H16.6154V19.3333H14.7692V21.1667H12.9231V23H11.0769V21.1667H9.23077V19.3333H7.38462V17.5H1.84615V15.6667H0V2.83333H1.84615V1H22.1538Z",fill:c}),(0,a.Y)("rect",{x:"5",y:"9",width:"2",height:"2",fill:"white"}),(0,a.Y)("rect",{x:"11",y:"9",width:"2",height:"2",fill:"white"}),(0,a.Y)("rect",{x:"17",y:"9",width:"2",height:"2",fill:"white"})]}))}},25461:function(e,t,n){n.d(t,{A:()=>c});var i=n(69277),r=n(70408),o=n(32641),a=n(4006),l=n(97731),s=n(57753);let c=e=>{var{isHovered:t}=e,n=(0,o._)(e,["isHovered"]);let c=t?s.Q3.brightOrange.hex:s.Q3.lightGray.hex;return(0,a.FD)(l.A,(0,r._)((0,i._)({},n),{name:"FPShareIcon",svgParams:{width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"none"},children:[(0,a.Y)("path",{d:"M5 10H1V22H3V24H21V22H23V10H19V20H5V10Z",fill:c}),(0,a.Y)("path",{d:"M11 0H13V2H15V4H17V6H19V8H15V17H9V8H5V6H7V4H9V2H11V0Z",fill:c})]}))}},65754:function(e,t,n){n.d(t,{e:()=>m});var i=n(4006),r=n(90232),o=n(48635),a=n(99862),l=n(13950),s=n(84605),c=n(53989),d=n(86500),u=n(35369),p=n(76977),h=n(11510);let m=e=>{let{post:t}=e,n=(0,c.Pu)().getSettingFor("enable_prev_next_nav"),m=(0,h.Iu)(),{iString:g}=(0,s.GO)();if(!n)return null;let f=t.next_post_slug,b=t.previous_post_slug;return f||b?(0,i.Y)(l.DH,{children:(0,i.FD)(p.pT,{justifyContent:f&&b?"space-between":f?"end":"start",paddingY:16,children:[b&&(0,i.Y)(u.$n,{leading:(0,i.Y)(r.A,{size:20}),priority:m?"tertiary":"secondary",size:m?"sm":"md",onClick:()=>{(0,d.u4)(d.qY.PREVIOUS_POST_LINK_CLICKED,{post_id:t.id}),(0,a.route)("/p/".concat(b))},children:g("Previous")}),f&&(0,i.Y)(u.$n,{trailing:(0,i.Y)(o.A,{size:20}),priority:m?"tertiary":"secondary",size:m?"sm":"md",onClick:()=>{(0,d.u4)(d.qY.NEXT_POST_LINK_CLICKED,{post_id:t.id}),(0,a.route)("/p/".concat(f))},children:g("Next")})]})}):null}},11333:function(e,t,n){n.d(t,{_:()=>c});var i=n(4006),r=n(17402),o=n(78330),a=n(58398),l=n(86500),s=n(98111);function c(e){let t,{className:n,linkClassName:c,user:d,pub:u,post:p,reaction_token:h,height:m,onChange:g,isStatic:f,children:b,sharedShareDialog:_,noIcon:v,position:y}=e,[w,Y]=(0,r.useState)(!1);return t=p.share_url_override?p.share_url_override:f?p?s.T.SHARE_URL:s.T.SHARE_PUB_URL:"javascript:void(0)",(0,i.FD)("span",{className:n,children:[(0,i.FD)("a",{href:t,onClick:e=>(e=>{if((0,l.u4)(l.qY.POST_SHARE_BUTTON_CLICKED,{position:y,post_id:p.id}),!f)if(e&&e.stopPropagation(),_){var t;null==(t=e.target)||t.dispatchEvent(new CustomEvent("share-post",{bubbles:!0}))}else Y(!0)})(e),className:c,children:[!v&&(0,i.Y)(o.A,{className:"recommend-icon post-meta-icon",isStatic:f,height:m,alt:"Share",stroke:"#757575",fill:"transparent",strokeWidth:f?1:1.5}),b]}),!f&&!_&&(0,i.Y)(a.Z,{isOpen:w,onClose:()=>Y(!1),user:d,pub:u,post:p,reaction_token:h,onChange:g,medium:"web"})]})}},90177:function(e,t,n){n.d(t,{s:()=>I});var i=n(69277),r=n(4006),o=n(32485),a=n.n(o),l=n(93893),s=n(36066),c=n(27437),d=n(41935),u=n(39318);function p(e){var t;let{pub:n,post:i}=e,o=(0,u.dJ9)("".concat((0,u.$_T)(n),"/p/").concat(i.slug,"/authors.svg"),800,{format:"png",crop:"scale"}),{height:a,width:l}={width:((null==i||null==(t=i.publishedBylines)?void 0:t.length)-1)*32+40+4,height:44};return(0,r.Y)("img",{src:o,width:l,height:a})}var h=n(84605),m=n(53989),g=n(13022),f=n(24078),b=n(22057),_=n(76977),v=n(49095),y=n(16291),w=n(4016),Y=n(56262),S=n(19601),k=n(98949),C=n(82776);function I(e){let{post:t,pub:n,user:o,showDate:I,showDatetime:D,isStatic:E,className:x,postReactionToken:T,onChange:P,allowEdit:F,hidePinning:N,showEmailSent:A,allowSendEmail:O,allowMobileFooter:B,onCommentsClick:L,showRestackModal:R,setFooterShown:V}=e,U=(0,k.Fr)({checkFirst4:!0}),H="undefined"==typeof window,M=(0,C.getBylineUsers)(t),{language:z}=(0,h.GO)(),W=D?(0,y.A)(t.post_date).locale(z).standardDatetime():E?(0,y.A)(t.post_date).locale(z).standardDate():(0,y.A)(t.post_date).locale(z).standardDateOrTime(),{getSettingFor:j}=(0,m.Pu)(),q=n.bylines_enabled&&(0,C.getPrintedByline)(n,t)&&"podcast"!==t.type,G=q&&n.byline_images_enabled&&M.some(e=>{let{photo_url:t}=e;return!!t}),K="page"!==t.type,Q=U&&G&&M.length>2,J=(null==n?void 0:n.community_enabled)&&t.slug&&!t.is_draft&&(0,C.showCommentsOnPost)({publication:n,post:t}),$=q&&1===M.length&&M[0].is_guest&&M[0].primaryPublicationSubscribeUrl&&M[0].primaryPublicationId!==n.id&&!t.is_draft&&!(0,g.Ay)("dont_show_guest_byline"),X=(0,C.oxfordComma)(M.map(e=>E?(0,r.Y)("a",{className:"byline-profile-link",href:(0,u.laT)(e,n,{base:E}),onClick:e=>e.stopPropagation(),children:e.name}):(0,r.FD)(_.Ye,{inline:!0,gap:4,alignItems:"center",children:[(0,r.Y)(c.ProfileHoverCard,{subject:e,utmSource:"byline",trigger:(0,r.Y)("a",{className:"byline-profile-link",href:(0,u.laT)(e,n,{base:E}),onClick:e=>e.stopPropagation(),children:e.name})}),!E&&(0,r.Y)(v.UserStatusSymbols,{status:e.status,size:"sm",userId:e.id})]}))),Z=!t.is_draft&&(0,S.A)(o,{enable_restacking:!!j("enable_restacking")},t,n,E);return(0,r.FD)("div",{className:a()("post-subheader",x),children:[(0,r.FD)("div",{className:a()("left",{vertical:Q}),children:[G&&(E?(0,r.Y)(p,{pub:n,post:t}):(0,r.Y)(b.Z,{users:M.map(e=>{let{id:t,name:n,photo_url:i}=e;return{id:t,name:n,photo_url:i}}),max:5,size:36,renderAvatar:e=>(0,r.Y)(f.tp,(0,i._)({},e))})),(0,r.FD)("div",{className:"label-stack",children:[q&&(0,r.Y)("div",{className:"bylines",children:(0,r.Y)("span",{className:"byline-names",children:X})}),$&&(0,r.FD)("div",{className:"guest-author-publication",children:["Writes\xa0",(0,r.Y)("a",{className:"guest-author-publication-name",href:M[0].primaryPublicationUrl,title:M[0].primaryPublicationName,children:M[0].primaryPublicationName}),"\xa0\xb7\xa0",(0,r.Y)("a",{className:"guest-author-publication-subscribe",href:M[0].primaryPublicationSubscribeUrl,children:"Subscribe"})]}),(0,r.FD)("div",{className:"publish-context",children:["adhoc_email"===t.type?(0,r.Y)(l.A,{className:"audience-icon adhoc-email-icon",size:16}):K&&(0,Y.isPaidAudience)(t.audience)&&!(0,w.zM)({post:t})&&(0,r.Y)(s.A,{audience:t.audience,className:"audience-icon audience-lock-icon",size:16,isStatic:E,thin:!0}),(I||D)&&t.post_date&&!t.is_draft&&(0,r.Y)("time",{dateTime:(0,y.A)(t.post_date).toISOString(),children:W}),t.is_draft&&(I||D)&&"Draft"]})]})]}),(0,r.FD)("div",{className:"right",children:[U&&!H&&B&&(0,r.Y)(d.I2,{post:t,pub:n,user:o,isStatic:E,onChange:P,allowEdit:F,hidePinning:N,showEmailSent:A,allowSendEmail:O,hideComments:!J,onCommentsClick:L,showRestackButton:Z,showRestackModal:R,setFooterShown:V,postReactionToken:T}),!U&&(0,r.Y)(d.xx,{post:t,pub:n,user:o,isStatic:E,variant:"button",onChange:P,allowEdit:F,hidePinning:N,showEmailSent:A,allowSendEmail:O,labelStyle:"counts-or-none",hideComments:!J,onCommentsClick:L,position:"post-header",showRestackButton:Z,showRestackModal:R,showClipping:"podcast"===t.type,editButtonIsLast:!0,postReactionToken:T})]})]})}},37494:function(e,t,n){n.d(t,{A:()=>W});var i=n(99851),r=n(69277),o=n(70408),a=n(32641),l=n(4006),s=n(83673),c=n.n(s),d=n(38221),u=n.n(d),p=n(2404),h=n.n(p),m=n(41811),g=n(17402),f=n(80707),b=n(69843),_=n.n(b),v=n(56265),y=n(23623),w=n(58925),Y=n(46271),S=n(86500),k=n(68349),C=n(76977),I=n(63136),D=n(28916),E=n(49807),x=n(7642);function T(e){var t,n,i,o,a;let{nuxModal:s,showRestackNux:c}=(0,D.w)("post");return(0,l.FD)(l.FK,{children:[s,!_()(null==(t=e.selection)?void 0:t.text)&&(null==(a=e.selection)||null==(o=a.text)||null==(i=o.split)||null==(n=i.call(o," "))?void 0:n.length)>=3&&(0,l.Y)(P,(0,r._)({onShare:c},e))]})}function P(e){let{pub:t,post:n,selection:i,onClose:r,userInteractionDisabled:o}=e,a=(0,Y.Jd)(),[s,c]=(0,g.useState)(!1);(0,g.useEffect)(()=>{c(!0)},[]);let d=async()=>{(0,S.u4)(S.qY.VIDEO_QUOTE_TEXT_SELECTED,{post_id:n.id,selection_id:i.id}),(0,k.V2)((0,E.U_V)(t,n.id,{selectionForQuote:i.text}),{local_navigation:!1})};(0,g.useEffect)(()=>(window.addEventListener("scroll",r,{passive:!0,capture:!0,once:!0}),()=>{window.removeEventListener("scroll",r,{capture:!0,once:!0})}),[r]);let u=i.text&&i.text.length>2048;return(0,l.Y)(y.a,{children:(0,l.Y)(C.I1,{style:{top:i.y-48-12,left:i.rect.x+i.rect.width/2,transform:"translateX(-50%)",pointerEvents:o?"none":"auto",maxWidth:240},justifyContent:"center",outline:"detail",shadow:"md",radius:"md",className:"".concat(x.A.popover," ").concat(s?x.A.visible:""," ").concat(o?x.A.disabled:""),padding:4,gap:4,children:(0,l.FD)(w.ut,{onClick:d,disabled:!!(!a||u),children:[(0,l.Y)(v.A,{size:20,stroke:"var(--color-utility-white)"}),(0,l.Y)(I.EY.B4,{color:"vibrance-primary",weight:"medium",children:u?"Selection too long":"Use this text"})]})})})}var F=n(85478),N=n(52742),A=n(94729),O=n(2481),B=n(57324);let L=(0,g.createContext)({action:null,selectedImage:null}),R=async e=>{let{imgSrc:t,post:n,pub:i}=e,r=await (0,A.x6)("/api/v1/post_selection/image",{method:"PUT",json:{post_id:n.id,publication_id:i.id,img_src:t}});if(r instanceof Error)throw r;return r.selection.id},V=async e=>{let{imgSrc:t,pub:n,post:i}=e,r=await R({imgSrc:t,post:i,pub:n});return(0,E.wu9)(n,i,{urlParams:{utm_campaign:B._9.postSelection,utm_medium:B.Jn.web,imgSelection:r}})},U=e=>{var t;let{children:n,imageState:i,selectedImageIndex:r,selectedImageAction:o=null,onClose:a,pub:s,post:c,onLike:d}=e,u=(0,O.NP)(),[p,h]=(0,g.useState)(r&&null!=(t=null==i?void 0:i[r])?t:null);(0,g.useEffect)(()=>{if(null!=r&&i){var e;h(null!=(e=i[r])?e:null)}},[i,r]);let m=(0,g.useCallback)(async()=>{(null==p?void 0:p.src)&&u.open({restackUrl:await V({imgSrc:null==p?void 0:p.src,pub:s,post:c}),onCompose(){h(null),a()},onDismiss(){h(null),a()}})},[u,a,c,s,null==p?void 0:p.src]);(0,g.useEffect)(()=>{p&&"restack"===o&&!u.state.isOpen&&m()},[o,u.state.isOpen,p,m]);let f=null!=c&&"comment_count"in c&&"number"==typeof c.comment_count?c:null;return(0,l.FD)(L.Provider,{value:{action:o,selectedImage:p},children:[n,(0,l.Y)(N.V6,{isOpen:"view"===o,modalContent:i,onClose:a,step:null!=r?r:0,post:f,publication:s,onLike:d})]})};var H=n(90292),M=n(82776);let z="\n:is(\n div.body.markup, .pullquote, blockquote, li, caption, .footnote-content\n) > :is(\n h1, h2, h3, h4, h5, h6, p:not(.button-wrapper)\n)\n";class W extends g.Component{async componentDidMount(){if(!this.body.current)return;let e=Array.from(this.body.current.querySelectorAll(z));this.originalParagraphState=e.map(e=>({text:e.textContent}));let t=new URL(window.location.href).searchParams.get("img"),n=new URL(window.location.href).searchParams.get("cutoffElementIndex"),i=Array.from(this.body.current.querySelectorAll(".image-link.image2"));i.forEach(e=>{"A"!==e.tagName&&console.warn("while parsing prosemirror doc for images, expected an anchor tag, but got",e.tagName)});let r=c()(i.map(e=>{let t=e.querySelector("img");if(!t)return console.warn("missing img when rendering prosemirror document"),null;let n=t.getAttribute("data-attrs"),i=n?JSON.parse(n):{},r=i.width/i.height,o=i.resizeWidth?i.resizeWidth/r:i.height,a=i.resizeWidth?i.resizeWidth/o:r;return{element:e,image:t,attrs:i,extraAttrs:{imageRatio:r,resizeHeight:o,resizeRatio:a}}})),o=0;if(t){let e=r.find(e=>e.attrs.src===t);e&&(o=e.image.getBoundingClientRect().top-65)}else if(n){let e=this.body.current.querySelector("*:nth-child(".concat(n,")"));e&&e.scrollIntoView()}if(r=(r=r.filter(e=>Number(e.attrs.height)>240&&e.extraAttrs.resizeHeight>240)).filter(e=>e.extraAttrs.imageRatio<4&&e.extraAttrs.resizeRatio<4),this.originalImageState=r.map(e=>{let t=e.image.src,n=null,i=e.element.parentElement;if(i&&"FIGURE"===i.tagName){var r;n=null==(r=i.querySelector(":scope > figcaption"))?void 0:r.textContent}return{src:t,attrs:e.attrs,caption:n}}),t&&this.originalImageState){window.scrollTo({top:o});let e=this.originalImageState.findIndex(e=>e.attrs.src===t);e>=0&&this.setState({selectedImgIndex:e})}"undefined"!=typeof window&&(document.addEventListener("selectionchange",this.onSelectionChange),document.addEventListener("mouseup",this.onMouseUp),window.addEventListener("mouseup",this.onMouseUp))}componentWillUnmount(){"undefined"!=typeof window&&(document.removeEventListener("selectionchange",this.onSelectionChange),document.removeEventListener("mouseup",this.onMouseUp),window.removeEventListener("mouseup",this.onMouseUp))}shouldComponentUpdate(e,t){return this.props.html!==e.html||this.state.selectedImgIndex!==t.selectedImgIndex||this.state.selection!==t.selection||this.state.selectionUserInteractionDisabled!==t.selectionUserInteractionDisabled||this.state.selectingTextForQuote!==t.selectingTextForQuote}onLinkClick(e){var t,n;if(!e.target||!(null==(t=e.target)?void 0:t.nodeName)||"A"!==e.target.nodeName&&(null==(n=e.target.parentNode)?void 0:n.nodeName)!=="A")return;let i="A"===e.target.nodeName?e.target:e.target.parentNode;if((0,S.u4)(S.qY.POST_LINK_CLICKED,{post_id:this.props.post.id,publication_id:this.props.post.publication_id,url:i.href}),window.location.host===i.host){let t=(0,M.transformDocumentLink)(i.href);t!==i.href&&(0,k.V2)(t,{local_navigation:!1,event:e});return}e.preventDefault(),(0,M.handleDocumentLinkClick)(i.href)}getSelectionState(){if(this.props.trackSelection&&window.getSelection)try{let e=window.getSelection();if(!e||e.isCollapsed||e.anchorNode===e.focusNode&&e.anchorOffset===e.focusOffset)return;let t=this.findParentParagraph(e.anchorNode);if(!t)return;let n=this.findParentParagraph(e.focusNode);if(!n||!this.body.current)return;let i=Array.from(this.body.current.querySelectorAll(z)),r=i.findIndex(e=>e.isSameNode(t));if(-1===r)return;let o=i.findIndex(e=>e.isSameNode(n));if(-1===o)return;let a=this.getCharacterOffsetParagraph(t,e.anchorNode,e.anchorOffset);if(null===a)return;let l=this.getCharacterOffsetParagraph(n,e.focusNode,e.focusOffset);if(null===l)return;let s=r>o||r===o&&a>l,c=e.getRangeAt(0).getBoundingClientRect();return{startParagraph:s?o:r,endParagraph:s?r:o,startOffset:s?l:a,endOffset:s?a:l,y:c.y,height:c.height,rect:c,text:e.toString()}}catch(e){console.error("Failed to parse selection:",e)}}findParentParagraph(e){return e?["P","H1","H2","H3","H4","H5","H6"].includes(e.nodeName)?e:this.findParentParagraph(e.parentNode):null}isAncestorOf(e,t){return null!==e&&(!!e.isSameNode(t)||this.isAncestorOf(e.parentNode,t))}getCharacterOffsetParagraph(e,t,n){let i=n;for(let n=0;n{var t,n,i,r;return(null==(t=e.props)?void 0:t.className)==="latex-rendered"||(null==(r=e.props)||null==(i=r.children)||null==(n=i.props)?void 0:n.className)==="latex-rendered"}),v=(0,l.Y)(l.FK,{children:(0,l.FD)(U,{imageState:this.originalImageState,selectedImageIndex:m,selectedImageAction:b,onClose:this.onCloseViewer,pub:i,post:this.props.post,onLike:this.props.onLike,children:[(0,l.Y)("div",{className:"body markup",dangerouslySetInnerHTML:p?{__html:p}:null,ref:this.body,onClick:this.onDocumentClick,onMouseDown:this.onBodyMouseDown,onMouseUp:this.onMouseUp,dir:"auto",children:u}),g&&!f?(0,l.Y)(w.YA,{pub:i,post:this.props.post,selection:h,onClose:this.clearActiveSelection,userInteractionDisabled:this.state.selectionUserInteractionDisabled,themeVariables:this.props.themeVariables}):h&&(0,l.Y)(T,{pub:i,post:this.props.post,selection:h,onClose:this.clearActiveSelection,userInteractionDisabled:this.state.selectionUserInteractionDisabled})]})});return _&&!c.isStatic?(0,l.Y)(H.q,{children:v}):v}constructor(e,t){super(e,t),(0,i._)(this,"body",void 0),(0,i._)(this,"originalParagraphState",void 0),(0,i._)(this,"originalImageState",void 0),(0,i._)(this,"state",{selection:null,urlSelection:null,selectedImgIndex:null,selectionUserInteractionDisabled:!1,shouldUseSelectionV2Popover:!1,imgAction:null}),(0,i._)(this,"onBodyMouseDown",()=>{this.setState({selectionUserInteractionDisabled:!0})}),(0,i._)(this,"onMouseUp",()=>{this.setState((e,t)=>e.selectionUserInteractionDisabled?(e.selection&&t.trackSelection&&(0,S.u4)(S.qY.POST_TEXT_SELECTED,{post_id:t.post.id,post_audience:t.post.audience,post_type:t.post.type}),{selectionUserInteractionDisabled:!1}):null)}),(0,i._)(this,"onSelectionChange",u()(()=>{let e=this.getSelectionState();if(e){let t=this.shouldShowShareSelectionPopover();this.setState({selection:e,shouldUseSelectionV2Popover:t})}else this.state.selection&&this.setState({selection:null})},10)),(0,i._)(this,"onDocumentClick",e=>{if(!e.target)return;let t=e.target.closest(".image-link.image2");if(t&&this.originalImageState){var n,i;let r=t.querySelector("img"),o=this.originalImageState.findIndex(e=>e.src===(null==r?void 0:r.src)),a=this.originalImageState[o],l=e.target,s=(null==l?void 0:l.classList.contains("restack-image"))||(null==l||null==(n=l.parentElement)?void 0:n.classList.contains("restack-image")),c=(null==l?void 0:l.classList.contains("view-image"))||(null==l||null==(i=l.parentElement)?void 0:i.classList.contains("view-image")),d=a&&!!a.attrs.href;if(a&&(!d||s||c)){e.preventDefault(),this.setState({selectedImgIndex:o,imgAction:s?"restack":"view"});return}}if(this.props.skipTrackClick)return null;this.onLinkClick(e)}),(0,i._)(this,"onCloseViewer",()=>{this.setState({selectedImgIndex:null,imgAction:null})}),(0,i._)(this,"clearActiveSelection",()=>{this.setState({selection:null})}),(0,i._)(this,"closeImageViewerModal",()=>{this.setState({selectedImgIndex:null})}),(0,i._)(this,"shouldShowShareSelectionPopover",()=>{let e;return"undefined"!=typeof window&&(e="true"===new URLSearchParams(window.location.search).get("selectQuote")),!e}),(0,i._)(this,"memoizedDeepPrepareDocumentBody",(0,m.A)(f.bs,h())),this.body=(0,g.createRef)()}}(0,i._)(W,"contextType",F.W8)},99927:function(e,t,n){n.d(t,{V:()=>v});var i=n(69277),r=n(70408),o=n(4006),a=n(17402),l=n(13589),s=n(77450),c=n(63446),d=n(16514),u=n(15894),p=n(76977),h=n(39318),m=n(57324);let g=e=>{let{children:t,isFreeSubscribed:n,isOpen:i,isSubscribed:r,pub:a,onClose:l}=e,s=(0,h.eV6)(a,{utm_source:m.VU.downloadPdfButton,simple:!0,next:(0,h.yRP)(document.location.href,{triggerPDF:!0}),addBase:!0});return(0,o.Y)(d.w,{closeOnOutsideClick:!0,content:(0,o.FD)(p.I1,{gap:4,position:"relative",children:[(0,o.Y)(u.T,{preset:"d4-serif",children:r?"Paid subscribers can now save articles as PDFs, formatted for printing out and enjoying offline.":"Saving articles as PDFs, formatted for printing and reading offline, is a benefit we're proud to offer our\n paid subscribers. ".concat(n?"Upgrade":"Sign up"," today to unlock this feature.")}),!r&&(0,o.Y)(p.Ye,{children:(0,o.Y)(c.v,{href:s,localNavigation:!1,size:"sm",trailingIcon:"chevron-right",variant:"tertiary",children:n?"Upgrade now":"Subscribe now"})})]}),isOpen:i,onClose:l,children:t})};var f=n(86500),b=n(68349),_=n(49807);let v=e=>{let{post:t,pub:n,user:c}=e,[d,u]=(0,l.Mk)(),[h,m]=(0,a.useState)(!1),v=!!(null==c?void 0:c.is_subscribed),y=!!(null==c?void 0:c.is_free_subscribed);return(0,a.useEffect)(()=>{let e=new URL(document.location.href);if(e.searchParams.get("triggerPDF")){if(v){var i;(0,b.V2)((0,_.MGs)(n,t.id,{token:"token"in window._preloads&&null!=(i=window._preloads.token)?i:void 0}),{local_navigation:!1,newTab:!0})}e.searchParams.delete("triggerPDF"),window.history.replaceState({},"",e)}},[v,t.id,n]),(0,o.Y)(g,{isFreeSubscribed:y,isOpen:h,isSubscribed:v,pub:n,onClose:()=>{m(!1)},children:(0,o.Y)(p.pT,(0,r._)((0,i._)({},u),{cursor:"pointer",onClick:()=>{((0,f.u4)(f.qY.POST_PDF_BUTTON_CLICKED,{post_id:t.id}),v)?(0,b.V2)((0,_.MGs)(n,t.id),{local_navigation:!1,newTab:!0}):m(!h)},children:(0,o.Y)(s.A,{height:24,isHovered:d,width:24})}))})}},65812:function(e,t,n){n.d(t,{A:()=>s});var i=n(4006),r=n(97432),o=n(68349),a=n(39318);let l="emailInput-VN3GpJ";function s(e){let{pub:t,user:n,post:s,utmSource:c,submitButtonText:d,preset:u="primary",allowEmptyInput:p,onSuccess:h}=e,m="accent"===u?"".concat(l," ").concat("emailInputAccent-tTlqVa"," fp-email-input-accent"):"".concat(l," fp-email-input");return(0,i.Y)(r.A,{allowEmptyInput:p,className:"emailContainer-JfVhvU",inputClassName:m,placeholder:"ENTER YOUR EMAIL",promptClassName:"prompt-j7JgJU",pub:t,source:c,submitButtonText:null!=d?d:"SIGN UP",subscribeButtonClassName:"accent"===u?"".concat("subscribeButtonAccent-pwy2Eg"," fp-subscribe-button-accent"):"".concat("subscribeButton-fDC87J"," fp-subscribe-button"),user:n,onAccentBackground:!0,onSuccess:e=>{if(h)return h(e);(0,o.V2)((0,a.my9)(t,{just_signed_up:!0,autoSubmit:!!e.body.prompt_to_login||void 0,email:e.body.email,next:(0,a.wu9)(t,s)}),{replace:!0,local_navigation:!1})}})}},69656:function(e,t,n){n.d(t,{Q:()=>h});var i=n(4006),r=n(48697),o=n(17402),a=n(15894),l=n(46271),s=n(68410),c=n(35369),d=n(39318),u=n(57324);let p={container:"container-fkyH3f",content:"content-UDY69G",link:"link-R3vXCZ",dismissButton:"dismissButton-z1E0Nw"},h=e=>{let{pub:t,onDismiss:n}=e,[h,m]=(0,o.useState)(!1),{isMobile:g}=(0,s.sM)(),f=(0,l.Jd)(),b=(0,o.useCallback)(()=>"undefined"==typeof window?"#":(0,d.eV6)(t,{addBase:!0,next:(0,d.yRP)(window.location.href,{follow:!0}),utm_source:u.VU.fixedFooterPaywall,utm_medium:u.Jn.web}),[t]),_=(0,o.useCallback)(()=>"undefined"==typeof window?"#":(0,d.eV6)(t,{addBase:!0,isSignInAttempt:!0,next:(0,d.yRP)(window.location.href,{follow:!0}),utm_source:u.VU.fixedFooterPaywall,utm_medium:u.Jn.web}),[t]);return h?null:(0,i.FD)("div",{className:"".concat(p.container," ").concat(p.text),children:[(0,i.FD)(a.T,{preset:"detail-large",children:[g?"To read ":"To read this article, ",f?null:(0,i.FD)(i.FK,{children:[(0,i.Y)("a",{className:p.link,"data-native":!0,href:_(),children:"sign in"})," ","or"," "]}),(0,i.Y)("a",{className:p.link,"data-native":!0,href:b(),children:"subscribe"})]}),(0,i.Y)(c.Nm,{"aria-label":"Dismiss",className:p.dismissButton,onClick:()=>{m(!0),null==n||n()},children:(0,i.Y)(r.A,{size:20})})]})}},16514:function(e,t,n){n.d(t,{w:()=>u});var i=n(69277),r=n(70408),o=n(32641),a=n(4006),l=n(32485),s=n.n(l),c=n(13589),d=n(13950);let u=e=>{let{children:t,closeOnOutsideClick:n,content:l,isOpen:u,onClose:p,onToggle:h}=e,{arrowProps:m,layerProps:g,renderLayer:f,triggerProps:b}=(0,c.Z4)({auto:!0,containerOffset:28,isOpen:u,overflowContainer:!0,placement:"bottom-center",possiblePlacements:["bottom-center"],triggerOffset:16,onOutsideClick:n?p:void 0}),_=g.style,{style:v}=g,y=(0,o._)(g,["style"]),w="undefined"==typeof window;return(0,a.FD)(a.FK,{children:[(0,a.Y)("div",(0,r._)((0,i._)({},b),{onClick:()=>{null==h||h(!u)},children:t})),u&&!w&&f((0,a.FD)("div",(0,r._)((0,i._)({style:_},y),{className:s()("popoverContainer-EjJsJc","the-free-press-theme"),children:[(0,a.Y)(d.DH,{children:l}),(0,a.Y)(c.i3,(0,r._)((0,i._)({},m),{borderColor:"var(--color-fg-primary-themed)",borderWidth:2,size:10}))]})))]})}},77921:function(e,t,n){n.d(t,{n:()=>S});var i=n(69277),r=n(4006),o=n(32485),a=n.n(o),l=n(17402),s=n(13950),c=n(65812),d=n(15894),u=n(84565),p=n(68410),h=n(35369),m=n(76977),g=n(39318),f=n(57324);let b="wrapper-TFWk0w",_="fade-vBsC3Z",v="signInLink-TZ6ND4",y=[{name:"Annual",price:"$8.33/month",billedAs:"$100 yearly",save:"17%!"},{name:"Monthly",price:"$10/month",billedAs:"$10 monthly"}],w=(0,g.dJ9)("".concat((0,g.Ewe)(),"/img/thefp/save-ribbon.svg"),200),Y=e=>{let{onPlanChange:t}=e,[n,i]=(0,l.useState)("Annual"),o=e=>{i(e),null==t||t(e)},{isMobile:s}=(0,p.sM)();return(0,r.Y)(m.pT,{direction:s?"column":"row",gap:0,style:{width:"100%"},children:y.map(e=>(0,r.FD)("div",{className:a()("subPlanContainer-nTA_GR",n===e.name&&"selected-_2BPlx"),onClick:()=>o(e.name),children:[(0,r.Y)("input",{checked:n===e.name,className:"planRadio-wVgJ5P",name:"plan",type:"radio",value:e.name,onChange:()=>o(e.name)}),(0,r.FD)(m.I1,{alignItems:"start",gap:8,children:[(0,r.Y)(d.T,{preset:"lg-preview-byline",children:e.name}),(0,r.Y)(d.T,{color:"blue",preset:"d2-serif-bold",style:{paddingBottom:"2px"},children:e.price}),(0,r.FD)(d.T,{className:"billedAs-aSsRNm",preset:"caption",children:["Billed as ",e.billedAs]}),e.save&&(0,r.FD)("div",{className:"banner-PABwyI",style:{backgroundImage:'url("'.concat(w,'")'),backgroundRepeat:"no-repeat",backgroundSize:"cover",backgroundPosition:"right center",display:"flex",alignItems:"center",justifyContent:"flex-end",padding:"4px 8px 4px 16px"},children:[" ",(0,r.FD)(d.T,{color:"white",preset:"detail-small",children:["Save ",e.save]})]})]})]},e.name))})},S=e=>{var t;let{post:n,user:o,pub:p,freeSignupEmail:y,freeTrialCoupon:w}=e,S="newsletter"===n.type,k=!!(y||(null==o?void 0:o.is_free_subscribed)||!n.current_user_post_meter),C=(0,u.NQ)(),[I,D]=(0,l.useState)("Annual"),E=w&&(null!=(t=w.trial_period_days)?t:0)>0;if(k){let e="treatment"===C.getExperimentVariant("thefp_paywall_with_plans");return C.exposeExperiment("thefp_paywall_with_plans",{ignoreDownsampling:!0}),(0,r.Y)(s.DH,{children:(0,r.FD)(m.I1,{alignItems:"center",className:a()(b,{[_]:S,"wrapperWithPlans-PEZhOz":e}),gap:24,justifyContent:"center",textAlign:"center",children:[(0,r.FD)(m.I1,{gap:16,children:[(0,r.Y)(d.T,{preset:"h5-sans",children:E?"Start Your Free Trial to Unlock This Story":"Continue Reading The Free Press"}),!!n.current_user_post_meter&&(0,r.Y)(d.T,{preset:"d2-serif",children:"You've reached your monthly article limit."}),(0,r.Y)(d.T,{preset:"d3-serif",children:E?"Support our journalism and unlock all of our investigative stories and provocative commentary about the world as it actually is. Get your first ".concat(w.trial_period_days," days free."):"To support our journalism, and unlock all of our investigative stories and provocative commentary about the world as it actually is, subscribe below."}),e&&(0,r.Y)(Y,{onPlanChange:D})]}),(0,r.Y)(h.Nm,{className:"subscribeButtonLarge-lAytbH",href:(0,g.my9)(p,(0,i._)({utm_source:f.VU.meteredPostPaywall,next:(0,g.wu9)(p,n,{noBase:!0})},e&&I&&{plan:I.toLowerCase()})),localNavigation:!1,children:(0,r.Y)(d.T,{color:"white",preset:"detail-large",children:E?"Start Free Trial":"Subscribe Now"})}),(0,r.FD)(m.Ye,{alignItems:"center",gap:8,justifyContent:"center",children:[(0,r.Y)(d.T,{preset:"detail-small",children:"Already have an account?"}),(0,r.Y)("a",{className:v,href:(0,g.my9)(p,{isSignInAttempt:!0,next:(0,g.wu9)(p,n,{noBase:!0})}),children:(0,r.Y)(d.T,{color:"accent",preset:"detail-large",children:"Sign In"})})]})]})})}return(0,r.Y)(s.DH,{children:(0,r.FD)(m.I1,{alignItems:"center",className:a()(b,{[_]:S}),gap:24,justifyContent:"center",textAlign:"center",children:[(0,r.FD)(m.I1,{gap:16,children:[(0,r.Y)(d.T,{preset:"h5-sans",children:"Enjoying the story?"}),(0,r.Y)(d.T,{preset:"d2-serif",children:"Enter your email to read this article and receive our daily newsletter."})]}),(0,r.Y)(c.A,{post:n,pub:p,user:o,utmSource:f.VU.meteredPostRegistrationWall}),(0,r.FD)(m.Ye,{gap:16,children:[(0,r.Y)(d.T,{preset:"caption",children:"Already have an account?"}),(0,r.Y)("a",{className:v,href:(0,g.my9)(p,{isSignInAttempt:!0,next:(0,g.wu9)(p,n,{noBase:!0})}),children:(0,r.Y)(d.T,{color:"accent",preset:"caption",children:"Sign In"})})]})]})})}},1842:function(e,t,n){n.d(t,{_:()=>v});var i=n(4006),r=n(32485),o=n.n(r),a=n(38221),l=n.n(a),s=n(17402),c=n(17988),d=n(64647),u=n(15894),p=n(76977),h=n(75303),m=n(58278),g=n(82776);let f="label-gHN5_J",b="active-label-ndUdOP",_=e=>{let{postId:t,toc:n,title:r,activeItem:a,wordCount:c,leftMargin:_,commentCount:v,showComments:y,onItemClick:w}=e,Y=(0,s.useRef)(null),[S,k]=(0,s.useState)(!1),[C,I]=(0,s.useState)("0"),[D,E]=(0,s.useState)("0"),x=(0,s.useCallback)(()=>{if(Y.current){var e,t,n;let i=Y.current.getBoundingClientRect(),r=null==(e=Y.current.parentElement)?void 0:e.getBoundingClientRect(),o=null==(n=Y.current.parentElement)||null==(t=n.parentElement)?void 0:t.getBoundingClientRect(),a=window.innerHeight/2;if(i&&r)if(a+2>r.top+i.height/2){let e=((e,t)=>{if(document.getElementById("discussion")){var n,i;return Number(null==(i=document.getElementById("discussion"))||null==(n=i.getBoundingClientRect())?void 0:n.top)+t/2+20}return Number(null==e?void 0:e.bottom)-t/2})(o,i.height);e<=a?(k(!0),I(e.toString())):(k(!0),I("50%")),E(r.left.toString())}else k(!1),I("0"),E("0")}},[S,Y,C]),T=(0,s.useMemo)(()=>l()(x,25,{trailing:!0,leading:!0,maxWait:60}),[x]);(0,s.useEffect)(()=>(window.addEventListener("scroll",T,{passive:!0}),()=>{window.removeEventListener("scroll",T)}),[S,T]);let P="".concat(_+Number(D),"px");return(0,i.Y)("div",{id:"toc",style:{position:"relative"},children:(0,i.Y)("div",{ref:Y,className:o()("container-NR9v7N",S&&"fixed-gIIqpc"),style:{top:"50%"===C?"50%":Number(C),left:P},children:(0,i.FD)(p.I1,{flex:"grow",gap:4,children:[r&&(0,i.FD)("div",{className:o()("header-ggAXv9",f),id:"header"===a?b:void 0,onClick:()=>w(document.querySelector(".markup")),children:[(0,i.Y)(u.T,{className:"title-3Yeuyx",color:"header"===a?"primary":"disabled",preset:"detail-large",children:r}),!!c&&(0,i.FD)(u.T,{color:"header"===a?"primary":"disabled",preset:"caption",children:[Math.round(c/g.READ_WORDS_PER_MINUTE)," min read"]})]}),n.map((e,n)=>{let r=(0,m.HN)(e.text,t),o=a===r;return(0,i.Y)(h.AE,{href:"#\xa7".concat(r),onClick:e=>{e.preventDefault(),w(document.getElementById("\xa7".concat(r)))},children:(0,i.Y)(p.Ye,{children:(0,i.Y)(u.T,{className:f,color:o?"primary":"disabled",id:o?b:void 0,preset:"body",children:e.text})})},n)}),y&&(0,i.FD)("div",{className:o()("commentContainer-dmiFCB",f),onClick:()=>w(document.getElementById("discussion")),children:[(0,i.Y)(d.A,{isHovered:"discussion"===a}),v]})]})})})},v=e=>{let{postId:t,toc:n,title:r,wordCount:o,leftMargin:a=0,commentCount:l,showComments:d}=e,u=((e,t)=>{let[n,i]=(0,s.useState)("header"),r=[{text:"header",id:"header",selector:".markup > p:first-of-type"},...e,{text:"discussion",id:"discussion",selector:"#discussion > div"}];return(0,s.useEffect)(()=>{let e=[];return r.forEach(n=>{let r=(0,m.HN)(n.text,t),o=document.getElementById("\xa7".concat(r))||n.selector&&document.querySelector(n.selector);if(o){let t=new IntersectionObserver(e=>{e.forEach(e=>{e.isIntersecting&&e.intersectionRatio>=.3&&i(r)})},{rootMargin:"0% 0px -70% 0px"});t.observe(o),e.push(t)}}),()=>e.forEach(e=>e.disconnect())},[e]),n})(n,t),p=(0,c.useMediaQuery)({maxWidth:1100});return n.length<2||p?null:(0,i.Y)(_,{activeItem:u,commentCount:l,leftMargin:a,postId:t,showComments:d,title:r,toc:n,wordCount:o,onItemClick:e=>{e&&e.scrollIntoView({behavior:"smooth",block:"start"})}})}},90847:function(e,t,n){n.d(t,{Z:()=>p});var i=n(4006),r=n(32485),o=n.n(r),a=n(13950),l=n(49984),s=n(68410),c=n(89490),d=n(49807);let u={thefpPostBodyWrapper:"thefpPostBodyWrapper-Sk9SUV",withEagleWatermark:"withEagleWatermark-SQ7w6N",eagleWatermark:"eagleWatermark-QuTSZR",noPaddingOnMobile:"noPaddingOnMobile-SkPaHP",withDropCap:"withDropCap-izNtyr",withSpaceForMissingDropCap:"withSpaceForMissingDropCap-MMwASG",threadHeadBody:"threadHeadBody-gHFj3E"},p=e=>{var t,n;let{children:r,disabled:p,inThreadHead:h,isCustomPage:m,isShowsPost:g,post:f}=e,b=!!(null==f||null==(t=f.postTheme)?void 0:t.disable_drop_cap),{isMobile:_}=(0,s.sM)(),v=!!f&&(0,l.o6)(f)&&_;return p?(0,i.Y)(i.FK,{children:r}):(0,i.Y)(a.DH,{children:(0,i.FD)(c.az,{className:o()(u.thefpPostBodyWrapper,u[null==f||null==(n=f.postTheme)?void 0:n.header_variant],{[u.withDropCap]:!(h||m||b),[u.withSpaceForMissingDropCap]:b,[u.threadHeadBody]:h,[u.noPaddingOnMobile]:g||h||m,[u.withEagleWatermark]:v}),children:[v&&(0,i.Y)("div",{className:u.eagleWatermark,style:{backgroundImage:"url(".concat((0,d.dJ9)("".concat((0,d.Ewe)(),"/img/thefp/eagle_stamp.png"),500,{quality:"auto:good",crop:"limit"}),")")}}),r]})})}},86673:function(e,t,n){n.d(t,{xn:()=>D,qS:()=>C,ct:()=>k,wu:()=>I});var i=n(69277),r=n(70408),o=n(4006),a=n(36119),l=n.n(a),s=n(54718),c=n(13589),d=n(64647),u=n(32641),p=n(97731),h=n(57753);let m=e=>{var{isHovered:t,isLiked:n}=e,a=(0,u._)(e,["isHovered","isLiked"]);let l=n?h.Q3.mediumRed.hex:t?h.Q3.brightOrange.hex:h.Q3.lightGray.hex;return(0,o.FD)(p.A,(0,r._)((0,i._)({},a),{name:"FPLikeIcon",svgParams:{width:24,height:24,viewBox:"0 0 24 24",stroke:"none",fill:"none"},children:[(0,o.Y)("path",{d:"M3.69231 1H9.23077V2.83333H11.0769V4.66667H12.9231V2.83333H14.7692V1H20.3077V2.83333H22.1538V4.66667H24V12H22.1538V13.8333H20.3077V15.6667H18.4615V17.5H16.6154V19.3333H14.7692V21.1667H12.9231V23H11.0769V21.1667H9.23077V19.3333H7.38462V17.5H5.53846V15.6667H3.69231V13.8333H1.84615V12H0V4.66667H1.84615V2.83333H3.69231V1Z",fill:l}),(0,o.Y)("rect",{x:"5",y:"4",width:"2",height:"2",fill:"white"}),(0,o.Y)("rect",{x:"3",y:"6",width:"2",height:"4",fill:"white"})]}))};var g=n(25461),f=n(97683),b=n(41935),_=n(33460),v=n(15894),y=n(35369),w=n(76977),Y=n(49807),S=n(82776);let k=e=>{let{cta:t,post:n,pub:a,showCounts:s=!0,size:d,user:u,onChange:p}=e,[h,g]=(0,c.Mk)(),f=l()(Object.values((null==n?void 0:n.reactions)||{})),_=(0,S.numberToString)(f||0),y="small"===d?16:24,Y="small"===d?"sm-preview-byline":"detail-large";return(0,o.Y)(b.Z4,{isStatic:!1,post:n,pub:a,user:u,variant:"button",onChange:p,children:e=>{let{isLiked:n,handleLike:a}=e;return(0,o.FD)(w.Ye,(0,r._)((0,i._)({},g),{alignItems:"center",cursor:"pointer",gap:8,role:"button",onClick:a,children:[(0,o.FD)(w.Ye,{alignItems:"center",gap:"small"===d?4:6,children:[(0,o.Y)(m,{height:y,isHovered:h,isLiked:n,width:y}),s&&f>0&&(0,o.Y)(v.T,{preset:Y,children:_})]}),t&&(0,o.Y)(v.T,{preset:"detail-large",children:t})]}))}})},C=e=>{let t,{post:n,pub:a,showCounts:l=!0,size:s,cta:u}=e,[p,h]=(0,c.Mk)(),m=(0,S.numberToString)(n.comment_count),g="small"===s?16:24;return t=(null==n?void 0:n.comment_url_override)?n.comment_url_override:(0,Y.wu9)(a,n,{comments:!0}),(0,o.FD)(w.Ye,(0,r._)((0,i._)({},h),{alignItems:"center",cursor:"pointer",gap:8,role:"button",onClick:e=>{e.stopPropagation(),window.location.href=t},children:[(0,o.FD)(w.Ye,{alignItems:"center",gap:"small"===s?4:6,children:[(0,o.Y)(d.A,{height:g,isHovered:p,width:g}),n.comment_count>0&&l&&(0,o.Y)(v.T,{preset:"small"===s?"sm-preview-byline":"detail-large",children:m})]}),u&&(0,o.Y)(v.T,{preset:"detail-large",children:u})]}))},I=e=>{let{pub:t,post:n,user:a,cta:l}=e,[s,d]=(0,c.Mk)();return(0,o.Y)(_.$8,{post:n,pub:t,trigger:(0,o.FD)(w.pT,(0,r._)((0,i._)({},d),{alignItems:"center",cursor:"pointer",gap:8,children:[(0,o.Y)(g.A,{height:24,isHovered:s,width:24}),l&&(0,o.Y)(v.T,{preset:"detail-large",children:l})]})),user:a})},D=e=>{let{className:t,context:n,post:a,pub:l,user:d}=e,[u,p]=(0,c.Mk)();if(!d)return null;let m=u?h.Q3.brightOrange.hex:h.Q3.lightGray.hex,g=(0,o.Y)(y.Nm,(0,r._)((0,i._)({display:"flex",resetCss:!0},p),{onClick:e=>{e.stopPropagation()},children:(0,o.Y)(s.A,{size:"post-preview"===n?16:24,stroke:m})}));return(0,o.Y)("div",{className:t,style:{cursor:"pointer"},children:(0,o.Y)(f.D,{hideDropCapOption:"post-preview"===n,hidePinning:!0,hidePostHeaderOptions:"post-preview"===n,post:a,pub:l,trigger:g,user:d})})}},47791:function(e,t,n){n.d(t,{A:()=>I});var i=n(69277),r=n(70408),o=n(32641),a=n(4006),l=n(32485),s=n.n(l),c=n(17402),d=n(99070),u=n(20347),p=n(3849),h=n(97731);let m=e=>{var t=(0,u._)({},(0,p._)(e));return(0,a.Y)(h.A,(0,r._)((0,i._)({},t),{name:"FPPauseIcon",svgParams:{width:25,height:25,viewBox:"0 0 25 24",fill:"none",stroke:"none"},children:(0,a.FD)("g",{id:"play-circle",children:[(0,a.Y)("path",{id:"Icon",d:"M12.5 22C18.0228 22 22.5 17.5228 22.5 12C22.5 6.47715 18.0228 2 12.5 2C6.97715 2 2.5 6.47715 2.5 12C2.5 17.5228 6.97715 22 12.5 22Z",stroke:"#F2312C",strokeWidth:"2",strokeLinecap:"round"}),(0,a.Y)("rect",{id:"Rectangle 2398",x:"8.5",y:"7.08496",width:"3",height:"10",fill:"#F2312C"}),(0,a.Y)("rect",{id:"Rectangle 2399",x:"13.5",y:"7.08496",width:"3",height:"10",fill:"#F2312C"})]})}))};var g=n(92918),f=n(63446),b=n(16514),_=n(15894),v=n(86500),y=n(76977),w=n(39318),Y=n(82776),S=n(57324);let k="ctaMode-zO5a9a",C=e=>{let{containerRef:t,currentTime:n,remainingTime:i,progress:r,onMouseDown:o,className:l}=e;return(0,a.FD)(y.Ye,{alignItems:"center",className:l,gap:4,children:[(0,a.Y)(_.T,{preset:"caption",style:{flexShrink:0,minWidth:"28px"},children:n}),(0,a.FD)("div",{ref:t,className:"progressBar-yUZk3A",onMouseDown:o,children:[(0,a.Y)("div",{className:"progressBarBackground-rOIsbW"}),(0,a.Y)("div",{className:"progressBarProgress-EiVcPg",style:{width:"".concat(100*r,"%")}}),(0,a.Y)("div",{className:"progressBarPlayhead-KWfdzC",style:{left:"".concat(100*r,"%")}})]}),(0,a.Y)(_.T,{preset:"caption",style:{flexShrink:0,paddingLeft:"4px",minWidth:"36px"},children:i})]})},I=e=>{var{mediaUploadId:t,user:n,post:l,pub:u}=e,p=(0,o._)(e,["mediaUploadId","user","post","pub"]);let[h,I]=(0,c.useState)(!0),[D,E]=(0,c.useState)(!1),x=!!(null==n?void 0:n.is_subscribed),T=!!(null==n?void 0:n.is_free_subscribed);return(0,c.useEffect)(()=>{D&&(0,v.u4)(v.qY.TTS_UPGRADE_TO_LISTEN_CLICKED,{post_id:l.id})},[D,l.id]),(0,a.Y)(d.A,(0,r._)((0,i._)({},p),{feature:"Add voiceover",metricsPost:l,post:l,pub:u,render:e=>{let{isPaywalled:t,currentTime:n,isPlaying:i,progress:r,progressBarRef:o,progressBarOnMouseDown:c,remainingTime:d,duration:p,togglePlayback:v}=e,P=()=>{t?E(!0):(h&&I(!1),v())},F=(0,a.FD)(y.Ye,{alignItems:"center",className:s()("wrapper-LdgflB",{[k||""]:h}),gap:16,justifyContent:"space-between",children:[(0,a.FD)(y.Ye,{alignItems:"center",className:s()("innerWrapper-ersGfZ",{[k||""]:h}),gap:16,onClick:h?P:void 0,children:[(0,a.Y)(y.I1,{className:s()("playButton-vLW5qd",{[k||""]:h,"static-tP398S":t}),style:{flexShrink:0},onClick:()=>{P()},children:i?(0,a.Y)(m,{}):(0,a.Y)(g.A,{})}),(0,a.Y)(C,{className:s()("progressBarWrap-vpoiUw",{[k||""]:h}),containerRef:o,currentTime:n,progress:r,remainingTime:d,onMouseDown:c}),(0,a.FD)(y.Ye,{alignItems:"center",className:s()("cta-GdLXe1",{[k||""]:h}),gap:16,children:[(0,a.Y)(_.T,{preset:"detail-small",children:t?"Upgrade to Listen":"Listen to Article"}),(0,a.Y)(_.T,{color:"tertiary",preset:"caption",style:{flexShrink:0},children:(0,Y.secondsToLargestUnit)(p||300)})]})]}),(0,a.Y)(_.T,{className:s()("disclaimer-i3yYG0",{[k||""]:h}),color:"tertiary",preset:"caption",children:"Produced by ElevenLabs using AI narration"})]});return t?(0,a.Y)(b.w,{closeOnOutsideClick:!0,content:(0,a.FD)(y.I1,{gap:4,position:"relative",children:[(0,a.Y)(_.T,{preset:"d4-serif",children:"Listening to articles, is a benefit we're proud to offer our paid subscribers. Sign up today to unlock this feature."}),!x&&(0,a.Y)(y.Ye,{children:(0,a.Y)(f.v,{href:(0,w.my9)(u,{UTM_SOURCE:S.VU.voiceoverPlayer,next:(0,w.wu9)(u,l)}),localNavigation:!1,size:"sm",trailingIcon:"chevron-right",variant:"tertiary",children:T?"Upgrade now":"Subscribe now"})})]}),isOpen:D,onClose:()=>{E(!1)},children:F}):F},src:t?"/api/v1/audio/upload/".concat(t,"/src"):null,trackingProps:{}}))}},89160:function(e,t,n){n.d(t,{G:()=>l});var i=n(38970),r=n.n(i),o=n(17402),a=n(13770);let l=e=>{let{pub:t}=e,n=r()(null==t?void 0:t.sections,"id"),{setting:i,save:l}=(0,a.E)({key:"archived_section_ids",fallback:[]}),[s,c]=(0,o.useState)(i),[d,u]=(0,o.useState)(!1),p=async()=>{u(!0),await l({setting:s})};return{isSaving:d,ids:s,onChange:e=>{let{ids:t}=e;c(t.filter(e=>n[e]))},onSave:p}}},79796:function(e,t,n){n.d(t,{i:()=>c});var i=n(38970),r=n.n(i),o=n(44383),a=n.n(o),l=n(17402),s=n(13770);let c=e=>{let{pub:t,pubSetting:n="column_section_ids"}=e,i=r()(null==t?void 0:t.sections,"id"),{setting:o,save:c}=(0,s.E)({key:n,fallback:{metadata:{},order:[]}}),[d,u]=(0,l.useState)(o.order),[p,h]=(0,l.useState)(o.metadata),[m,g]=(0,l.useState)(!1),f=async()=>{g(!0),await c({setting:{order:d,metadata:a()(p,d)}})};return{isSaving:m,metadata:p,ids:d,onChangeMetadata:e=>{let{metadata:t}=e;h(t)},onChangeOrder:e=>{let{ids:t}=e;u(t.filter(e=>i[e]))},onSave:f}}},27428:function(e,t,n){n.d(t,{M:()=>c});var i=n(83673),r=n.n(i),o=n(38970),a=n.n(o),l=n(17402),s=n(13770);let c=e=>{let{pub:t}=e,n=a()(null==t?void 0:t.sections,"id"),{setting:i,save:o}=(0,s.E)({key:"event_section_ids",fallback:[]}),[c,d]=(0,l.useState)(i),[u,p]=(0,l.useState)(!1),h=async()=>{p(!0),await o({setting:c})};return{initialSections:r()(i.map(e=>n[e])),isSaving:u,ids:c,sections:r()(c.map(e=>n[e])),onChange:e=>{let{ids:t}=e;d(t.filter(e=>n[e]))},onSave:h}}},13770:function(e,t,n){n.d(t,{E:()=>r});var i=n(53989);let r=e=>{let t,{key:n,fallback:r}=e,{getSettingFor:o,changeSetting:a}=(0,i.Pu)(),l=o(n);try{t=l?JSON.parse(l):r}catch(e){t=r}return{setting:t,save:async e=>{let{setting:t}=e;await a({[n]:JSON.stringify(t)})}}}},77124:function(e,t,n){n.d(t,{q:()=>p});var i=n(69277),r=n(70408),o=n(44383),a=n.n(o),l=n(17402),s=n(13770),c=n(74894);let d={"Honestly with Bari Weiss":"darkGreen","The Witch Trials of J.K. Rowling":"mediumOrange","Raising Parents with Emily Oster":"brightBlue"},u=["mediumYellow","darkGreen","mediumRed","darkOrange","mediumPurple","mediumBlue"],p=e=>{let{pub:t}=e,n=t?(0,c.Zu)(t):[],o=n.map(e=>{var t;return null!=(t=e.sectionId)?t:-1}),p=n.reduce((e,t,n)=>{var o,a,l;return(0,r._)((0,i._)({},e),{[null!=(o=t.sectionId)?o:-1]:{carouselColor:null!=(l=null!=(a=d[t.podcastTitle])?a:u[n%u.length])?l:"mediumRed"}})},{}),{setting:h,save:m}=(0,s.E)({key:"podcasts_metadata",fallback:{order:o,metadata:p}}),[g,f]=(0,l.useState)(h.order),[b,_]=(0,l.useState)(h.metadata),v=async()=>{await m({setting:{order:g,metadata:a()(b,g)}})};return{ids:g,metadata:b,onChangeOrder:e=>{let{ids:t}=e;f(t)},onChangeMetadata:e=>{let{metadata:t}=e;_(t)},onSave:v}}},95691:function(e,t,n){n.d(t,{P:()=>p});var i=n(83673),r=n.n(i),o=n(38970),a=n.n(o),l=n(44383),s=n.n(l),c=n(17402),d=n(13770);let u=["mediumYellow","darkGreen","mediumRed","darkOrange","mediumPurple","mediumBlue"],p=e=>{let{pub:t}=e,n=a()(null==t?void 0:t.sections,"id"),{setting:i,save:o}=(0,d.E)({key:"video_section_ids",fallback:{metadata:{},order:[]}});for(let e=0;e{v(!0),await o({setting:{order:m,metadata:s()(f,m)}}),window.location.reload()};return{initialSections:r()(i.order.map(e=>n[e])),isSaving:_,metadata:f,ids:m,sections:r()(m.map(e=>n[e])),onChangeMetadata:e=>{let{metadata:t}=e;b(t)},onChangeOrder:e=>{let{ids:t}=e;g(t.filter(e=>n[e]))},onSave:y}}},81668:function(e,t,n){n.d(t,{w:()=>m});var i=n(4006),r=n(17402),o=n(84605),a=n(86500),l=n(35369),s=n(76977),c=n(28911),d=n(63136),u=n(54542),p=n(39318),h=n(57324);function m(e){let{postId:t,onClose:n}=e,{iString:u}=(0,o.GO)();return(0,r.useEffect)(()=>{(0,a.u4)(a.qY.LISTEN_TO_THIS_POST_MODAL_SHOWN,{post_id:t})},[]),(0,i.FD)(c.aF,{isOpen:!0,onClose:n,children:[(0,i.Y)(c.rQ,{onClose:n}),(0,i.Y)(c.cw,{children:(0,i.FD)(s.I1,{alignItems:"center",gap:24,children:[(0,i.FD)(s.I1,{style:{textAlign:"center"},justifyContent:"center",gap:8,children:[(0,i.Y)(d.EY.H3,{weight:"heavy",children:u("Listen to this post")}),(0,i.Y)(d.EY,{color:"secondary",style:{lineHeight:1.5},children:u("Get the Substack app to hear this article read aloud.")})]}),(0,i.Y)(g,{})]})}),(0,i.Y)(c.jl,{showDivider:!0,direction:"column",primaryButton:(0,i.Y)(l.$n,{priority:"primary",href:(0,p.wHz)({utm_source:h.VU.web,utm_campaign:h._9.ttsModal}),onClick:()=>(0,a.u4)(a.qY.LISTEN_TO_THIS_POST_MODAL_GET_THE_APP_CLICKED,{post_id:t}),children:u("Get the app")})})]})}function g(){let e="/img/main/tts-dialog";return(0,i.FD)("video",{height:220,autoPlay:!0,muted:!0,loop:!0,children:[(0,i.Y)("source",{src:"".concat(e,"/nux.mp4"),type:"video/mp4"}),(0,i.Y)("img",{width:374,height:233,src:"".concat(e,"/1x.png"),srcset:Array.from((0,u.y1)(1,4)).map(t=>"".concat(e,"/").concat(t,"x.png ").concat(t,"x")).join(", ")})]})}},1459:function(e,t,n){n.d(t,{e:()=>i});let i=(e,t)=>"enabled"===t.payments_state?e.is_subscribed:e.is_free_subscribed},36375:function(e,t,n){n.d(t,{A:()=>u});var i=n(4006),r=n(45994),o=n(34746),a=n(52077),l=n(84605),s=n(86500),c=n(56458),d=n(82776);let u=e=>{let{post:t,pub:n,user:u,playerRef:p}=e,h=!(0,d.canSeeTranscription)(u,t),m=(0,c.NJ)(t),{iString:g}=(0,l.GO)();return((0,r.vJ)(()=>{(0,s.u4)(s.qY.TRANSCRIPTION_PAGE_VIEWED,{post_id:t.id})},[t.id]),m)?h?(0,i.Y)(o.pU,{user:u,publication:n,post:t,title:g("Transcriptions on this post are for paid subscribers"),reauthenticationTitle:g("To see the post, please re-authenticate.")}):(0,i.Y)(a.Ay,{transcription:m,player:p,postId:t.id}):null}}}]);