PageSourceSearch

https://reim.kr/_next/static/chunks/9424a9c9ad5b6da6.js?dpl=dpl_BEs1s7UCL1GNSGM8mxj4MxXSqbB4

js reim.kr collected 2026-09-24 15:05:08 UTC 29,570 bytes, 3 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,351930,e=>{"use strict";var t=e.i(290627);function l(e){let t=String(e||"").trim();if(!t)return null;if(t.includes("/")){let e=t.split(/\s*\/\s*/).map(e=>e.trim()).filter(Boolean);return e.length?{kind:"soloPack",names:e}:null}if(/\s[-–—]\s/.test(t)){let e=t.split(/\s[-–—]\s/).map(e=>e.trim()).filter(Boolean);return e.length?{kind:"link",names:e}:null}return{kind:"link",names:[t]}}function i(e){return String(e||"").split(/\r?\n/).map(l).filter(Boolean)}function r(e,l){let i=[],r=[],a=0,s=0;for(let o of e||[]){if(!o?.names?.length)continue;let e=[];for(let i of o.names){let a=function(e,t){let l=String(e||"").trim();return l?t instanceof Map?t.get(l)||t.get(l.toLowerCase())||null:t[l]||t[l.toLowerCase()]||null:null}(i,l),s=(0,t.entityToSkillGemRef)(a);s?e.push(s):r.push(String(i).trim())}if("soloPack"===o.kind){let l=e.slice(0,t.SKILL_BOARD_SOLO_MAX);if(!l.length)continue;i.push({kind:"soloPack",id:(0,t.createSkillBoardId)("solo"),solos:l}),s+=1;continue}let[n,...d]=e;n&&(i.push({kind:"link",id:(0,t.createSkillBoardId)("link"),main:n,supports:d}),a+=1)}return{cards:i,skipped:r,addedLink:a,addedSolo:s}}function a(e){let t=[],l=Number(e?.addedLink)||0,i=Number(e?.addedSolo)||0,r=Array.isArray(e?.skipped)?[...new Set(e.skipped.filter(
1Boolean))]:[];if(l>0&&t.push(`링크 그룹 ${l}`),i>0&&t.push(`단독 묶음 ${i}`),!t.length&&!r.length)return"추가된 젬이 없습니다.";let a=t.length?`추가됨: ${t.join(" · ")}`:"추가된 카드 없음";return r.length&&(a+=` \xb7 미매칭 생략: ${r.join(", ")}`),a}e.s(["buildSkillBoardCardsFromPaste",()=>r,"formatSkillBoardPasteMessage",()=>a,"parseSkillBoardPasteText",()=>i])},847894,e=>{"use strict";var t=e.i(229969),l=e.i(694148),i=e.i(290627);function r(e,i=""){let a=String(i||"").trim();if(a.toLowerCase().endsWith(".zip")){let i=(0,t.unzipSync)(e),r=[];for(let[e,t]of Object.entries(i)){let i=e.split("/").pop()||e;if(!i.toLowerCase().endsWith(".build")||e.includes("__MACOSX")||i.startsWith("."))continue;let a=new TextDecoder().decode(t),s=(0,l.parseBuildFileText)(a);s.ok&&r.push({name:(0,l.stripBuildExtension)(i)||s.data?.name||i,data:(0,l.normalizeBuildFileData)(s.data)})}if(!r.length)throw Error("압축 안에 .build 파일이 없습니다.");return r}let s=new TextDecoder().decode(e),o=(0,l.parseBuildFileText)(s);if(!o.ok)throw Error(o.error||"빌드 파일을 읽지 못했습니다.");return[{name:(0,l.stripBuildExtension)(a.split("/").pop()||a)||o.data?.name||"빌드 플래너",data:(0,l.normalizeBuildFileData)(o.data)}]}function a(e,t){let r=String(e?.id||e?.name||"").trim();if(!r)return null;let a=(0,l.resolveGemDisplayMeta)(r,{preferSupport:t},"ko");return(0,i.normalizeSkillGemRef)({id:r,label:a.label||e?.name||r,color:a.color||"neutral",icon:a.icon||""})}function s(e,t="poe2"){let l=(Array.isArray(e)?e:[]).map((e,t)=>{let l=Array.isArray(e?.data?.skills)?e.data.skills:[],r=[];for(let e of l){let t=a(e,!1);if(!t?.label&&!t?.id)continue;let l=(Array.isArray(e?.support_skills)?e.support_skills:[]).map(e=>a(e,!0)).filter(Boolean);r.push({kind:"link",id:(0,i.createSkillBoardId)("link"),main:t,supports:l})}return r.length?{id:(0,i.createSkillBoardId)("stage"),title:String(e?.name||"").trim()||`${t+1}. 구간`,cards:r}:null}).filter(Boolean);return(0,i.normalizeSkillBoard)({game:"poe1"===t?"poe1":"poe2",stages:l,activeStageId:l[0]?.id||""},{game:t})}e.s(["parsePlannerBundleBytes",()=>r,"skillBoardFromPlannerBuilds",()=>s])},695684,e=>{"use strict";var t=e.i(843476),l=e.i(271645),i=e.i(290627),r=e.i(351930),a=e.i(847894);let s="reim-skill-board-stage",o="REIM_SKILL_BOARD_STAGE:1\n";var n=e.i(776703),d=e.i(791191),c=e.i(556457);function u({game:e,onSelect:i,placeholder:r="젬 검색…",disabled:a=!1}){let s=(0,l.useId)(),[o,n]=(0,l.useState)(""),[u,p]=(0,l.useState)([]),[m,b]=(0,l.useState)(!1),[g,h]=(0,l.useState)(!1),[k,f]=(0,l.useState)(-1),_=(0,l.useRef)(null),x=(0,l.useRef)(null),v=(0,l.useRef)(null);(0,l.useEffect)(()=>{let e=e=>{_.current?.contains(e.target)||b(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[]),(0,l.useEffect)(()=>{if(!m||!e||"poe1"!==e&&"poe2"!==e){p([]),f(-1);return}v.current?.abort();let t=new AbortController;v.current=t;let l=setTimeout(async()=>{h(!0);try{let l=new URLSearchParams({game:e,q:o,limit:"15",types:"gem"}),i=await fetch(`/api/guide-entities?${l}`,{signal:t.signal}),r=await i.json().catch(()=>({})),a=Array.isArray(r?.data)?r.data:[];p(a),f(-1)}catch(e){e?.name!=="AbortError"&&(p([]),f(-1))}finally{h(!1)}},120);return()=>{clearTimeout(l),t.abort()}},[m,o,e]),(0,l.useEffect)(()=>{if(k<0||!x.current)return;let e=x.current.querySelector(`[data-skill-picker-index="${k}"]`);e?.scrollIntoView?.({block:"nearest"})},[k]);let y=(0,l.useCallback)(e=>{i?.(e),n(""),b(!1),f(-1)},[i]);return(0,t.jsxs)("div",{className:"reim-skill-picker",ref:_,children:[(0,t.jsx)("input",{type:"text",className:"reim-skill-picker__input",value:o,disabled:a||"poe1"!==e&&"poe2"!==e,placeholder:r,role:"combobox","aria-expanded":m,"aria-controls":s,"aria-autocomplete":"list","aria-activedescendant":k>=0?`${s}-opt-${k}`:void 0,onChange:e=>{n(e.target.value),b(!0)},onFocus:()=>b(!0),onKeyDown:e=>{if(e.stopPropagation(),m||"ArrowDown"!==e.key&&"Enter"!==e.key||b(!0),"Escape"===e.key){e.preventDefault(),b(!1),f(-1);return}if(m&&!g&&0!==u.length){if("ArrowDown"===e.key){e.preventDefault(),f(e=>e<0?0:Math.min(e+1,u.length-1));return}if("ArrowUp"===e.key){e.preventDefault(),f(e=>e<=0?-1:e-1);return}if("Enter"===e.key){e.preventDefault();let t=u[k>=0?k:0];t&&y(t)}}},onKeyUp:e=>e.stopPropagation()}),m&&(0,t.jsxs)("div",{id:s,ref:x,className:"reim-skill-picker__menu",role:"listbox",children:[g&&(0,t.jsx)("div",{className:"reim-skill-picker__empty",children:"검색 중…"}),!g&&0===u.length&&(0,t.jsx)("div",{className:"reim-skill-picker__empty",children:"결과 없음"}),!g&&u.map((e,l)=>(0,t.jsxs)("button",{id:`${s}-opt-${l}`,type:"button",role:"option","aria-selected":l===k,"data-skill-picker-index":l,className:`reim-skill-picker__item${l===k?" is-active":""}`,onMouseEnter:()=>f(l),onMouseDown:t=>{t.preventDefault(),y(e)},children:[(0,t.jsx)(d.default,{icon:e.icon,color:e.color,label:e.nameKo}),(0,t.jsxs)("span",{className:"reim-skill-picker__text",children:[(0,t.jsx)("span",{className:(0,d.gemColorClass)(e.color),children:(0,c.formatGemNameWithGrade)(e.nameKo||e.nameEn,e.level)}),(0,t.jsx)("span",{className:"reim-skill-picker__meta",children:["catalog"===e.source?"수동":null,!e.hasIcon&&!e.icon?"아이콘 없음":null,e.nameEn&&e.nameEn!==e.nameKo?e.nameEn:null].filter(
1Boolean).join(" · ")})]})]},`${e.source||"db"}-${e.id}`))]})]})}function p(){return{kind:"link",id:(0,i.createSkillBoardId)("link"),main:{id:"",label:"",color:"neutral",icon:""},supports:[]}}function m(e){return!!e&&("soloPack"===e.kind?(e.solos||[]).length>0:!!e.main?.label||(e.supports||[]).length>0)}function b(e){return!!e&&("soloPack"===e.kind?(e.solos||[]).length>0:!!e.main?.label)}function g({board:e,game:d,onChange:c,selected:u=!1,hideStageTabs:g=!1}){let[f,_]=(0,l.useState)(!1),[x,v]=(0,l.useState)(!1),[y,S]=(0,l.useState)(""),[j,w]=(0,l.useState)("poe1"===d||"poe2"===d?d:"poe2"),[N,C]=(0,l.useState)(!1),[B,P]=(0,l.useState)(""),[$,A]=(0,l.useState)(""),[E,L]=(0,l.useState)(!1),[D,I]=(0,l.useState)(""),[O,M]=(0,l.useState)(!1),[R,K]=(0,l.useState)(""),[T,z]=(0,l.useState)(""),X=(0,l.useRef)(null),[F,G]=(0,l.useState)("create"),[U,J]=(0,l.useState)("link"),[q,W]=(0,l.useState)(p),[Y,V]=(0,l.useState)(null),[H,Q]=(0,l.useState)(null),[Z,ee]=(0,l.useState)(null),et=(0,l.useRef)(null),el=(0,l.useRef)([]),ei=(0,l.useRef)(null),er=(0,l.useRef)(()=>{}),ea=(0,l.useRef)(null),es=(0,l.useMemo)(()=>(0,i.normalizeSkillBoard)(e,{game:d}),[e,d]),eo=Math.max(0,es.stages.findIndex(e=>e.id===es.activeStageId)),en=es.stages[eo]||es.stages[0],ed="poe1"===d||"poe2"===d,ec="poe2"===d,eu=(e=en)=>(e?.cards||[]).some(e=>"link"===e.kind?!!e.main?.label||(e.supports||[]).length>0:(e.solos||[]).length>0);el.current=en?.cards||[];let ep=()=>{G("create"),J("link"),W(p()),V(null)};(0,l.useEffect)(()=>{G("create"),J("link"),W(p()),V(null),Q(null),ee(null),ea.current?.()},[en?.id]),(0,l.useEffect)(()=>()=>{ea.current?.()},[]);let em=e=>{c?.((0,i.normalizeSkillBoard)(e,{game:e?.game||d}))},eb=(e,t=es.activeStageId)=>{em({...es,game:d,stages:e,activeStageId:t})},eg=e=>{eb(es.stages.map(t=>t.id===en.id?{...t,...e}:t),en.id)},eh=e=>eg({cards:e});er.current=eh;let ek=e=>{let t="copy"===e?(0,i.cloneSkillBoardStage)(en):{id:(0,i.createSkillBoardId)("stage"),title:`${es.stages.length+1}. 구간`,cards:[],detailHtml:""},l=[...es.stages];l.splice(eo+1,0,t),eb(l,t.id),_(!1)},ef=e=>{let t=eo+e;if(t<0||t>=es.stages.length)return;let l=[...es.stages],[i]=l.splice(eo,1);l.splice(t,0,i),eb(l,en.id)},e_=async(e="replace")=>{let t=y.trim();if(!t||N)return;if(!ed)return void P("PoB 불러오기는 PoE1/PoE2 스킬 보드에서만 사용할 수 있습니다.");let l="poe1"===j?"poe1":"poe2",r=es.stages.some(e=>(e.cards||[]).some(e=>"link"===e.kind?!!e.main?.label||(e.supports||[]).length>0:(e.solos||[]).length>0));if(!r||"replace"!==e||window.confirm("현재 스킬 보드 내용을 PoB 스킬 세트로 덮어쓸까요?")){C(!0),P("");try{let a=await fetch("/api/poe2/pob-import/skill-board",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({source:t,game:l})}),s=await a.json().catch(()=>({}));if(!a.ok||!s?.ok||!s?.board)throw Error(s?.message||"PoB를 불러오지 못했습니다.");let o=(0,i.normalizeSkillBoard)(s.board,{game:l});if(r&&"append"===e){let e=(o.stages||[]).map(e=>({...e,id:(0,i.createSkillBoardId)("stage")})),t=[...es.stages,...e];em({...es,game:l,stages:t,activeStageId:e[0]?.id||es.activeStageId})}else em({...o,game:l});let n=s.meta?.skillSetCount??o.stages?.length??0,d=s.meta?.cardCount??0,c=(Array.isArray(s.warnings)?s.warnings:[]).map(e=>e?.message).filter(Boolean),u=r&&"append"===e?"새 구간 추가":"불러옴";P(c.length?`${u}: 구간 ${n} \xb7 링크 ${d} \xb7 ${c.join(" · ")}`:`${u}: 구간 ${n}개 \xb7 링크 그룹 ${d}개`),v(!1),S("")}catch(e){P(e instanceof Error?e.message:"PoB를 불러오지 못했습니다.")}finally{C(!1)}}},ex=async(e,t="replace")=>{if(e&&!O){if(!ec)return void K("플래너 파일 불러오기는 PoE2 스킬 보드에서만 사용할 수 있습니다.");if(!eu()||"replace"!==t||window.confirm("현재 구간의 스킬 구성을 플래너 파일 내용으로 덮어쓸까요?")){M(!0),K("");try{let l=await e.arrayBuffer(),r=function(e,t,l="poe2"){let i=e instanceof Uint8Array?e:new Uint8Array(e||[]),r=(0,a.parsePlannerBundleBytes)(i,t),s=(0,a.skillBoardFromPlannerBuilds)(r,l),o=Array.isArray(s?.stages)?s.stages:[],n=o.flatMap(e=>e.cards||[]);return{builds:r,board:s,stages:o,cards:n,fileCount:r.length,cardCount:n.length}}(l,e.name,"poe2");if(!r.cardCount)throw Error("파일에서 스킬 젬을 찾지 못했습니다.");if(r.fileCount>1&&window.confirm(`.build ${r.fileCount}개를 찾았습니다. 각각을 새 구간으로 추가할까요?
2취소를 누르면 모든 스킬을 현재 구간에 넣습니다.`)){let e=r.stages.map(e=>(0,i.cloneSkillBoardStage)(e)),t=[...es.stages,...e];em({...es,stages:t,activeStageId:e[0]?.id||es.activeStageId}),K(`새 구간 ${e.length}개 추가 \xb7 링크 ${r.cardCount}개`);return}let s="merge"===t?[...en.cards||[],...r.cards]:r.cards;eh(s),K("merge"===t?`현재 구간에 링크 ${r.cards.length}개 추가`:`현재 구간을 플래너 스킬 ${r.cards.length}개로 채움`)}
2catch(e){K(e instanceof Error?e.message:"플래너 파일을 불러오지 못했습니다.")}finally{M(!1),X.current&&(X.current.value="")}}}},ev=async()=>{z("");try{let e=function(e,t="poe2"){return o+JSON.stringify({type:s,version:1,game:"poe1"===t?"poe1":"poe2",stage:(0,i.cloneSkillBoardStage)(e)})}(en,d);await navigator.clipboard.writeText(e),z("현재 구간을 복사했습니다. 가이드 스킬 보드에 붙여넣으세요.")}catch(e){z(e instanceof Error?e.message:"클립보드 복사에 실패했습니다.")}},ey=e=>{"create"===F&&e!==U&&(!m(q)||window.confirm("작성 중인 내용이 초기화됩니다. 종류를 바꿀까요?"))&&(J(e),W("soloPack"===e?{kind:"soloPack",id:(0,i.createSkillBoardId)("solo"),solos:[]}:p()))},eS=async e=>{let t=String(e??$).trim();if(!t||E)return;let l=function(e){let t=String(e||"").trim();if(!t)return null;let l=t;if(t.startsWith(o))l=t.slice(o.length).trim();else if(!t.startsWith("{"))return null;try{let e=JSON.parse(l);if(!e||e.type!==s||!e.stage)return null;let t=(0,i.normalizeSkillBoardStage)({...e.stage,id:(0,i.createSkillBoardId)("stage")},0),r=(0,i.cloneSkillBoardStage)(t);return{game:"poe1"===e.game?"poe1":"poe2",stage:r}}catch{return null}}(t);if(l?.stage){L(!0),I("");try{let e=l.stage,t=(e.cards||[]).length;if(!t)return void I("복사한 구간에 스킬이 없습니다.");if(!eu()||window.confirm(`복사한 구간 스킬 ${t}개를 현재 구간에 합칠까요?
3취소를 누르면 새 구간으로 추가합니다.`))eh([...en.cards||[],...e.cards||[]]),I(`현재 구간에 링크 ${t}개 붙여넣음`);else{let l=(0,i.cloneSkillBoardStage)(e);l.title?.trim()||(l.title=`${es.stages.length+1}. 구간`);let r=[...es.stages,l];em({...es,stages:r,activeStageId:l.id}),I(`새 구간으로 링크 ${t}개 추가`)}A("")}finally{L(!1)}return}let a=(0,r.parseSkillBoardPasteText)(t);if(!a.length)return void I("붙여넣을 내용이 없습니다.");let n=[...new Set(a.flatMap(e=>e.names))],c="poe1"===d||"poe2"===d?d:"poe2";L(!0),I("");try{let e=await fetch("/api/guide-entities/resolve-gems",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({game:c,names:n})}),t=await e.json().catch(()=>({}));if(!e.ok)throw Error(t?.error||"ì ¬ 이름을 해석하지 못했습니다.");let l=t?.resolved&&"object"==typeof t.resolved?t.resolved:{},i=(0,r.buildSkillBoardCardsFromPaste)(a,l);i.cards.length&&eh([...en.cards,...i.cards]),I((0,r.formatSkillBoardPasteMessage)(i)),A("")}catch(e){I(e instanceof Error?e.message:"붙여넣기 적용 중 오류가 발생했습니다.")}finally{L(!1)}};return(0,t.jsxs)("div",{className:`reim-skill-board-editor${u?" is-selected":""}`,contentEditable:!1,onKeyDown:e=>e.stopPropagation(),onKeyUp:e=>e.stopPropagation(),onKeyPress:e=>e.stopPropagation(),children:[(0,t.jsxs)("div",{className:"reim-skill-board-editor__toolbar",children:[(0,t.jsx)("strong",{children:"스킬 보드"}),(0,t.jsxs)("span",{className:"reim-skill-board-editor__hint",children:["작성 후 완료 · 카드 드래그로 순서 변경 · 단독 묶음 최대 ",i.SKILL_BOARD_SOLO_MAX]}),ed?(0,t.jsx)("button",{type:"button",className:`reim-skill-board-editor__pob-toggle${x?" is-active":""}`,onClick:()=>{v(e=>(e||w("poe1"===d?"poe1":"poe2"),!e)),P("")},children:"PoB 불러오기"}):null,ec?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("input",{ref:X,type:"file",accept:".build,.zip,application/zip",hidden:!0,onChange:e=>{let t=e.target.files?.[0];t&&ex(t,"replace")}}),(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__pob-toggle",disabled:O,onClick:()=>X.current?.click(),children:O?"불러오는 중…":"플래너 파일"}),(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__pob-toggle",disabled:O,onClick:()=>{let e=document.createElement("input");e.type="file",e.accept=".build,.zip,application/zip",e.onchange=()=>{let t=e.files?.[0];t&&ex(t,"merge")},e.click()},children:"파일 합치기"})]}):null,(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__pob-toggle",onClick:()=>void ev(),children:"구간 복사"})]}),R?(0,t.jsx)("p",{className:"reim-skill-board-editor__pob-message",children:R}):null,T?(0,t.jsx)("p",{className:"reim-skill-board-editor__pob-message",children:T}):null,x&&ed?(0,t.jsxs)("div",{className:"reim-skill-board-editor__pob",children:[(0,t.jsx)("p",{className:"reim-skill-board-editor__hint",children:"PoB 코드 또는 pobb.in / pob.codes 주소를 넣으면 스킬 세트마다 구간이 만들어집니다. 이미 구간이 있으면 새 구간으로 추가할 수 있습니다. 액트가 없는 PoB는 구간을 직접 만든 뒤, 나중에 다른 PoB를 새 구간으로 가져ì˜
3¤ë©´ 됩니다."}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__pob-game",children:[(0,t.jsx)("span",{children:"게임"}),(0,t.jsxs)("label",{children:[(0,t.jsx)("input",{type:"radio",name:"skill-board-pob-game",checked:"poe1"===j,onChange:()=>w("poe1"),disabled:N}),"PoE1"]}),(0,t.jsxs)("label",{children:[(0,t.jsx)("input",{type:"radio",name:"skill-board-pob-game",checked:"poe2"===j,onChange:()=>w("poe2"),disabled:N}),"PoE2"]})]}),(0,t.jsx)("textarea",{className:"reim-skill-board-editor__pob-input",value:y,onChange:e=>S(e.target.value),onKeyDown:e=>e.stopPropagation(),placeholder:"https://pob.codes/b/... · pobb.in/... · 또는 PoB 코드",rows:3,spellCheck:!1,disabled:N}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__pob-actions",children:[(0,t.jsx)("button",{type:"button",onClick:()=>e_("replace"),disabled:N||!y.trim(),children:N?"불러오는 중…":"보드에 채우기"}),(0,t.jsx)("button",{type:"button",onClick:()=>e_("append"),disabled:N||!y.trim(),children:"새 구간으로 추가"}),(0,t.jsx)("button",{type:"button",onClick:()=>{v(!1),P("")},disabled:N,children:"닫기"})]})]}):null,B?(0,t.jsx)("p",{className:"reim-skill-board-editor__pob-message",children:B}):null,g?null:(0,t.jsxs)("div",{className:"reim-skill-board-editor__stages",children:[es.stages.map(e=>(0,t.jsx)("button",{type:"button",className:`reim-skill-board-editor__stage-tab${e.id===en.id?" is-active":""}`,onClick:()=>{var t;return t=e.id,void em({...es,activeStageId:t})},children:e.title},e.id)),f?(0,t.jsxs)("div",{className:"reim-skill-board-editor__stage-add-menu",children:[(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__stage-add",onClick:()=>
3ek("copy"),title:"현재 구간의 링크/단독 그룹을 복사합니다",children:"앞 구간 복사"}),(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__stage-add",onClick:()=>ek("blank"),children:"빈 구간"}),(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__stage-add",onClick:()=>_(!1),children:"취소"})]}):(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__stage-add",onClick:()=>_(!0),children:"+ 구간"})]}),g?null:(0,t.jsxs)("div",{className:"reim-skill-board-editor__stage-fields",children:[(0,t.jsxs)("label",{children:["구간 제목",(0,t.jsx)("input",{type:"text",value:en.title,onChange:e=>{eg({title:e.target.value})},onKeyDown:e=>{e.stopPropagation()},placeholder:`${eo+1}. 구간`})]}),es.stages.length>1&&(0,t.jsxs)("div",{className:"reim-skill-board-editor__stage-tools",children:[(0,t.jsx)("button",{type:"button",onClick:()=>ef(-1),title:"왼쪽으로 이동",children:"←"}),(0,t.jsx)("button",{type:"button",onClick:()=>ef(1),title:"오른쪽으로 이동",children:"→"}),(0,t.jsx)("button",{type:"button",className:"reim-skill-board-editor__danger",onClick:()=>{if(es.stages.length<=1)return;let e=es.stages.filter(e=>e.id!==en.id);eb(e,e[0]?.id)},children:"이 구간 삭제"})]})]}),(0,t.jsxs)("div",{ref:et,className:`reim-skill-board-editor__composer${"edit"===F?" is-editing":""}`,children:[(0,t.jsxs)("div",{className:"reim-skill-board-editor__card-head",children:[(0,t.jsx)("span",{children:"edit"===F?`${q?.kind==="soloPack"?"단독 묶음":"링크 그룹"} 수정`:"새 그룹"}),"create"===F?(0,t.jsxs)("div",{className:"reim-skill-board-editor__kind-toggle",children:[(0,t.jsx)("button",{type:"button",className:"link"===U?"is-active":"",onClick:()=>ey("link"),children:"링크 그룹"}),(0,t.jsx)("button",{type:"button",className:"soloPack"===U?"is-active":"",onClick:()=>ey("soloPack"),children:"단독 묶음"})]}):null]}),"soloPack"===U?(0,t.jsx)(k,{card:q,game:d,onChange:W}):(0,t.jsx)(h,{card:q,game:d,onChange:W}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__composer-actions",children:[(0,t.jsx)("button",{type:"button",className:"is-primary",disabled:!b(q),onClick:()=>{if(b(q)){if("edit"===F&&Y){let e={...q,id:Y};eh(en.cards.map(t=>t.id===Y?e:t))}else eh([...en.cards,q]);ep()}},children:"완료"}),"edit"===F?(0,t.jsx)("button",{type:"button",onClick:ep,children:"취소"}):(0,t.jsx)("span",{className:"reim-skill-board-editor__hint",children:"완료를 누르면 카드로 추가됩니다."})]})]}),en.cards.length?(0,t.jsxs)("div",{ref:ei,className:"reim-skill-board reim-skill-board-editor__board","data-game":es.game,children:[en.title?.trim()?(0,t.jsx)("div",{className:"reim-skill-board__title-only",children:en.title}):null,(0,t.jsx)("div",{className:"reim-skill-board__grid",children:en.cards.map((e,l)=>{let i=en.cards.slice(0,l).filter(m).length;return(0,t.jsxs)("div",{"data-skill-card-id":e.id,className:`reim-skill-board-editor__preview-card${H===e.id?" is-dragging":""}${Z?.id===e.id&&"before"===Z.side?" is-drop-before":""}${Z?.id===e.id&&"after"===Z.side?" is-drop-after":""}${Y===e.id?" is-editing":""}`,title:"끌어 순서 변경",onMouseDown:e=>{e.target.closest("button, input, select, textarea, a, label")||(e.preventDefault(),e.stopPropagation())},onPointerDown:t=>((e,t)=>{if(0!==e.button||e.target.closest("button, input, select, textarea, a, label"))return;e.preventDefault(),e.stopPropagation();let l=e.clientX,i=e.clientY,r=!1,a=null,s=null,o=0,n=0,d=e=>{ea.current&&(ea.current=null,window.removeEventListener("pointermove",c),window.removeEventListener("pointerup",u),window.removeEventListener("pointercancel",u),s?.remove(),s=null,document.body.classList.remove("reim-skill-board-dragging"),Q(null),ee(null),e&&r&&a&&((e,t,l)=>{if(!e||!t||e===t)return;let i=[...el.current||[]],r=i.findIndex(t=>t.id===e);if(r<0)return;let[a]=i.splice(r,1),s=i.findIndex(e=>e.id===t);s<0||("after"===l&&(s+=1),i.splice(s,0,a),er.current(i))})(t,a.id,a.side))},c=e=>{if(!(!r&&6>Math.hypot(e.clientX-l,e.clientY-i))){if(!r){r=!0,Q(t),document.body.classList.add("reim-skill-board-dragging");let l=ei.current?.querySelector(`[data-skill-card-id="${CSS.escape(t)}"]`);if(l){let t=l.getBoundingClientRect();o=e.clientX-t.left,n=e.clientY-t.top;let i=document.createElement("div");i.className="reim-skill-board reim-skill-board-editor__drag-ghost",i.setAttribute("aria-hidden","true");let r=l.cloneNode(!0);r.querySelector(".reim-skill-board-editor__preview-tools")?.remove(),r.classList.remove("is-dragging","is-editing","is-drop-before","is-drop-after","is-drop-target"),r.removeAttribute("title"),i.appendChild(r),i.style.width=`${t.width}px`,i.style.height=`${t.height}px`,i.style.left=`${e.clientX-o}px`,i.style.top=`${e.clientY-n}px`,document.body.appendChild(i),s=i}}e.preventDefault(),s&&(s.style.left=`${e.clientX-o}px`,s.style.top=`${e.clientY-n}px`),a=((e,t,l)=>{let i=ei.current;if(!i)return null;let r=null,a=null,s=1/0;for(let o of i.querySelectorAll("[data-skill-card-id]")){let i=o.getAttribute("data-skill-card-id");if(!i||i===l)continue;let n=o.getBoundingClientRect(),d=e<n.left+n.width/2?"before":"after";if(e>=n.left&&e<=n.right&&t>=n.top&&t<=n.bottom){r={id:i,side:d};break}let c=Math.min(Math.max(e,n.left),n.right),u=Math.min(Math.max(t,n.top),n.bottom),p=Math.hypot(e-c,t-u);p<s&&(s=p,a={id:i,side:d})}return r||(s<=40?a:null)})(e.clientX,e.clientY,t),ee(e=>e?.id===a?.id&&e?.side===a?.side?e:a)}},u=()=>d(!0);ea.current=()=>d(!1),window.addEventListener("pointermove",c),window.addEventListener("pointerup",u),window.addEventListener("pointercancel",u)})(t,e.id),children:[(0,t.jsxs)("div",{className:"reim-skill-board-editor__preview-tools",children:[(0,t.jsx)("button",{type:"button",title:"수정","aria-label":"수정",onClick:()=>{Y===e.id?et.current?.scrollIntoView({block:"nearest",behavior:"smooth"}):"create"===F&&m(q)&&!window.confirm("작성 중인 내용이 있습니다. 이 카드를 수정할까요?")||("edit"!==F||!Y||Y===e.id||window.confirm("수정 중인 내용을 취소하고 다른 카드를 수정할까요?"))&&(G("edit"),J("soloPack"===e.kind?"soloPack":"link"),V(e.id),W(JSON.parse(JSON.stringify(e))),requestAnimationFrame(()=>{et.current?.scrollIntoView({block:"nearest",behavior:"smooth"})}))},children:"수정"}),(0,t.jsx)("button",{type:"button",title:"삭제","aria-label":"삭제",onClick:()=>{var t;return t=e.id,void(eh(en.cards.filter(e=>e.id!==t)),Y===t&&ep())},children:"삭제"})]}),m(e)?(0,t.jsx)(n.SkillBoardCardPreview,{card:e,index:i}):(0,t.jsx)("p",{className:"reim-skill-board-editor__preview-empty",children:"비어 있는 카드"})]},e.id)})})]}):(0,t.jsx)("p",{className:"reim-skill-board-editor__empty",children:"아직 등록된 카드가 없습니다."}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__card-actions",children:[(0,t.jsx)("textarea",{className:"reim-skill-board-editor__paste-input",value:$,disabled:E,rows:1,placeholder:"붙여넣기: 구간 복사 JSON · 또는 메인 - 보조… / 단독 / 단독",onChange:e=>A(e.target.value),onPaste:e=>{let t=e.clipboardData?.getData("text");t?.trim()&&(e.preventDefault(),A(t),eS(t))},onKeyDown:e=>{e.stopPropagation(),"Enter"!==e.key||e.shiftKey||(e.preventDefault(),eS($))}}),(0,t.jsx)("button",{type:"button",onClick:()=>void eS($),disabled:E||!$.trim(),children:E?"적용 중…":"붙여넣기 적용"})]}),D?(0,t.jsx)("p",{className:"reim-skill-board-editor__paste-message",children:D}):null]})}
3function h({card:e,game:l,onChange:r}){return(0,t.jsxs)("div",{className:"reim-skill-board-editor__link",children:[(0,t.jsxs)("div",{className:"reim-skill-board-editor__row",children:[(0,t.jsx)("span",{className:"reim-skill-board-editor__label",children:"메인"}),e.main?.label?(0,t.jsxs)("span",{className:"reim-skill-board-editor__chip",children:[(0,t.jsx)(d.default,{icon:e.main.icon,color:e.main.color,label:e.main.label}),(0,t.jsx)("span",{className:(0,d.gemColorClass)(e.main.color),children:e.main.label}),(0,t.jsxs)("label",{className:"reim-skill-board-editor__level",children:["Lv",(0,t.jsx)("input",{type:"number",min:1,max:40,value:e.main.level??"",placeholder:"—",onChange:t=>(t=>{if(!e.main)return;let l=""===t?null:Number(t),i={...e.main};null!=l&&Number.isFinite(l)&&l>=1?i.level=Math.round(l):delete i.level,r({...e,main:i})})(t.target.value),onKeyDown:e=>e.stopPropagation()})]}),(0,t.jsx)("button",{type:"button",onClick:()=>r({...e,main:{id:"",label:"",color:"neutral",icon:""}}),children:"변경"})]}):(0,t.jsx)(u,{game:l,onSelect:t=>{let l=(0,i.entityToSkillGemRef)(t);l&&r({...e,main:{...l,...e.main?.level!=null?{level:e.main.level}:{}}})},placeholder:"메인 젬 검색"})]}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__row",children:[(0,t.jsx)("span",{className:"reim-skill-board-editor__label",children:"무기 세트"}),(0,t.jsxs)("select",{className:"reim-skill-board-editor__weapon-set",value:1===e.weaponSet||2===e.weaponSet?String(e.weaponSet):"",onChange:t=>(t=>{if("1"===t)r({...e,weaponSet:1});else if("2"===t)r({...e,weaponSet:2});else{let t={...e};delete t.weaponSet,r(t)}})(t.target.value),onKeyDown:e=>e.stopPropagation(),children:[(0,t.jsx)("option",{value:"",children:"양쪽 / 표시 안 함"}),(0,t.jsx)("option",{value:"1",children:"세트 I 만"}),(0,t.jsx)("option",{value:"2",children:"세트 II 만"})]})]}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__row",children:[(0,t.jsx)("span",{className:"reim-skill-board-editor__label",children:"보조"}),(0,t.jsxs)("div",{className:"reim-skill-board-editor__supports",children:[(e.supports||[]).map((l,i)=>(0,t.jsxs)("span",{className:"reim-skill-board-editor__chip",children:[(0,t.jsx)("span",{className:(0,d.gemColorClass)(l.color),children:l.label}),(0,t.jsxs)("label",{className:"reim-skill-board-editor__level",children:["Lv",(0,t.jsx)("input",{type:"number",min:1,max:40,value:l.level??"",placeholder:"—",onChange:t=>{var l;let a;return l=t.target.value,a=(e.supports||[]).map((e,t)=>{if(t!==i)return e;let r={...e},a=""===l?null:Number(l);return null!=a&&Number.isFinite(a)&&a>=1?r.level=Math.round(a):delete r.level,r}),void r({...e,supports:a})},onKeyDown:e=>e.stopPropagation()})]}),(0,t.jsx)("button",{type:"button",onClick:()=>{r({...e,supports:e.supports.filter((e,t)=>t!==i)})},children:"×"})]},`${l.id}-${i}`)),(0,t.jsx)(u,{game:l,onSelect:t=>{let l=(0,i.entityToSkillGemRef)(t);l&&r({...e,supports:[...e.supports||[],l]})},placeholder:"보조 젬 추가 (없으면 단독 링크)"})]})]})]})}
3function k({card:e,game:l,onChange:r}){return(0,t.jsxs)("div",{className:"reim-skill-board-editor__solo",children:[(0,t.jsx)("div",{className:"reim-skill-board-editor__supports",children:(e.solos||[]).map((l,i)=>(0,t.jsxs)("span",{className:"reim-skill-board-editor__chip",children:[(0,t.jsx)(d.default,{icon:l.icon,color:l.color,label:l.label}),(0,t.jsx)("span",{className:(0,d.gemColorClass)(l.color),children:l.label}),(0,t.jsx)("button",{type:"button",onClick:()=>{r({...e,solos:e.solos.filter((e,t)=>t!==i)})},children:"×"})]},`${l.id}-${i}`))}),(e.solos||[]).length<i.SKILL_BOARD_SOLO_MAX?(0,t.jsx)(u,{game:l,onSelect:t=>{if((e.solos||[]).length>=i.SKILL_BOARD_SOLO_MAX)return;let l=(0,i.entityToSkillGemRef)(t);l&&r({...e,solos:[...e.solos||[],l].slice(0,i.SKILL_BOARD_SOLO_MAX)})},placeholder:`단독 젬 추가 (${(e.solos||[]).length}/${i.SKILL_BOARD_SOLO_MAX})`}):(0,t.jsxs)("p",{className:"reim-skill-board-editor__hint",children:["단독 묶음은 최대 ",i.SKILL_BOARD_SOLO_MAX,"개입니다."]})]})}e.s(["default",()=>g],695684)}]);

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.