1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2298],{3095:(e,t,n)=>{n.d(t,{eG:()=>i,y1:()=>r});let a=BigInt(0),l=BigInt(36);function s(e){if(e<=a)return"0";let t="",n=e;for(;n>a;)t="0123456789abcdefghijklmnopqrstuvwxyz"[Number(n%l)]+t,n/=l;return t}function r(e,t){let n=s(BigInt(Math.floor(t)));return e.startsWith("region:")?`g${s(BigInt(e.slice(7)))}-${n}`:`${s(BigInt(e))}-${n}`}function i(e,t){return`/r/${r(e,t)}`}},42298:(e,t,n)=>{n.d(t,{ProfileClient:()=>m});var a=n(95155),l=n(98500),s=n.n(l),r=n(12115),i=n(86644),o=n(66685),c=n(80514),d=n(3095);let p=e=>{let t=Math.max(1,Math.floor((Date.now()-e)/1e3));return t<60?`${t}ì´ ì `:t<3600?`${Math.floor(t/60)}ë¶ ì `:t<86400?`${Math.floor(t/3600)}ìê° ì `:t<2592e3?`${Math.floor(t/86400)}ì¼ ì `:new Date(e).toLocaleDateString("ko-KR",{year:"2-digit",month:"2-digit",day:"2-digit"})};function x({userId:e,nickname:t}){let[n,l]=(0,r.useState)(!1);return n?(0,a.jsx)("div",{className:"flex h-[72px] w-[72px] shrink-0 items-center justify-center rounded-full border border-line text-2xl font-semibold text-graphite",children:t.slice(0,1)}):(0,a.jsx)("img",{src:`/api/avatar/${e}`,alt:"",onError:()=>l(!0),className:"h-[72px] w-[72px] shrink-0 rounded-full border border-line object-cover"})}function h({className:e="h-3 w-3"}){return(0,a.jsxs)("svg",{viewBox:"0 0 24 24",className:e,fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[(0,a.jsx)("path",{d:"M9 4 h6 l-1 6 3 3 v1 H7 v-1 l3-3 Z"}),(0,a.jsx)("path",{d:"M12 14 v6"})]})}let u=[{key:"talks",label:"Talks"},{key:"comments",label:"ëµê¸"},{key:"reports",label:"리í¬í¸"},{key:"reposts",label:"리í¬ì¤í¸"}];function m({userId:e,embed:t=!1,onOpenTalk:n,onOpenReport:l}){let s,[j,y]=(0,r.useState)(null),[N,w]=(0,r.useState)(null),[_,v]=(0,r.useState)("talks"),[$,C]=(0,r.useState)(!1),[S,L]=(0,r.useState)(!1),[F,M]=(0,r.useState)(""),[T,R]=(0,r.useState)(""),D=(0,r.useCallback)(async()=>{if(!e)return void w("ì못ë íë¡í 주ììì.");let t=await fetch(`/api/profile/${e}`).catch(()=>null);t?.ok?y(await t.json()):w(t?.status===404?"ì¡´ì¬íì§ ìë ì¬ì©ììì.":"ë¶ë¬ì¤ì§ 못íì´ì.")},[e]);(0,r.useEffect)(()=>{D()},[D]);let I=async()=>{if(j&&null!==j.isFollowing&&!$){C(!0);try{let t=await fetch("/api/profile/follow",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({user_id:e,follow:!j.isFollowing})}).then(e=>e.ok?e.json():null);t&&y(e=>e&&{...e,isFollowing:t.following,user:{...e.user,follower_count:t.follower_count}})}finally{C(!1)}}},B=async()=>{if(!$){C(!0);try{let e=T.split(",").map(e=>e.trim()).filter(Boolean);(await fetch("/api/profile/me",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({bio:F,tags:e})})).ok&&(L(!1),await D())}finally{C(!1)}}},K=async e=>{if(j&&!$){C(!0);try{let t=j.user.pinned_talk_id===e?null:e;(await fetch("/api/caketalk/pin",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({talk_id:t})})).ok&&await D()}finally{C(!1)}}},O=t?g:b,q=l&&((e,t)=>()=>l(e,t));if(N)return(0,a.jsx)(O,{children:(0,a.jsx)("p",{className:"py-16 text-center text-sm text-graphite",children:N})});if(!j)return(0,a.jsx)(O,{children:(0,a.jsx)("p",{className:"py-16 text-center text-sm text-graphite",children:"ë¶ë¬ì¤ë ì¤â¦"})});let{user:E}=j,P=(e,l=!1)=>(0,a.jsx)("li",{className:"border-b border-line",children:(0,a.jsxs)("div",{className:"flex flex-col gap-1.5 rounded-sm px-2 py-3 transition hover:bg-white",children:[l&&(0,a.jsxs)("p",{className:"flex items-center gap-1 font-mono text-[11px] uppercase tracking-wide",style:{color:i.Lx},children:[(0,a.jsx)(h,{className:"h-3 w-3"})," ê³ ì ë¨"]}),t&&n?(0,a.jsx)("button",{type:"button",onClick:()=>n(e.talk_id),className:"block text-left",children:(0,a.jsx)("p",{className:"line-clamp-4 whitespace-pre-wrap break-keep text-[14px] leading-relaxed text-ink",children:e.body})}):(0,a.jsx)("a",{href:`/talk/${e.talk_id}`,className:"block",children:(0,a.jsx)("p",{className:"line-clamp-4 whitespace-pre-wrap break-keep text-[14px] leading-relaxed text-ink",children:e.body})}),(e.parcels?.length??0)>0&&(0,a.jsxs)("p",{className:"truncate font-mono text-[11px] text-gra
1phite",children:["â ",e.parcels.map(e=>e.addr).join(" \xb7 ")]}),(0,a.jsxs)("div",{className:"flex items-center gap-3 font-mono text-[11px] text-graphite tabular-nums",children:[(0,a.jsx)("span",{children:p(e.created_at)}),(0,a.jsxs)("span",{children:["\uD83D\uDC4D",e.up_count??0]}),(0,a.jsxs)("span",{children:["ëê¸ ",e.comment_count]}),(0,a.jsxs)("span",{children:["리í¬ì¤í¸ ",e.repost_count??0]}),j.isSelf&&(0,a.jsxs)("button",{type:"button",onClick:()=>void K(e.talk_id),className:"ml-auto flex items-center gap-1 text-[11px] text-graphite transition hover:text-ink",title:E.pinned_talk_id===e.talk_id?"ê³ ì í´ì ":"íë¡í ìë¨ ê³ ì ",children:[(0,a.jsx)(h,{className:"h-3 w-3"})," ",E.pinned_talk_id===e.talk_id?"ê³ ì í´ì ":"ê³ ì "]})]})]})},e.talk_id);return(0,a.jsxs)(O,{children:[(0,a.jsxs)("div",{className:"flex items-start justify-between gap-4 pt-6",children:[(0,a.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,a.jsx)("h1",{className:"truncate text-[24px] font-semibold leading-tight text-ink",children:E.nickname}),(0,a.jsxs)("p",{className:"mt-0.5 font-mono text-[12px] text-graphite",children:["TALK",Number.isFinite(E.created_at)&&E.created_at>0?` \xb7 since ${new Date(E.created_at).toLocaleDateString("ko-KR",{year:"numeric",month:"2-digit"})}`:""]}),E.bio&&(0,a.jsx)("p",{className:"mt-3 whitespace-pre-wrap break-keep text-[14px] leading-relaxed text-ink",children:E.bio}),E.tags.length>0&&(0,a.jsx)("div",{className:"mt-2.5 flex flex-wrap gap-1.5",children:E.tags.map(e=>(0,a.jsx)("span",{className:"rounded-full border border-line px-2.5 py-0.5 text-[12px]",style:{color:i.Lx},children:e},e))}),(0,a.jsxs)("p",{className:"mt-3 text-[13px] text-graphite",children:["íë¡ì ",(0,a.jsxs)("span",{className:"font-medium text-ink",children:[(s=E.follower_count)>=1e4?`${(s/1e4).toFixed(s>=1e5?0:1)}ë§`:`${s}`,"ëª
"]}),(0,a.jsx)("span",{className:"mx-1.5",children:"\xb7"}),"ê³µê° ë¦¬í¬í¸ ",j.reports.length,"ê±´"]})]}),(0,a.jsx)(x,{userId:E.user_id,nickname:E.nickname})]}),(0,a.jsx)("div",{className:"mt-4 flex gap-2",children:j.isSelf?(0,a.jsx)("button",{type:"button",onClick:()=>{L(e=>!e),M(E.bio??""),R(E.tags.join(", "))},className:"flex-1 rounded-sm border border-line py-2 text-[14px] text-ink transition hover:bg-panel",children:S?"í¸ì§ ë«ê¸°":"íë¡í í¸ì§"}):null!==j.isFollowing?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("button",{type:"button",onClick:()=>void I(),disabled:$,className:`flex-1 rounded-sm py-2 text-[14px] font-medium transition disabled:opacity-40 ${j.isFollowing?"border border-line text-gra
1phite hover:text-ink":"text-paper"}`,style:j.isFollowing?void 0:{backgroundColor:"#1a1a1a"},children:j.isFollowing?"íë¡ì":"íë¡ì°"}),(0,a.jsx)("a",{href:`/messages?to=${encodeURIComponent(E.user_id)}&nick=${encodeURIComponent(E.nickname)}`,className:"flex-1 rounded-sm border border-line py-2 text-center text-[14px] text-ink transition hover:bg-panel",children:"ë©ìì§ ë³´ë´ê¸°"})]}):(0,a.jsx)("a",{href:"/signin",className:"flex-1 rounded-sm border border-line py-2 text-center text-[14px] text-graphite transition hover:text-ink",children:"ë¡ê·¸ì¸íê³ íë¡ì°"})}),S&&j.isSelf&&(0,a.jsxs)("div",{className:"mt-3 flex flex-col gap-2 rounded-sm border border-line p-3",children:[(0,a.jsx)("label",{className:"text-[12px] text-graphite",children:"ì기ìê° (200ì)"}),(0,a.jsx)("textarea",{value:F,onChange:e=>M(e.target.value),rows:3,maxLength:200,className:"resize-none rounded-sm border border-line bg-paper px-2.5 py-2 text-[14px] text-ink outline-none focus:border-graphite",placeholder:"ì´ë¤ ë¶ëì° ì´ì¼ê¸°ë¥¼ ë¤ë£¨ëì?"}),(0,a.jsx)("label",{className:"text-[12px] text-graphite",children:"ë¤ë£¨ë ì í íê·¸: ì¼íë¡ êµ¬ë¶ (ìµë 5ê° \xb7 ì: ì¬ê±´ì¶, ìê°, ì¬ìë)"}),(0,a.jsx)("input",{value:T,onChange:e=>R(e.target.value),className:"rounded-sm border border-line bg-paper px-2.5 py-2 text-[14px] text-ink outline-none focus:border-graphite",placeholder:"ì¬ê±´ì¶, ì²ì½, ìê¶ë¶ì"}),(0,a.jsx)("button",{type:"button",onClick:()=>void B(),disabled:$,className:"self-end rounded-sm px-4 py-1.5 text-[13px] font-medium text-paper transition disabled:opacity-40",style:{backgroundColor:i.Lx},children:"ì ì¥"})]}),(0,a.jsx)("div",{className:"mt-6 grid grid-cols-4 border-b border-line font-mono text-[12px] uppercase tracking-wide",children:u.map(e=>(0,a.jsx)("button",{type:"button",onClick:()=>v(e.key),className:`pb-2 text-center transition ${_===e.key?"border-b-2 border-ink font-medium text-ink":"text-graphite hover:text-ink"}`,children:e.label},e.key))}),"talks"===_&&(0,a.jsxs)("ul",{children:[j.pinned&&P(j.pinned,!0),j.talks.map(e=>P(e)),!j.pinned&&0===j.talks.length&&(0,a.jsx)(k,{children:"ìì§ ì¬ë¦° í¡ì´ ìì´ì."})]}),"comments"===_&&(0,a.jsxs)("ul",{children:[j.comments.map(e=>(0,a.jsx)("li",{className:"border-b border-line",children:(0,a.jsxs)(f,{embed:t,onClick:()=>n?.(e.talk_id),href:`/talk/${e.talk_id}`,children:[(0,a.jsxs)("p",{className:"whitespace-pre-wrap break-keep text-[14px] leading-relaxed text-ink",children:[e.reply_to&&(0,a.jsxs)("span",{className:"mr-1 font-medium",style:{color:i.Lx},children:["@",e.reply_to]}),e.body]}),e.talk_preview&&(0,a.jsxs)("p",{className:"mt-1 truncate text-[12px] text-graphite",children:["â³ ",e.talk_preview]}),(0,a.jsxs)("p",{className:"mt-1 font-mono text-[11px] text-graphite tabular-nums",children:[p(e.created_at)," \xb7 \uD83D\uDC4D",e.up_count??0]})]})},e.comment_id)),0===j.comments.length&&(0,a.jsx)(k,{children:"ìì§ ë¨ê¸´ ëµê¸ì´ ìì´ì."})]}),"reports"===_&&(0,a.jsxs)("ul",{children:[j.reports.map(e=>(0,a.jsx)("li",{className:"border-b border-line",children:(0,a.jsx)(o.V,{model:(0,c.yV)({reportTitle:e.report_title,question:e.preview,dateMs:e.created_at,starCount:e.star_count,upCount:e.up_count,commentCount:e.comment_count}),href:(0,d.eG)(e.pnu,e.created_at),onOpen:q?.(e.pnu,e.created_at)})},`${e.pnu}-${e.created_at}`)),0===j.reports.length&&(0,a.jsx)(k,{children:"ìì§ ê³µê°í 리í¬í¸ê° ìì´ì."})]}),"reposts"===_&&(0,a.jsxs)("ul",{children:[j.reposts.map(e=>(0,a.jsx)("li",{className:"border-b border-line",children:(0,a.jsxs)(f,{embed:t,onClick:()=>n?.(e.talk.talk_id),href:`/talk/${e.talk.talk_id}`,children:[(0,a.jsxs)("p",{className:"font-mono text-[11px] text-graphite",children:["â³ ",p(e.reposted_at)," 리í¬ì¤í¸ \xb7 ìê¸ ",e.talk.author_nickname]}),(0,a.jsx)("p",{className:"mt-1 line-clamp-3 whitespace-pre-wrap break-keep text-[14px] leading-relaxed text-ink",children:e.talk.body}),(0,a.jsxs)("p",{className:"mt-1 font-mono text-[11px] text-graphite tabular-nums",children:["\uD83D\uDC4D",e.talk.up_count??0," \xb7 ëê¸ ",e.talk.comment_count]})]})},`${e.talk.talk_id}-${e.reposted_at}`)),0===j.reposts.length&&(0,a.jsx)(k,{children:"ìì§ ë¦¬í¬ì¤í¸ê° ìì´ì."})]})]})}function g({children:e}){return(0,a.jsx)("div",{className:"scrollbar-thin min-h-0 flex-1 overflow-y-auto px-3 pb-20",children:e})}function b({children:e}){return(0,a.jsxs)("div",{className:"min-h-dvh bg-paper",children:[(0,a.jsx)("header",{className:"border-b border-line bg-white",children:(0,a.jsx)("div",{className:"mx-auto flex h-12 max-w-xl items-center gap-3 px-4",children:(0,a.jsx)(s(),{href:"/",className:"text-[14px] text-gra
1phite transition hover:text-ink",children:"â TALK"})})}),(0,a.jsx)("main",{className:"mx-auto max-w-xl px-4 pb-24",children:e})]})}function f({embed:e,onClick:t,href:n,children:l}){return e?(0,a.jsx)("button",{type:"button",onClick:t,className:"block w-full rounded-sm px-2 py-3 text-left transition hover:bg-white",children:l}):(0,a.jsx)("a",{href:n,className:"block rounded-sm px-2 py-3 transition hover:bg-white",children:l})}function k({children:e}){return(0,a.jsx)("li",{className:"py-10 text-center text-[13px] text-graphite",children:e})}},66685:(e,t,n)=>{n.d(t,{V:()=>s});var a=n(95155),l=n(86644);function s({model:e,selected:t=!1,href:n,onOpen:r,leading:i,trailing:o,compact:c=!1}){let d=c?"line-clamp-1":"line-clamp-2",p=(0,a.jsxs)(a.Fragment,{children:[!c&&(e.target||e.targetRight)&&(0,a.jsxs)("span",{className:"flex items-baseline gap-2 font-mono text-[11px] leading-snug text-graphite",children:[e.target&&(0,a.jsx)("span",{className:"min-w-0 truncate",children:e.target}),e.targetRight&&(0,a.jsx)("span",{className:"ml-auto max-w-[50%] shrink-0 truncate",children:e.targetRight})]}),(0,a.jsx)("span",{className:`${d} text-[14px] leading-snug break-keep ${e.headline?"font-semibold text-ink":"text-graphite"}`,children:e.headline??e.statusLabel}),e.question&&(0,a.jsx)("span",{className:`${d} text-[13px] leading-snug text-ink/80 break-keep`,children:e.question}),(0,a.jsxs)("span",{className:"flex flex-wrap items-center gap-x-1.5 font-mono text-[12px] leading-snug text-graphite tabular-nums",children:[(0,a.jsx)("span",{children:e.date}),e.badges.map((e,t)=>(0,a.jsx)("span",{className:e.accent?"font-medium":"",style:e.accent?{color:l.Lx}:void 0,children:e.text},`${e.text}-${t}`)),e.engagement&&(0,a.jsx)("span",{children:e.engagement})]})]}),x=`flex min-w-0 flex-1 flex-col ${c?"gap-0 py-1.5":"gap-0.5 py-2"} pr-3 text-left no-underline ${i?"pl-1.5":"pl-3"}`,h=e=>{!r||n&&(e.metaKey||e.ctrlKey||e.shiftKey)||(n&&e.preventDefault(),r())};return(0,a.jsxs)("div",{className:`group flex items-stretch transition hover:bg-white ${t?"bg-white shadow-[inset_2px_0_0_#C25E40]":""}`,children:[i,n?(0,a.jsx)("a",{href:n,onClick:h,className:x,children:p}):(0,a.jsx)("button",{type:"button",onClick:h,className:x,children:p}),o]})}},80514:(e,t,n)=>{function a(e){let t=new Date(e);return`${String(t.getFullYear()).slice(2)}.${String(t.getMonth()+1).padStart(2,"0")}.${String(t.getDate()).padStart(2,"0")}`}function l(e){let t=e.pnu.startsWith("region:")?"ê´ì":"ëìì§ë²",n=(e.repCount??0)-1;return`${t}${e.addr?` : ${e.addr}`:""}${n>0?` ì¸ ${n}ê³³`:""}`}function s(e,t){return e?"ë´ ë¦¬í¬í¸":t||null}function r(e){let t,n="session"===e.kind?"none":"completed",l=e.noReport?"none":e.outcome??n,s=e.customTitle?.trim()||null,r=e.reportTitle?.trim()||null,i=e.question?.trim()||null,o=i&&"(ì§ë¬¸ ìì)"!==i?i:null,c=s??("completed"===l?r??o:null),d=(t=[],e.mine&&t.push({text:"ë´ ë¦¬í¬í¸"}),e.shared&&t.push({text:"ê³µì ",accent:!0}),"public"===e.publish?t.push({text:"ê³µê°",accent:!0}):"teaser"===e.publish?t.push({text:"í°ì ",accent:!0}):"private"===e.publish&&e.mine&&t.push({text:"ë¹ê³µê°"}),t);return c&&"failed"===l&&d.push({text:"ìì± ì¤í¨",accent:!0}),c&&"cancelled"===l&&d.push({text:"ì¤ë¨"}),{target:e.target?.trim()||null,targetRight:e.targetRight?.trim()||null,headline:c,statusLabel:c?null:"running"===l?"(리í¬í¸ ìì
ì¤)":"failed"===l?"(ìì± ì¤í¨)":"cancelled"===l?"(ì¤ë¨)":"(리í¬í¸ 미ìì±)",question:o&&o!==c?o:null,date:a(e.dateMs),badges:d,engagement:function(e=0,t=0,n=0){let a=[];return e>0&&a.push(`â
${e}`),t>0&&a.push(`ì¶ì² ${t}`),n>0&&a.push(`ëê¸ ${n}`),a.join(" \xb7 ")}(e.starCount,e.upCount,e.commentCount)}}n.d(t,{$r:()=>l,Yi:()=>a,tM:()=>s,yV:()=>r})}}]);
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.