{"version":3,"file":"CalcReportOverride.CSF6WlTx.mjs","names":[],"sources":["https:/framerusercontent.com/modules/z0oj9QyRLLgK2SVL4GjC/XgJLhdFURsyil0KToO4v/CalcReportOverride.js"],"sourcesContent":["/**\n * Calculator Report Overrides\n * Text display overrides for calculator-answer and reports/calculator pages\n */import{jsx as _jsx}from\"react/jsx-runtime\";import{getCalculatorResults,getCalculatorInputs}from\"https://framerusercontent.com/modules/w0F4YxuFb1ebk0OW8AIq/teVE2bZqLM74DLc9qPge/CalcStore.js\";import{getLeadInfo}from\"https://framerusercontent.com/modules/v8ehZ9vOl9zPRq81Oomz/ayAKEtB1fUbXKa3rr0dq/LeadStore.js\";import{replaceValuesInChildren,formatCurrency,formatNumber}from\"https://framerusercontent.com/modules/pImxelvy6iA22OBzkUsA/LMIu8hDuP0jybZHjWGDM/Utils.js\";import{calcTotalFleetMiles,calcGallonsPerYear,calcGallonsSaved,calcFuelCostPerYear}from\"https://framerusercontent.com/modules/iOqZ8ifhsfr4Mm9X6VKi/3XfoQKGTBN7HQQvAvya7/Calculations.js\";function safeCalc(inputs,calcFn,fallback){if(!inputs)return fallback;try{return calcFn(inputs);}catch{return fallback;}}/**\n * Replace all calculator placeholders in children.\n *\n * Placeholders:\n *   {CO}     - Company name\n *   {TRUCKS} - Number of trucks\n *   {MILES}  - Miles per truck/year\n *   {MPG}    - Average MPG\n *   {PRICE}  - Fuel price/gallon\n *   {IMPACT} - Ferox impact %\n *   {SAVE}   - Gross fuel savings\n *   {CO2}    - CO2 reduction (tons)\n *   {FCOST}  - Ferox cost\n *   {NET}    - Net savings\n *   {TMILES} - Total fleet miles\n *   {GAL}    - Gallons per year\n *   {GSAVE}  - Gallons saved\n *   {SPEND}  - Annual fuel spend\n *\n * @framerDisableUnlink\n */export function withAllCalculatorValues(Component){return props=>{const inputs=getCalculatorInputs();const results=getCalculatorResults();const leadInfo=getLeadInfo();const replacements={\"{CO}\":leadInfo?.company||\"Your Company\",\"{TRUCKS}\":inputs?.numTrucks?formatNumber(inputs.numTrucks):\"—\",\"{MILES}\":inputs?.milesPerYear?formatNumber(inputs.milesPerYear):\"—\",\"{MPG}\":inputs?.avgMpg?inputs.avgMpg.toFixed(1):\"—\",\"{PRICE}\":inputs?.fuelPrice?`$${inputs.fuelPrice.toFixed(2)}`:\"$—\",\"{IMPACT}\":inputs?.feroxImpact?`${(inputs.feroxImpact*100).toFixed(1)}%`:\"—%\",\"{SAVE}\":results?.dollarSavings?formatCurrency(results.dollarSavings):\"$—\",\"{CO2}\":results?.co2eSavings?formatNumber(results.co2eSavings):\"—\",\"{FCOST}\":results?.feroxCost?formatCurrency(results.feroxCost):\"$—\",\"{NET}\":results?.savingsAfterCostOfFerox?formatCurrency(results.savingsAfterCostOfFerox):\"$—\",\"{TMILES}\":safeCalc(inputs,calcTotalFleetMiles,null)?formatNumber(calcTotalFleetMiles(inputs)):\"—\",\"{GAL}\":safeCalc(inputs,calcGallonsPerYear,null)?formatNumber(calcGallonsPerYear(inputs)):\"—\",\"{GSAVE}\":safeCalc(inputs,calcGallonsSaved,null)?formatNumber(calcGallonsSaved(inputs)):\"—\",\"{SPEND}\":safeCalc(inputs,calcFuelCostPerYear,null)?formatCurrency(calcFuelCostPerYear(inputs)):\"$—\"};const newChildren=replaceValuesInChildren(props.children,replacements);return /*#__PURE__*/_jsx(Component,{...props,children:newChildren});};}/**\n * MCP COMPATIBILITY FOOTER. DO NOT MODIFY.\n * FEROX SYSTEMS 2025\n *\n * The Framer MCP can only see files that export an override. This dummy\n * override makes this file visible and editable to the MCP.\n *\n * Does nothing; just returns the component unchanged.\n * @framerDisableUnlink\n */export function withMcp(Component){return Component;}\nexport const __FramerMetadata__ = {\"exports\":{\"withAllCalculatorValues\":{\"type\":\"reactHoc\",\"name\":\"withAllCalculatorValues\",\"annotations\":{\"framerDisableUnlink\":\"\",\"framerContractVersion\":\"1\"}},\"withMcp\":{\"type\":\"reactHoc\",\"name\":\"withMcp\",\"annotations\":{\"framerDisableUnlink\":\"\",\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