import{u as m,bw as v,d_ as g,w as G,x as I,r as p,q as w,s as d}from"./index-dP1W1_bd.js";import{p as x}from"./project-B1Z_dM9_.js";const N=(r="",t=d.featureGroup.overview)=>{const{id:s,fsId:a}=m(),o=v(),e=g({pId:+s,fsId:+a,fgName:r},{skip:!r,selectFromResult:G({currentData:I(x(["version","id"]))})}),u=p.useCallback(l=>{var i,c;const n=(c=(i=e.currentData)==null?void 0:i.find(({version:f})=>f===+l))==null?void 0:c.id;n&&o(w(t,d.project.value,{id:s,fsId:a,fgId:n}))},[e.currentData,o,t,s,a]);return p.useMemo(()=>({...e,handleVersionChange:u}),[e,u])};export{N as u};
