1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,247984,e=>{"use strict";var t={0:8203,1:8204,2:8205,3:8290,4:8291,5:8288,6:65279,7:8289,8:119155,9:119156,a:119157,b:119158,c:119159,d:119160,e:119161,f:119162},n={0:8203,1:8204,2:8205,3:65279},r={0:String.fromCodePoint(n[0]),1:String.fromCodePoint(n[1]),2:String.fromCodePoint(n[2]),3:String.fromCodePoint(n[3])},a=[,,,,].fill(String.fromCodePoint(n[0])).join("");Object.fromEntries(Object.entries(r).map(e=>[e[1],+e[0]])),Object.fromEntries(Object.entries(t).map(e=>e.reverse()));var o=`${Object.values(t).map(e=>`\\u{${e.toString(16)}}`).join("")}`,i=RegExp(`[${o}]{4,}`,"gu");e.s(["isRecord",0,function(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)},"stegaClean",0,function(e){var t,n;return e&&JSON.parse({cleaned:(t=JSON.stringify(e)).replace(i,""),encoded:(null==(n=t.match(i))?void 0:n[0])||""}.cleaned)},"y",0,function(e,t,n="auto"){return!0===n||"auto"===n&&(!(!Number.isNaN(Number(e))||/[a-z]/i.test(e)&&!/\d+(?:[-:\/]\d+){2}(?:T\d+(?:[-:\/]\d+){1,2}(\.\d+)?Z?)?/.test(e))&&Date.parse(e)||function(e){try{new URL(e,e.startsWith("/")?"https://acme.com":void 0)}catch{return!1}return!0}(e))?e:`${e}${function(e){let t=JSON.stringify(e),n=new TextEncoder().encode(t),o="";for(let e=0;e<n.length;e++){let t=n[e];o+=r[t>>6&3]+r[t>>4&3]+r[t>>2&3]+r[3&t]}return a+o}(t)}`}])},621482,e=>{"use strict";var t=e.i(869230),n=e.i(992571),r=class extends t.QueryObserver{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e){super.setOptions({...e,behavior:(0,n.infiniteQueryBehavior)()})}getOptimisticResult(e){return e.behavior=(0,n.infiniteQueryBehavior)(),super.getOptimisticResult(e)}fetchNextPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"backward"}}})}createResult(e,t){let{state:r}=e,a=super.createResult(e,t),{isFetching:o,isRefetching:i,isError:s,isRefetchError:l}=a,u=r.fetchMeta?.fetchMore?.direction,c=s&&"forward"===u,d=o&&"forward"===u,m=s&&"backward"===u,f=o&&"backward"===u;return{...a,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:(0,n.hasNextPage)(t,r.data),hasPreviousPage:(0,n.hasPreviousPage)(t,r.data),isFetchNextPageError:c,isFetchingNextPage:d,isFetchPreviousPageError:m,isFetchingPreviousPage:f,isRefetchError:l&&!c&&!m,isRefetching:i&&!d&&!f}}},a=e.i(469637);e.s(["useInfiniteQuery",0,function(e,t){return(0,a.useBaseQuery)(e,r,t)}],621482)},303756,e=>{"use strict";let t=new Set,n="checking",r=new Set,a=new Set,o=null;e.s(["d",0,function(e){for(let e of r)e()},"f",0,function(e){if(n.toString()!==e.toString())for(let r of(n=e,t))r()},"l",0,function(e){for(let t of(o=e,a))t()},"r",0,a,"t",()=>o,"u",0,function(e,t){for(let e of a)e()}])},90317,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={bindSnapshot:function(){return u},createAsyncLocalStorage:function(){return l},createSnapshot:function(){return c}};for(var a in r)Object.defineProperty(n,a,{enumerable:!0,get:r[a]});let o=Object.defineProperty(Error("Invariant: AsyncLocalStorage accessed in runtime where it is not available"),"__NEXT_ERROR_CODE",{value:"E504",enumerable:!1,configurable:!0});class i{disable(){throw o}getStore(){}run(){throw o}exit(){throw o}enterWith(){throw o}static bind(e){return e}}let s="u">typeof globalThis&&globalThis.AsyncLocalStorage;function l(){return s?new s:new i}function u(e){return s?s.bind(e):i.bind(e)}function c(){return s?s.snapshot():function(e,...t){return e(...t)}}},242344,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"workAsyncStorageInstance",{enumerable:!0,get:function(){return r}});let r=(0,e.r(90317).createAsyncLocalStorage)()},563599,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"workAsyncStorage",{enumerable:!0,get:function(){return r.workAsyncStorageInstance}});let r=e.r(242344)},309885,(e,t,n)=>{"use strict";function r(e){return e.split("/").map(e=>encodeURIComponent(e)).join("/")}Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"encodeURIPath",{enumerable:!0,get:function(){return r}})},667585,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"BailoutToCSR",{enumerable:!0,get:function(){return a}});let r=e.r(132061);function a({reason:e,children:t}){if("u"<typeof window)throw Object.defineProperty(new r.BailoutToCSRError(e),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,
1configurable:!0});return t}},652157,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"PreloadChunks",{enumerable:!0,get:function(){return l}});let r=e.r(843476),a=e.r(174080),o=e.r(563599),i=e.r(309885),s=e.r(543369);function l({moduleIds:e}){if("u">typeof window)return null;let t=o.workAsyncStorage.getStore();if(void 0===t)return null;let n=[];if(t.reactLoadableManifest&&e){let r=t.reactLoadableManifest;for(let t of e){if(!r[t])continue;let e=r[t].files;n.push(...e)}}if(0===n.length)return null;let u=(0,s.getAssetTokenQuery)();return(0,r.jsx)(r.Fragment,{children:n.map(e=>{let n=`${t.assetPrefix}/_next/${(0,i.encodeURIPath)(e)}${u}`;return e.endsWith(".css")?(0,r.jsx)("link",{precedence:"dynamic",href:n,rel:"stylesheet",as:"style",nonce:t.nonce},e):((0,a.preload)(n,{as:"script",fetchPriority:"low",nonce:t.nonce}),null)})})}},869093,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"default",{enumerable:!0,get:function(){return u}});let r=e.r(843476),a=e.r(271645),o=e.r(667585),i=e.r(652157);function s(e){return{default:e&&"default"in e?e.default:e}}let l={loader:()=>Promise.resolve(s(()=>null)),loading:null,ssr:!0},u=function(e){let t={...l,...e},n=(0,a.lazy)(()=>t.loader().then(s)),u=t.loading;function c(e){let s=u?(0,r.jsx)(u,{isLoading:!0,pastDelay:!0,error:null}):null,l=!t.ssr||!!t.loading,c=l?a.Suspense:a.Fragment,d=t.ssr?(0,r.jsxs)(r.Fragment,{children:["u"<typeof window?(0,r.jsx)(i.PreloadChunks,{moduleIds:t.modules}):null,(0,r.jsx)(n,{...e})]}):(0,r.jsx)(o.BailoutToCSR,{reason:"next/dynamic",children:(0,r.jsx)(n,{...e})});return(0,r.jsx)(c,{...l?{fallback:s}:{},children:d})}return c.displayName="LoadableComponent",c}},770703,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0}),Object.defineProperty(n,"default",{enumerable:!0,get:function(){return a}});let r=e.r(555682)._(e.r(869093));function a(e,t){let n={};"function"==typeof e&&(n.loader=e);let a={...n,...t};return(0,r.default)({...a,modules:a.loadableGenerated?.modules})}("function"==typeof n.default||"object"==typeof n.default&&null!==n.default)&&void 0===n.default.__esModule&&(Object.defineProperty(n.default,"__esModule",{value:!0}),Object.assign(n.default,n),t.exports=n.default)},296142,e=>{"use strict";var t=e.i(843476),n=e.i(271645),r=e.i(672950),a=e.i(555977);let o="catalyst_ad_top";e.s(["default",0,({onViewable:e,showAd:i=!0})=>((0,n.useEffect)(()=>{if(!e||!i)return;let t=n=>{n.detail.containerId===o&&(e(o),document.removeEventListener("cmnUNT-ad-viewable",t))};return document.addEventListener("cmnUNT-ad-viewable",t),()=>document.removeEventListener("cmnUNT-ad-viewable",t)},[e,i]),(0,t.jsx)(a.default,{fullBleed:!0,hideLabel:!0,className:"p-3 flex flex-col justify-center items-center min-h-[90px] sm:min-h-[100px] lg:min-h-[250px]",children:i&&(0,t.jsx)(r.default,{adType:"top",id:o})}))])},167155,e=>{"use strict";var t=e.i(843476),n=e.i(271645),r=e.i(255667),a=e.i(989970),o=e.i(395859);e.s(["default",0,()=>{let e=(0,r.useLenis)(),{setScrollEnabled:i}=(0,o.useCoverStoryContext)();return(0,n.useEffect)(()=>{"scrollRestoration"in history&&(history.scrollRestoration="manual"),window.scrollTo(0,0),e&&a.default.delayedCall(.1,()=>{e.scrollTo(0,{immediate:!0}),i(!1)})},[e,i]),(0,t.jsx)(r.ReactLenis,{root:!0})}])},128241,e=>{"use strict";var t=e.i(843476),n=e.i(919056);e.s(["default",0,({className:e="",...r})=>(0,t.jsxs)("div",{className:(0,n.twMerge)("block text-center w-full",e),...r,children:[(0,t.jsx)("span",{className:"inline-block h-[10px] w-[10px] mx-[5px] first:ml-0 last:mr-0",children:(0,t.jsx)("span",{className:"block bg-black w-full h-full content-[''] origin-center opacity-25 animate-pulsing-bubbles"})}),(0,t.jsx)("span",{className:"inline-block h-[10px] w-[10px] mx-[5px] first:ml-0 last:mr-0",children:(0,t.jsx)("span",{className:"block bg-black w-full h-full content-[''] origin-center opacity-25 animate-pulsing-bubbles-delay-300"})}),(0,t.jsx)("span",{className:"inline-block h-[10px] w-[10px] mx-[5px] first:ml-0 last:mr-0",children:(0,t.jsx)("span",{className:"block bg-black w-full h-full content-[''] origin-center opacity-25 animate-pulsing-bubbles-delay-600"})})]})])},870642,e=>{"use strict";e.s(["DEFAULT_FEED_PAGE_SIZE",0,18,"MAX_FEED_AUTOLOAD_COUNT",0,100])},911781,e=>{"use strict";var t=e.i(271645);e.s(["useNativeShare",0,function(){let[e,n]=(0,t.useState)(!1);return(0,t.useEffect)(()=>{n("function"==typeof navigator.share)},[]),{isSupported:e,nativeShare:(0,t.useCallback)(async e=>{if("function"!=typeof navigator.share)return"unsupported";try{return await navigator.share(e),"shared"}catch(e){if(e instanceof Error&&"AbortError"===e.name)return"cancelled";return"failed"}},[])}}])},976258,e=>{"use strict";let t=async(e,t,n="",r={})=>{let a=new URLSearchParams;e.size&&a.set("size",String(e.size)),t&&(a.set("cursor_id",t.id),a.set("cursor_publishedAt",t.publishedAt)),e.channelIds?.length&&a.set("channelIds",e.channelIds.join(",")),e.editionIds?.length&&a.set("editionIds",e.editionIds.join(",")),e.excludeTagIds?.length&&a.set("excludeTagIds",e.excludeTagIds.join(",")),e.excludeContentCategories?.length&&a.set("excludeContentCategories",e.excludeContentCategories.join(",")),e.channelSlug&&a.set("channelSlug",e.channelSlug),e.channel&&a.set("channel",e.channel),e.feedTagId&&a.set("feedTagId",e.feedTagId),e.feedTagSlug&&a.set("feedTagSlug",e.feedTagSlug),e.authorId&&a.set("authorId",e.authorId),e.authorSlug&&a.set("authorSlug",e.authorSlug),e.tagId&&a.set("tagId",e.tagId),e.tagSlug&&a.set("tagSlug",e.tagSlug),e.excludePostAlias&&a.set("excludePostAlias",e.excludePostAlias);let o={items:[],next:null,shopModules:[]};try{let e=await fetch(`${n}/api/feed?${a.toString()}`,{cache:"no-store",...r});if(!e.ok)return o;return await e.json()}catch{return o}};e.s(["fetchFeedPage",0,t])},595888,319699,e=>{"use strict";function t(e,t,n){return{ok:!1,status:t,...function(e,t,n){let r=e=>!!n?.includes(e);switch(e){case"create":if(409===t)return{message:"Looks like you already posted this. Give it a moment and try again.",code:"freeze"};if(429===t)return{message:"Oops! You're commenting too quickly. Try again in a moment.",code:"freeze"};if(503===t)return{message:"Commenting is temporarily disabled. Try again later.",code:"freeze"};if(404===t||400===t&&r("cannot reply to a deleted comment"))return{message:"This comment is no longer available. Refresh and try again.",code:"forbidden"};if(400===t&&r("blocked content"))return{message:"Your comment couldn't be posted. Please review our community guidelines and try again.",code:"freeze"};if(403===t)return{message:"Couldn't post your comment. Try again.",code:"suspended"};return{message:"Couldn't post your comment. Try again.",code:"unknown"};case"edit":if(403===t)return{message:"You can only edit your own comments.",code:"forbidden"};if(404===t||400===t&&r("cannot edit a deleted comment"))return{message:"This comment is no longer available.",code:"forbidden"};
1if(400===t&&r("can only be edited within"))return{message:"Your edit window has closed.",code:"forbidden"};if(429===t)return{message:"You're editing too quickly. Try again in a moment.",code:"freeze"};if(400===t&&r("blocked content"))return{message:"Your edit couldn't be saved. Please review our community guidelines and try again.",code:"freeze"};return{message:"Couldn't save your edit. Try again.",code:"unknown"};case"delete":if(404===t)return{message:"This comment has already been deleted."};if(429===t)return{message:"You're deleting too quickly. Try again in a moment."};return{message:"Couldn't delete your comment. Try again."};case"like":if(404===t||400===t&&r("cannot react to a deleted comment"))return{message:"This comment is no longer available. Refresh and try again."};if(429===t)return{message:"You're doing that too quickly. Try again in a moment."};return{message:"Couldn't like this comment. Try again."};case"unlike":if(404===t)return{message:"We couldn't find that like. Refresh and try again."};if(429===t)return{message:"You're doing that too quickly. Try again in a moment."};return{message:"Couldn't unlike this comment. Try again."};case"report":if(409===t)return{message:"You've already reported this comment."};if(404===t)return{message:"This comment is no longer available."};if(429===t)return{message:"You're reporting too quickly. Try again in a moment."};return{message:"Couldn't report this comment. Try again."}}}(e,t,n)}}function n(e){return e?.error}function r(){let e={};return{middleware:{onResponse({response:t}){e.status=t.status}},captured:e}}function a(e,t){console.error(`[comments/api] ${e} failed`,t);try{let n=window.faro;n?.api?.pushError?.(Error(`[comments/api] ${e} failed`),{context:{source:"comments-api",detail:t instanceof Error?t.message:String(t)}})}catch{}}e.s(["RERANK_ALREADY_POSTED_MESSAGE",0,"You already posted a ReRank here â delete your old one to post a new one.","getCommentErrorMessage",0,t],319699);let o={comments:[],next_cursor:null,total_count:0};async function i(e,t,n={}){try{let{data:r,error:a}=await e.GET("/comments",{params:{query:{external_id:t,...n}}});if(a||!r)return o;return r}catch(e){return a("fetchComments",e),o}}async function s(e,t){try{let{data:n,error:r}=await e.GET("/comments/count",{params:{query:{external_id:t}}});if(r||!n)return 0;return n.total_count??0}catch(e){return a("fetchCommentCount",e),0}}async function l(e,a){let{middleware:o,captured:i}=r();try{let{data:r,error:i,response:s}=await e.POST("/comments/{comment_id}/reactions",{params:{path:{comment_id:a}},body:{reaction_type:"like"},middleware:[o]});if(!i&&r)return{ok:!0,reaction:r.reaction};return t("like",s.status,n(i))}catch{return t("like",i.status)}}async function u(e,a,o){let{middleware:i,captured:s}=r();try{let{data:r,error:s,response:l}=await e.DELETE("/comments/{comment_id}/reactions/{reaction_id}",{params:{path:{comment_id:a,reaction_id:o}},middleware:[i]});if(!s&&r?.success)return{ok:!0};return t("unlike",l.status,n(s))}catch{return t("unlike",s.status)}}async function c(e,a,o){let{middleware:i,captured:s}=r();try{let{data:r,error:s,response:l}=await e.POST("/comments",{body:{external_id:a,...o},middleware:[i]});if(!s&&r)return{ok:!0,comment:r.comment};return t("create",l.status,n(s))}catch{return t("create",s.status)}}async function d(e,o,i){let{middleware:s,captured:l}=r();try{let{data:r,error:l,response:u}=await e.POST("/comments",{body:{external_id:o,...i},middleware:[s]});if(!l&&r)return{ok:!0,comment:r.comment};let c=n(l);return u.status>=500&&a("create rerank comment",Error(`POST /comments (rerank) responded ${u.status}${c?`: ${c}`:""}`)),t("create",u.status,c)}catch(e){return a("create rerank comment",e),t("create",l.status)}}async function m(e,a,o){let{middleware:i,captured:s}=r();try{let{data:r,error:s,response:l}=await e.PUT("/comments/{comment_id}",{params:{path:{comment_id:a}},body:{comment_text:o},middleware:[i]});if(!s&&r)return{ok:!0,comment:r.comment};return t("edit",l.status,n(s))}catch{return t("edit",s.status)}}async function f(e,a){let{middleware:o,captured:i}=r();try{let{data:r,error:i,response:s}=await e.DELETE("/comments/{comment_id}",{params:{path:{comment_id:a}},middleware:[o]});if(!i&&r?.success)return{ok:!0};return t("delete",s.status,n(i))}catch{return t("delete",i.status)}}async function h(e,a,{category:o,category_detail:i}={}){let{middleware:s,captured:l}=r();try{let{data:r,error:l,response:u}=await e.POST("/comments/{comment_id}/flag",{params:{path:{comment_id:a}},body:{category:o,category_detail:i},middleware:[s]});if(!l&&r?.flag)return{ok:!0};return t("report",u.status,n(l))}catch{return t("report",l.status)}}e.s(["createComment",0,c,"createRerankComment",0,d,"deleteComment",0,f,"fetchCommentCount",0,s,"fetchComments",0,i,"flagComment",0,h,"getLikeCount",0,function(e){return e.reaction_counts?.find(e=>"like"===e.reaction_type)?.count??0},"getMyLikeReaction",0,function(e){return e.viewer_reactions?.find(e=>"like"===e.reaction_type)},"likeComment",0,l,"replaceCommentInResult",0,function(e,t,n){return{...e,comments:e.comments.map(e=>e.id===t?{...e,...n}:e.top_replies?.some(e=>
1e.id===t)?{...e,top_replies:e.top_replies.map(e=>e.id===t?{...e,...n}:e)}:e)}},"unlikeComment",0,u,"updateComment",0,m],595888)},138921,e=>{"use strict";let t=(e,t)=>t?["commentReplies",e,t]:["commentReplies",e];e.s(["invalidateCommentThread",0,function(e,n,{parentId:r,includeReplies:a}={}){(e.invalidateQueries({queryKey:["comments",n]}),r)?e.invalidateQueries({queryKey:t(n,r)}):a&&e.invalidateQueries({queryKey:t(n)})}])},51099,e=>{"use strict";let t=(0,e.i(744183).createQuerySerializer)();e.s(["serializeFeedGetQuery",0,function(e){if(!e||"object"!=typeof e)return t(e);let{groq_fragments:n,gql_fragments:r,...a}=e,o=[],i=t(a);return i&&o.push(i),n&&"object"==typeof n&&(null!=n.story&&o.push(`groq_fragments.story=${encodeURIComponent(n.story)}`),null!=n.article&&o.push(`groq_fragments.article=${encodeURIComponent(n.article)}`)),r&&"object"==typeof r&&null!=r.product&&o.push(`gql_fragments.product=${encodeURIComponent(r.product)}`),o.join("&")}])},593054,e=>{"use strict";e.i(408712),Object.freeze({width:1200,height:630}),Object.freeze({width:2048,height:1440});Object.freeze({width:1200,height:1200});let t=e=>(e??[]).map(e=>e.trim()).filter(e=>e.length>0);e.s(["buildLatestFeedGroqFragment",0,(e={})=>{let n=t(e.channelIds),r=t(e.editionIds),a=t(e.excludeTagIds),o=t(e.excludeContentCategories),i=[];if(n.length>0&&i.push(`references(${JSON.stringify(n)})`),r.length>0&&i.push(`references(${JSON.stringify(r)})`),a.length>0&&i.push(`count((tags[]._ref)[@ in ${JSON.stringify(a)}]) == 0`),o.length>0&&i.push(`count((contentCategory)[@ in ${JSON.stringify(o)}]) == 0`),0!==i.length)return i.join(" && ")},"parseFeedItemToStoryPreview",0,(e,t)=>{let n;try{n=JSON.parse(e)}catch(e){return console.warn("[forYouFeed] Failed to parse FeedItem.item JSON",{error:e}),null}if(!n||"object"!=typeof n)return null;let r=n,a=r.id??r._id??t;if(!a||!r.name||!r.alias||!Array.isArray(r.authors)||0===r.authors.length)return null;try{var o;let e,t,n;return o={...r,id:a},e=o?.authors?.map(e=>({id:e.id,alias:e.alias,name:e.name,url:`/author/${e.alias}`,type:e.type,image:e.image||"",sponsored_type:o.sponsored_type})),t=o?.tags?.map(e=>e.name),n=o?.tags?.filter(e=>"branded"===e.type).map(e=>e.name),{id:o.id,name:o.name,alias:o.alias,authors:e,path:`/${o.channel?.alias}/a/${o.authors?.[0]?.alias}/${o.alias}`,url:`/${o.channel?.alias}/a/${o.authors?.[0]?.alias}/${o.alias}`,description:o.description,category:o.channel?.name,thumbnail:{"16x9":{image:o.thumbnail?.image??"https://images.complex.com/complex/image/upload/v1723773978/sanity/complex-image-not-available.jpg",altText:o.thumbnail?.altText??""},"4x5":o.thumbnail_4x5?{image:o.thumbnail_4x5?.image,altText:o.thumbnail_4x5?.altText}:void 0,"3x2":o.thumbnail_3x2?{image:o.thumbnail_3x2?.image,altText:o.thumbnail_3x2?.altText}:void 0},tags:t,brandedTags:n,createdAt:o.createdAt,isVideo:!1,isSoleCollector:!1,metadata_variations:{},publishedAt:o.publishedAt,body:[],complexos_generated:o.complexos_generated??!1,complexos_style:o.complexosMetadata?.style??null,type:o.type??"post",contentCategory:o.contentCategory??[],contentSubCategory:o.contentSubCategory}}catch(e){return console.warn("[forYouFeed] Failed to map FeedItem to StoryPreview",{error:e}),null}}],593054)},540095,e=>{"use strict";var t=e.i(271645),n=e.i(621482),r=e.i(865653),a=e.i(593054),o=e.i(51099);async function i(e,t,n){let r=await fetch("/api/story-cards",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({ids:e,tags:t}),signal:n});if(!r.ok)throw Error("Failed to fetch story cards");return r.json()}e.s(["useForYouFeed",0,({filter:e,pageSize:s,enabled:l,tags:u=[],contextExternalId:c})=>{let d=(0,r.useApiGatewayClient)(),m=(0,t.useMemo)(()=>(0,a.buildLatestFeedGroqFragment)(e),[e]),f=async({pageParam:e,signal:t})=>{let n=m?{story:m,article:m}:void 0,{data:r,error:l}=await d.GET("/feed",{params:{query:{types:["story","article"],limit:s,...e?{after:e}:{},...n?{groq_fragments:n}:{},...c?{context_external_id:c}:{}}},querySerializer:o.serializeFeedGetQuery,signal:t});if(l||!r)throw console.warn("[forYouFeed] /feed request failed",{error:l}),Error(`Failed to fetch /feed: ${l?JSON.stringify(l):"no data"}`);let f=r.items.length,h=r.items.map(e=>{let t,n=(0,a.parseFeedItemToStoryPreview)(e.item,e.id);try{let n=JSON.parse(e.item);n&&"object"==typeof n&&"string"==typeof n._id&&(t=n._id)}catch{}return{mapped:n,sourceId:t??e.id}}),p=new Map,g=Array.from(new Set(h.filter(e=>(null===e.mapped||!e.mapped.thumbnail["3x2"])&&!!e.sourceId).map(e=>
1e.sourceId)));g.length>0&&(p=new Map((await i(g,u,t)).map(e=>[e.id,e])));let y=h.map(e=>p.get(e.sourceId)??e.mapped).filter(e=>null!=e);return f>0&&0===y.length&&console.warn(`[forYouFeed] /feed returned ${f} row(s) but none mapped to StoryPreview (directly or via id hydration). Falling back may trigger.`),{items:y,next:r.next_cursor?{id:r.next_cursor,publishedAt:""}:null,rawItemCount:f}},h=(0,n.useInfiniteQuery)({queryKey:["forYouFeed",e,s,u,c],enabled:l,initialPageParam:void 0,getNextPageParam:e=>e.next?.id??void 0,queryFn:f}),p=h.data?.pages[0],g=h.isSuccess&&!!p&&0===p.items.length,y=h.isSuccess&&!!p&&0===p.rawItemCount,b=h.isError;return{...h,isFirstPageEmpty:g,isFirstPageApiEmpty:y,hasErrored:b}}])},107545,e=>{"use strict";let t="comment",n="commentsOpen",r="post_rerank",a="post_rerank_text";e.s(["COMMENT_PARAM",0,t,"appendCommentDeepLinkParam",0,function(e,r){e.searchParams.delete(t),e.searchParams.delete(n),r?e.searchParams.set(t,r):e.searchParams.set(n,"1")},"appendPostRerankParams",0,function(e,t,n){e.searchParams.set(r,t),e.searchParams.set(a,n)},"cleanCommentDeepLinkFromUrl",0,function(){let e=new URL(window.location.href),r=e.searchParams;if(r.has(t)||r.has(n)){r.delete(t),r.delete(n);let a=r.toString()?`${e.pathname}?${r.toString()}${e.hash}`:`${e.pathname}${e.hash}`;window.history.replaceState({},"",a)}},"cleanPostRerankFromUrl",0,function(){let e=new URL(window.location.href),t=e.searchParams;if(t.has(r)||t.has(a)){t.delete(r),t.delete(a);let n=t.toString()?`${e.pathname}?${t.toString()}${e.hash}`:`${e.pathname}${e.hash}`;window.history.replaceState({},"",n)}},"getCommentDeepLinkId",0,function(){return new URLSearchParams(window.location.search).get(t)||null},"getPostRerankIntent",0,function(){let e=new URLSearchParams(window.location.search),t=e.get(r);return t?{submissionId:t,caption:e.get(a)??""}:null},"getShouldOpenCommentsPanel",0,function(){return"1"===new URLSearchParams(window.location.search).get(n)}])},820162,e=>{"use strict";let t=new Set(["socialEmbed","twitterEmbed","youtubeEmbed","instagramEmbed","tikTokEmbed","facebookEmbed","
1spotifyEmbed","soundcloudEmbed","vimeoEmbed","customEmbed","jwVideo"]);e.s(["isEmbedLeadMedia",0,e=>!!e&&t.has(e._type)])},310206,e=>{"use strict";var t=e.i(271645);let n=0,r=null,a=0,o=null,i=null,s=e=>{if("u">typeof document){if(0===n){let t=e?.preferredStrategy??(()=>{if("u"<typeof navigator)return"overflow";let e=navigator.userAgent||"";return/iPhone|iPad|iPod/.test(e)||e.includes("Mac")&&"number"==typeof navigator.maxTouchPoints&&navigator.maxTouchPoints>1?"ios":"overflow"})();r=t,a=window.scrollY,"ios"===t?(o={position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,right:document.body.style.right,overflow:document.body.style.overflow},document.body.style.position="fixed",document.body.style.top=`-${a}px`,document.body.style.left="0",document.body.style.right="0",document.body.style.overflow="hidden"):(i=document.documentElement.style.overflow,document.documentElement.style.overflow="hidden")}n++}},l=()=>{"u"<typeof document||0===n||--n>0||("ios"===r&&o?(document.body.style.position=o.position,document.body.style.top=o.top,document.body.style.left=o.left,document.body.style.right=o.right,document.body.style.overflow=o.overflow,o=null,window.scrollTo(0,a)):"overflow"===r&&(document.documentElement.style.overflow=i??"",i=null,window.scrollY!==a&&window.scrollTo(0,a)),r=null)};e.s(["acquireScrollLock",0,s,"default",0,e=>{(0,t.useEffect)(()=>{if(e)return s(),()=>{l()}},[e])},"releaseScrollLock",0,l])},148449,e=>{"use strict";var t=e.i(408712);let n=/^[A-Za-z0-9_-]{11}$/,r=e=>"youtu.be"===e||"youtube.com"===e||e.endsWith(".youtube.com"),a=e=>{let t=null;return(t="youtu.be"===e.hostname?e.pathname.slice(1).split("/")[0]??null:e.pathname.startsWith("/embed/")?e.pathname.split("/embed/")[1]?.split("/")[0]??null:e.pathname.startsWith("/live/")?e.pathname.split("/live/")[1]?.split("/")[0]??null:e.pathname.startsWith("/shorts/")?e.pathname.split("/shorts/")[1]?.split("/")[0]??null:e.searchParams.get("v"))&&n.test(t)?t:null};e.s(["getCloudinaryVideoThumbnailUrl",0,function(e){if(!e)return null;let n=(0,t.parseCloudinaryUrl)(e);return n&&"video"===n.type?(0,t.buildCloudinaryUrl)({...n,transformations:n.transformations?`${n.transformations},so_auto`:"so_auto",format:"jpg"}):null},"getVideoEmbedUrl",0,function(e){if(!e)return null;try{let t=new URL(e);if(r(t.hostname)){let e=a(t);if(!e)return null;return`https://www.youtube.com/embed/${e}?autoplay=1&mute=1&playsinline=1`}if("vimeo.com"===t.hostname||t.hostname.endsWith(".vimeo.com")){let e=null;if("player.vimeo.com"===t.hostname)e=t.pathname.split("/video/")[1]?.split("/")[0]??null;else{let n=t.pathname.split("/").filter(Boolean);e=n[n.length-1]??null}if(!e)return null;return`https://player.vimeo.com/video/${e}?autoplay=1&muted=1&playsinline=1`}return null}catch{return null}},"getYouTubeThumbnailUrl",0,function(e){let t=function(e){if(!e)return null;try{let t=new URL(e);if(!r(t.hostname))return null;return a(t)}catch{return null}}(e);return t?`https://img.youtube.com/vi/${t}/hqdefault.jpg`:null}])}]);
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.