{"version":3,"file":"ReadingTimeCalculator.CheXeRBK.mjs","names":[],"sources":["https:/framerusercontent.com/modules/zJxfjewX1hQKhHt5QmY3/Tbkl9guPiCRkBGBxfZcm/ReadingTimeCalculator.js"],"sourcesContent":["// Reading Time Calculator\n// Displays the estimated reading time (in minutes) for a given number of words. Only the number is shown, no prefix or suffix.\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useMemo}from\"react\";/**\n * Reading Time Calculator\n *\n * @framerIntrinsicWidth 80\n * @framerIntrinsicHeight 40\n *\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function ReadingTimeCalculator(props){const{words,readingSpeed,font,color,style}=props;// Map readingSpeed to WPM\nconst wpmMap={slow:150,average:200,fast:300,speedReader:500};const wpm=wpmMap[readingSpeed]||200;// Calculate reading time in minutes, rounded up to nearest integer\nconst minutes=useMemo(()=>{if(!wpm||wpm<=0)return 0;return Math.ceil(words/wpm);},[words,wpm]);return /*#__PURE__*/_jsx(\"span\",{style:{color,...font,...style,minWidth:\"max-content\",minHeight:\"max-content\",display:\"inline-block\"},children:minutes});}addPropertyControls(ReadingTimeCalculator,{words:{type:ControlType.Number,title:\"Words\",defaultValue:250,min:0,max:1e5,step:1,displayStepper:true},readingSpeed:{type:ControlType.Enum,title:\"Speed\",options:[\"slow\",\"average\",\"fast\",\"speedReader\"],optionTitles:[\"Slow (150 WPM)\",\"Average (200 WPM)\",\"Fast (300 WPM)\",\"Speed Reader (500 WPM)\"],defaultValue:\"average\"},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#000000\"},font:{type:ControlType.Font,title:\"Font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"32px\",variant:\"Semibold\",letterSpacing:\"-0.01em\",lineHeight:\"1.2em\"}}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ReadingTimeCalculator\",\"slots\":[],\"annotations\":{\"framerIntrinsicWidth\":\"80\",\"framerSupportedLayoutHeight\":\"auto\",\"framerContractVersion\":\"1\",\"framerIntrinsicHeight\":\"40\",\"framerSupportedLayoutWidth\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ReadingTimeCalculator.map"],"mappings":"kQAUG,SAAwB,EAAsB,EAAM,CAAC,GAAK,CAAC,QAAM,eAAa,OAAK,QAAM,QAAM,CAAC,EAC7F,EAAO,CAAC,KAAK,IAAI,QAAQ,IAAI,KAAK,IAAI,YAAY,GAAI,EAAO,EAAI,EAAO,IAAe,IACvF,EAAQ,EAAQ,KAAS,GAAK,GAAK,EAAS,EAAS,KAAK,KAAK,EAAM,EAAI,CAAG,CAAC,EAAM,CAAI,EAAC,CAAC,MAAoB,GAAK,OAAO,CAAC,MAAM,CAAC,QAAM,GAAG,EAAK,GAAG,EAAM,SAAS,cAAc,UAAU,cAAc,QAAQ,cAAe,EAAC,SAAS,CAAQ,EAAC,AAAE,cAAA,AAVzP,GAA2C,IAAoD,IAA2B,CAU+H,EAAoB,EAAsB,CAAC,MAAM,CAAC,KAAK,EAAY,OAAO,MAAM,QAAQ,aAAa,IAAI,IAAI,EAAE,IAAI,IAAI,KAAK,EAAE,gBAAe,CAAK,EAAC,aAAa,CAAC,KAAK,EAAY,KAAK,MAAM,QAAQ,QAAQ,CAAC,OAAO,UAAU,OAAO,aAAc,EAAC,aAAa,CAAC,iBAAiB,oBAAoB,iBAAiB,wBAAyB,EAAC,aAAa,SAAU,EAAC,MAAM,CAAC,KAAK,EAAY,MAAM,MAAM,QAAQ,aAAa,SAAU,EAAC,KAAK,CAAC,KAAK,EAAY,KAAK,MAAM,OAAO,SAAS,WAAW,gBAAgB,aAAa,aAAa,CAAC,SAAS,OAAO,QAAQ,WAAW,cAAc,UAAU,WAAW,OAAQ,CAAC,CAAC,EAAC"}