import{u as h,d,h as j,r as l,j as t}from"./main-406.js";import{g as _,$ as b,h as w,d as C,_ as c,i as I,I as v,s as y}from"./bi.394.85.js";import{h as N,A as S,c as A}from"./bi.385.753.js";import"./bi.704.707.js";import"./bi.701.708.js";function R({allIntegURL:m}){const f=h(),[e,a]=d(_),[n,p]=d(b),i=j(w),[o,r]=l.useState(!1),[g,s]=l.useState({show:!1}),u=()=>{if(!A(e)){s({show:!0,msg:"Please map all required fields to continue."});return}y({flow:n,setFlow:p,allIntegURL:m,conf:e,navigate:f,edit:1,setIsLoading:r,setSnackbar:s})};return t.jsxs("div",{style:{width:900},children:[t.jsx(C,{snack:g,setSnackbar:s}),t.jsxs("div",{className:"flx mt-3",children:[t.jsx("b",{className:"wdt-200 d-in-b",children:c("Integration Name:","bit-integrations")}),t.jsx("input",{className:"btcd-paper-inp w-5",onChange:x=>N(x,e,a),name:"name",value:e.name,type:"text",placeholder:c("Integration Name...","bit-integrations")})]}),t.jsx("br",{}),t.jsx("br",{}),t.jsx(I,{entity:n.triggered_entity,setSnackbar:s}),t.jsx(S,{formID:n.triggered_entity_id,formFields:i,autonamiConf:e,setAutonamiConf:a,isLoading:o,step:2,setIsLoading:r,setSnackbar:s}),t.jsx(v,{edit:!0,saveConfig:u,disabled:e.field_map.length<1,isLoading:o,dataConf:e,setDataConf:a,formFields:i}),t.jsx("br",{})]})}export{R as default};
