{"version":3,"file":"PulsingRedCircle.CdtSlEoZ.mjs","names":["useMemo","React"],"sources":["https:/framerusercontent.com/modules/Mury8kaVp2gXjOdBK4tB/j6VECJSjlNvSYs1iKjyP/PulsingRedCircle.js"],"sourcesContent":["// Instructions: make me this thing pulsing red circle. No green just wait background\nimport{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import React,{useMemo}from\"react\";import{addPropertyControls,ControlType,useIsStaticRenderer}from\"framer\";import{useInView}from\"framer-motion\";/**\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight any-prefer-fixed\n */export default function PulsingRedCircle(props){const{badgeText,countText,suffixText,showSuffix,showCount,gap,pillPaddingX,pillPaddingY,pillRadius,pillBorderWidth,pillBackground,pillBorderColor,pillTextColor,dotColor,dotRingColor,pulseDot,pulseScale,pulseOpacity,duration,blur,pillFont,countFont,suffixFont,style}=props;const isStatic=useIsStaticRenderer();const mergedStyle=useMemo(()=>({position:\"relative\",width:\"100%\",height:\"100%\",display:\"flex\",alignItems:\"center\",justifyContent:\"flex-start\",gap,...style}),[gap,style]);return /*#__PURE__*/_jsxs(\"div\",{style:mergedStyle,role:\"status\",\"aria-label\":\"Demand indicator\",children:[/*#__PURE__*/_jsxs(\"div\",{style:{position:\"relative\",display:\"inline-flex\",alignItems:\"center\",gap:12,padding:`${pillPaddingY}px ${pillPaddingX}px`,borderRadius:pillRadius,border:`${pillBorderWidth}px solid ${pillBorderColor}`,background:pillBackground,boxSizing:\"border-box\",flex:\"0 0 auto\"},children:[/*#__PURE__*/_jsx(Dot,{enabled:!isStatic&&pulseDot,dotColor:dotColor,ringColor:dotRingColor,pulseScale:pulseScale,pulseOpacity:pulseOpacity,duration:duration,blur:blur}),/*#__PURE__*/_jsx(\"span\",{style:{...pillFont,color:pillTextColor,letterSpacing:\"0.08em\",textTransform:\"uppercase\",whiteSpace:\"nowrap\",minWidth:\"max-content\"},children:badgeText})]}),(showCount||showSuffix)&&/*#__PURE__*/_jsxs(\"div\",{style:{position:\"relative\",display:\"inline-flex\",alignItems:\"baseline\",gap:8,flex:\"0 0 auto\",whiteSpace:\"nowrap\"},children:[showCount&&/*#__PURE__*/_jsx(\"span\",{style:{...countFont,minWidth:\"max-content\"},children:countText}),showSuffix&&/*#__PURE__*/_jsx(\"span\",{style:{...suffixFont,minWidth:\"max-content\"},children:suffixText})]})]});}function Dot({enabled,dotColor,ringColor,pulseScale,pulseOpacity,duration,blur}){const ref=React.useRef(null);const inView=useInView(ref,{amount:.2});const shouldAnimate=enabled&&inView;const shadowColor=React.useMemo(()=>{if(!dotColor)return\"rgba(233, 61, 60, 0.45)\";const c=dotColor.trim();if(c.startsWith(\"#\")){const hex=c.slice(1);const norm=hex.length===3?hex.split(\"\").map(x=>x+x).join(\"\"):hex;if(norm.length===6){const r=parseInt(norm.slice(0,2),16);const g=parseInt(norm.slice(2,4),16);const b=parseInt(norm.slice(4,6),16);return`rgba(${r}, ${g}, ${b}, 0.45)`;}}return\"rgba(233, 61, 60, 0.45)\";},[dotColor]);return /*#__PURE__*/_jsxs(\"div\",{ref:ref,style:{position:\"relative\",width:14,height:14,flex:\"0 0 auto\"},\"aria-hidden\":\"true\",children:[/*#__PURE__*/_jsx(\"style\",{dangerouslySetInnerHTML:{__html:`@keyframes currentPulse {\n  0% { transform: scale(1); box-shadow: 0 0 0 0 ${shadowColor}; }\n  70% { transform: scale(${pulseScale}); box-shadow: 0 0 0 8px rgba(233, 61, 60, 0); }\n  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(233, 61, 60, 0); }\n}`}}),/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",inset:0,borderRadius:9999,background:ringColor}}),/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",inset:0,borderRadius:9999,background:dotColor,transformOrigin:\"50% 50%\",filter:blur>0?`blur(${blur}px)`:undefined,willChange:shouldAnimate?\"transform, box-shadow\":undefined,animation:shouldAnimate?`currentPulse ${duration}s ease-in-out infinite`:undefined}})]});}addPropertyControls(PulsingRedCircle,{badgeText:{type:ControlType.String,title:\"Badge\",defaultValue:\"HIGH DEMAND\"},countText:{type:ControlType.String,title:\"Count\",defaultValue:\"2,745\"},suffixText:{type:ControlType.String,title:\"Suffix\",defaultValue:\"registered in the last 24 hours\"},showCount:{type:ControlType.Boolean,title:\"Show Count\",defaultValue:true,enabledTitle:\"Show\",disabledTitle:\"Hide\"},showSuffix:{type:ControlType.Boolean,title:\"Show Suffix\",defaultValue:true,enabledTitle:\"Show\",disabledTitle:\"Hide\"},gap:{type:ControlType.Number,title:\"Gap\",defaultValue:16,min:0,max:80,step:1,unit:\"px\"},pillPaddingX:{type:ControlType.Number,title:\"Pad X\",defaultValue:18,min:8,max:40,step:1,unit:\"px\"},pillPaddingY:{type:ControlType.Number,title:\"Pad Y\",defaultValue:10,min:4,max:30,step:1,unit:\"px\"},pillRadius:{type:ControlType.Number,title:\"Radius\",defaultValue:999,min:0,max:999,step:1,unit:\"px\"},pillBorderWidth:{type:ControlType.Number,title:\"Border\",defaultValue:3,min:0,max:10,step:1,unit:\"px\"},pillBackground:{type:ControlType.Color,title:\"Pill BG\",defaultValue:\"#FCE7E5\"},pillBorderColor:{type:ControlType.Color,title:\"Pill Border\",defaultValue:\"#E85A4F\"},pillTextColor:{type:ControlType.Color,title:\"Pill Text\",defaultValue:\"#E85A4F\"},dotRingColor:{type:ControlType.Color,title:\"Dot Ring\",defaultValue:\"#F3B0AA\"},dotColor:{type:ControlType.Color,title:\"Dot\",defaultValue:\"#E85A4F\"},pulseDot:{type:ControlType.Boolean,title:\"Pulse\",defaultValue:true,enabledTitle:\"On\",disabledTitle:\"Off\"},pulseScale:{type:ControlType.Number,title:\"Pulse Scale\",defaultValue:1.18,min:1,max:2,step:.01,hidden:({pulseDot})=>!pulseDot},pulseOpacity:{type:ControlType.Number,title:\"Pulse Opacity\",defaultValue:.65,min:0,max:1,step:.01,hidden:({pulseDot})=>!pulseDot},duration:{type:ControlType.Number,title:\"Duration\",defaultValue:1.2,min:.2,max:6,step:.05,unit:\"s\",hidden:({pulseDot})=>!pulseDot},blur:{type:ControlType.Number,title:\"Blur\",defaultValue:0,min:0,max:10,step:.5,unit:\"px\",hidden:({pulseDot})=>!pulseDot},pillFont:{type:ControlType.Font,title:\"Pill Font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"20px\",variant:\"Bold\",letterSpacing:\"0.08em\",lineHeight:\"1em\"}},countFont:{type:ControlType.Font,title:\"Count Font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"30px\",variant:\"Bold\",letterSpacing:\"-0.02em\",lineHeight:\"1em\"}},suffixFont:{type:ControlType.Font,title:\"Suffix Font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"28px\",variant:\"Medium\",letterSpacing:\"-0.02em\",lineHeight:\"1em\"}}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"PulsingRedCircle\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"any-prefer-fixed\",\"framerSupportedLayoutWidth\":\"any-prefer-fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./PulsingRedCircle.map"],"mappings":"iPAIG,SAAwB,EAAiB,EAAM,CAAC,GAAK,CAAC,YAAU,YAAU,aAAW,aAAW,YAAU,MAAI,eAAa,eAAa,aAAW,kBAAgB,iBAAe,kBAAgB,gBAAc,WAAS,eAAa,WAAS,aAAW,eAAa,WAAS,OAAK,WAAS,YAAU,aAAW,SAAO,EAAY,EAAS,GAAqB,CAA2K,OAAoB,EAAM,MAAM,CAAC,MAAzLA,OAAa,CAAC,SAAS,WAAW,MAAM,OAAO,OAAO,OAAO,QAAQ,OAAO,WAAW,SAAS,eAAe,aAAa,MAAI,GAAG,EAAM,EAAE,CAAC,EAAI,EAAM,CAAC,CAAoD,KAAK,SAAS,aAAa,mBAAmB,SA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