import{r as n,j as m}from"./vendor-react-wBh_31cN.js";import{g as d,r as p,aq as j}from"./index-BKr2rJhV.js";import{u as f}from"./useTitle-DQo_L6Ox.js";import{t as g}from"./titles-CzjGGAB3.js";import{u as l}from"./useCurrentProject-C6qZaZgv.js";import{c as P}from"./index-BeaoFlb1.js";import{P as x}from"./ProjectForm-Cu_HDb_2.js";import{u as v}from"./vendor-router-D1GqFWiT.js";import"./vendor-redux-CJZrIb6x.js";import"./vendor-utils-OeoE2qq_.js";import"./vendor-icons-BUUmD6ht.js";import"./vendor-radix-BRyWS4bQ.js";import"./vendor-grid-CeFlDWv4.js";import"./useProject-FSnHbCQX.js";import"./index.esm-CAGtek53.js";import"./yup-XkUC3UEH.js";import"./getInputValidation-CUi6Oel7.js";import"./input-H6_qmzms.js";import"./label-Dnebucx5.js";import"./card-DISTA6Ay.js";import"./form-footer-CprMCGDT.js";import"./tooltip-Da8-EbK8.js";import"./utils-DSqkOIhq.js";import"./storage-connector-DQCKY9HZ.js";import"./combobox-CcK1PxyF.js";import"./input-group-Z3Qmt3PL.js";import"./textarea-Co48BFy3.js";import"./vendor-recharts-DmJlpLaF.js";import"./hoverable-link-onkuw0bk.js";import"./getHopsDoc-BWSxyuXn.js";import"./selectors-CMD4o3wq.js";import"./index-DkvW68Om.js";import"./ArrayField-DU-w4GBF.js";import"./icon-button-FETOk6q1.js";import"./radio-group-D7-g0sv3.js";import"./always-CtAmwIxm.js";import"./toast-3g7Fh-a0.js";import"./confirmation-dialog-DFt7ZgUQ.js";import"./useCopyToClipboard-3DFwhniW.js";import"./useNotifier-BCEAoFCf.js";import"./notifications-x-pTFTQl.js";import"./fileExplorer-BRS7UOt9.js";import"./useDownload-YBz540B0.js";import"./getPathAndFileName-BId4RGny.js";import"./FileUploaderButton-DXl5ypdF.js";import"./fileUploader-97-Ey7M3.js";import"./index-yLMRwF40.js";import"./file-utils-DSAei-GW.js";import"./converge-BDz-h6lA.js";import"./lensPath-CdufhmA3.js";import"./join-DatdAzSt.js";import"./init-BDcDHUTz.js";import"./ifElse-Blhrcs6_.js";import"./length-DTSUQW_a.js";import"./_isNumber-DRgbAj-F.js";import"./inc-0XPMXBh9.js";import"./add-DCChD-X4.js";import"./append-Bu8TTG0x.js";import"./includes-D04d5Ytc.js";import"./uniq-Cy5NeM3Y.js";import"./uniqBy-qYjau2JN.js";import"./concat-AxOj0lUI.js";import"./useDebounce-BiuGz9t2.js";import"./dumbPluralize-CcxDsNiu.js";import"./utils-JPS97eRI.js";import"./all-DVU-BA5G.js";import"./mergeRight-Cv2eiGXV.js";import"./juxt-BvCFisbd.js";import"./checkbox-DbZXziG0.js";import"./callout-Dd8FkTQe.js";import"./value-76ihWpF6.js";import"./props-gQDi595u.js";import"./zipObj-BpJhvpTB.js";const zt=()=>{const{id:r,project:t,isLoading:e,isFetching:a}=l(),i=v(),[o,{isLoading:s}]=P();f(`${g.editProject} ${(t==null?void 0:t.projectName)??""}`);const u=n.useCallback(async c=>{await o({id:+r,data:{services:[],...c}}).unwrap(),i(d(p.project.prj.view,p.project.value,{id:r}))},[o,i,r]);return e||a?m.jsx(j,{}):m.jsx(x,{isLoading:s,isEdit:!0,initialData:t,onSubmit:u})};export{zt as default};
