try{let e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]=`5b0ec57d-704a-4b9c-badb-0862a0333efe`,e._sentryDebugIdIdentifier=`sentry-dbid-5b0ec57d-704a-4b9c-badb-0862a0333efe`)}catch{}import{$m as e,Ag as t,Hm as n,_r as r,ng as i,op as a}from"./entry.client-mpghtlrl.js";import{t as o}from"./HorizontalSocialItem-locb7qz2.js";import{t as s}from"./HorizontalSocialItemLoading-lf95egyh.js";import{t as c}from"./ContainerVirtualGrid-gc40b5uu.js";import{t as l}from"./guideRouterEnvironmentHooks-h2xlfina.js";import{t as u}from"./GuidePageLayout-eh7novzv.js";import{n as d,t as f}from"./useFormatAmountOfTime-b07yvc3l.js";import{t as p}from"./GuideIllustration-pex5y7xc.js";import{t as m}from"./GuideL2Header-a2pogkf0.js";var h=t(),g=i(),_=r(e=>{let t=(0,h.c)(6),{xuid:n,onPress:r,timestampMs:i,referenceTime:a}=e,s=f(i,a,!0),c;t[0]===s?c=t[1]:(c=s?(0,g.jsx)(`div`,{className:`text-item-visible-container-default-content-primary-rest type-body`,children:s}):null,t[0]=s,t[1]=c);let l;return t[2]!==n||t[3]!==r||t[4]!==c?(l=(0,g.jsx)(o,{xuid:n,onPress:r,version:`regular`,background:`invisible`,extraContent:c}),t[2]=n,t[3]=r,t[4]=c,t[5]=l):l=t[5],l},({xuid:e,...t})=>{let n=l();return{onPress:()=>{n({to:a.dialog.guide.people.profileCard.fullPath,params:{xuid:e}})},xuid:e,...t}}),v=t=>{let r=(0,h.c)(41),{users:i,isError:a,isPending:o,userType:s}=t,{t:l}=e(`GuidePeopleTab`),{locSomethingWentWrong:f,locGenericErrorSubheading:v}=n(),b=_.useComponent(),x;r[0]!==i||r[1]!==s?(x=()=>{if(!(!i||i.length===0))return s===`recentFollowers`?i[0].followedByDateInMs:i[0].friendedDateInMs},r[0]=i,r[1]=s,r[2]=x):x=r[2];let S=x,C;r[3]===S?C=r[4]:(C=S(),r[3]=S,r[4]=C);let w=d(`auto`,C),T;r[5]!==s||r[6]!==l?(T=s===`recentFollowers`?l(`Recent followers`,{shortKey:`recent_followers`}):l(`Recent friends`,{shortKey:`recent_friends`}),r[5]=s,r[6]=l,r[7]=T):T=r[7];let E=T;if(i){let e=`guide-${s}`,t;r[8]===E?t=r[9]:(t=(0,g.jsx)(m,{title:E}),r[8]=E,r[9]=t);let n;r[10]!==b||r[11]!==s||r[12]!==w?(n=e=>(0,g.jsx)(b,{xuid:e.xuid,timestampMs:s===`recentFollowers`?e.followedByDateInMs:e.friendedDateInMs,referenceTime:w?.referenceTime},e.xuid),r[10]=b,r[11]=s,r[12]=w,r[13]=n):n=r[13];let a;r[14]!==i||r[15]!==n?(a=(0,g.jsx)(c,{items:i,renderItem:n,columns:1,overscan:10,gapSize:`var(--V225)`}),r[14]=i,r[15]=n,r[16]=a):a=r[16];let o;return r[17]!==e||r[18]!==t||r[19]!==a?(o=(0,g.jsx)(u,{id:e,header:t,children:a}),r[17]=e,r[18]=t,r[19]=a,r[20]=o):o=r[20],o}else if(a||!o){let e=`guide-${s}`,t;r[21]===E?t=r[22]:(t=(0,g.jsx)(m,{title:E}),r[21]=E,r[22]=t);let n;r[23]===f?n=r[24]:(n=f(),r[23]=f,r[24]=n);let i;r[25]===v?i=r[26]:(i=v(),r[25]=v,r[26]=i);let a;r[27]!==n||r[28]!==i?(a=(0,g.jsx)(p,{title:n,subtitle:i,illustrationType:`error`}),r[27]=n,r[28]=i,r[29]=a):a=r[29];let o;return r[30]!==e||r[31]!==t||r[32]!==a?(o=(0,g.jsx)(u,{id:e,header:t,children:a}),r[30]=e,r[31]=t,r[32]=a,r[33]=o):o=r[33],o}else{let e=`guide-${s}`,t;r[34]===E?t=r[35]:(t=(0,g.jsx)(m,{title:E}),r[34]=E,r[35]=t);let n;r[36]===Symbol.for(`react.memo_cache_sentinel`)?(n=(0,g.jsx)(`div`,{className:`flex max-h-full flex-col gap-layout-vertical-group-of-items-tight overflow-y-hidden`,children:Array.from({length:15},y)}),r[36]=n):n=r[36];let i;return r[37]!==e||r[38]!==t||r[39]!==n?(i=(0,g.jsx)(u,{id:e,header:t,children:n}),r[37]=e,r[38]=t,r[39]=n,r[40]=i):i=r[40],i}};function y(e,t){return(0,g.jsx)(s,{includeContainer:!0},t)}export{v as t};