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