import{Ct as e,Nt as t,Pt as n,X as r}from"../chunks/xY0c-UfG.js";import"../chunks/xihTtKlq.js";import{i}from"../chunks/Ca8AGdcM.js";import{t as a}from"../chunks/ByTixK1i.js";import{t as o}from"../chunks/Bdz75Gen.js";import{t as s}from"../chunks/BCCbgL3X2.js";function c(c,l){n(l,!0),a.showGraph();let u=e(()=>{let e=new Map;for(let t of i.repos)for(let n of t.entities)e.set(n.id,n.title);return e}),d=e(()=>{let e=[],t=[],n=new Set,r=new Set;for(let a of i.repos)for(let i of a.entities){if(n.has(i.id))continue;n.add(i.id),e.push({id:i.id,type:i.entityType,repo:a.name});let o=i.wikilinks??[];for(let e of o){let n=i.id<e?`${i.id}|${e}`:`${e}|${i.id}`;!r.has(n)&&i.id!==e&&(r.add(n),t.push({source:i.id,target:e}))}}return{nodes:e,edges:t.filter(e=>n.has(e.source)&&n.has(e.target))}});s(c,{get graphData(){return r(d)},get nameMap(){return r(u)},get sidebarHoveredId(){return a.hoveredEntityId},get highlightedIds(){return o.highlightedIds}}),t()}export{c as component};