{"version":3,"file":"shared.DCVtIgpu.mjs","names":[],"sources":["https:/framerusercontent.com/modules/jVLLjQHkvkEyEzQOaLBo/k8YqwzY4mNcTLXWCDNNs/TypewriterText_2.js"],"sourcesContent":["// Typing effect text component\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/**\n * TypewriterText\n *\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function TypewriterText(props){const{text,font,color,style,highlight=\"\",highlightColor=\"#FFBB00\",highlight2=\"\",highlight2Color=\"#00BBFF\"}=props;const displayed=text;return /*#__PURE__*/_jsx(\"div\",{style:{width:\"100%\",height:\"100%\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\",boxSizing:\"border-box\",overflow:\"hidden\"},children:/*#__PURE__*/_jsx(\"span\",{style:{...font,color,...style,width:\"fit-content\",minWidth:0,maxWidth:\"100%\",whiteSpace:\"pre-wrap\",wordBreak:\"break-word\",textAlign:\"center\",boxSizing:\"border-box\",overflowWrap:\"break-word\",overflow:\"hidden\",display:\"block\",fontWeight:font?.variant===\"Bold\"?700:font?.variant===\"Semibold\"?600:font?.variant===\"Medium\"?500:font?.variant===\"Regular\"?400:undefined},\"aria-label\":text,role:\"text\",tabIndex:0,children:(()=>{if(!highlight&&!highlight2)return displayed;// Support multiple highlights for highlight and highlight2\nlet result=[];let lastIndex=0;let i=0;while(i<displayed.length){// Check highlight1\nif(highlight&&displayed.slice(i,i+highlight.length)===highlight){result.push(/*#__PURE__*/_jsx(\"span\",{style:{color:highlightColor,fontWeight:700},children:displayed.slice(i,i+highlight.length)}));i+=highlight.length;lastIndex=i;continue;}// Check highlight2\nif(highlight2&&displayed.slice(i,i+highlight2.length)===highlight2){result.push(/*#__PURE__*/_jsx(\"span\",{style:{color:highlight2Color,fontWeight:700},children:displayed.slice(i,i+highlight2.length)}));i+=highlight2.length;lastIndex=i;continue;}// Normal char\nresult.push(displayed[i]);i++;lastIndex=i;}return result;})()})});}addPropertyControls(TypewriterText,{text:{type:ControlType.String,title:\"Text\",defaultValue:\"Hello, world!\",displayTextArea:true},font:{type:ControlType.Font,title:\"Font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"32px\",variant:\"Semibold\",letterSpacing:\"-0.01em\",lineHeight:\"1.2em\"}},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#000000\"},highlight:{type:ControlType.String,title:\"Highlight Text\",defaultValue:\"\",placeholder:\"Type to highlight...\"},highlightColor:{type:ControlType.Color,title:\"Highlight Color\",defaultValue:\"#FFBB00\"},highlight2:{type:ControlType.String,title:\"Highlight 2 Text\",defaultValue:\"\",placeholder:\"Type to highlight...\"},highlight2Color:{type:ControlType.Color,title:\"Highlight 2 Color\",defaultValue:\"#00BBFF\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"TypewriterText\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"auto\",\"framerSupportedLayoutWidth\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./TypewriterText_2.map"],"mappings":"4JAMG,SAAwB,EAAe,EAAM,CAAC,GAAK,CAAC,OAAK,OAAK,QAAM,QAAM,YAAU,GAAG,iBAAe,UAAU,aAAW,GAAG,kBAAgB,WAAW,EAAY,EAAU,EAAK,OAAoB,EAAK,MAAM,CAAC,MAAM,CAAC,MAAM,OAAO,OAAO,OAAO,QAAQ,OAAO,WAAW,SAAS,eAAe,SAAS,UAAU,aAAa,SAAS,SAAS,CAAC,SAAsB,EAAK,OAAO,CAAC,MAAM,CAAC,GAAG,EAAK,QAAM,GAAG,EAAM,MAAM,cAAc,SAAS,EAAE,SAAS,OAAO,WAAW,WAAW,UAAU,aAAa,UAAU,SAAS,UAAU,aAAa,aAAa,aAAa,SAAS,SAAS,QAAQ,QAAQ,WAAW,GAAM,UAAU,OAAO,IAAI,GAAM,UAAU,WAA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