{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/pQyZaGzVD2HpsSoD7dkU/tHMd9KdO7NArl5jioipD/Spotlight.js"],
  "sourcesContent": ["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useState,useRef}from\"react\";import{motion}from\"framer-motion\";function getRelativeCoordinates(event,referenceElement){const position={x:event.pageX,y:event.pageY};const offset={left:referenceElement.offsetLeft,top:referenceElement.offsetTop};let reference=referenceElement.offsetParent;while(reference){offset.left+=reference.offsetLeft;offset.top+=reference.offsetTop;reference=reference.offsetParent;}return{x:position.x-offset.left,y:position.y-offset.top};}export function withSpotlight(Component){const style={position:\"absolute\",width:\"100%\",height:\"100%\",zIndex:0,boxSizing:\"border-box\",borderRadius:\"inherit\",WebkitMaskImage:`radial-gradient(circle at center, rgb(255, 255, 255) 0%, rgba(0, 0, 0, 0) 100%)`,opacity:0,// Change this gradient\nbackgroundImage:`linear-gradient(to right, #183132, #17393B)`};return props=>{const[mousePosition,setMousePosition]=useState({x:0,y:0});const boxRef=useRef();const handleMouseMove=e=>{setMousePosition(getRelativeCoordinates(e,boxRef.current));};return /*#__PURE__*/_jsxs(Component,{...props,ref:boxRef,onMouseMove:e=>handleMouseMove(e),children:[/*#__PURE__*/_jsx(motion.div,{style:{...style},whileHover:{opacity:1},animate:{WebkitMaskImage:`radial-gradient(circle at ${mousePosition.x}px ${mousePosition.y}px, rgb(255, 255, 255) 0%, rgba(0, 0, 0, 0) 100%)`},transition:{duration:0}}),props.children]});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withSpotlight\":{\"type\":\"reactHoc\",\"name\":\"withSpotlight\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Spotlight.map"],
  "mappings": "uGAA8H,SAASA,EAAuBC,EAAMC,EAAiB,CAAC,IAAMC,EAAS,CAAC,EAAEF,EAAM,MAAM,EAAEA,EAAM,KAAK,EAAQG,EAAO,CAAC,KAAKF,EAAiB,WAAW,IAAIA,EAAiB,SAAS,EAAMG,EAAUH,EAAiB,aAAa,KAAMG,GAAWD,EAAO,MAAMC,EAAU,WAAWD,EAAO,KAAKC,EAAU,UAAUA,EAAUA,EAAU,aAAc,MAAM,CAAC,EAAEF,EAAS,EAAEC,EAAO,KAAK,EAAED,EAAS,EAAEC,EAAO,GAAG,CAAE,CAAQ,SAASE,EAAcC,EAAU,CAAC,IAAMC,EAAM,CAAC,SAAS,WAAW,MAAM,OAAO,OAAO,OAAO,OAAO,EAAE,UAAU,aAAa,aAAa,UAAU,gBAAgB,kFAAkF,QAAQ,EACnxB,gBAAgB,6CAA6C,EAAE,OAAOC,GAAO,CAAC,GAAK,CAACC,EAAcC,CAAgB,EAAEC,EAAS,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC,EAAQC,EAAOC,EAAO,EAAQC,EAAgBC,GAAG,CAACL,EAAiBX,EAAuBgB,EAAEH,EAAO,OAAO,CAAC,CAAE,EAAE,OAAoBI,EAAMV,EAAU,CAAC,GAAGE,EAAM,IAAII,EAAO,YAAYG,GAAGD,EAAgBC,CAAC,EAAE,SAAS,CAAcE,EAAKC,EAAO,IAAI,CAAC,MAAM,CAAC,GAAGX,CAAK,EAAE,WAAW,CAAC,QAAQ,CAAC,EAAE,QAAQ,CAAC,gBAAgB,6BAA6BE,EAAc,OAAOA,EAAc,oDAAoD,EAAE,WAAW,CAAC,SAAS,CAAC,CAAC,CAAC,EAAED,EAAM,QAAQ,CAAC,CAAC,CAAE,CAAE",
  "names": ["getRelativeCoordinates", "event", "referenceElement", "position", "offset", "reference", "withSpotlight", "Component", "style", "props", "mousePosition", "setMousePosition", "ye", "boxRef", "pe", "handleMouseMove", "e", "u", "p", "motion"]
}
