import{j as t}from"./main.2.8.1.js";import{u as x,h as S,d as e}from"./react-router-dom.9mCuUg3q.js";import"./Note.BeM7sN-p.js";import{S as j}from"./SnackMsg.S8DrwLlT.js";import{S as b}from"./Steps.1hz7v9Vj.js";import{g as k}from"./Integrations.D2bgBas2.js";import v from"./WebHooksIntegration.B7pcODxw.js";import{W as N}from"./WebHooksStepTwo.CLsJIPcj.js";import{t as w}from"./tutorialLinks.kMkIDzcD.js";import{T as H}from"./TutorialLink.BAFX--T3.js";import"./CopyIcn.3gZpHton.js";import"./Table.DAL7rcPQ.js";import"./index.wO-AxluA.js";import"./BackIcn._kGL_vVw.js";function z({formFields:r,setFlow:n,flow:m,allIntegURL:c}){const p=x(),{formID:d}=S(),[s,u]=e.useState(1),[l,a]=e.useState({show:!1}),[f,h]=e.useState(!1),{n8nLinks:o}=w,[i,g]=e.useState({name:"N8n Web Hooks",type:"N8n",method:"POST",url:"",apiConsole:"https://connect.n8n.com/dashboard"});return t.jsxs("div",{children:[t.jsx(j,{snack:l,setSnackbar:a}),t.jsx("div",{className:"txt-center mt-2",children:t.jsx(b,{step:2,active:s})}),t.jsxs("div",{className:"btcd-stp-page",style:{width:s===1&&1100,height:s===1&&"auto"},children:[o==null?void 0:o.youTubeLink,t.jsx(H,{title:"n8n.io",docLink:o==null?void 0:o.docLink}),t.jsx(v,{formID:d,formFields:r,webHooks:i,setWebHooks:g,step:s,setStep:u,setSnackbar:a,create:!0})]}),t.jsx("div",{className:"btcd-stp-page",style:{width:s===2&&"100%",height:s===2&&"auto"},children:t.jsx(N,{step:s,saveConfig:()=>k(m,n,c,i,p,"","",h),isLoading:f})})]})}export{z as default};
