{"version":3,"file":"CircleSticker.hyRWkst6.mjs","names":[],"sources":["https:/framerusercontent.com/modules/SLMJEM5M1HovuaJLTFrX/iKOVrOKUfmdaGEv40IeL/CircleSticker.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{motion}from\"framer-motion\";// Mallow — Circle Sticker\n// Text running around a soft circle that slowly spins, with an optional\n// center glyph that wobbles. Speeds up gently on hover.\n/**\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n * @framerIntrinsicWidth 160\n * @framerIntrinsicHeight 160\n */export default function CircleSticker(props){const{text,glyph,background,color,glyphColor,duration,font,fontSize,direction}=props;const id=\"mallow-circle-\"+Math.abs(hash(text)).toString(36);const label=(text+\" \").repeat(Math.max(1,Math.round(60/Math.max(8,text.length))));return /*#__PURE__*/_jsxs(motion.div,{style:{width:\"100%\",height:\"100%\",position:\"relative\",borderRadius:\"50%\",background},whileHover:{scale:1.06},transition:{type:\"spring\",stiffness:300,damping:18},children:[/*#__PURE__*/_jsxs(motion.svg,{viewBox:\"0 0 200 200\",style:{position:\"absolute\",inset:0,width:\"100%\",height:\"100%\"},animate:{rotate:direction===\"Clockwise\"?360:-360},transition:{repeat:Infinity,ease:\"linear\",duration},children:[/*#__PURE__*/_jsx(\"defs\",{children:/*#__PURE__*/_jsx(\"path\",{id:id,d:\"M 100, 100 m -72, 0 a 72,72 0 1,1 144,0 a 72,72 0 1,1 -144,0\"})}),/*#__PURE__*/_jsx(\"text\",{style:{fontFamily:font.fontFamily,fontWeight:font.fontWeight,fontStyle:font.fontStyle,fontSize,letterSpacing:\"0.12em\",textTransform:\"uppercase\"},fill:color,children:/*#__PURE__*/_jsx(\"textPath\",{href:`#${id}`,textLength:452,lengthAdjust:\"spacing\",children:label})})]}),glyph&&/*#__PURE__*/_jsx(motion.div,{style:{position:\"absolute\",inset:0,display:\"flex\",alignItems:\"center\",justifyContent:\"center\",fontSize:\"34%\",color:glyphColor,fontFamily:font.fontFamily,lineHeight:1},animate:{rotate:[0,-12,10,0],scale:[1,1.08,1]},transition:{repeat:Infinity,duration:3.2,ease:\"easeInOut\"},children:/*#__PURE__*/_jsx(\"span\",{style:{fontSize:\"inherit\"},children:glyph})})]});}function hash(s){let h=0;for(let i=0;i<s.length;i++)h=(h<<5)-h+s.charCodeAt(i);return h;}CircleSticker.defaultProps={text:\"Baked fresh every morning ✿\",glyph:\"✿\",background:\"#F6C9D0\",color:\"#3B2A2F\",glyphColor:\"#D9577A\",duration:14,font:{fontFamily:\"DM Sans, sans-serif\",fontWeight:500},fontSize:15,direction:\"Clockwise\"};addPropertyControls(CircleSticker,{text:{type:ControlType.String,title:\"Text\"},glyph:{type:ControlType.String,title:\"Center\"},background:{type:ControlType.Color,title:\"Fill\"},color:{type:ControlType.Color,title:\"Text color\"},glyphColor:{type:ControlType.Color,title:\"Center color\"},duration:{type:ControlType.Number,title:\"Spin (s)\",min:2,max:60,step:1},direction:{type:ControlType.Enum,title:\"Direction\",options:[\"Clockwise\",\"Counter\"]},font:{type:ControlType.Font,title:\"Font\",controls:\"extended\",defaultFontType:\"sans-serif\"},fontSize:{type:ControlType.Number,title:\"Size\",min:8,max:40}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"CircleSticker\",\"slots\":[],\"annotations\":{\"framerIntrinsicWidth\":\"160\",\"framerIntrinsicHeight\":\"160\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\",\"framerSupportedLayoutHeight\":\"fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./CircleSticker.map"],"mappings":"oNAQG,SAAwB,EAAc,EAAM,CAAC,GAAK,CAAC,OAAK,QAAM,aAAW,QAAM,aAAW,WAAS,OAAK,WAAS,aAAW,EAAY,EAAG,iBAAiB,KAAK,IAAI,EAAK,CAAI,CAAC,CAAC,CAAC,SAAS,EAAE,EAAQ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