{
  "version": 3,
  "sources": ["ssg:https://framer.com/m/framer/store.js@^1.0.0", "ssg:https://framer.com/m/state-sAyK.js@pbXhY22TY8XJve9UcdWq", "ssg:https://framerusercontent.com/modules/HssK7AUON4Us8RecwjFs/7VlxJkQ9suaI9SCKGhed/InputNumber.js", "ssg:https://framerusercontent.com/modules/cwB67xYLJqtJr317FWve/LLuOg8VBwe5rrTvVcFDN/ROICalculator.js"],
  "sourcesContent": ["import{useState,useEffect}from\"react\";import{Data,useObserveData}from\"framer\";export function createStore(state1){// Use Data so that a Preview reload resets the state\nconst dataStore=Data({state:Object.freeze({...state1})});// Create a set function that updates the state\nconst setDataStore=newState=>{// If the state is an object, make sure we copy it\nif(typeof newState===\"function\"){newState=newState(dataStore.state);}dataStore.state=Object.freeze({...dataStore.state,...newState});};// Store the initial state, copy the object if it's an object\nlet storeState=typeof state1===\"object\"?Object.freeze({...state1}):state1;// Keep a list of all the listeners, in the form of React hook setters\nconst storeSetters=new Set();// Create a set function that updates all the listeners / setters\nconst setStoreState=newState=>{// If the state is an object, make sure we copy it\nif(typeof newState===\"function\"){newState=newState(storeState);}storeState=typeof newState===\"object\"?Object.freeze({...storeState,...newState}):newState;// Update all the listeners / setters with the new value\nstoreSetters.forEach(setter=>setter(storeState));};// Create the actual hook based on everything above\nfunction useStore(){// Create the hook we are going to use as a listener\nconst[state,setState]=useState(storeState);// If we unmount the component using this hook, we need to remove the listener\n// @ts-ignore\nuseEffect(()=>{// But right now, we need to add the listener\nstoreSetters.add(setState);return()=>storeSetters.delete(setState);},[]);// If Data context exists, use Data, otherwise use vanilla React state\nif(useObserveData()===true){useObserveData();return[dataStore.state,setDataStore];}else{// Return the state and a function to update the central store\nreturn[state,setStoreState];}}return useStore;}\nexport const __FramerMetadata__ = {\"exports\":{\"createStore\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./createStore.map", "import{createStore}from\"https://framer.com/m/framer/store.js@^1.0.0\";export const useStore=createStore({amount:1,time:1,rate:4,completionFee:0,totalInterest:0,totalPayable:0,totalMonthly:0});\nexport const __FramerMetadata__ = {\"exports\":{\"useStore\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./state.map", "import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useStore}from\"https://framer.com/m/state-sAyK.js@pbXhY22TY8XJve9UcdWq\";export default function InputNumber(props){const[store,setStore]=useStore();const handleChange=event=>{const innerValue=event.target.value;if(innerValue===\"\"){return;}if(parseFloat(innerValue)<1){event.target.value=1;return;}// Format value if it's hourly wage\nif(props.name===\"hourlyWage\"){const numericValue=parseFloat(innerValue);setStore(prev=>({...prev,[props.name]:numericValue.toFixed(2)}));}else{setStore(prev=>({...prev,[props.name]:innerValue}));}};return /*#__PURE__*/_jsx(\"input\",{name:props.name,onChange:handleChange,type:\"number\",min:\"1\",placeholder:props.placeholder,defaultValue:store?.[props.name],style:{WebkitAppearance:\"none\",width:\"100%\",height:\"100%\",borderRadius:\"8px\",border:\"1px solid #2E2E33\",backgroundColor:\"#CFD4FD\",color:\"white\",paddingLeft:\"12px\",fontSize:\"16px\",fontFamily:\"Inter, sans-serif\",\"::placeholder\":{color:\"#666\"}}});}addPropertyControls(InputNumber,{name:{title:\"Input Name\",type:ControlType.String},placeholder:{title:\"Placeholder\",type:ControlType.String,defaultValue:\"Enter value...\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"InputNumber\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./InputNumber.map", "import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useStore}from\"https://framer.com/m/state-sAyK.js@pbXhY22TY8XJve9UcdWq\";export default function ROICalculator(props){const[store]=useStore();// Calculate values\nconst numNurses=parseFloat(store?.numNurses)||0;const hourlyWage=parseFloat(store?.hourlyWage)||0;const phoneTime=parseFloat(store?.phoneTime)||0;const monthlyShifts=parseFloat(store?.monthlyShifts)||0;const hoursSaved=numNurses*(phoneTime/60)*monthlyShifts;const monthlySavings=hoursSaved*hourlyWage;const roi=numNurses&&hourlyWage&&phoneTime&&monthlyShifts?(monthlySavings-1500)/1500*100:0;return /*#__PURE__*/_jsx(\"div\",{style:{padding:\"12px\",backgroundColor:props.fill,borderRadius:\"8px\",fontFamily:\"Inter, sans-serif\"},children:/*#__PURE__*/_jsxs(\"div\",{style:{marginBottom:\"8px\"},children:[/*#__PURE__*/_jsx(\"div\",{style:{fontSize:\"14px\",marginBottom:\"16px\",color:props.labelColor},children:props.label}),/*#__PURE__*/_jsxs(\"div\",{style:{fontSize:\"24px\",fontWeight:\"600\",color:props.valueColor},children:[props.type===\"roi\"&&`${roi.toFixed(0)}%`,props.type===\"hours\"&&hoursSaved.toFixed(0),props.type===\"savings\"&&`$${monthlySavings.toFixed(0)}`]})]})});}addPropertyControls(ROICalculator,{label:{title:\"Label\",type:ControlType.String,defaultValue:\"Label\"},type:{title:\"Display Type\",type:ControlType.Enum,options:[\"roi\",\"hours\",\"savings\"],defaultValue:\"roi\"},fill:{title:\"Background Color\",type:ControlType.Color,defaultValue:\"#F8F9FC\"},labelColor:{title:\"Label Color\",type:ControlType.Color,defaultValue:\"#666666\"},valueColor:{title:\"Value Color\",type:ControlType.Color,defaultValue:\"#000000\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ROICalculator\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ROICalculator.map"],
  "mappings": "4HAAqF,SAASA,EAAYC,EAAO,CACjH,IAAMC,EAAUC,EAAK,CAAC,MA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,EAAM,UAAU,EAAE,SAASA,EAAM,KAAK,CAAC,EAAeW,EAAM,MAAM,CAAC,MAAM,CAAC,SAAS,OAAO,WAAW,MAAM,MAAMX,EAAM,UAAU,EAAE,SAAS,CAACA,EAAM,OAAO,OAAO,GAAGS,EAAI,QAAQ,CAAC,CAAC,IAAIT,EAAM,OAAO,SAASO,EAAW,QAAQ,CAAC,EAAEP,EAAM,OAAO,WAAW,IAAIQ,EAAe,QAAQ,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAE,CAACI,EAAoBb,EAAc,CAAC,MAAM,CAAC,MAAM,QAAQ,KAAKc,EAAY,OAAO,aAAa,OAAO,EAAE,KAAK,CAAC,MAAM,eAAe,KAAKA,EAAY,KAAK,QAAQ,CAAC,MAAM,QAAQ,SAAS,EAAE,aAAa,KAAK,EAAE,KAAK,CAAC,MAAM,mBAAmB,KAAKA,EAAY,MAAM,aAAa,SAAS,EAAE,WAAW,CAAC,MAAM,cAAc,KAAKA,EAAY,MAAM,aAAa,SAAS,EAAE,WAAW,CAAC,MAAM,cAAc,KAAKA,EAAY,MAAM,aAAa,SAAS,CAAC,CAAC",
  "names": ["createStore", "state1", "dataStore", "Data", "setDataStore", "newState", "storeState", "storeSetters", "setStoreState", "setter", "useStore", "state", "setState", "ye", "ue", "useObserveData", "useStore", "createStore", "InputNumber", "props", "store", "setStore", "useStore", "handleChange", "event", "innerValue", "numericValue", "prev", "p", "addPropertyControls", "ControlType", "ROICalculator", "props", "store", "useStore", "numNurses", "hourlyWage", "phoneTime", "monthlyShifts", "hoursSaved", "monthlySavings", "roi", "p", "u", "addPropertyControls", "ControlType"]
}
