{"version":3,"file":"VAPI.C26T2vOB.mjs","names":[],"sources":["https:/framerusercontent.com/modules/ZnuUCUxFGixe5aAWJoGF/k3Sw1bgzDnn1H0IU3JWR/VAPI.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect}from\"react\";import{addPropertyControls,ControlType}from\"framer\";export default function VAPI(props){useEffect(()=>{const vapiComponent=document.getElementById(\"vapi\");const assistant=props.assistantID||\"56c4edab-bf9e-4a47-909a-0f2d9face11d\";const apiKey=props.apiKey||\"a6dbe9c1-a755-4b99-8db8-82f155e999b6\";const buttonConfig={position:\"bottom-right\",offset:\"40px\",width:\"50px\",height:\"50px\",idle:{color:`rgb(112, 57, 214)`,type:\"pill\",title:\"Have a quick question?\",subtitle:\"Talk with CR8OR AI assistant\",icon:`https://storage.googleapis.com/msgsndr/1MYZGk1d84joGG5pd8Dq/media/67b370931267c53f43e3e8f4.svg`},loading:{color:`rgb(93, 124, 202)`,type:\"pill\",title:\"Connecting...\",subtitle:\"Please wait\",icon:`https://unpkg.com/lucide-static@0.321.0/icons/loader-2.svg`},active:{color:`rgb(255, 0, 0)`,type:\"pill\",title:\"Call is in progress...\",subtitle:\"End the call.\",icon:`https://unpkg.com/lucide-static@0.321.0/icons/phone-off.svg`}};const script=document.createElement(\"script\");script.src=\"https://cdn.jsdelivr.net/gh/VapiAI/html-script-tag@latest/dist/assets/index.js\";script.defer=true;script.async=true;script.onload=()=>{const vapi=window.vapiSDK.run({apiKey,assistant,config:buttonConfig});if(vapi){const divToMove=document.getElementById(\"vapi-support-btn\");if(divToMove&&vapiComponent){vapiComponent.appendChild(divToMove);}}};document.body.appendChild(script);return()=>{if(script.parentNode){script.parentNode.removeChild(script);}};},[props.assistantID,props.apiKey]);return /*#__PURE__*/_jsx(\"div\",{id:\"vapi\",style:{width:\"100%\",height:\"100%\",display:\"flex\",justifyContent:\"center\",alignItems:\"center\"}});}addPropertyControls(VAPI,{assistantID:{type:ControlType.String,title:\"Assistant ID\",defaultValue:\"56c4edab-bf9e-4a47-909a-0f2d9face11d\"},apiKey:{type:ControlType.String,title:\"API Key\",defaultValue:\"a6dbe9c1-a755-4b99-8db8-82f155e999b6\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"VAPI\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./VAPI.map"],"mappings":"0SAA4H,SAAwB,EAAK,EAAM,CAAw2C,OAAv2C,MAAc,CAAC,IAAM,EAAc,SAAS,eAAe,OAAO,CAAO,EAAU,EAAM,aAAa,uCAA6C,EAAO,EAAM,QAAQ,uCAA6C,EAAa,CAAC,SAAS,eAAe,OAAO,OAAO,MAAM,OAAO,OAAO,OAAO,KAAK,CAAC,MAAM,oBAAoB,KAAK,OAAO,MAAM,yBAAyB,SAAS,+BAA+B,KAAK,iGAAiG,CAAC,QAAQ,CAAC,MAAM,oBAAoB,KAAK,OAAO,MAAM,gBAAgB,SAAS,cAAc,KAAK,6DAA6D,CAAC,OAAO,CAAC,MAAM,iBAAiB,KAAK,OAAO,MAAM,yBAAyB,SAAS,gBAAgB,KAAK,8DAA8D,CAAC,CAAO,EAAO,SAAS,cAAc,SAAS,CAAuY,MAAtY,GAAO,IAAI,iFAAiF,EAAO,MAAM,GAAK,EAAO,MAAM,GAAK,EAAO,WAAW,CAAuE,GAA3D,EAAO,QAAQ,IAAI,CAAC,SAAO,YAAU,OAAO,EAAa,CAAC,CAAS,CAAC,IAAM,EAAU,SAAS,eAAe,mBAAmB,CAAI,GAAW,GAAe,EAAc,YAAY,EAAU,GAAK,SAAS,KAAK,YAAY,EAAO,KAAW,CAAI,EAAO,YAAY,EAAO,WAAW,YAAY,EAAO,GAAM,CAAC,EAAM,YAAY,EAAM,OAAO,CAAC,CAAqB,EAAK,MAAM,CAAC,GAAG,OAAO,MAAM,CAAC,MAAM,OAAO,OAAO,OAAO,QAAQ,OAAO,eAAe,SAAS,WAAW,SAAS,CAAC,CAAC,sBAArmD,IAA6B,IAAoD,CAAshD,EAAoB,EAAK,CAAC,YAAY,CAAC,KAAK,EAAY,OAAO,MAAM,eAAe,aAAa,uCAAuC,CAAC,OAAO,CAAC,KAAK,EAAY,OAAO,MAAM,UAAU,aAAa,uCAAuC,CAAC,CAAC"}