{"version":3,"file":"TextShimmer.VJ6rtIgn.mjs","names":["useRef","useState"],"sources":["https:/framerusercontent.com/modules/h8ioHyt4BUxuvVCE1Q10/aTM6mEMGlM19JjX8exDe/AvoidLayoutJumping_Prod.js","https:/framerusercontent.com/modules/ksIvuBAeux8ie4t4cDZN/AnnrP5Kx6J72KlYdfGrV/TextShimmer.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";import{useEffect,useRef}from\"react\";/**\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n *\n * @framerDisableUnlink\n */export default function AvoidLayoutJumping({direction,style}){const isCanvas=RenderTarget.current()===RenderTarget.canvas;const ref=useRef(null);const rafId=useRef();const vertical=direction===\"vertical\"||direction===\"both\";const horizontal=direction===\"horizontal\"||direction===\"both\";useEffect(()=>{if(isCanvas)return;const parent=ref.current?.parentElement?.parentElement;if(!parent)return;const container=parent.parentElement;if(!container)return;const updateSize=()=>{const rect=parent.getBoundingClientRect();if(horizontal){container.style.width=`${rect.width}px`;}if(vertical){container.style.height=`${rect.height}px`;}rafId.current=requestAnimationFrame(updateSize);};// Start the RAF loop\nrafId.current=requestAnimationFrame(updateSize);return()=>{if(rafId.current){cancelAnimationFrame(rafId.current);}if(container){if(horizontal){container.style.width=\"\";}if(vertical){container.style.height=\"\";}}};},[direction]);return /*#__PURE__*/_jsx(\"div\",{ref:ref,style:{...style}});}AvoidLayoutJumping.displayName=\"Layout Jump Preventer\";addPropertyControls(AvoidLayoutJumping,{direction:{type:ControlType.Enum,defaultValue:\"vertical\",options:[\"vertical\",\"horizontal\",\"both\"],optionTitles:[\"Vertical\",\"Horizontal\",\"Both\"],displaySegmentedControl:true,segmentedControlDirection:\"vertical\",// @ts-ignore\noptionIcons:[\"direction-vertical\",\"direction-horizontal\",\"direction-all\"],description:\"More components at [Framer University](https://frameruni.link/cc).\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"AvoidLayoutJumping\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerDisableUnlink\":\"\",\"framerSupportedLayoutWidth\":\"auto\",\"framerSupportedLayoutHeight\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./AvoidLayoutJumping_Prod.map","// Text component with gradient colors, font controls, and shimmer effect on hover\nimport{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useState}from\"react\";/**\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function TextShimmer(props){const{text=\"Gradient Text\",font,textColor=\"linear-gradient(90deg, #2ED1A6 0%, #207AF9 50%, #8000FF 100%)\",uppercase=false,shimmerEnabled=true,shimmerSpeed=3.5,shimmerIntensity=.6,shimmerStartPosition=-200,shimmerEndPosition=200,rotationSpeed=2,rotationEnabled=false,padding=\"16px\",style}=props;const[isHovered,setIsHovered]=useState(false);const shimmerGradient=`linear-gradient(90deg, transparent 30%, rgba(255,255,255,${shimmerIntensity}) 50%, transparent 70%)`;const textStyle={background:textColor,WebkitBackgroundClip:\"text\",WebkitTextFillColor:\"transparent\",backgroundClip:\"text\",display:\"inline-block\",position:\"relative\",textTransform:uppercase?\"uppercase\":\"none\",width:\"max-content\",...font};const shimmerStyle={position:\"absolute\",top:0,left:0,right:0,bottom:0,background:shimmerGradient,backgroundSize:\"200% 100%\",WebkitBackgroundClip:\"text\",WebkitTextFillColor:\"transparent\",backgroundClip:\"text\",opacity:isHovered&&shimmerEnabled?1:0,pointerEvents:\"none\",textTransform:uppercase?\"uppercase\":\"none\",...font};return /*#__PURE__*/_jsxs(\"div\",{style:{...style,position:\"relative\",display:\"inline-flex\",alignItems:\"center\",width:\"max-content\",padding:padding,overflowY:\"hidden\"},onMouseEnter:()=>setIsHovered(true),onMouseLeave:()=>setIsHovered(false),children:[/*#__PURE__*/_jsx(\"style\",{children:`\n                @keyframes shimmer {\n                    0% {\n                        background-position: ${shimmerEndPosition}% 0;\n                    }\n                    100% {\n                        background-position: ${shimmerStartPosition}% 0;\n                    }\n                }\n                \n                @keyframes rotate {\n                    0% {\n                        transform: rotate(0deg);\n                    }\n                    100% {\n                        transform: rotate(360deg);\n                    }\n                }\n                `}),/*#__PURE__*/_jsxs(\"div\",{style:{position:\"relative\",display:\"inline-block\",animation:rotationEnabled?`rotate ${rotationSpeed}s linear infinite`:\"none\"},children:[/*#__PURE__*/_jsx(\"span\",{style:textStyle,children:text}),shimmerEnabled&&/*#__PURE__*/_jsx(\"span\",{style:{...shimmerStyle,animation:isHovered?`shimmer ${shimmerSpeed}s linear infinite`:\"none\"},children:text})]})]});}addPropertyControls(TextShimmer,{text:{type:ControlType.String,title:\"Text\",defaultValue:\"Gradient Text\"},font:{type:ControlType.Font,title:\"Font\",defaultValue:{fontSize:\"32px\",variant:\"Bold\",letterSpacing:\"-0.02em\",lineHeight:\"1.2em\"},controls:\"extended\",defaultFontType:\"sans-serif\"},textColor:{type:ControlType.String,title:\"Text Color\",defaultValue:\"linear-gradient(90deg, #2ED1A6 0%, #207AF9 50%, #8000FF 100%)\",placeholder:\"Enter CSS gradient or color\"},uppercase:{type:ControlType.Boolean,title:\"Uppercase\",defaultValue:false,enabledTitle:\"On\",disabledTitle:\"Off\"},padding:{type:ControlType.Padding,title:\"Padding\",defaultValue:\"16px\"},shimmerEnabled:{type:ControlType.Boolean,title:\"Shimmer Effect\",defaultValue:true,enabledTitle:\"On\",disabledTitle:\"Off\"},shimmerSpeed:{type:ControlType.Number,title:\"Shimmer Speed\",defaultValue:3.5,min:.5,max:5,step:.1,unit:\"s\",hidden:({shimmerEnabled})=>!shimmerEnabled},shimmerIntensity:{type:ControlType.Number,title:\"Shimmer Intensity\",defaultValue:.6,min:.1,max:1,step:.1,hidden:({shimmerEnabled})=>!shimmerEnabled},shimmerStartPosition:{type:ControlType.Number,title:\"Start Position\",defaultValue:-200,min:-300,max:300,step:10,unit:\"%\",hidden:({shimmerEnabled})=>!shimmerEnabled},shimmerEndPosition:{type:ControlType.Number,title:\"End Position\",defaultValue:200,min:-300,max:300,step:10,unit:\"%\",hidden:({shimmerEnabled})=>!shimmerEnabled},rotationEnabled:{type:ControlType.Boolean,title:\"Rotation\",defaultValue:false,enabledTitle:\"On\",disabledTitle:\"Off\"},rotationSpeed:{type:ControlType.Number,title:\"Rotation Speed\",defaultValue:2,min:.5,max:10,step:.1,unit:\"s\",hidden:({rotationEnabled})=>!rotationEnabled}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"TextShimmer\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"auto\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./TextShimmer.map"],"mappings":"sMAKG,SAAwB,EAAmB,CAAC,YAAU,SAAO,CAAC,IAAM,EAAS,EAAa,SAAS,GAAG,EAAa,OAAa,EAAIA,EAAO,KAAK,CAAO,EAAMA,GAAQ,CAAO,EAAS,IAAY,YAAY,IAAY,OAAa,EAAW,IAAY,cAAc,IAAY,OACvD,OAD8D,MAAc,CAAC,GAAG,EAAS,OAAO,IAAM,EAAO,EAAI,SAAS,eAAe,cAAc,GAAG,CAAC,EAAO,OAAO,IAAM,EAAU,EAAO,cAAc,GAAG,CAAC,EAAU,OAAO,IAAM,MAAe,CAAC,IAAM,EAAK,EAAO,uBAAuB,CAAI,IAAY,EAAU,MAAM,MAAM,GAAG,EAAK,MAAM,KAAQ,IAAU,EAAU,MAAM,OAAO,GAAG,EAAK,OAAO,KAAK,EAAM,QAAQ,sBAAsB,EAAW,EACrnB,MAAhD,GAAM,QAAQ,sBAAsB,EAAW,KAAW,CAAI,EAAM,SAAS,qBAAqB,EAAM,QAAQ,CAAK,IAAc,IAAY,EAAU,MAAM,MAAM,IAAO,IAAU,EAAU,MAAM,OA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