import{h as p,g as j,$ as b,k as I,i as C,j as t,_ as d}from"./main.2.9.0.js";import{u as S,e as _,b as l}from"./react-router.DMwpH23k.js";import{S as w}from"./SnackMsg.DYSD96P4.js";import"./Note.NSUdvR3c.js";import"./CopyIcn.CEA_lFLo.js";import{S as v,I as N,s as k}from"./Integrations.DL8wqGct.js";import{h as c}from"./KeapCommonFunc.DRCBVG_Q.js";import{K as y}from"./KeapIntegLayout.DAuWX3ve.js";import"./react-vendor.P7K3d6op.js";import"./Table.BfF8RYFZ.js";import"./index.DpWdl9V1.js";import"./TagifyInput.KPPRQJ1B.js";import"./lodash.DCvQBX3r.js";function B({allIntegURL:f}){const g=S(),{id:E,formID:x}=_(),[e,s]=p(j),[n,u]=p(b),[i,r]=l.useState(!1),[h,a]=l.useState({show:!1}),m=I(C);return t.jsxs("div",{style:{width:900},children:[t.jsx(w,{snack:h,setSnackbar:a}),t.jsxs("div",{className:"flx mt-3",children:[t.jsx("b",{className:"wdt-200 d-in-b",children:d("Integration Name:","bit-integrations")}),t.jsx("input",{className:"btcd-paper-inp w-5",onChange:o=>c(o,e,s),name:"name",value:e.name,type:"text",placeholder:d("Integration Name...","bit-integrations")})]}),t.jsx("br",{}),t.jsx(v,{entity:n.triggered_entity,setSnackbar:a}),t.jsx(y,{formID:x,formFields:m,handleInput:o=>c(o,e,s),keapConf:e,setKeapConf:s,isLoading:i,setIsLoading:r,setSnackbar:a}),t.jsx(N,{edit:!0,saveConfig:()=>k({flow:n,setFlow:u,allIntegURL:f,conf:e,navigate:g,edit:1,setIsLoading:r,setSnackbar:a}),disabled:e.field_map.length<2,isLoading:i,dataConf:e,setDataConf:s,formFields:m}),t.jsx("br",{})]})}export{B as default};
