import{u as b,k as S,r as a,j as e}from"./main-406.js";import{d as T,G as h}from"./bi.394.85.js";import{S as k}from"./bi.68.941.js";import y from"./bi.738.248.js";import{W as w}from"./bi.771.743.js";import{T as i,t as H}from"./bi.150.760.js";import"./bi.46.744.js";function D({formFields:n,setFlow:r,flow:d,allIntegURL:p}){const l=b(),{formID:u}=S(),[t,m]=a.useState(1),[x,o]=a.useState({show:!1}),[f,g]=a.useState(!1),{thriveAutomatorLinks:s}=H,[c,j]=a.useState({name:"ThriveAutomator Web Hooks",type:"ThriveAutomator",method:"POST",url:""});return e.jsxs("div",{children:[e.jsx(T,{snack:x,setSnackbar:o}),e.jsx("div",{className:"txt-center mt-2",children:e.jsx(k,{step:2,active:t})}),e.jsxs("div",{className:"btcd-stp-page",style:{width:t===1&&1100,height:t===1&&"auto"},children:[(s==null?void 0:s.youTubeLink)&&e.jsx(i,{title:s==null?void 0:s.title,youTubeLink:s==null?void 0:s.youTubeLink}),(s==null?void 0:s.docLink)&&e.jsx(i,{title:s==null?void 0:s.title,docLink:s==null?void 0:s.docLink}),e.jsx(y,{formID:u,formFields:n,webHooks:c,setWebHooks:j,step:t,setStep:m,setSnackbar:o,create:!0})]}),e.jsx("div",{className:"btcd-stp-page",style:{width:t===2&&"100%",height:t===2&&"auto"},children:e.jsx(w,{step:t,saveConfig:()=>h(d,r,p,c,l,"","",g),isLoading:f})})]})}export{D as default};
