PageSourceSearch

https://handballscore.onrender.com/assets/LinkProfile-CA8I0LzH.js

js handballscore.onrender.com collected 2026-10-03 11:41:32 UTC 10,727 bytes, 1 lines download raw bytes

1import{D as me,c as ie,a as ue,h as xe,u as fe,r as m,o as pe,k as he,j as s,fj as te,B as H,f as $}from"./index-ItQ9IC6Y.js";import{a as ge}from"./index-DMWNPysC.js";import{T as je}from"./Title-ClonZBwO.js";import{C as J,c as X}from"./card-F8Asu6zr.js";import{C as Ne}from"./checkbox-C_Awn3dd.js";import{I as be}from"./input-BdKiMncn.js";import{L as ve}from"./label-HDd5d1dI.js";import{S as ae}from"./skeleton-dOXaKbgi.js";import{s as ye,a as Se}from"./IdentityVerificationService-AV6DgkoG.js";import{c as we,e as ke}from"./imageCompression-B6265JJb.js";import{C as Ce}from"./chevron-right-DwXGwFT5.js";import{S as ne}from"./search-CsiPuTJu.js";import{U as Ee}from"./upload-BW-Lb2H_.js";import"./index-DXh-VhcJ.js";import"./check-CeidorNy.js";import"./index-BUz41SNz.js";const Pe=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],_e=me("arrow-left",Pe),Le=[{value:"player",label:"Jugador",description:"Estoy fichado en un equipo de la asociación"},{value:"coach",label:"Entrenador",description:"Dirijo a un equipo de la asociación"},{value:"referee",label:"Árbitro",description:"Arbitro partidos de la asociación"}],re=["Tipo de perfil","Buscar ficha","Foto del DNI"],qe="Autorizo a que un administrador de mi asociación acceda a esta foto (mi DNI junto a mi cara) con el único f
1in de verificar que soy la persona vinculada a la ficha deportiva seleccionada. La imagen se guarda en un almacenamiento privado, se revisa manualmente y se elimina de forma automática una vez que la solicitud sea aprobada o rechazada. No se comparte con terceros ni se usa para ningún otro fin. De acuerdo con la Ley 25.326 de Protección de Datos Personales, puedo ejercer en cualquier momento mis derechos de acceso, rectificación y supresión sobre este dato.";function Ge(){const e=ie.c(63),n=ue(),o=xe(),{linkedProfiles:l}=fe(),[a,c]=m.useState(1),[d,oe]=m.useState(null),[r,G]=m.useState(null),[_,W]=m.useState(""),[u,Z]=m.useState(null),[C,ee]=m.useState(null),[L,le]=m.useState(!1),i=ge(_,400);let q;e[0]!==l?(q=t=>!l.some(P=>P.entity_type===t.value),e[0]=l,e[1]=q):q=e[1];const se=Le.filter(q);let x,f,p;e[2]!==i||e[3]!==d?(x=["identityVerification","searchProfiles",d,i],f=()=>ye({entityType:d,search:i||void 0,pageSize:10}),p=!!d&&i.trim().length>=2,e[2]=i,e[3]=d,e[4]=x,e[5]=f,e[6]=p):(x=e[4],f=e[5],p=e[6]);let z;e[7]!==x||e[8]!==f||e[9]!==p?(z={queryKey:x,queryFn:f,enabled:p},e[7]=x,e[8]=f,e[9]=p,e[10]=z):z=e[10];const{data:h,isLoading:g}=pe(z);let j;e[11]!==d||e[12]!==u||e[13]!==r?.entity_id?(j=()=>Se(d,r?.entity_id,u),e[11]=d,e[12]=u,e[13]=r?.entity_id,e[14]=j):j=e[14];let N;e[15]!==n||e[16]!==o?(N=()=>{$.success("Tu solicitud está siendo revisada por un administrador"),o.invalidateQueries({queryKey:["identityVerification"]}),n("/my-profile")},e[15]=n,e[16]=o,e[17]=N):N=e[17];let T;e[18]!==j||e[19]!==N?(T={mutationFn:j,onSuccess:N,onError:Te},e[18]=j,e[19]=N,e[20]=T):T=e[20];const E=he(T);let I;e[21]===Symbol.for("react.memo_cache_sentinel")?(I=t=>{oe(t),G(null),W(""),c(2)},e[21]=I):I=e[21];const ce=I;let D;e[22]===Symbol.for("react.memo_cache_sentinel")?(D=t=>{G(t),c(3)},e[22]=D):D=e[22];const V=D;let F;e[23]===Symbol.for("react.memo_cache_sentinel")?(F=async t=>{if(t)try{const P=await we(t);if(ke(P)){$.error("La foto es demasiado grande. Probá con una de menor resolución.");return}Z(P),ee(URL.createObjectURL(P))}catch{$.error("No se pudo procesar la imagen")}},e[23]=F):F=e[23];const Q=F;let R;e[24]!==n||e[25]!==a?(R=()=>{if(a===1){n("/my-profile");return}c(a-1)},e[24]=n,e[25]=a,e[26]=R):R=e[26];const O=R;let A;e[27]!==i||e[28]!==g||e[29]!==h?.items?.length?(A=!g&&i.trim().length>=2&&h?.items?.length===0,e[27]=i,e[28]=g,e[29]=h?.items?.length,e[30]=A):A=e[30];const Y=A,de="mx-auto flex w-full max-w-2xl flex-col gap-6 p-4";let U;e[31]===Symbol.for("react.memo_cache_sentinel")?(U=s.jsx(_e,{size:20}),e[31]=U):U=e[31];let b;e[32]!==O?(b=s.jsx(H,{variant:"ghost",size:"icon",onClick:O,"aria-label":"Volver",children:U}),e[32]=O,e[33]=b):b=e[33];const K=`Paso ${a} de 3 · ${re[a-1]}`;let v;e[34]!==K?(v=s.jsx(je,{title:"Vincular mi perfil",description:K}),e[34]=K,e[35]=v):v=e[35];let y;e[36]!==b||e[37]!==v?(y=s.jsxs("div",{className:"flex items-center gap-3",children:[b,v]}),e[36]=b,e[37]=v,e[38]=y):y=e[38];let S;e[39]!==a?(S=s.jsx(Ie,{current:a}),e[39]=a,e[40]=S):S=e[40];const M=a===1&&s.jsxs("div",{className:"flex flex-col gap-3",children:[s.jsx("p",{className:"text-sm text-muted-foreground",children:"¿Qué sos dentro de la asociación?"}),se.length===0&&s.jsx(J,{children:s.jsx(X,{className:"py-6 text-center text-sm text-muted-foreground",children:"Ya tenés vinculados todos los tipos de perfil disponibles."})}),se.map(t=>s.jsxs("button",{type:"button",onClick:()=>
1ce(t.value),className:"flex items-center gap-4 rounded-xl border bg-card p-4 text-left shadow-sm transition-colors hover:bg-accent focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",children:[s.jsx("span",{className:"flex h-11 w-11 shrink-0 items-center justify-center rounded-full bg-muted text-muted-foreground",children:s.jsx(te,{size:22})}),s.jsxs("div",{className:"min-w-0 flex-1",children:[s.jsx("p",{className:"font-medium",children:t.label}),s.jsx("p",{className:"text-sm text-muted-foreground",children:t.description})]}),s.jsx(Ce,{size:18,className:"shrink-0 text-muted-foreground"})]},t.value))]});let w;e[41]!==i||e[42]!==V||e[43]!==g||e[44]!==h?.items||e[45]!==_||e[46]!==Y||e[47]!==a?(w=a===2&&s.jsxs("div",{className:"flex flex-col gap-3",children:[s.jsx("p",{className:"text-sm text-muted-foreground",children:"Buscá tu ficha por nombre o apellido y seleccionala."}),s.jsxs("div",{className:"relative",children:[s.jsx(ne,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"}),s.jsx(be,{autoFocus:!0,placeholder:"Nombre o apellido",className:"pl-9",value:_,onChange:t=>W(t.target.value)})]}),i.trim().length<2&&s.jsx("p",{className:"text-sm text-muted-foreground",children:"Escribí al menos 2 letras para buscar."}),g&&s.jsx("div",{className:"flex flex-col gap-2",children:[0,1,2].map(ze)}),Y&&s.jsx(J,{children:s.jsxs(X,{className:"flex flex-col items-center gap-2 py-8 text-center",children:[s.jsx(ne,{size:24,className:"text-muted-foreground"}),s.jsx("p",{className:"text-sm text-muted-foreground",children:"No encontramos ninguna ficha con ese nombre. Si creés que debería existir, hablá con tu asociación."})]})}),s.jsx("div",{className:"flex flex-col gap-2",children:h?.items?.map(t=>s.jsxs("button",{type:"button",onClick:()=>V(t),className:"flex items-center justify-between gap-4 rounded-xl border bg-card p-3 text-left shadow-sm transition-colors hover:bg-accent focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",children:[s.jsxs("div",{className:"min-w-0",children:[s.jsxs("p",{className:"truncate font-medium",children:[t.surname,", ",t.name]}),s.jsxs("p",{className:"truncate text-sm text-muted-foreground",children:[t.team_name||"Sin equipo"," · DNI"," ",t.dni_masked]})]}),t.claimed&&s.jsx("span",{className:"shrink-0 text-xs text-muted-foreground",children:"Ya vinculada a otro usuario"})]},t.entity_id))})]}),e[41]=i,e[42]=V,e[43]=g,e[44]=h?.items,e[45]=_,e[46]=Y,e[47]=a,e[48]=w):w=e[48];let k;e[49]!==L||e[50]!==Q||e[51]!==u||e[52]!==C||e[53]!==r||e[54]!==a||e[55]!==E?(k=a===3&&r&&s.jsxs("div",{className:"flex flex-col gap-4",children:[s.jsx(J,{children:s.jsxs(X,{className:"flex items-center gap-3",children:[s.jsx("span",{className:"flex h-11 w-11 shrink-0 items-center justify-center rounded-full bg-muted text-muted-foreground",children:s.jsx(te,{size:22})}),s.jsxs("div",{className:"min-w-0",children:[s.jsx("p",{className:"text-xs uppercase tracking-wide text-muted-foreground",children:"Ficha seleccionada"}),s.jsxs("p",{className:"truncate font-medium",children:[r.surname,", ",r.name]}),s.jsxs("p",{className:"truncate text-sm text-muted-foreground",children:[r.team_name||"Sin equipo"," · DNI"," ",r.dni_masked]})]})]})}),s.jsxs("div",{children:[s.jsx("p",{className:"font-medium",children:"Foto del DNI"}),s.jsx("p",{className:"text-sm text-muted-foreground",children:"Sacate una foto sosteniendo tu DNI junto a tu cara, de modo que se lean los datos. Un administrador la va a revisar y después se elimina."})]}),s.jsxs("label",{className:"flex cursor-pointer flex-col items-center gap-2 rounded-xl border border-dashed p-6 text-center transition-colors hover:bg-accent focus-within:ring-1 focus-within:ring-ring",children:[C?s.jsx("img",{src:C,alt:"Vista previa del DNI",className:"max-h-64 rounded-md object-contain"}):s.jsxs(s.Fragment,{children:[s.jsx("span",{className:"flex h-12 w-12 items-center justify-center rounded-full bg-muted text-muted-foreground",children:s.jsx(Ee,{size:22})}),s.jsx("span",{className:"text-sm font-medium",children:"Tocá para elegir una foto"}),s.jsx("span",{className:"text-xs text-muted-foreground",children:"En el celular podés usar la cámara directamente."})]}),s.jsx("input",{type:"file",accept:"image/jpeg,image/png,image/webp",capture:"user",className:"hidden",onChange:t=>Q(t.target.files?.[0])})]}),C&&s.jsx(H,{variant:"outline",size:"sm",className:"self-center",onClick:()=>{Z(null),ee(null)},children:"Cambiar foto"}),s.jsxs("div",{className:"flex items-start gap-3 rounded-xl border bg-card p-4",children:[s.jsx(Ne,{id:"consent",checked:L,onCheckedChange:t=>le(t===!0),className:"mt-0.5"}),s.jsx(ve,{htmlFor:"consent",className:"text-sm font-normal leading-snug text-muted-foreground",children:qe})]}),s.jsx(H,{className:"w-full",disabled:!u||!L||E.isPending,onClick:()=>E.mutate(),children:E.isPending?"Enviando…":"Enviar solicitud"})]}),e[49]=L,e[50]=Q,e[51]=u,e[52]=C,e[53]=r,e[54]=a,e[55]=E,e[56]=k):k=e[56];let B;return e[57]!==y||e[58]!==S||e[59]!==M||e[60]!==w||e[61]!==k?(B=s.jsxs("div",{className:de,children:[y,S,M,w,k]}),e[57]=y,e[58]=S,e[59]=M,e[60]=w,e[61]=k,e[62]=B):B=e[62],B}function ze(e){return s.jsxs("div",{className:"flex items-center gap-3 rounded-lg border p-3",children:[s.jsx(ae,{className:"h-4 w-40"}),s.jsx(ae,{className:"ml-auto h-4 w-24"})]},e)}function Te(e){$.error(e?.response?.data??"No se pudo enviar la solicitud")}function Ie(e){const n=ie.c(3),{current:o}=e;let l;n[0]===Symbol.for("react.memo_cache_sentinel")?(l=[1,2,3],n[0]=l):l=n[0];let a;return n[1]!==o?(a=s.jsx("div",{className:"flex items-center gap-2",children:l.map(c=>s.jsxs("div",{className:"flex flex-1 flex-col gap-1.5",children:[s.jsx("div",{className:`h-1.5 rounded-full transition-colors ${c<=o?"bg-primary":"bg-muted"}`}),s.jsx("span",{className:`text-xs ${c<=o?"font-medium text-foreground":"text-muted-foreground"}`,children:re[c-1]})]},c))}),n[1]=o,n[2]=a):a=n[2],a}export{Ge as default};

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.