1import{j as e,r as j,I as Q,Y as z,L as Y,a as H}from"./playbook-DzR_ry6Q.js";import{S as K}from"./StickyNavigationTabs-eR1oi6sY.js";import{u as J}from"./useURLParams-CIlhPcPz.js";import{A as X,a as Z,P as x,b as ee,C as ie,c as te,S as re,d as se,e as oe,f as ae,g as ne,h as le,i as de,R as ce,j as me,k as p,l as pe,m as he,n as ue,o as fe,T as Pe,p as b,q as ge,r as U,s as Ae,t as Te,u as xe}from"./AthleteProfileVideoDisplay--cAvSL2V.js";import{b as Ce,c as Ie,d as Ee,e as je,f as k,g as Le,h as Oe,l as Ne,A as Se,i as be,j as _e,k as ke,m as De,n as ve,o as ye,p as Ue,q as Re,r as Ve,s as we,t as He,u as Me,v as Fe,w as Be,x as Ge}from"./analytics-CONfvw2h.js";import{u as N,P as qe}from"./ProfileAnalyticsContext--HGMmZwa.js";import{m as $e}from"./makeAthleteProfileShareService-CM6LZqWK.js";import{g as We,W as Qe,h as ze,E as Ye,H as R}from"./AppUpdateMonitor-Bn2pSfA6.js";import{a as Ke,u as Je}from"./useLogAthleteProfileVideoPlay-D8z6qdsw.js";import{u as Xe}from"./useMutation-BauU2Qu1.js";import{F as Ze,u as ei}from"./FlagContentModal-Cg5nm96f.js";import{u as D}from"./urlBuilder-BROSAaNt.js";import{k as M,v as ii,l as ti,C as _}from"./app-public-BF3VXhlA.js";import{S as ri}from"./SignUpFormModal-a6hLgiN9.js";import{S as si}from"./SocialProfileIconRow-DZSvQNR8.js";import{e as O,p as C,t as oi,S as T,u as ai,v as ni,H as li,w as di,j as V,L as ci}from"./TimelineItem-CKqixz7z.js";import{c as L}from"./crossAppUrlBuilder-BhofUUh6.js";import{C as mi}from"./CoachDetails-C4dSxrHd.js";import{u as F}from"./useQuery-yAE_5L0B.js";import{u as B}from"./urlBuilder-BDOOCRBm.js";import{u as pi,T as hi,a as ui,M as fi}from"./useAthleteTimelineRenderer-DJNtXuJc.js";import{m as Pi}from"./FlagContentModalDisplay-CriCdfhJ.js";import{u as gi,a as Ai}from"./profileApi-KfeEm1VR.js";import{g as Ti,a as xi}from"./VideoProgress-Bs8Ayx9o.js";import{V as Ci}from"./videoAnalytics-Duw4vVvW.js";import{V as Ii}from"./VideoPlayer-DpggQEUQ.js";import{s as Ei}from"./queryUtils-BMPR3ius.js";import"./VerifiedMinor-BNpBUCD7.js";import"./PrivateVideo-CSMhzaq9.js";import"./EyeOffIcon-D8Dhacr1.js";import"./ContextMenu-B3iwZvcl.js";import"./DropdownMenu-ExsHO29w.js";import"./EyeIcon-CaM30W6f.js";import"./MapPinIcon-DCZntUQN.js";import"./clipboard-BEioycmS.js";import"./formatter-C_B5LTc2.js";import"./enumHelper-D5e-p8Kk.js";import"./positionDisciplineSport-BPeg1wk4.js";import"./SkeletonHeadshot-ackY3W7e.js";import"./natsAnalyticsUtils-B3DIQD8S.js";import"./masquerading-CBSqNbPk.js";import"./ReadMoreText-D9kzG7fI.js";import"./ShareControl-DZTPT6ds.js";import"./CopyLink-BZb7ciry.js";import"./Responsive-BFVHKv7y.js";import"./useAnalytics-S-JP8F9Q.js";import"./googleAnalytics-ube9QF46.js";import"./TwitterMajor-Df5iUS11.js";import"./LinkIcon-D4XTdOhE.js";import"./AthleteHeadshot-CCVkz9AN.js";import"./imageSrcManager-B_vswghy.js";import"./TeamLogo-BcNhaL61.js";import"./PrimeBadgeIcon-o8Ye35qf.js";import"./athleticAssociationUtils-8LDySNgt.js";import"./dataTypes-DjeN0w5k.js";import"./ScrollButtons-Br8g_bDI.js";import"./dateUtils-DoT-fxLW.js";import"./AltLinkMajor-GCiG8Mje.js";import"./VideoMajor-BzGbQGeJ.js";import"./apiUtils-BWI8TrrO.js";import"./stringUtils-FyBfVTU1.js";import"./_arrayPush-B15kSNDA.js";import"./AthleteDetailsDisplay-BnOeGV7q.js";import"./ForwardDesktopMinorBold-u6DPqbgo.js";import"./TeamDetailsDisplay-BmuD31IK.js";import"./use_UNSTABLE_horizontalScrollTracking-fivdJVrO.js";import"./VideoDuration-B2_SdC2P.js";import"./videoDisplayUtils-DhnN6B-W.js";import"./utils-C3Uzq3hM.js";import"./profilePrivacyPreferencesApi-CeokeonZ.js";import"./LinkedinMajor-jXmX5JLG.js";import"./SignUpFormModalDisplay-ClzvZnlP.js";import"./PreventOrphanText-Bcm1LySc.js";import"./Separator-BrtRP9EU.js";import"./useValidatedForm-Des8iXVn.js";import"./YouTubeMajor-cFvjqMTi.js";import"./UserHeadshot-DH2I1AAY.js";import"./makeCrossAppUrlBuilder-D4l0bYsQ.js";import"./CoachDetailsDisplay-BlGZOWRh.js";import"./urlBuilder-D-ptMKPk.js";import"./useBaseQuery-CV-kdyom.js";import"./CommitmentMajor-CU7Bjhw0.js";import"./IDIcon-DNe6IUl_.js";import"./PortalAnnouncementMajor-C91DKIci.js";import"./api-BMqwOw8W.js";import"./UnconfiguredVideoPlayer-BBSsN5DU.js";import"./PlayIconDesign-D66IgAmN.js";import"./videoApi-DXv6Nxk9.js";const ji=({options:i}={})=>Xe(t=>Ke({profileId:t.profileId,sportEnum:t.sportEnum}),i),Li="General",Oi=i=>({Twitter:i?.TwitterHandle||"",Instagram:i?.InstagramHandle||"",TikTok:i?.TikTokHandle||"",Facebook:i?.FacebookHandle||"",YouTube:i?.YouTubeHandle||""}),Ni=i=>i?.Items?.find(t=>t.QuestionType===Li)?.AnswerText||"",Si=({about:i,details:t})=>{const s=N(),o=Ni(i),r=Oi(t),c=Object.values(r).some(d=>!!d);return!!!o&&!c?!1:e.jsx(X,{bioText:o,canEdit:!1,socialsRendering:c?e.jsx(si,{socials:r,onLinkClick:d=>Ce({...s,platform:d})}):null})},bi=({athlete:i,details:t,privacyConfig:s})=>t?.HasAnyAcademics?O({mapper:C,data:s,isAuthenticated:!1}).getConfig(oi).contents===T?e.jsx(Z,{gpa:i?.Gpa,weightedGpa:i?.WeightedGpa,sat:t?.Sat,act:t?.Act,plannedCollegeMajor:t?.PlannedCollegeMajor,ncaaId:t?.NcaaId,naiaId:t?.NaiaId}):e.jsx(x,{title:"Academics",children:e.jsx("div",{className:"bg-background-highlight-muted p-4 lg:p-6 rounded",children:e.jsx("p",{className:"text-muted",children:"Available to verified recruiting coaches."})})}):null,_i=({details:i,privacyConfig:t})=>i?.HasEquipmentPreferences?O({mapper:C,data:t,isAuthenticated:!1}).getConfig(ai).contents===T?e.jsx(ee,{equipmentPreferences:i?.EquipmentPreferences}):e.jsx(x,{title:"Equipment",children:e.jsx("div",{className:"bg-background-highlight-muted p-4 lg:p-6 rounded",children:e.jsx("p",{className:"text-muted",children:"Available to FieldLevel members."})})}):null,ki=({details:i,profileDetailUrl:t})=>i?.HasFamilyMembers?e.jsx(x,{title:"Family",children:e.jsx("div",{className:"bg-background-highlight-muted p-4 lg:p-6 rounded",children:e.jsx("p",{className:"text-muted",children:"Available to verified recruiting coaches."})})}):null,Di=({athlete:i,details:t,privacyConfig:s,profileDetailUrl:o})=>{const[r,c]=j.useState(!1),d=O({mapper:C,data:s,isAuthenticated:!1}).getConfig(ni),u=L.publicSignUpPage({searchParams:{returnUrl:o}}).wiredLinkProps;return e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex items-center text-[#0369a1] cursor-pointer",onClick:()=>c(!0),children:[e.jsx("span",{className:"mr-1",children:e.jsx(Q,{source:z,color:"current"})}),"Contact info"]}),e.jsx(ie,{open:r,onDismiss:()=>c(!1),configContact:d,athlete:i,details:t,canViewContactInfo:!1,hiddenStatusActionRendering:e.jsx(Y,{unstyled:!0,...u,children:e.jsx(H,{children:"Join now"})})})]})},vi=({athlete:i,shareService:t,profileDetailUrl:s})=>{if(We().IsAuthenticated)return e.jsx(te,{athlete:i,shareService:t});const r=L.publicSignUpPage({searchParams:{returnUrl:s}}).wiredLinkProps;return e.jsxs(e.Fragment,{children:[e.jsx(Qe,{...r,children:e.jsx(H,{variant:"primary",children:"View full profile"})}),e.jsx(re,{shareService:t,heading:`Share ${i.FirstName}'s Profile`})]})},yi=({athlete:i,viewerContext:t,details:s,privacyConfig:o,shareService:r,profileDetailUrl:c,sportEnum:n,commitment:d})=>
1{const h=O({mapper:C,data:o,isAuthenticated:!1}).getConfig(li),f=M(),P=!!d?.CommittedToTeam&&d.CommitmentLevelEnum?.Value!=="Uncommitted",l=P?f.commitmentsDetail({pathParams:{username:i.Username,sport:n,id:d.AthleteCommitmentHistoryId}}).wiredLinkProps:null;return e.jsx(se,{athlete:i,viewerContext:t,showGpa:h.gpa===T,showHeightWeight:h.heightWeight===T,showHeadshot:h.headshot===T,showHometown:h.hometown===T,contactInfo:e.jsx(Di,{athlete:i,details:s,privacyConfig:o,profileDetailUrl:c}),actions:e.jsx(ae,{children:e.jsx(vi,{athlete:i,shareService:r,profileDetailUrl:c})}),commitmentCard:P&&e.jsx(oe,{commitment:d,commitmentStoryLinkProps:l})})},Ui=({details:i,privacyConfig:t})=>i?.HasHobbiesAndInterests?O({mapper:C,data:t,isAuthenticated:!1}).getConfig(di).contents===T?e.jsx(ne,{hobbiesAndInterests:i?.HobbiesAndInterests}):e.jsx(x,{title:"Hobbies & interests",children:e.jsx("div",{className:"bg-background-highlight-muted p-4 lg:p-6 rounded",children:e.jsx("p",{className:"text-muted",children:"Available to FieldLevel members."})})}):null,Ri=({metricsData:i})=>e.jsx(le,{metricsData:i,canEdit:!1}),Vi=({certifications:i,sportEnum:t})=>e.jsx(de,{ctaRendering:null,certifications:i,renderCertification:({certification:s})=>e.jsx(ce,{certification:s,sportEnum:t,contents:ci,discussAthlete:V,updateEvaluation:V,coachDetailsRendering:e.jsx(mi,{coach:s.CertifiedBy,options:{mode:"Short"}})})}),wi=({details:i})=>e.jsx(me,{achievements:i?.HonorsAndAchievements}),Hi=({details:i})=>i?.HasSchedule?e.jsx(x,{title:"Schedule",children:e.jsx("div",{className:"bg-background-highlight-muted p-4 lg:p-6 rounded",children:e.jsx("p",{className:"text-muted",children:"Available to FieldLevel members."})})}):null,Mi=({profileId:i,sportEnum:t})=>ze.get(`/api/similarathletes/getall/${i}`,{sport:t}),Fi=({profileId:i,sportEnum:t}={})=>["ProfileV2_fetchSimilarAthletes",{profileId:`${i}`,sportEnum:`${t}`}],Bi=({params:{profileId:i,sportEnum:t},options:s}={})=>F(Fi({profileId:i,sportEnum:t}),()=>Mi({profileId:i,sportEnum:t}),s),Gi=({profileId:i,sportEnum:t,buildProfileLinkProps:s})=>{const o=N(),r=ii(),{data:c,isInitialLoading:n}=Bi({params:{profileId:i,sportEnum:t},options:{enabled:!!i,useErrorBoundary:!0}}),d=r.athleteSearch({searchParams:{sportEnum:t}}).wiredLinkProps,u={...d,onClick:h=>{Ee({...o,sportEnum:t}),d.onClick?.(h)}};return e.jsx(p,{action:Ie,data:o,children:n?e.jsx(pe,{}):c?.length?e.jsx(he,{athletes:c,buildAthleteLinkProps:h=>s({username:h.Username,sportEnumValue:t}),seeAllLinkProps:u}):null})},qi=({teams:i=[]})=>{const t=B(),s=o=>o.TeamId?t.organizationTeamOverviewPage({pathParams:{shortName:o.ShortName,sportEnum:o.SportEnum.Value.toLowerCase()}}).wiredLinkProps:null;return e.jsx(ue,{teams:i,buildTeamProfileLinkProps:s})},$i=i=>!i||i.length===0?null:i.reduce((t,s)=>s.PostedDateUtc?t?new Date(s.PostedDateUtc)>new Date(t)?s.PostedDateUtc:t:s.PostedDateUtc:t,null),Wi=({timeline:i,athlete:t,viewerContext:s,sportEnum:o,privacyConfig:r})=>{const c=N(),n=D(),d=M(),u=ti(),h=B(),f=t?.Username,{mutate:P}=gi(),[l,a]=j.useState(null),g=r?{mapper:C,data:r,isAuthenticated:!1}:void 0,I=()=>L.publicSignInPage({searchParams:{returnUrl:`${window.location.pathname}${window.location.search}`}}).go(),E=({video:m})=>{const A=n.profileVideosDetail({pathParams:{id:f,sportEnum:o,videoId:m.VideoId}}).wiredLinkProps;return e.jsx(Pe,{video:m,videoDetailsLinkProps:A})},G=f?L.publicSignUpPage({searchParams:{returnUrl:n.profileDetail({pathParams:{id:f,sportEnum:o}}).href}}).wiredLinkProps:void 0,q=m=>e.jsx(ui,{item:m,viewerContext:s,onReportVideo:A=>a(A.Video)}),$=({video:m})=>{if(!t)return null;const A=Pi({athleteDisplayName:t.DisplayName,sportEnum:o,videoDetailsPath:n.profileVideosDetail({pathParams:{id:f,sportEnum:o,videoId:m.VideoId}}).href});return e.jsx(hi,{heading:`Share ${t.FirstName}'s Video`,shareService:A})},{renderItem:W}=pi({athlete:t,sportEnum:o,profileUrlBuilder:n,commitmentsUrlBuilder:d,organizationUrlBuilder:h,transferPortalUrlBuilder:u,renderVideoPlayer:E,renderVideoShareButton:$,renderItemMenu:q,onLinkClick:m=>P({profileId:t.ProfileId,sportEnum:o,linkGuid:m.Link.Guid}),configContext:g,videoSignUpLinkProps:G}),S=(i?.Results||[]).map(m=>({id:m.TimelineItemId,rendering:W(m)})).filter(m=>!!m.rendering);if(S.length===0)return null;const v=n.profileTimeline({pathParams:{id:f,sportEnum:o}}).wiredLinkProps,y=m=>({...v,onClick:A=>{je({...c,linkType:m}),v.onClick?.(A)}});return e.jsxs(e.Fragment,{children:[e.jsx(fe,{items:S,totalCount:i?.TotalResultCount??S.length,lastUpdatedDateUtc:$i(i?.Results),timelinePageLinkProps:y(k.header),seeAllLinkProps:y(k.seeAll)}),l&&e.jsx(Ze,{isOpen:!0,onDismiss:()=>a(null),onSignIn:I})]})},Qi=({details:i}
1)=>i?.HasTranscripts?e.jsx(x,{title:"Academic transcripts",children:e.jsx("div",{className:"bg-background-highlight-muted p-4 lg:p-6 rounded",children:e.jsx("p",{className:"text-muted",children:"Available to verified recruiting coaches."})})}):null,zi=({athlete:i,sportEnum:t,videos:s=[],privacyConfig:o})=>{const r=N(),c=D(),{mutate:n}=Je();if(s.length===0)return e.jsx(b,{videos:s,emptyStateRendering:e.jsx(x,{title:"Videos",children:e.jsx(ge,{title:"No videos yet",description:"Videos will appear here once they are added."})})});if(!o.HighlightVideo){const l=c.profileDetail({pathParams:{id:i.Username,sportEnum:t}}).href,a=L.publicSignUpPage({searchParams:{returnUrl:l}}).wiredLinkProps;return e.jsx(b,{videos:s,isMasked:!0,videosListLinkProps:a,buildVideoDetailsLinkProps:()=>a,renderInlineVideoPlayer:()=>e.jsx(fi,{signUpLinkProps:a})})}const d=c.profileVideosList({pathParams:{id:i.Username,sportEnum:t}}).wiredLinkProps,u={...d,onClick:l=>{Oe({...r,linkType:k.header}),d.onClick?.(l)}},h=l=>{const a=c.profileVideosDetail({pathParams:{id:i.Username,sportEnum:t,videoId:l.VideoId}}).wiredLinkProps;return{...a,onClick:g=>{Le({...r,videoId:l.VideoId}),a.onClick?.(g)}}},f=l=>n({profileId:l.ProfileId,sportEnum:t,videoGuid:l.Guid}),P=(l,{onInit:a,onEnd:g,autoplay:I=!1}={})=>{const E=Ti({url:l.ThumbnailUrl})?xi({src:l.ThumbnailUrl,ext:"webp",muxParams:{width:800}}):l.ThumbnailUrl;return e.jsx(Ii,{video:l,showTitle:!1,showFilmType:!l.IsPinned,interactionContext:Ci.AthleteProfile,autoplay:I,posterURL:E,optimizedThumbnailProps:{variant:"variant1"},onInit:a,onEnd:g,onInitialPlay:f})};return e.jsx(b,{videos:s,videosListLinkProps:u,buildVideoDetailsLinkProps:h,renderInlineVideoPlayer:P})},Yi=({username:i,sport:t}={})=>["Profile_fetchProfileV2",Ei({params:{username:i,sport:t}})],Ki=({params:{username:i,sport:t},options:s}={})=>F(Yi({username:i,sport:t}),()=>Ai({username:i,sport:t}),s),w="public-profile-v2",kr=()=>{const{path:{id:i,sportEnum:t}}=J(),s=D(),o=s.profileDetail({pathParams:{id:i,sportEnum:t}}).href,{data:r,isLoading:c}=Ki({params:{username:i,sport:t},options:{useErrorBoundary:!0}}),{data:n,isLoading:d}=ei({params:{athleteProfileId:r?.Athlete?.ProfileId},options:{enabled:!!r?.Athlete?.ProfileId,useErrorBoundary:!0}}),[u]=j.useState(()=>Ye()),{mutate:h}=ji(),f=j.useRef(!1);if(j.useEffect(()=>{r?.Athlete&&!f.current&&(h({sportEnum:t,profileId:r.Athlete.ProfileId}),Ne({pageViewId:u,page:Se.profile,profileId:r.Athlete.ProfileId,isAnonymous:!0,isRecruiter:!1,isMobile:!!R(),isIndividualSport:!!r.Details?.IsIndividualSport,emptyComponents:be(r),profileVersion:"v2"}),f.current=!0)},[r]),c||d||!r?.Athlete||!n)return e.jsx(_,{children:e.jsx(U,{})});if(!n.ProfileVisibility)return e.jsx(_,{children:e.jsxs("div",{className:"relative",children:[e.jsx(ri,{isOpen:!0,heading:`Sign Up to View ${r.Athlete.DisplayName}'s Profile`,returnUrl:o,elem:w}),e.jsx("div",{id:w,children:e.jsx(U,{})})]})});const P=$e({athleteDisplayName:r.Athlete.DisplayName,sportEnum:t,profileDetailPath:o,viewerContext:null}),l=({username:I,sportEnumValue:E})=>s.profileDetail({pathParams:{id:I,sportEnum:E}}).wiredLinkProps,a=()=>({pageViewId:u}),g=Ae({profileData:r,hasVideo:!0,hasTimeline:(r.Timeline?.Results?.length??0)>0,hasAcademics:!!r.Details?.HasAnyAcademics});return e.jsx(qe,{value:{pageViewId:u},children:e.jsxs(_,{children:[g.length>0&&e.jsx(K,{sections:g,headerElementId:"athlete-profile-header",topOffset:R()?56:80}),e.jsx(Te,{leadWithMetrics:!!r.Details?.IsIndividualSport,headerRendering:e.jsx("div",{id:"athlete-profile-header",children:e.jsx(yi,{athlete:r.Athlete,viewerContext:r.ViewerContext,details:r.Details,privacyConfig:n,shareService:P,profileDetailUrl:o,sportEnum:t,commitment:r.Commitment})}),timelineCardRendering:e.jsx(p,{id:"timeline",action:Ge,data:a(),children:e.jsx(Wi,{timeline:r.Timeline,athlete:r.Athlete,viewerContext:r.ViewerContext,sportEnum:t,privacyConfig:n})}),videoCardRendering:e.jsx(p,{id:"video",action:Be,data:a(),children:e.jsx(zi,{athlete:r.Athlete,sportEnum:t,videos:r.Videos,privacyConfig:n})}),aboutCardRendering:e.jsx(p,{id:"bio",action:Fe,data:a(),children:e.jsx(Si,{about:r.About,details:r.Details})}),equipmentCardRendering:e.jsx(p,{id:"equipment",action:Me,data:a(),children:e.jsx(_i,{details:r.Details,privacyConfig:n})}),referencesCardRendering:e.jsx(p,{id:"references",action:He,data:a(),children:e.jsx(Vi,{certifications:r.Certifications||[],sportEnum:t})}),metricsCardRendering:e.jsx(p,{id:"metrics",action:we,data:a(),children:e.jsx(Ri,{metricsData:r.Metrics})}),athleticsCardRendering:e.jsx(p,{id:"athletics",action:Ve,data:a(),children:e.jsx(xe,{athlete:r.Athlete,details:r.Details,viewerContext:r.ViewerContext,sportEnum:t,buildProfileLinkProps:l})}),teamsCardRendering:e.jsx(p,{id:"teams",action:Re,data:a(),children:e.jsx(qi,{teams:r.Details?.Teams??[]})}),hobbiesCardRendering:e.jsx(p,{id:"hobbies",action:Ue,data:a(),children:e.jsx(Ui,{details:r.Details,privacyConfig:n})}),familyCardRendering:e.jsx(p,{id:"family",action:ye,data:a(),children:e.jsx(ki,{details:r.Details,profileDetailUrl:o})}),resultsAchievementsCardRendering:e.jsx(p,{id:"results",action:ve,data:a(),children:e.jsx(wi,{details:r.Details})}),academicsCardRendering:e.jsx(p,{id:"academics",action:De,data:a(),children:e.jsx(bi,{athlete:r.Athlete,details:r.Details,privacyConfig:n})}),transcriptsCardRendering:e.jsx(p,{id:"transcripts",action:ke,data:a(),children:e.jsx(Qi,{details:r.Details})}),scheduleCardRendering:e.jsx(p,{id:"schedule",action:_e,data:a(),children:e.jsx(Hi,{details:r.Details})}),similarAthletesCardRendering:e.jsx(Gi,{profileId:r.Athlete.ProfileId,sportEnum:t,buildProfileLinkProps:l})})]})})};export{kr as default}; 2//# sourceMappingURL=AthleteProfileDetail-O4DGkDXB.js.map
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.