PageSourceSearch

https://hanttrail-8fwxhbgl.manus.space/assets/Register-DPzApaDO.js

js hanttrail-8fwxhbgl.manus.space collected 2026-10-03 05:02:20 UTC 68,157 bytes, 11 lines download raw bytes

1import{c as Ce,q as Ee,H as De,v as Fe,r as a,j as e,z as Le,E as Be,B as A,s as y,t as r,Z as Ge,$ as Oe}from"./index-CqGqwWKp.js";import{I as o}from"./input-C-dhHZfz.js";import{L as x}from"./label-BKVSJH31.js";import{S as te,a as se,b as ae,c as re,d as ce}from"./select-4H_lyalD.js";import{P as Se}from"./phone-GaEkZOZ2.js";import{C as ke}from"./chevron-down-D5hvyLKM.js";import{E as ie}from"./eye-off-CtJ4omIA.js";import{E as le}from"./eye-B8aPKStA.js";import{L as W}from"./loader-circle-CCfGGRPf.js";import{L as Pe}from"./log-in-DiOYefbL.js";import"./useComposition-CjDhl5L8.js";import"./usePersistFn-DaDCSoQ3.js";import"./index-Bx-ZvfA0.js";import"./index-Day0wMJL.js";import"./check-Crx4ZKfw.js";import"./chevron-up-BZF2vgGI.js";/**
2 * @license lucide-react v0.453.0 - ISC
3 *
4 * This source code is licensed under the ISC license.
5 * See the LICENSE file in the root directory of this source tree.
6 */const Me=Ce("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
7 * @license lucide-react v0.453.0 - ISC
8 *
9 * This source code is licensed under the ISC license.
10 * See the LICENSE file in the root directory of this source tree.
11 */const $e=Ce("UserPlus",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]),Ve="https://d2xsxph8kpxj0f.cloudfront.net/310519663548498135/8FWXHBGLaXzwMXfkkMnXxw/hant-logo-new_6f9c4c11.png",je="hant_pending_profile";function ut(n){localStorage.setItem(je,JSON.stringify(n))}function ft(){try{const n=localStorage.getItem(je);return n?JSON.parse(n):null}catch{return null}}function bt(){localStorage.removeItem(je)}function ue(n,c){localStorage.setItem("hant_session_token",n),localStorage.setItem("hant_session_expires",String(c)),localStorage.removeItem("hant_logged_out"),Ge(),localStorage.removeItem("manus-runtime-user-info"),window.__hant_token_valid=!0,Oe()}function We(){try{const n=new URLSearchParams(window.location.search).get("returnTo");return n&&n.startsWith("/")&&!n.startsWith("//")?n:"/"}catch{return"/"}}const Te=["서울특별시","부산광역시","대구광역시","인천광역시","광주광역시","대전광역시","울산광역시","세종특별자치시","경기도","강원특별자치도","충청북도","충청남도","전북특별자치도","전라남도","경상북도","경상남도","제주특별자치도"];function wt(){const{isAuthenticated:n,loading:c}=Ee(),[,u]=De(),h=typeof window<"u"&&(window.location.hostname==="hantp.com"||window.location.hostname==="www.hantp.com"||window.location.hostname.endsWith(".hantp.com")),E=Fe();(()=>{try{return localStorage.getItem("hant_logged_out")==="1"}catch{return!1}})();const[b,_]=a.useState(!1);return a.useEffect(()=>{!h&&!c&&n&&u("/")},[n,c,u]),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:90",className:"min-h-screen bg-[#1a4a2e] flex flex-col items-center justify-center px-4 py-8",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:91",className:"flex flex-col items-center mb-6",children:[e.jsx("img",{"data-loc":"client/src/pages/Register.tsx:92",src:Ve,alt:"HANT",className:"h-20 object-contain mb-3"}),e.jsx("h1",{"data-loc":"client/src/pages/Register.tsx:93",className:"text-white text-2xl font-bold tracking-tight",children:"HANT 한국트레일"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:94",className:"text-white/60 text-sm mt-1",children:"사단법인 한국 사람길 (KHA)"})]}),!b&&e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:99",type:"button",onClick:()=>_(!0),className:"w-full max-w-sm mb-3 flex items-center gap-3 px-4 py-3 rounded-xl bg-amber-500/20 border border-amber-400/40 hover:bg-amber-500/30 transition-colors text-left",children:[e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:104",className:"text-2xl",children:"👋"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:105",className:"flex-1",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:106",className:"text-amber-200 text-sm font-semibold",children:"처음 오셨나요?"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:107",className:"text-amber-300/70 text-xs mt-0.5",children:"무료 회원가입 후 HANT 따라걷기를 시작하세요"})]}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:109",className:"text-amber-300/60 text-sm font-bold",children:"→"})]}),e.jsx(Le,{"data-loc":"client/src/pages/Register.tsx:112",className:"w-full max-w-sm bg-white/10 border-white/20 backdrop-blur-sm",children:e.jsx(Be,{"data-loc":"client/src/pages/Register.tsx:113",className:"p-6",children:b?e.jsx(e.Fragment,{children:e.jsx(Ue,{"data-loc":"client/src/pages/Register.tsx:116",navigate:u,onSwitchToLogin:()=>_(!1)})}):e.jsxs(e.Fragment,{children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:120",className:"text-white font-semibold text-base mb-4 text-center",children:"로그인"}),e.jsx(qe,{"data-loc":"client/src/pages/Register.tsx:121",navigate:u,onSwitchToRegister:()=>_(!0)})]})})}),!h&&E&&!b&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:128",className:"w-full max-w-sm mt-4 text-center",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:129",className:"text-white/65 text-xs leading-relaxed mb-3",children:"서버 연결이 복구되면 로그인·비밀번호 찾기·기록 전송을 이용할 수 있습니다. 로그아웃 상태의 자
11유걷기는 이 기기에만 보관됩니다."}),e.jsx(A,{"data-loc":"client/src/pages/Register.tsx:132",type:"button",variant:"outline",onClick:()=>u("/track?offline=1"),className:"w-full border-amber-300/60 bg-amber-300/10 text-amber-100 hover:bg-amber-300/20",children:"서버 연결 없이 자유걷기 기록하기"})]}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:143",className:"text-white/40 text-xs mt-6 text-center",children:"HANT 한국트레일"})]})}const d="bg-white/10 border-white/20 text-white placeholder:text-white/40",p="text-white/80 text-sm";function Ye({navigate:n}){const[c,u]=a.useState(""),[h,E]=a.useState(""),[b,_]=a.useState(!1),[C,w]=a.useState("login"),[f,H]=a.useState("phone"),[R,D]=a.useState(""),[k,F]=a.useState(""),[v,L]=a.useState(""),[$,B]=a.useState(""),[P,q]=a.useState(!1),[m,G]=a.useState(""),g=y.auth.loginPhone.useMutation({onSuccess:i=>{ue(i.token,i.expires),r.success("로그인 성공!"),typeof window<"u"&&(window.location.hostname.includes("hantp.com")||window.location.hostname.includes("manus.space"))?setTimeout(()=>{window.location.href="/"},800):n("/")},onError:i=>r.error(i.message||"로그인 실패")}),M=y.auth.sendPasswordResetByPhone.useMutation({onSuccess:()=>{w("forgot_code"),r.success("인증번호를 발송했습니다")},onError:i=>r.error(i.message||"인증번호 발송 실패")}),N=y.auth.sendPasswordResetByEmail.useMutation({onSuccess:i=>{G(i.maskedPhone||""),w("forgot_code"),r.success(`등록된 전화번호(${i.maskedPhone})로 인증번호를 발송했습니다`)},onError:i=>r.error(i.message||"인증번호 발송 실패")}),I=y.auth.resetPasswordWithSms.useMutation({onSuccess:()=>{r.success("비밀번호가 변경되었습니다"),w("login"),D(""),F(""),L(""),B("")},onError:i=>r.error(i.message||"비밀번호 변경 실패")});return C!=="login"?e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:187",className:"space-y-3",children:[e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:188",type:"button",onClick:()=>w("login"),className:"text-white/60 hover:text-white text-sm flex items-center gap-1 mb-1",children:[e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:189",children:"←"})," 로그인으로 돌아가기"]}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:191",className:"text-white font-semibold text-base",children:"비밀번호 찾기"}),C==="forgot_select"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:193",className:"space-y-3",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:194",className:"text-white/70 text-sm",children:"본인 확인 방법을 선택해주세요"}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:195",type:"button",onClick:()=>{H("phone"),w("forgot_input")},className:"w-full h-12 rounded-lg border border-white/30 text-white text-sm font-medium hover:bg-white/10 transition-colors",children:"전화번호로 찾기"}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:199",type:"button",onClick:()=>{H("email"),w("forgot_input")},className:"w-full h-12 rounded-lg border border-white/30 text-white text-sm font-medium hover:bg-white/10 transition-colors",children:"이메일로 찾기"})]}),C==="forgot_input"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:206",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:207",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:208",className:p,children:f==="email"?"가입 시 사용한 이메일":"가입 시 등록한 전화번호"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:209",type:f==="email"?"email":"tel",inputMode:f==="email"?"email":"tel",placeholder:f==="email"?"[email protected]":"01012345678",value:R,onChange:i=>D(i.target.value),autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:214",type:"button",onClick:()=>{if(!R.trim()){r.error(f==="email"?"이메일을 입력해주세요":"전화번호를 입력해주세요");return}f==="email"?N.mutate({email:R.trim()}
11):M.mutate({phoneNumber:R.trim()})},className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base",disabled:N.isPending||M.isPending,children:[N.isPending||M.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:220",size:16,className:"animate-spin mr-2"}):null,"인증번호 받기"]})]}),C==="forgot_code"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:226",className:"space-y-3",children:[m&&e.jsxs("p",{"data-loc":"client/src/pages/Register.tsx:227",className:"text-white/70 text-sm",children:[m,"으로 인증번호를 발송했습니다"]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:228",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:229",className:p,children:"인증번호 (6자리)"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:230",type:"text",inputMode:"numeric",placeholder:"123456",maxLength:6,value:k,onChange:i=>F(i.target.value.replace(/[^0-9]/g,"").slice(0,6)),autoComplete:"one-time-code","data-form-type":"other",className:`${d} text-center text-lg tracking-widest`})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:235",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:236",className:p,children:"새 비밀번호 (8자 이상)"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:237",className:"relative",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:238",type:P?"text":"password",placeholder:"새 비밀번호",value:v,onChange:i=>L(i.target.value),autoComplete:"new-password","data-form-type":"other",className:`${d} pr-10`}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:241",type:"button",onClick:()=>q(!P),className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/50",children:P?e.jsx(ie,{"data-loc":"client/src/pages/Register.tsx:243",size:16}):e.jsx(le,{"data-loc":"client/src/pages/Register.tsx:243",size:16})})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:247",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:248",className:p,children:"새 비밀번호 확인"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:249",type:"password",placeholder:"비밀번호 재입력",value:$,onChange:i=>B(i.target.value),autoComplete:"new-password","data-form-type":"other",className:d})]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:253",type:"button",onClick:()=>{if(k.length!==6){r.error("인증번호 6자리를 입력해주세요");return}if(v.length<8){r.error("비밀번호는 8자 이상이어야 합니다");return}if(v!==$){r.error("비밀번호가 일치하지 않습니다");return}I.mutate({identifier:R.trim(),identifierType:f,code:k,newPassword:v})},className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base",disabled:I.isPending,children:[I.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:260",size:16,className:"animate-spin mr-2"}):null,"비밀번호 변경"]})]})]}):e.jsx("form",{"data-loc":"client/src/pages/Register.tsx:270",autoComplete:"off",onSubmit:i=>{if(i.preventDefault(),!c.trim()){r.error("전화번호를 입력해주세요");return}if(!h){r.error("비밀번호를 입력해주세요");return}g.mutate({phoneNumber:c,password:h})},noValidate:!0,children:e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:271",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:272",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:273",className:p,children:"전화번호"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:274",type:"tel",inputMode:"tel",placeholder:"010-1234-5678",value:c,onChange:i=>u(ve(i.target.value)),autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:278",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:279",className:p,children:"비밀번호"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:280",className:"relative",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:281",type:b?"text":"password",placeholder:"비밀번호",value:h,onChange:i=>E(i.target.value),autoComplete:"current-password","data-form-type":"other",className:`${d} pr-10`}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:285",type:"button",onClick:()=>_(!b),className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/50",children:b?e.jsx(ie,{"data-loc":"client/src/pages/Register.tsx:287",size:16}):e.jsx(le,{"data-loc":"client/src/pages/Register.tsx:287",size:16})})]})]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:291",type:"submit",className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base mt-1",disabled:g.isPending,children:[g.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:293",size:16,className:"animate-spin mr-2"}):e.jsx(Pe,{"data-loc":"client/src/pages/Register.tsx:293",size:16,className:"mr-2"}),"로그인"]}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:296",type:"button",onClick:()=>w("forgot_select"),className:"w-full text-white/50 text-xs text-center py-1 hover:text-white/80 transition-colors",children:"비밀번호를 잊으셨나요?"})]})})}function Ue({navigate:n,onSwitchToLogin:c}
11){const[u,h]=a.useState("sms");return e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:310",className:"space-y-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:311",className:"flex gap-2",children:[e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:312",type:"button",onClick:()=>h("sms"),className:`flex-1 flex items-center justify-center gap-1.5 py-2 rounded-lg text-sm font-medium border transition-colors ${u==="sms"?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:[e.jsx(Se,{"data-loc":"client/src/pages/Register.tsx:319",size:14}),"전화번호"]}),e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:322",type:"button",onClick:()=>h("email"),className:`flex-1 flex items-center justify-center gap-1.5 py-2 rounded-lg text-sm font-medium border transition-colors ${u==="email"?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:[e.jsx(Me,{"data-loc":"client/src/pages/Register.tsx:329",size:14}),"이메일"]})]}),u==="sms"?e.jsx(Je,{"data-loc":"client/src/pages/Register.tsx:335",navigate:n}):e.jsx(Ze,{"data-loc":"client/src/pages/Register.tsx:337",navigate:n}),e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:340",type:"button",onClick:c,className:"w-full text-center text-white/50 text-sm hover:text-white/70 transition-colors pt-1",children:["이미 계정이 있으신가요? ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:345",className:"underline",children:"로그인"})]})]})}function qe({navigate:n,onSwitchToRegister:c}){const[u,h]=a.useState("phone");return e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:355",className:"space-y-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:356",className:"flex gap-2",children:[e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:357",type:"button",onClick:()=>h("phone"),className:`flex-1 flex items-center justify-center gap-1.5 py-2 rounded-lg text-sm font-medium border transition-colors ${u==="phone"?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:[e.jsx(Se,{"data-loc":"client/src/pages/Register.tsx:361",size:14}),"전화번호"]}),e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:364",type:"button",onClick:()=>h("email"),className:`flex-1 flex items-center justify-center gap-1.5 py-2 rounded-lg text-sm font-medium border transition-colors ${u==="email"?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:[e.jsx(Me,{"data-loc":"client/src/pages/Register.tsx:368",size:14}),"이메일"]})]}),u==="phone"?e.jsx(Ye,{"data-loc":"client/src/pages/Register.tsx:373",navigate:n}):e.jsx(Qe,{"data-loc":"client/src/pages/Register.tsx:375",navigate:n}),e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:377",type:"button",onClick:c,className:"w-full text-center text-white/50 text-sm hover:text-white/70 transition-colors pt-1",children:["계정이 없으신가요? ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:379",className:"underline",children:"회원가입"})]})]})}function ve(n){const c=n.replace(/[^0-9]/g,"");return c.length<=3?c:c.length<=7?`${c.slice(0,3)}-${c.slice(3)}`:`${c.slice(0,3)}-${c.slice(3,7)}-${c.slice(7,11)}`}function Xe(n){const c=Math.floor(n/60),u=n%60;return`${c}:${u.toString().padStart(2,"0")}`}function Je({navigate:n}){const[c,u]=a.useState(""),[h,E]=a.useState(""),[b,_]=a.useState(""),[C,w]=a.useState(""),[f,H]=a.useState(""),[R,D]=a.useState(""),[k,F]=a.useState(""),[v,L]=a.useState(""),[$,B]=a.useState(""),[P,q]=a.useState("general"),[m,G]=a.useState("personal"),[g,M]=a.useState(""),[N,I]=a.useState(""),[i,K]=a.useState(""),[l,ne]=a.useState(""),[T,fe]=a.useState("association"),[Y,xe]=a.useState(""),[O,X]=a.useState(!1),[U,pe]=a.useState(!1),[he,oe]=a.useState(!1),[z,be]=a.useState(""),[Z,we]=a.useState(""),[de,Q]=a.useState(!1),[V,Re]=a.useState(""),[ge,ee]=a.useState("info"),[J,s]=a.useState(0),j=a.useRef(null),Ae=y.profile.upsert.useMutation(),_e=y.hant.checkAndIssue.useMutation(),He=y.useUtils(),me=y.sms.sendCode.useMutation({onSuccess:t=>{t.success?(ee("code"),s(180),r.success("인증번호가 발송되었습니다 (3분 유효)")):r.error("발송 실패")},onError:t=>{const S=t.message||"";
11S.includes("IP")?r.error("SMS 서비스 오류입니다. 이메일로 가입해 주세요."):r.error(S||"인증번호 발송 실패")}}),Ne=y.auth.loginSms.useMutation({onSuccess:async t=>{ue(t.token,t.expires);try{if(await Ae.mutateAsync({fullName:c.trim(),phoneNumber:h,gender:b||void 0,birthDate:C||void 0,regionCity:v||void 0,regionDistrict:$||void 0,affiliationType:m,hgGeneration:m==="hg"&&g?parseInt(g):void 0,orgName:m==="group"?N.trim():void 0,groupSize:i?parseInt(i):void 0,companionCount:m==="personal"&&l?parseInt(l):void 0,leaderType:m==="leader"?T:void 0,hantNumber:Y.trim()||void 0}),U)try{const S=await _e.mutateAsync({name:c.trim(),phone:h,paidDeposit:!1,affiliationType:m,hgGeneration:m==="hg"&&g?parseInt(g):void 0,groupSize:i?parseInt(i):void 0,companionCount:m==="personal"&&l?parseInt(l):void 0,leaderType:m==="leader"?T:void 0});S.issued&&S.hantNumber&&r.success(`축하합니다! 우리 국토를 걷는 회원님의 HANT 등록번호 ${S.hantNumber}가 발급되었습니다 🎉`)}catch{}}catch{}r.success("가입 완료! 환영합니다."),n("/")},onError:t=>r.error(t.message||"인증 실패")});a.useEffect(()=>(J>0&&(j.current=setInterval(()=>{s(t=>t<=1?(clearInterval(j.current),0):t-1)},1e3)),()=>{j.current&&clearInterval(j.current)}),[J]);const Ie=async()=>{if(!c.trim()){r.error("이름을 먼저 입력해 주세요");return}if(!h.trim()){r.error("전화번호를 먼저 입력해 주세요");return}try{const t=await He.client.hantReg.lookupByNamePhone.query({name:c.trim(),phoneNumber:h});t.found&&t.hantNumber?(xe(t.hantNumber),X(!0),pe(!0),r.success("축하합니다! 우리 국토를 걷는 회원님의 HANT 등록번호가 발급되었습니다 🎉")):(X(!0),pe(!1),r.info("HANT 완주 인증을 위해 등록한 분께만 발급됩니다. HANT 등록번호 없어도 회원가입 됩니다."))}catch{r.error("조회 중 오류가 발생했습니다.")}},ye=()=>{if(!c.trim()){r.error("이름을 입력해 주세요");return}if(!b){r.error("성별을 선택해 주세요");return}if(!C){r.error("생년월일을 입력해 주세요");return}if(!v){r.error("거주지 시/도를 선택해 주세요");return}if(!$.trim()){r.error("거주지 시/êµ°/구를 입력해 주세요");return}if(m==="hg"&&!g){r.error("국토종주단 기수를 입력해 주세요");return}if(m==="group"&&!N.trim()){r.error("단체명을 입력해 주세요");return}if(m==="leader"&&!T){r.error("인솔자 유형을 선택해 주세요");return}if(!h.trim()){r.error("전화번호를 입력해 주세요");return}me.mutate({phoneNumber:h})},ze=()=>{if(V.length!==6){r.error("6자리 인증번호를 입력해 주세요");return}if(z.length<8){r.error("비밀번호는 8자 이상이어야 합니다");return}if(z!==Z){r.error("비밀번호가 일치하지 않습니다");return}Ne.mutate({phoneNumber:h,code:V,name:c.trim()||void 0,password:z||void 0})};return e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:548",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:550",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:551",className:p,children:["이름 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:551",className:"text-red-400",children:"*"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:552",placeholder:"홍길동",value:c,onChange:t=>u(t.target.value),autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:557",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:558",className:p,children:["전화번호 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:558",className:"text-red-400",children:"*"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:559",type:"tel",inputMode:"tel",placeholder:"010-1234-5678",value:h,onChange:t=>{E(ve(t.target.value)),ee("info"),Re(""),X(!1)},disabled:ge==="code",autoComplete:"off","data-form-type":"other",className:`${d} flex-1 w-full`})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:565",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:566",className:p,children:["HANT 등록번호",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:568",className:"text-white/40 text-xs ml-1",children:"(없으면 가입 후 신청)"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:570",className:"flex gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:571",placeholder:"이름+전화ë²
11ˆí˜¸ 입력 후 발급 버튼 클릭",value:Y,onChange:t=>{xe(t.target.value.trim()),X(!1)},autoComplete:"off","data-form-type":"other",className:`${d} flex-1`,readOnly:O&&!!Y}),e.jsx(A,{"data-loc":"client/src/pages/Register.tsx:575",type:"button",onClick:Ie,className:"bg-[#52b788] text-white hover:bg-[#40916c] shrink-0 text-xs px-3 font-semibold",children:"발급"})]}),O&&U&&e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:581",className:"text-green-300 text-xs mt-1",children:"🎉 축하합니다! 우리 국토를 걷는 회원님의 HANT 등록번호가 발급되었습니다."}),O&&!U&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:584",className:"mt-1 space-y-1",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:585",className:"text-yellow-300 text-xs",children:"HANT 사전등록자가 아닌 분은 HANT 번호가 발급되지 않습니다."}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:586",className:"text-white/60 text-xs",children:"HANT 번호 없어도 회원가입은 가능합니다."}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:587",type:"button",onClick:()=>oe(!0),className:"text-[#52b788] text-xs underline underline-offset-2 hover:text-[#40916c]",children:"HANT 등록 신청 방법을 안내해 드릴까요? →"})]}),!O&&e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:594",className:"text-white/40 text-xs",children:"이름과 전화번호 입력 후 발급 버튼을 누르세요."})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:599",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:600",className:p,children:["성별 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:600",className:"text-red-400",children:"*"})]}),e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:601",className:"flex gap-2",children:[{v:"male",l:"남성"},{v:"female",l:"여성"}].map(({v:t,l:S})=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:603",type:"button",onClick:()=>_(t),className:`flex-1 py-2 rounded-lg text-sm font-medium border transition-colors ${b===t?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:S},t))})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:612",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:613",className:p,children:["생년월일 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:613",className:"text-red-400",children:"*"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:614",className:"flex gap-2",children:[e.jsxs(te,{"data-loc":"client/src/pages/Register.tsx:615",value:f,onValueChange:t=>{H(t),w(`${t}-${R||"01"}-${k||"01"}`)},children:[e.jsx(se,{"data-loc":"client/src/pages/Register.tsx:616",className:"flex-1 bg-white/10 border-white/20 text-white",children:e.jsx(ae,{"data-loc":"client/src/pages/Register.tsx:617",placeholder:"연도"})}),e.jsx(re,{"data-loc":"client/src/pages/Register.tsx:619",className:"max-h-60",children:Array.from({length:new Date().getFullYear()-1919},(t,S)=>String(new Date().getFullYear()-S)).map(t=>e.jsxs(ce,{"data-loc":"client/src/pages/Register.tsx:621",value:t,children:[t,"년"]},t))})]}),e.jsxs(te,{"data-loc":"client/src/pages/Register.tsx:625",value:R,onValueChange:t=>{D(t),w(`${f||"2000"}-${t}-${k||"01"}`)},children:[e.jsx(se,{"data-loc":"client/src/pages/Register.tsx:626",className:"w-20 bg-white/10 border-white/20 text-white",children:e.jsx(ae,{"data-loc":"client/src/pages/Register.tsx:627",placeholder:"월"})}),e.jsx(re,{"data-loc":"client/src/pages/Register.tsx:629",children:Array.from({length:12},(t,S)=>String(S+1).padStart(2,"0")).map(t=>e.jsxs(ce,{"data-loc":"client/src/pages/Register.tsx:631",value:t,children:[t,"월"]},t))})]}),e.jsxs(te,{"data-loc":"client/src/pages/Register.tsx:635",value:k,onValueChange:t=>{F(t),w(`${f||"2000"}-${R||"01"}-${t}`)},children:[e.jsx(se,{"data-loc":"client/src/pages/Register.tsx:636",className:"w-20 bg-white/10 border-white/20 text-white",children:e.jsx(ae,{"data-loc":"client/src/pages/Register.tsx:637",placeholder:"일"})}),e.jsx(re,{"data-loc":"client/src/pages/Register.tsx:639",children:Array.from({length:31},(t,S)=>String(S+1).padStart(2,"0")).map(t=>e.jsxs(ce,{"data-loc":"client/src/pages/Register.tsx:641",value:t,children:[t,"일"]},t))})]})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:649",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:650",className:p,children:["거주지 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:650",className:"text-red-400",children:"*"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:651",className:"flex gap-2",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:652",className:"relative flex-1",children:[e.jsxs("select",{"data-loc":"client/src/pages/Register.tsx:653",value:v,onCh
11ange:t=>L(t.target.value),className:"w-full appearance-none bg-white/10 border border-white/20 text-white rounded-md px-3 py-2 text-sm focus:outline-none focus:ring-1 focus:ring-primary pr-8",children:[e.jsx("option",{"data-loc":"client/src/pages/Register.tsx:655",value:"",className:"bg-[#1a4a2e]",children:"시/도 선택"}),Te.map(t=>e.jsx("option",{"data-loc":"client/src/pages/Register.tsx:656",value:t,className:"bg-[#1a4a2e]",children:t},t))]}),e.jsx(ke,{"data-loc":"client/src/pages/Register.tsx:658",size:14,className:"absolute right-2 top-1/2 -translate-y-1/2 text-white/50 pointer-events-none"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:660",placeholder:"시/군/구",value:$,onChange:t=>B(t.target.value),className:`${d} flex-1`})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:666",className:"space-y-1.5",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:667",className:"flex items-center justify-between",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:668",className:p,children:["소속 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:668",className:"text-red-400",children:"*"})]}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:669",className:"text-white/40 text-xs",children:"나중에 변경 가능합니다"})]}),e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:671",className:"flex gap-2",children:["hant","general"].map(t=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:673",type:"button",onClick:()=>{q(t),G(t==="hant"?"hg":"personal")},className:`flex-1 py-2 rounded-lg text-sm font-semibold border transition-colors ${P===t?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:t==="hant"?"HANT":"일반 사용자"},t))}),P==="hant"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:683",className:"space-y-1.5 mt-1",children:[e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:684",className:"flex gap-1.5 flex-wrap",children:["hg","personal","group","leader"].map(t=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:686",type:"button",onClick:()=>G(t),className:`flex-1 min-w-[4rem] py-1.5 rounded-lg text-xs font-medium border transition-colors ${m===t?"bg-[#52b788] text-white border-[#52b788]":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:t==="hg"?"국토종주단":t==="personal"?"개인":t==="group"?"단체":"인솔자"},t))}),m==="hg"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:695",className:"flex items-center gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:696",type:"number",inputMode:"numeric",placeholder:"기수 (1, 2, 3...)",value:g,onChange:t=>M(t.target.value.replace(/[^0-9]/g,"")),className:`${d} flex-1`}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:699",className:"text-white/60 text-sm shrink-0",children:"기"})]}),m==="personal"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:703",className:"flex items-center gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:704",type:"number",inputMode:"numeric",placeholder:"동료 수 (선택)",value:l,onChange:t=>ne(t.target.value.replace(/[^0-9]/g,"")),className:`${d} flex-1`}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:707",className:"text-white/60 text-sm shrink-0",children:"명"})]}),m==="group"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:711",className:"space-y-1.5",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:712",placeholder:"단체명 입력",value:N,onChange:t=>I(t.target.value),className:d}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:713",className:"flex items-center gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:714",type:"number",inputMode:"numeric",placeholder:"인원수 (선택)",value:i,onChange:t=>K(t.target.value.replace(/[^0-9]/g,"")),className:`${d} flex-1`}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:717",className:"text-white/60 text-sm shrink-0",children:"명"})]})]}),m==="leader"&&e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:722",className:"flex gap-1.5",children:["association","external"].map(t=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:724",type:"button",onClick:()=>fe(t),className:`flex-1 py-1.5 rounded-lg text-xs font-medium border transition-colors ${T===t?"bg-[#52b788] text-white border-[#52b788]":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:t==="association"?"협회 인솔자":"외부 인솔자"},t))})]}),P==="general"&&e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:736",className:"flex gap-1.5 mt-1",children:["personal","cyclist"].map(t=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:738",type:"button",onClick:()=>G(t),className:`flex-1 py-1.5 rounded-lg text-xs font-medium border transition-colors ${m===t?"bg-[#52b788] text-white border-[#52b788]":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:t==="personal"?"일반 사용자":"자전거여행자"},t))})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:750",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:751",className:p,children:["비밀번호 설정 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:751",className:"text-red-400",children:"*"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:752",className:"relative",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:753",type:de?"text":"password",placeholder:"8자 이상",value:z,onChange:t=>be(t.target.value),autoComplete:"new-password","data-form-type":"other",className:`${d} pr-10`}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:756",type:"button",onClick:()=>Q(!de),className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/50",children:de?e.jsx(ie,{"data-loc":"client/src/pages/Register.tsx:758",size:16}):e.jsx(le,{"data-loc":"client/src/pages/Register.tsx:758",size:16})})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:761",type:"password",placeholder:"비밀번호 확인",value:Z,onChange:t=>we(t.target.value),autoComplete:"new-password","data-form-type":"other",className:d}),z&&Z&&z!==Z&&e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:765",className:"text-red-400 text-xs",children:"비밀번호가 일치하지 않습니다"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:770",className:"border-t border-white/10 pt-3 space-y-3",children:[ge==="info"&&e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:772",type:"button",onClick:ye,disabled:me.isPending,className:"w-full h-12 bg-white/20 text-white hover:bg-white/30 font-semibold text-sm border border-white/30",children:[me.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:775",size:14,className:"animate-spin mr-2"}):null,"휴대폰 본인인증"]}),ge==="code"&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:781",className:"flex gap-2 items-center",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:782",type:"text",inputMode:"numeric",placeholder:"인증번호 6자리",value:V,onChange:t=>Re(t.target.value.replace(/[^0-9]/g,"").slice(0,6)),autoComplete:"one-time-code","data-form-type":"other",className:`${d} flex-1 text-center text-lg tracking-widest`}),e.jsx(A,{"data-loc":"client/src/pages/Register.tsx:786",type:"button",onClick:ye,disabled:me.isPending||J>0,className:"bg-white/20 text-white hover:bg-white/30 shrink-0 text-xs px-3 border border-white/30",children:J>0?Xe(J):"재발송"})]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:792",type:"button",className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base",onClick:ze,disabled:Ne.isPending||V.length!==6,children:[Ne.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:794",size:16,className:"animate-spin mr-2"}):e.jsx($e,{"data-loc":"client/src/pages/Register.tsx:794",size:16,className:"mr-2"}),"회원가입 완료"]})]})]}),he&&e.jsx(Ke,{"data-loc":"client/src/pages/Register.tsx:802",onClose:()=>oe(!1),onApply:()=>oe(!1)})]})}function Ke({onClose:n,onApply:c}){return e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:815",className:"fixed inset-0 z-50 flex items-end justify-center bg-black/60",onClick:n,children:e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:816",className:"w-full max-w-md bg-[#1a2e1a] rounded-t-2xl p-5 pb-8 space-y-4",onClick:u=>u.stopPropagation(),children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:817",className:"flex items-center justify-between",children:[e.jsx("h2",{"data-loc":"client/src/pages/Register.tsx:818",className:"text-white font-bold text-base",children:"HANT 등록 신청 방법"}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:819",onClick:n,className:"text-white/50 text-xl leading-none",children:"✕"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:821",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:823",className:"flex gap-3 items-start",children:[e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:824",className:"w-7 h-7 rounded-full bg-[#52b788] flex items-center justify-center shrink-0 text-white font-bold text-sm",children:"1"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:825",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:826",className:"text-white font-semibold text-sm",children:"등록비 10만원 입금"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:827",className:"text-white/60 text-xs mt-0.5",children:"기업은행 257-148861-01-013"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:828",className:"text-white/60 text-xs",children:"예금주: 한국사람길걷기협회"})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:832",className:"flex gap-3 items-start",children:[e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:833",className:"w-7 h-7 rounded-full bg-[#52b788] flex items-center justify-center shrink-0 text-white font-bold text-sm",children:"2"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:834",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:835",className:"text-white font-semibold text-sm",children:"이름 + 전화번호 등록 신청"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:836",className:"text-white/60 text-xs mt-0.5",children:"회원가입 후 마이페이지 → HANT 등록 신청"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:837",className:"text-white/60 text-xs",children:"또는 아래 버튼으로 바로 신청"})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:841",className:"flex gap-3 items-start",children:[e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:842",className:"w-7 h-7 rounded-full bg-[#52b788] flex items-center justify-center shrink-0 text-white font-bold text-sm",children:"3"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:843",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:844",className:"text-white font-semibold text-sm",children:"HANT 번호 자동 발급"}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:845",className:"text-white/60 text-xs mt-0.5",children:"입금 확인 후 관리자 승인 시 자동 발급됩니다"})]})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:849",className:"bg-[#52b788]/20 rounded-lg p-3",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:850",className:"text-[#52b788] text-xs font-semibold",children:"💡 HANT 번호 없어도 회원가입 및 앱 사용이 가능합니다."}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:851",className:"text-white/60 text-xs mt-1",children:"HANT 완주 인증을 원하시는 분만 등록하세요."})]}),c&&e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:854",onClick:c,className:"w-full py-3 bg-[#52b788] text-white rounded-xl font-semibold text-sm hover:bg-[#40916c]",children:"지금 신청하러 가기"}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:859",onClick:n,className:"w-full py-2.5 bg-white/10 text-white/70 rounded-xl text-sm hover:bg-white/20",children:"닫기"})]})})}function Ze({navigate:n}){const[c,u]=a.useState(""),[h,E]=a.useState(""),[b,_]=a.useState(""),[C,w]=a.useState(""),[f,H]=a.use
11State(""),[R,D]=a.useState(""),[k,F]=a.useState(""),[v,L]=a.useState(""),[$,B]=a.useState(""),[P,q]=a.useState(""),[m,G]=a.useState("general"),[g,M]=a.useState("personal"),[N,I]=a.useState(""),[i,K]=a.useState(""),[l,ne]=a.useState(""),[T,fe]=a.useState(""),[Y,xe]=a.useState("association"),[O,X]=a.useState(""),[U,pe]=a.useState(""),[he,oe]=a.useState(""),[z,be]=a.useState(!1),Z=y.profile.upsert.useMutation(),we=y.hant.checkAndIssue.useMutation(),de=y.useUtils(),[Q,V]=a.useState(!1),[Re,ge]=a.useState(!1),ee=y.auth.registerEmail.useMutation({onSuccess:async s=>{ue(s.token,s.expires);try{if(await Z.mutateAsync({fullName:c.trim(),phoneNumber:b||void 0,gender:C||void 0,birthDate:f||void 0,regionCity:$||void 0,regionDistrict:P||void 0,affiliationType:g,hgGeneration:g==="hg"&&N?parseInt(N):void 0,orgName:g==="group"?i.trim():void 0,groupSize:l?parseInt(l):void 0,companionCount:g==="personal"&&T?parseInt(T):void 0,leaderType:g==="leader"?Y:void 0,hantNumber:O.trim()||void 0}),Q)try{const j=await we.mutateAsync({name:c.trim(),phone:b,paidDeposit:!1,affiliationType:g,hgGeneration:g==="hg"&&N?parseInt(N):void 0,groupSize:l?parseInt(l):void 0,companionCount:g==="personal"&&T?parseInt(T):void 0,leaderType:g==="leader"?Y:void 0});j.issued&&j.hantNumber&&r.success(`축하합니다! 우리 국토를 걷는 회원님의 HANT 등록번호 ${j.hantNumber}가 발급되었습니다 🎉`)}catch{}}catch{}r.success("회원가입 완료! 환영합니다."),n("/")},onError:s=>r.error(s.message||"회원가입 실패")}),J=()=>{if(!c.trim()){r.error("이름을 입력해 주세요");return}if(!h.trim()){r.error("이메일을 입력해 주세요");return}if(U.length<8){r.error("비밀번호는 8자 이상이어야 합니다");return}if(U!==he){r.error("비밀번호가 일치하지 않습니다");return}if(!b.trim()){r.error("전화번호를 입력해 주세요");return}if(!C){r.error("성별을 선택해 주세요");return}if(!f){r.error("생년월일을 입력해 주세요");return}if(!$){r.error("거주지 시/도를 선택해 주세요");return}if(!P.trim()){r.error("거주지 시/êµ°/구를 입력해 주세요");return}if(g==="hg"&&!N){r.error("국토종주단 기수를 입력해 주세요");return}if(g==="group"&&!i.trim()){r.error("단체명을 입력해 주세요");return}if(g==="leader"&&!Y){r.error("인솔자 유형을 선택해 주세요");return}ee.mutate({email:h.trim(),password:U,name:c.trim()})};return e.jsxs("form",{"data-loc":"client/src/pages/Register.tsx:959",autoComplete:"off",onSubmit:s=>{s.preventDefault(),J()},noValidate:!0,children:[e.jsx("input",{"data-loc":"client/src/pages/Register.tsx:960",type:"text",name:"fakeusernameremembered",style:{display:"none"},tabIndex:-1,readOnly:!0}),e.jsx("input",{"data-loc":"client/src/pages/Register.tsx:961",type:"password",name:"fakepasswordremembered",style:{display:"none"},tabIndex:-1,readOnly:!0}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:962",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:964",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:965",className:p,children:["이름 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:965",className:"text-red-400",children:"*"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:966",placeholder:"홍길동",value:c,onChange:s=>u(s.target.value),autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:970",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:971",className:p,children:["전화번호 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:971",className:"text-red-400",children:"*"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:972",type:"tel",inputMode:"tel",placeholder:"010-1234-5678",value:b,onChange:s=>{_(ve(s.target.value)),V(!1)},autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:977",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:978",className:p,children:["HANT 등록번호",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:980",className:"text-white/40 text-xs ml-1",children:"(없으면 가입 후 신청)"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:982",className:"flex gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:983",placeholder:"이름+전화ë²
11ˆí˜¸ 입력 후 발급 버튼 클릭",value:O,onChange:s=>{X(s.target.value.trim()),V(!1)},autoComplete:"off","data-form-type":"other",className:`${d} flex-1`,readOnly:Q&&!!O}),e.jsx(A,{"data-loc":"client/src/pages/Register.tsx:987",type:"button",onClick:async()=>{if(!c.trim()){r.error("이름을 먼저 입력해 주세요");return}if(!b.trim()){r.error("전화번호를 먼저 입력해 주세요");return}try{const s=await de.client.hantReg.lookupByNamePhone.query({name:c.trim(),phoneNumber:b});s.found&&s.hantNumber?(X(s.hantNumber),V(!0),r.success("축하합니다! 우리 국토를 걷는 회원님의 HANT 등록번호가 발급되었습니다 🎉")):(V(!1),r.info("HANT 사전등록자가 아닌 분은 번호가 발급되지 않습니다. 번호 없어도 가입 가능합니다."),ge(!0))}catch{r.error("조회 중 오류가 발생했습니다.")}},className:"bg-[#52b788] text-white hover:bg-[#40916c] shrink-0 text-xs px-3 font-semibold",children:"발급"})]}),Q&&e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:1008",className:"text-green-300 text-xs mt-1",children:"🎉 축하합니다! 우리 국토를 걷는 회원님의 HANT 등록번호가 발급되었습니다."}),!Q&&!O&&e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:1011",className:"text-white/40 text-xs",children:"이름과 전화번호 입력 후 발급 버튼을 누르세요."})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1015",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1016",className:p,children:["이메일 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1016",className:"text-red-400",children:"*"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1017",type:"text",inputMode:"email",placeholder:"[email protected]",value:h,onChange:s=>E(s.target.value),autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1022",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1023",className:p,children:["비밀번호 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1023",className:"text-red-400",children:"*"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1024",className:"relative",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1025",type:z?"text":"password",placeholder:"8자 이상",value:U,onChange:s=>pe(s.target.value),autoComplete:"new-password","data-form-type":"other",className:`${d} pr-10`}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1029",type:"button",onClick:()=>be(!z),className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/50",children:z?e.jsx(ie,{"data-loc":"client/src/pages/Register.tsx:1031",size:16}):e.jsx(le,{"data-loc":"client/src/pages/Register.tsx:1031",size:16})})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1035",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1036",className:p,children:["비밀번호 확인 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1036",className:"text-red-400",children:"*"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1037",type:"password",placeholder:"비밀번호 재입력",value:he,onChange:s=>oe(s.target.value),autoComplete:"new-password","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1042",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1043",className:p,children:["성별 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1043",className:"text-red-400",children:"*"})]}),e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:1044",className:"flex gap-2",children:[{v:"male",l:"남성"},{v:"female",l:"여성"}].map(({v:s,l:j})=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1046",type:"button",onClick:()=>w(s),className:`flex-1 py-2 rounded-lg text-sm font-medium border transition-colors ${C===s?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:j},s))})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1054",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1055",className:p,children:["생년월일 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1055",className:"text-red-400",children:"*"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1056",className:"flex gap-2",children:[e.jsxs(te,{"data-loc":"client/src/pages/Register.tsx:1057",value:R,onValueChange:s=>{D(s),H(`${s}-${k||"01"}-${v||"01"}`)},children:[e.jsx(se,{"data-loc":"client/src/pages/Register.tsx:1058",className:"flex-1 bg-white/10 border-white/20 text-white",children:e.jsx(ae,{"data-loc":"client/src/pages/Register.tsx:1059",placeholder:"연도"})}),e.jsx(re,{"data-loc":"client/src/pages/Register.tsx:1061",className:"max-h-60",children:Array.from({length:new Date().getFullYear()-1919},(s,j)=>String(new Date().getFullYear()-j)).map(s=>e.jsxs(ce,{"data-loc":"client/src/pages/Register.tsx:1063",value:s,children:[s,"년"]},s))})]}),e.jsxs(te,{"data-loc":"client/src/pages/Register.tsx:1067",value:k,onValueChange:s=>{F(s),H(`${R||"2000"}-${s}-${v||"01"}`)},children:[e.jsx(se,{"data-loc":"client/src/pages/Register.tsx:1068",className:"w-20 bg-white/10 border-white/20 text-white",children:e.jsx(ae,{"data-loc":"client/src/pages/Register.tsx:1069",placeholder:"월"})}),e.jsx(re,{"data-loc":"client/src/pages/Register.tsx:1071",children:Array.from({length:12},(s,j)=>String(j+1).padStart(2,"0")).map(s=>e.jsxs(ce,{"data-loc":"client/src/pages/Register.tsx:1073",value:s,children:[s,"월"]},s))})]}),e.jsxs(te,{"data-loc":"client/src/pages/Register.tsx:1077",value:v,onValueChange:s=>{L(s),H(`${R||"2000"}-${k||"01"}-${s}`)},children:[e.jsx(se,{"data-loc":"client/src/pages/Register.tsx:1078",className:"w-20 bg-white/10 border-white/20 text-white",children:e.jsx(ae,{"data-loc":"client/src/pages/Register.tsx:1079",placeholder:"일"})}),e.jsx(re,{"data-loc":"client/src/pages/Register.tsx:1081",children:Array.from({length:31},(s,j)=>String(j+1).padStart(2,"0")).map(s=>e.jsxs(ce,{"data-loc":"client/src/pages/Register.tsx:1083",value:s,children:[s,"일"]},s))})]})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1090",className:"space-y-1.5",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1091",className:p,children:["거주지 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1091",className:"text-red-400",children:"*"})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1092",className:"flex gap-2",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1093",className:"relative flex-1",children:[e.jsxs("select",{"data-loc":"client/src/pages/Register.tsx:1094",value:$,onChange:s=>B(s.target.value),className:"w-full appearance-none bg-white/10 border border-white/20 text-white rounded-md px-3 py-2 text-sm focus:outline-none focus:ring-1 focus:ring-primary pr-8",children:[e.jsx("option",{"data-loc":"client/src/pages/Register.tsx:1096",value:"",className:"bg-[#1a4a2e]",children:"시/도 선택"}),Te.map(s=>e.jsx("option",{"data-loc":"client/src/pages/Register.tsx:1097",value:s,className:"bg-[#1a4a2e]",children:s},s))]}),e.jsx(ke,{"data-loc":"client/src/pages/Register.tsx:1099",size:14,className:"absolute right-2 top-1/2 -translate-y-1/2 text-white/50 pointer-events-none"})]}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1101",placeholder:"시/êµ°/구",value:P,onChange:s=>q(s.target.value),className:`${d} flex-1`})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1106",className:"space-y-1.5",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1107",className:"flex items-center justify-between",children:[e.jsxs(x,{"data-loc":"client/src/pages/Register.tsx:1108",className:p,children:["소속 ",e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1108",className:"text-red-400",children:"*"})]}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1109",className:"text-white/40 text-xs",children:"나중에 변경 가능합니다"})]}),e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:1111",className:"flex gap-2",children:["hant","general"].map(s=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1113",type:"button",onClick:()=>{G(s),M(s==="hant"?"hg":"personal")},className:`flex-1 py-2 rounded-lg text-sm font-semibold border transition-colors ${m===s?"bg-white text-[#1a4a2e] border-white":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:s==="hant"?"HANT":"일반 사용자"},s))}),m==="hant"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1123",className:"space-y-1.5 mt-1",children:[e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:1124",className:"flex gap-1.5 flex-wrap",children:["hg","personal","group","leader"].map(s=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1126",type:"button",onClick:()=>M(s),className:`flex-1 min-w-[4rem] py-1.5 rounded-lg text-xs font-medium border transition-colors ${g===s?"bg-[#52b788] text-white border-[#52b788]":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:s==="hg"?"국토종주단":s==="personal"?"개인":s==="group"?"단체":"인솔자"},s))}),g==="hg"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1135",className:"flex items-center gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1136",type:"number",inputMode:"numeric",placeholder:"기수 (1, 2, 3...)",value:N,onChange:s=>I(s.target.value.replace(/[^0-9]/g,"")),className:`${d} flex-1`}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1139",className:"text-white/60 text-sm shrink-0",children:"기"})]}),g==="personal"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1143",className:"flex items-center gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1144",type:"number",inputMode:"numeric",placeholder:"동료 수 (선택)",value:T,onChange:s=>fe(s.target.value.replace(/[^0-9]/g,"")),className:`${d} flex-1`}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1147",className:"text-white/60 text-sm shrink-0",children:"명"})]}),g==="group"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1151",className:"space-y-1.5",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1152",placeholder:"단체명 입력",value:i,onChange:s=>K(s.target.value),className:d}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1153",className:"flex items-center gap-2",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1154",type:"number",inputMode:"numeric",placeholder:"인원수 (선택)",value:l,onCh
11ange:s=>ne(s.target.value.replace(/[^0-9]/g,"")),className:`${d} flex-1`}),e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1157",className:"text-white/60 text-sm shrink-0",children:"명"})]})]}),g==="leader"&&e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:1162",className:"flex gap-1.5",children:["association","external"].map(s=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1164",type:"button",onClick:()=>xe(s),className:`flex-1 py-1.5 rounded-lg text-xs font-medium border transition-colors ${Y===s?"bg-[#52b788] text-white border-[#52b788]":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:s==="association"?"협회 인솔자":"외부 인솔자"},s))})]}),m==="general"&&e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:1176",className:"flex gap-1.5 mt-1",children:["personal","cyclist"].map(s=>e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1178",type:"button",onClick:()=>M(s),className:`flex-1 py-1.5 rounded-lg text-xs font-medium border transition-colors ${g===s?"bg-[#52b788] text-white border-[#52b788]":"bg-transparent text-white/60 border-white/20 hover:border-white/40"}`,children:s==="personal"?"일반 사용자":"자전거여행자"},s))})]}),e.jsxs("p",{"data-loc":"client/src/pages/Register.tsx:1188",className:"text-white/50 text-xs text-center mt-2",children:["회원가입 시"," ",e.jsx("a",{"data-loc":"client/src/pages/Register.tsx:1190",href:"/privacy",target:"_blank",rel:"noopener noreferrer",className:"underline text-white/70 hover:text-white",children:"개인정보처리방침"}),"에 동의하는 것으로 간주됩니다."]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:1195",type:"submit",className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base mt-1",disabled:ee.isPending,children:[ee.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:1197",size:16,className:"animate-spin mr-2"}):e.jsx($e,{"data-loc":"client/src/pages/Register.tsx:1197",size:16,className:"mr-2"}),"회원가입 완료"]})]})]})}function Qe({navigate:n}){const[c,u]=a.useState(""),[h,E]=a.useState(""),[b,_]=a.useState(!1),[C,w]=a.useState("login"),[f,H]=a.useState("email"),[R,D]=a.useState(""),[k,F]=a.useState(""),[v,L]=a.useState(""),[$,B]=a.useState(""),[P,q]=a.useState(!1),[m,G]=a.useState(""),g=y.auth.loginEmail.useMutation({onSuccess:l=>{ue(l.token,l.expires),r.success("로그인 성공!");const ne=typeof window<"u"&&(window.location.hostname.includes("hantp.com")||window.location.hostname.includes("manus.space")),T=We();ne?setTimeout(()=>{window.location.href=T},800):n(T)},onError:l=>r.error(l.message||"로그인 실패")}),M=y.auth.sendPasswordResetByEmail.useMutation({onSuccess:l=>{G(l.maskedPhone||""),w("forgot_code"),r.success(`등록된 전화번호(${l.maskedPhone})로 인증번호를 발송했습니다`)},onError:l=>r.error(l.message||"인증번호 발송 실패")}),N=y.auth.sendPasswordResetByPhone.useMutation({onSuccess:()=>{w("forgot_code"),r.success("인증번호를 발송했습니다")},onError:l=>r.error(l.message||"인증번호 발송 실패")}),I=y.auth.resetPasswordWithSms.useMutation({onSuccess:()=>{r.success("비밀번호가 변경되었습니다. 새 비밀번호로 로그인해주세요"),w("login"),D(""),F(""),L(""),B("")},onError:l=>r.error(l.message||"비밀번호 변경 실패")}),i=()=>
11{if(!R.trim()){r.error(f==="email"?"이메일을 입력해주세요":"전화번호를 입력해주세요");return}f==="email"?M.mutate({email:R.trim()}):N.mutate({phoneNumber:R.trim()})},K=()=>{if(k.length!==6){r.error("인증번호 6자리를 입력해주세요");return}if(v.length<8){r.error("비밀번호는 8자 이상이어야 합니다");return}if(v!==$){r.error("비밀번호가 일치하지 않습니다");return}I.mutate({identifier:R.trim(),identifierType:f,code:k,newPassword:v})};return C!=="login"?e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1251",className:"space-y-3",children:[e.jsx("div",{"data-loc":"client/src/pages/Register.tsx:1252",className:"flex items-center gap-2 mb-1",children:e.jsxs("button",{"data-loc":"client/src/pages/Register.tsx:1253",type:"button",onClick:()=>w("login"),className:"text-white/60 hover:text-white text-sm flex items-center gap-1",children:[e.jsx("span",{"data-loc":"client/src/pages/Register.tsx:1254",children:"←"})," 로그인으로 돌아가기"]})}),e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:1257",className:"text-white font-semibold text-base",children:"비밀번호 찾기"}),C==="forgot_select"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1260",className:"space-y-3",children:[e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:1261",className:"text-white/70 text-sm",children:"본인 확인 방법을 선택해주세요"}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1262",type:"button",onClick:()=>{H("email"),w("forgot_input")},className:"w-full h-12 rounded-lg border border-white/30 text-white text-sm font-medium hover:bg-white/10 transition-colors",children:"이메일로 찾기"}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1266",type:"button",onClick:()=>{H("phone"),w("forgot_input")},className:"w-full h-12 rounded-lg border border-white/30 text-white text-sm font-medium hover:bg-white/10 transition-colors",children:"전화번호로 찾기"})]}),C==="forgot_input"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1274",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1275",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:1276",className:p,children:f==="email"?"가입 시 사용한 이메일":"가입 시 등록한 전화번호"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1277",type:f==="email"?"email":"tel",inputMode:f==="email"?"email":"tel",placeholder:f==="email"?"[email protected]":"01012345678",value:R,onChange:l=>D(l.target.value),autoComplete:"off","data-form-type":"other",className:d})]}),f==="email"&&e.jsx("p",{"data-loc":"client/src/pages/Register.tsx:1283",className:"text-white/50 text-xs",children:"가입 시 등록한 전화번호로 인증번호가 발송됩니다"}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:1284",type:"button",onClick:i,className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base",disabled:M.isPending||N.isPending,children:[M.isPending||N.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:1286",size:16,className:"animate-spin mr-2"}):null,"인증번호 받기"]})]}),C==="forgot_code"&&e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1293",className:"space-y-3",children:[m&&e.jsxs("p",{"data-loc":"client/src/pages/Register.tsx:1294",className:"text-white/70 text-sm",children:[m,"으로 인증번호를 발송했습니다"]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1295",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:1296",className:p,children:"인증번호 (6자리)"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1297",type:"text",inputMode:"numeric",placeholder:"123456",maxLength:6,value:k,onChange:l=>F(l.target.value.replace(/[^0-9]/g,"").slice(0,6)),autoComplete:"one-time-code","data-form-type":"other",className:`${d} text-center text-lg tracking-widest`})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1302",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:1303",className:p,children:"새 비밀번호 (8자 이상)"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1304",className:"relative",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1305",type:P?"text":"password",placeholder:"새 비밀번호",value:v,onCh
11ange:l=>L(l.target.value),autoComplete:"new-password","data-form-type":"other",className:`${d} pr-10`}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1308",type:"button",onClick:()=>q(!P),className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/50",children:P?e.jsx(ie,{"data-loc":"client/src/pages/Register.tsx:1310",size:16}):e.jsx(le,{"data-loc":"client/src/pages/Register.tsx:1310",size:16})})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1314",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:1315",className:p,children:"새 비밀번호 확인"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1316",type:"password",placeholder:"비밀번호 재입력",value:$,onChange:l=>B(l.target.value),autoComplete:"new-password","data-form-type":"other",className:d})]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:1320",type:"button",onClick:K,className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base",disabled:I.isPending,children:[I.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:1322",size:16,className:"animate-spin mr-2"}):null,"비밀번호 변경"]}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1325",type:"button",onClick:i,className:"w-full text-white/50 text-xs text-center py-1",disabled:M.isPending||N.isPending,children:"인증번호 재발송"})]})]}):e.jsxs("form",{"data-loc":"client/src/pages/Register.tsx:1336",autoComplete:"off",onSubmit:l=>{l.preventDefault(),g.mutate({email:c.trim(),password:h})},noValidate:!0,children:[e.jsx("input",{"data-loc":"client/src/pages/Register.tsx:1337",type:"text",name:"fakeusernameremembered",style:{display:"none"},tabIndex:-1,readOnly:!0}),e.jsx("input",{"data-loc":"client/src/pages/Register.tsx:1338",type:"password",name:"fakepasswordremembered",style:{display:"none"},tabIndex:-1,readOnly:!0}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1339",className:"space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1340",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:1341",className:p,children:"이메일"}),e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1342",type:"text",inputMode:"email",placeholder:"[email protected]",value:c,onChange:l=>u(l.target.value),autoComplete:"off","data-form-type":"other",className:d})]}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1346",className:"space-y-1.5",children:[e.jsx(x,{"data-loc":"client/src/pages/Register.tsx:1347",className:p,children:"비밀번호"}),e.jsxs("div",{"data-loc":"client/src/pages/Register.tsx:1348",className:"relative",children:[e.jsx(o,{"data-loc":"client/src/pages/Register.tsx:1349",type:b?"text":"password",placeholder:"비밀번호",value:h,onChange:l=>E(l.target.value),autoComplete:"current-password","data-form-type":"other",className:`${d} pr-10`}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1353",type:"button",onClick:()=>_(!b),className:"absolute right-3 top-1/2 -translate-y-1/2 text-white/50",children:b?e.jsx(ie,{"data-loc":"client/src/pages/Register.tsx:1355",size:16}):e.jsx(le,{"data-loc":"client/src/pages/Register.tsx:1355",size:16})})]})]}),e.jsxs(A,{"data-loc":"client/src/pages/Register.tsx:1359",type:"submit",className:"w-full h-12 bg-white text-[#1a4a2e] hover:bg-white/90 font-bold text-base mt-1",disabled:g.isPending,children:[g.isPending?e.jsx(W,{"data-loc":"client/src/pages/Register.tsx:1361",size:16,className:"animate-spin mr-2"}):e.jsx(Pe,{"data-loc":"client/src/pages/Register.tsx:1361",size:16,className:"mr-2"}),"로그인"]}),e.jsx("button",{"data-loc":"client/src/pages/Register.tsx:1364",type:"button",onClick:()=>w("forgot_select"),className:"w-full text-white/50 text-xs text-center py-1 hover:text-white/80 transition-colors",children:"비밀번호를 잊으셨나요?"})]})]})}export{bt as clearPendingProfile,wt as default,ft as loadPendingProfile,ut as savePendingProfile};

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.