import{aw as j,bo as m,cv as p,bw as l,bx as b,r as g,o as x,q as i,j as r,D as P}from"./index-46ma1THH.js";import{P as v}from"./ProjectForm-B6UBApZR.js";const E=()=>{const{id:e,project:t,isLoading:o,isFetching:c}=j(),a=m(),[s,{isLoading:n}]=p();l(`${b.editProject} ${(t==null?void 0:t.projectName)??""}`);const u=g.useCallback(async d=>{await s({id:+e,data:{services:[],...d}}).unwrap(),a(x(i.project.prj.view,i.project.value,{id:e}))},[s,a,e]);return o||c?r.jsx(P,{}):r.jsx(v,{isLoading:n,isEdit:!0,initialData:t,onSubmit:u})};export{E as default};
