{"version":3,"file":"TextFl2.CK5XIs_T.mjs","names":[],"sources":["https:/framerusercontent.com/modules/u9OElX4zPBYa8oRqhnSg/cgeV5EaxNzxhCbNzPBjZ/TextFl2.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";// HTML entities that are decoded before rendering.\n// Extend this map if more entities are needed (e.g. \"&amp;\": \"&\").\nconst ENTITIES={\"&nbsp;\":\"\\xa0\",\"&shy;\":\"\\xad\"};const ENTITY_REGEX=new RegExp(Object.keys(ENTITIES).join(\"|\"),\"g\");function decodeEntities(str){return str.replace(ENTITY_REGEX,entity=>ENTITIES[entity]);}export function ColoredTextBalance({text=\"\",fontSize=16,fontFamily=\"Poppins\",fontWeight=400,lineHeight=1.5,letterSpacing=0,textAlign=\"left\",textColor=\"#000000\",balance=true}){// Decode entities first so they work both in plain text and inside [fi]...[/fi]\nconst decoded=decodeEntities(text);const regex=/\\[fi\\](.*?)\\[\\/fi\\]/g;const parts=[];let lastIndex=0;let match;while((match=regex.exec(decoded))!==null){if(match.index>lastIndex){parts.push(decoded.slice(lastIndex,match.index));}parts.push(/*#__PURE__*/_jsx(\"span\",{style:{color:\"#FE42B4\"},children:match[1]},match.index));lastIndex=match.index+match[0].length;}if(lastIndex<decoded.length){parts.push(decoded.slice(lastIndex));}return /*#__PURE__*/_jsx(\"div\",{style:{fontSize,fontFamily,fontWeight,lineHeight,letterSpacing:`${letterSpacing}em`,textAlign,color:textColor,textWrap:balance?\"balance\":\"wrap\"},children:parts});}addPropertyControls(ColoredTextBalance,{text:{type:ControlType.String,title:\"Text\",defaultValue:\"Local [fi]IBAN[/fi] in 72 hours\"},textColor:{type:ControlType.Color,title:\"Text Color\",defaultValue:\"#000000\"},fontSize:{type:ControlType.Number,title:\"Font Size\",defaultValue:16,min:8,max:100},fontFamily:{type:ControlType.String,title:\"Font Family\",defaultValue:\"Inter\"},fontWeight:{type:ControlType.Number,title:\"Font Weight\",defaultValue:400,min:100,max:900,step:100},lineHeight:{type:ControlType.Number,title:\"Line Height\",defaultValue:1.5,min:.5,max:3,step:.1},letterSpacing:{type:ControlType.Number,title:\"Letter (em)\",defaultValue:0,min:-.1,max:.5,step:.005},textAlign:{type:ControlType.Enum,title:\"Text Align\",options:[\"left\",\"center\",\"right\",\"justify\"],defaultValue:\"left\"},balance:{type:ControlType.Boolean,title:\"Balance\",enabledTitle:\"Yes\",disabledTitle:\"No\",defaultValue:true}});\nexport const __FramerMetadata__ = {\"exports\":{\"ColoredTextBalance\":{\"type\":\"reactComponent\",\"name\":\"ColoredTextBalance\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./TextFl2.map"],"mappings":"6JAEmH,SAAS,EAAe,EAAI,CAAC,OAAO,EAAI,QAAQ,EAAa,GAAQ,EAAS,EAAO,CAAE,CAAC,SAAgB,EAAmB,CAAC,OAAK,GAAG,WAAS,GAAG,aAAW,UAAU,aAAW,IAAI,aAAW,IAAI,gBAAc,EAAE,YAAU,OAAO,YAAU,UAAU,UAAQ,IAAM,CACzX,IAAM,EAAQ,EAAe,CAAI,EAAQ,EAAM,uBAA6B,EAAM,CAAC,EAAM,EAAU,EAAM,EAAM,MAAO,EAAM,EAAM,KAAK,CAAO,KAAK,MAAS,EAAM,MAAM,GAAW,EAAM,KAAK,EAAQ,MAAM,EAAU,EAAM,KAAK,CAAC,EAAG,EAAM,KAAkB,EAAK,OAAO,CAAC,MAAM,CAAC,MAAM,SAAS,EAAE,SAAS,EAAM,EAAE,EAAE,EAAM,KAAK,CAAC,EAAE,EAAU,EAAM,MAAM,EAAM,EAAE,CAAC,OAA2E,OAAhE,EAAU,EAAQ,QAAQ,EAAM,KAAK,EAAQ,MAAM,CAAS,CAAC,EAAuB,EAAK,MAAM,CAAC,MAAM,CAAC,WAAS,aAAW,aAAW,aAAW,cAAc,GAAG,EAAc,IAAI,YAAU,MAAM,EAAU,SAAS,E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