{"version":3,"file":"TextShiner.Bdk1ITnW.mjs","names":["React.useRef","gsap"],"sources":["https:/framerusercontent.com/modules/hTQxuHfW6qsAKxSOBzLy/5nDdEJJ4ITY5KlFAWB8b/TextShiner.js"],"sourcesContent":["// Built by OceanDevs [X]@tymofgr✨\n/**\n * @framerLockCode\n */import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import*as React from\"react\";import{addPropertyControls,ControlType}from\"framer\";import gsap from\"gsap\";/**\n * @framerDisableUnlink\n * @framerDisableRename\n */export default function ShiningGlowText(props){const{text,font,textColor,glowColor,glowMin,glowMax,speed,easing,glowMotion,loopDirection,shineEffect,shineColor,appearAnimation,blurAmount,duration,textSelectable,iconEnable,iconImage=\"https://i.ibb.co.com/dwhsmYzH/sparkles.png\",iconPulseSpeed}=props;const containerRef=React.useRef(null);const glowRef=React.useRef(null);const shineRef=React.useRef(null);const iconRef=React.useRef(null);// Appear animation (runs only once)\nReact.useEffect(()=>{if(!containerRef.current)return;const el=containerRef.current;let fromVars={opacity:0,filter:`blur(${blurAmount}px)`};switch(appearAnimation){case\"bottom\":fromVars.y=20;break;case\"top\":fromVars.y=-20;break;case\"left\":fromVars.x=-20;break;case\"right\":fromVars.x=20;break;}gsap.fromTo(el,fromVars,{opacity:1,x:0,y:0,filter:\"blur(0px)\",duration,ease:\"power2.out\"});},[]);// Glow, Shine & Icon animation\nReact.useEffect(()=>{if(!glowRef.current)return;const start=loopDirection===\"left\"?\"-150%\":\"150%\";const end=loopDirection===\"left\"?\"150%\":\"-150%\";gsap.set(glowRef.current,{backgroundPositionX:start});const glowTween=gsap.to(glowRef.current,{backgroundPositionX:end,duration:speed,ease:easing,repeat:-1,yoyo:glowMotion===\"mirror\"});const pulseTween=gsap.to(glowRef.current,{filter:`drop-shadow(0 0 ${glowMin}px ${glowColor}) drop-shadow(0 0 ${glowMax}px ${glowColor})`,duration:1.5,repeat:-1,yoyo:true,ease:\"sine.inOut\"});let shineTween;if(shineEffect&&shineRef.current){gsap.set(shineRef.current,{backgroundPositionX:start});shineTween=gsap.to(shineRef.current,{backgroundPositionX:end,duration:speed,ease:easing,repeat:-1,yoyo:glowMotion===\"mirror\"});}let iconTween;if(iconEnable&&iconRef.current){iconTween=gsap.to(iconRef.current,{filter:`drop-shadow(0 0 ${glowMin}px ${glowColor}) drop-shadow(0 0 ${glowMax}px ${glowColor})`,duration:iconPulseSpeed,repeat:-1,yoyo:true,ease:\"sine.inOut\"});}return()=>{glowTween.kill();pulseTween.kill();if(shineTween)shineTween.kill();if(iconTween)iconTween.kill();};},[speed,easing,glowMotion,loopDirection,shineEffect,glowMin,glowMax,glowColor,iconPulseSpeed,iconEnable]);const iconStyle={width:\"1em\",height:\"1em\",userSelect:\"none\",WebkitUserSelect:\"none\",pointerEvents:\"none\"};const justifyMap={left:\"flex-start\",center:\"center\",right:\"flex-end\"};return /*#__PURE__*/_jsxs(\"span\",{ref:containerRef,style:{position:\"relative\",display:\"inline-flex\",alignItems:\"center\",gap:iconEnable&&iconImage?6:0,whiteSpace:\"pre\",color:textColor,userSelect:textSelectable?\"text\":\"none\",...font,textShadow:\"0 0 0 transparent\"},children:[/*#__PURE__*/_jsxs(\"span\",{ref:glowRef,\"aria-hidden\":true,style:{position:\"absolute\",inset:0,display:\"inline-flex\",alignItems:\"center\",gap:iconEnable&&iconImage?6:0,pointerEvents:\"none\",backgroundImage:`linear-gradient(\n                        90deg,\n                        transparent 0%,\n                        transparent 30%,\n                        ${glowColor} 50%,\n                        transparent 70%,\n                        transparent 100%\n                    )`,backgroundSize:\"300% 100%\",WebkitBackgroundClip:\"text\",backgroundClip:\"text\",WebkitTextFillColor:\"transparent\",filter:`drop-shadow(0 0 ${glowMin}px ${glowColor}) drop-shadow(0 0 ${glowMax}px ${glowColor})`,zIndex:2},children:[iconEnable&&iconImage&&/*#__PURE__*/_jsx(\"img\",{ref:iconRef,src:iconImage,alt:\"icon\",style:iconStyle}),text]}),shineEffect&&/*#__PURE__*/_jsxs(\"span\",{ref:shineRef,\"aria-hidden\":true,style:{position:\"absolute\",inset:0,display:\"inline-flex\",alignItems:\"center\",gap:iconEnable&&iconImage?6:0,backgroundImage:`linear-gradient(\n                            120deg,\n                            transparent 45%,\n                            ${shineColor} 50%,\n                            transparent 55%\n                        )`,backgroundSize:\"300% 100%\",WebkitBackgroundClip:\"text\",backgroundClip:\"text\",WebkitTextFillColor:\"transparent\",pointerEvents:\"none\",zIndex:4},children:[iconEnable&&iconImage&&/*#__PURE__*/_jsx(\"img\",{src:iconImage,alt:\"icon\",style:iconStyle}),text]}),/*#__PURE__*/_jsxs(\"span\",{style:{position:\"relative\",zIndex:3,display:\"inline-flex\",alignItems:\"center\",gap:iconEnable&&iconImage?6:0},children:[iconEnable&&iconImage&&/*#__PURE__*/_jsx(\"img\",{src:iconImage,alt:\"icon\",style:iconStyle}),text]})]});}// -------------------- Framer Controls --------------------\naddPropertyControls(ShiningGlowText,{// --- Icon ---\niconEnable:{type:ControlType.Boolean,title:\"Enable Icon\",defaultValue:false},iconImage:{type:ControlType.Image,title:\"Upload Icon\",hidden:props=>!props.iconEnable},// --- Text ---\ntext:{type:ControlType.String,title:\"Text\",defaultValue:\"Text Shiner & True Glow Effect\"},font:{type:ControlType.Font,title:\"Font\",controls:\"extended\"},textSelectable:{type:ControlType.Boolean,title:\"Text Selectable\",defaultValue:true},textColor:{type:ControlType.Color,title:\"Text Color\",defaultValue:\"#133942\"},// --- Glow ---\nglowColor:{type:ControlType.Color,title:\"Glow Color\",defaultValue:\"#013737\"},glowMin:{type:ControlType.Number,title:\"Glow Min\",min:0,max:40,defaultValue:4},glowMax:{type:ControlType.Number,title:\"Glow Max\",min:5,max:120,defaultValue:22},speed:{type:ControlType.Number,title:\"Glow Speed (s)\",min:.5,max:12,step:.1,defaultValue:3},iconPulseSpeed:{type:ControlType.Number,title:\"Icon Pulse Speed\",min:.2,max:5,step:.1,defaultValue:1.2,hidden:props=>!props.iconEnable},glowMotion:{type:ControlType.Enum,title:\"Glow Motion\",options:[\"mirror\",\"loop\"],defaultValue:\"loop\"},loopDirection:{type:ControlType.Enum,title:\"Loop Direction\",options:[\"left\",\"right\"],defaultValue:\"right\"},easing:{type:ControlType.Enum,title:\"Easing\",options:[\"linear\",\"sine.inOut\",\"power1.inOut\",\"power2.inOut\"],defaultValue:\"linear\"},// --- Shine ---\nshineEffect:{type:ControlType.Boolean,title:\"Shine Effect\",defaultValue:false},shineColor:{type:ControlType.Color,title:\"Shine Color\",defaultValue:\"#35675c\",hidden:props=>!props.shineEffect},// --- Appear Animation ---\nappearAnimation:{type:ControlType.Enum,title:\"Appear\",options:[\"none\",\"bottom\",\"top\",\"left\",\"right\"],defaultValue:\"none\"},blurAmount:{type:ControlType.Number,title:\"Blur\",min:0,max:20,defaultValue:5},duration:{type:ControlType.Number,title:\"Duration\",min:.1,max:5,defaultValue:.6,description:\"[AriniStudio](https://arini.studio) ✦ Developed By GrTuhin\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ShiningGlowText\",\"slots\":[],\"annotations\":{\"framerDisableUnlink\":\"* @framerDisableRename\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./TextShiner.map"],"mappings":"6OAMG,SAAwB,EAAgB,EAAM,CAAC,GAAK,CAAC,OAAK,OAAK,YAAU,YAAU,UAAQ,UAAQ,QAAM,SAAO,aAAW,gBAAc,cAAY,aAAW,kBAAgB,aAAW,WAAS,iBAAe,aAAW,YAAU,6CAA6C,kBAAgB,EAAY,EAAaA,EAAa,KAAK,CAAO,EAAQA,EAAa,KAAK,CAAO,EAASA,EAAa,KAAK,CAAO,EAAQA,EAAa,KAAK,CACvb,MAAoB,CAAC,GAAG,CAAC,EAAa,QAAQ,OAAO,IAAM,EAAG,EAAa,QAAY,EAAS,CAAC,QAAQ,EAAE,OAAO,QAAQ,EAAW,KAAK,CAAC,OAAO,EAAP,CAAwB,IAAI,SAAS,EAAS,EA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