var z=Object.defineProperty;var u=Object.getOwnPropertySymbols;var L=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable;var b=(r,e,s)=>e in r?z(r,e,{enumerable:!0,configurable:!0,writable:!0,value:s}):r[e]=s,p=(r,e)=>{for(var s in e||(e={}))L.call(e,s)&&b(r,s,e[s]);if(u)for(var s of u(e))f.call(e,s)&&b(r,s,e[s]);return r};import{j as t,_ as a}from"./main.2.8.1.js";import{d as x}from"./react-router-dom.9mCuUg3q.js";import{t as A}from"./tutorialLinks.kMkIDzcD.js";import{a9 as T,z as w}from"./Note.BeM7sN-p.js";import{T as h}from"./TutorialLink.BAFX--T3.js";import{n as I}from"./NotificationXCommonFunc.CNvphlgG.js";import"./CopyIcn.3gZpHton.js";function B({formID:r,notificationXConf:e,setNotificationXConf:s,step:o,nextPage:g,isLoading:l,setIsLoading:j,isInfo:m}){const[n,N]=x.useState(!1),[k,y]=x.useState({name:""}),{notificationX:i}=A,v=d=>{const c=p({},e);c[d.target.name]=d.target.value,s(c)};return t.jsxs("div",{className:"btcd-stp-page",style:{width:o===1&&900,height:o===1&&"auto"},children:[(i==null?void 0:i.youTubeLink)&&t.jsx(h,{title:"NotificationX",youTubeLink:i==null?void 0:i.youTubeLink}),(i==null?void 0:i.docLink)&&t.jsx(h,{title:"NotificationX",docLink:i==null?void 0:i.docLink}),t.jsx("div",{className:"mt-3",children:t.jsx("b",{children:a("Integration Name:","bit-integrations")})}),t.jsx("input",{className:"btcd-paper-inp w-6 mt-1",onChange:v,name:"name",value:e.name,type:"text",placeholder:a("Integration Name...","bit-integrations"),disabled:m}),t.jsx("div",{style:{color:"red",fontSize:"15px"},children:k.name}),t.jsx(T,{note:a("To use NotificationX integration, make sure NotificationX plugin is installed and active on your site.","bit-integrations")}),!m&&t.jsxs(t.Fragment,{children:[t.jsxs("button",{onClick:()=>I(e,s,y,N,j),className:"btn btcd-btn-lg purple sh-sm flx",type:"button",disabled:n||l,children:[n?a("Authorized ✔","bit-integrations"):a("Authorize","bit-integrations"),l&&t.jsx(w,{size:20,clr:"#022217",className:"ml-2"})]}),t.jsx("br",{}),t.jsxs("button",{onClick:()=>g(2),className:"btn f-right btcd-btn-lg purple sh-sm flx",type:"button",disabled:!n,children:[a("Next","bit-integrations"),t.jsx("div",{className:"btcd-icn icn-arrow_back rev-icn d-in-b"})]})]})]})}export{B as default};
