{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/TdHULzmw9kp0xQHRZglL/T58YMViHOMmd2f7hUTKk/MatrixButton.js"],
  "sourcesContent": ["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useEffect,useState}from\"react\";import{addPropertyControls,ControlType}from\"framer\";export default function MatrixButton({commandText=\"> execute: get_tickets.exe\",hoverText=\"ACCESS GRANTED\",buttonUrl=\"https://cosm.com/events/the-matrix\",glitchIntensity=3,glitchSpeed=.15,cursorBlinkSpeed=.5}){const[typedText,setTypedText]=useState(\"\");const[charIndex,setCharIndex]=useState(0);// Typing Effect using slice() to avoid \"undefined\" issue\nuseEffect(()=>{setTypedText(\"\")// Reset text when commandText changes\n;setCharIndex(0);const typingInterval=setInterval(()=>{setCharIndex(prevIndex=>{if(prevIndex<commandText.length){return prevIndex+1;}else{clearInterval(typingInterval);return prevIndex;}});},50);return()=>clearInterval(typingInterval);},[commandText]);const displayedText=commandText.slice(0,charIndex);return /*#__PURE__*/_jsx(\"div\",{style:styles.wrapper,children:/*#__PURE__*/_jsxs(\"button\",{style:styles.button,onClick:()=>window.open(buttonUrl,\"_blank\"),onMouseEnter:e=>e.currentTarget.children[1].style.transform=\"translateY(0)\",onMouseLeave:e=>e.currentTarget.children[1].style.transform=\"translateY(100%)\",children:[/*#__PURE__*/_jsxs(\"span\",{style:styles.typing,children:[displayedText,/*#__PURE__*/_jsx(\"span\",{style:{...styles.cursor,animationDuration:`${cursorBlinkSpeed}s`},children:\"\u2588\"})]}),/*#__PURE__*/_jsx(\"span\",{style:{...styles.overlay,animationDuration:`${glitchSpeed}s`},children:hoverText})]})});}// Styling\nconst styles={wrapper:{display:\"flex\",justifyContent:\"center\",alignItems:\"center\",minWidth:\"260px\",minHeight:\"50px\"},button:{color:\"#00FFB2\",background:\"transparent\",border:\"1px solid #00FFB2\",padding:\"1rem 2rem\",fontSize:\"1.2rem\",fontFamily:\"'Courier New', Courier, monospace\",position:\"relative\",overflow:\"hidden\",cursor:\"pointer\",transition:\"all 0.3s ease-in-out\"},typing:{display:\"inline-block\",whiteSpace:\"nowrap\",overflow:\"hidden\"},cursor:{borderLeft:\"2px solid #00FFB2\",marginLeft:\"2px\",animation:\"blink infinite alternate\"},overlay:{position:\"absolute\",top:0,left:0,height:\"100%\",width:\"100%\",backgroundColor:\"black\",color:\"#00FFB2\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\",transform:\"translateY(100%)\",transition:\"transform 0.3s ease-in-out\",fontFamily:\"'Courier New', Courier, monospace\",pointerEvents:\"none\"}};// Inject Keyframes for Blinking Cursor\nconst injectStyles=()=>{if(typeof document!==\"undefined\"){const styleSheet=document.createElement(\"style\");styleSheet.type=\"text/css\";styleSheet.innerHTML=`\n      @keyframes blink {\n        0% { opacity: 1; }\n        50% { opacity: 0; }\n        100% { opacity: 1; }\n      }\n    `;document.head.appendChild(styleSheet);}};injectStyles();// Expose adjustable properties in Framer UI\naddPropertyControls(MatrixButton,{commandText:{type:ControlType.String,title:\"Command Text\"},hoverText:{type:ControlType.String,title:\"Hover Text\"},buttonUrl:{type:ControlType.String,title:\"Button URL\"},glitchIntensity:{type:ControlType.Number,title:\"Glitch Intensity\",min:1,max:10,step:1,defaultValue:3},glitchSpeed:{type:ControlType.Number,title:\"Glitch Speed\",min:.05,max:1,step:.05,defaultValue:.15},cursorBlinkSpeed:{type:ControlType.Number,title:\"Cursor Blink Speed\",min:.2,max:1,step:.1,defaultValue:.5}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"MatrixButton\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./MatrixButton.map"],
  "mappings": "uHAAkK,SAARA,EAA8B,CAAC,YAAAC,EAAY,6BAA6B,UAAAC,EAAU,iBAAiB,UAAAC,EAAU,qCAAqC,gBAAAC,EAAgB,EAAE,YAAAC,EAAY,IAAI,iB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,WAAW,SAAS,SAAS,OAAO,UAAU,WAAW,sBAAsB,EAAE,OAAO,CAAC,QAAQ,eAAe,WAAW,SAAS,SAAS,QAAQ,EAAE,OAAO,CAAC,WAAW,oBAAoB,WAAW,MAAM,UAAU,0BAA0B,EAAE,QAAQ,CAAC,SAAS,WAAW,IAAI,EAAE,KAAK,EAAE,OAAO,OAAO,MAAM,OAAO,gBAAgB,QAAQ,MAAM,UAAU,QAAQ,OAAO,WAAW,SAAS,eAAe,SAAS,UAAU,mBAAmB,WAAW,6BAA6B,WAAW,oCAAoC,cAAc,MAAM,CAAC,EAC/zBI,EAAa,IAAI,CAAC,GAAG,OAAO,SAAW,IAAY,CAAC,IAAMC,EAAW,SAAS,cAAc,OAAO,EAAEA,EAAW,KAAK,WAAWA,EAAW,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MAMrJ,SAAS,KAAK,YAAYA,CAAU,CAAE,CAAC,EAAED,EAAa,EAC5DE,EAAoBvB,EAAa,CAAC,YAAY,CAAC,KAAKwB,EAAY,OAAO,MAAM,cAAc,EAAE,UAAU,CAAC,KAAKA,EAAY,OAAO,MAAM,YAAY,EAAE,UAAU,CAAC,KAAKA,EAAY,OAAO,MAAM,YAAY,EAAE,gBAAgB,CAAC,KAAKA,EAAY,OAAO,MAAM,mBAAmB,IAAI,EAAE,IAAI,GAAG,KAAK,EAAE,aAAa,CAAC,EAAE,YAAY,CAAC,KAAKA,EAAY,OAAO,MAAM,eAAe,IAAI,IAAI,IAAI,EAAE,KAAK,IAAI,aAAa,GAAG,EAAE,iBAAiB,CAAC,KAAKA,EAAY,OAAO,MAAM,qBAAqB,IAAI,GAAG,IAAI,EAAE,KAAK,GAAG,aAAa,EAAE,CAAC,CAAC",
  "names": ["MatrixButton", "commandText", "hoverText", "buttonUrl", "glitchIntensity", "glitchSpeed", "cursorBlinkSpeed", "typedText", "setTypedText", "ye", "charIndex", "setCharIndex", "ue", "typingInterval", "prevIndex", "displayedText", "p", "styles", "u", "window", "e", "injectStyles", "styleSheet", "addPropertyControls", "ControlType"]
}
