The module MVP has been discussed and concluded: We're only going to have expression mode on the calculator, we won't be doing simple mode vs advanced mode When the result is being used, we're just going to print out the result, we won't be having the widget variable edit in MVP We will be able to use as inputs, data from simple text, dropdowns and single selection, where values will be cast to numbers We will enhance this later when we're going to have specific element types for numbers Full specs below -------------- Calculate Node concept: 1. Purpose of the Calculate Node A dedicated node in the Formflow canvas that lets creators perform math operations on data collected from earlier steps in the form. Outputs the result as a variable that can be reused later (e.g., on a Thank You page, in emails/SMS, or in other nodes). 2. Core Inputs Label – Friendly name for the calculation (e.g., Estimate, Repayment). Expression – The math formula that defines the calculation. Can use @variable references pulled from previous nodes (e.g., @how long, @type of car). Supports basic operators (+, -, *, /), exponents, square root, percentages. Outputs – The named result(s) of the calculation for downstream use. Units & Formatting – Predefine units (m, cm, %, $, decimal places). 3. Expression Builder Modes Simple Mode – Point-and-click builder for non-technical users (sum, multiply, divide). Expression Mode – Text-based, where the creator types formulas using variable references. 4. Variable Handling Variables come from earlier form fields (e.g., sliders, dropdowns, multiple choice). Can be fixed (from the original input) or variable (changeable later by the user to recalculate results in real time). Variables are auto-suggested in the expression builder for easy insertion. 5. Preview & Validation Live Preview – Shows example calculation using the most recent input values (18 * 49 = 882). Error Handling – Warns if a variable is missing, value type mismatch, or division by zero. 6. Dynamic Interaction After Submission Clickable Variables on Thank You Page – Users can adjust certain variables after seeing the result to instantly recalculate (e.g., change loan length, rate, or price). Backwards Linking – Option to feed a new input (like multiple choice add-ons) back into a Calculate node to re-run calculations without advancing steps. 7. Example Use Cases Car Rental Inputs: Days (@how long), Daily rate from car type (@type of car), Add-ons (@extras). Formula: @how long * (@type of car + @extras). Output: Total cost. Mortgage Calculator Inputs: Interest rate slider, Loan length, House cost, Down payment. Formula: Complex interest/loan repayment formula. Output: Monthly repayment, total interest paid. 8. Downstream Usage Output variables from the Calculate node can: Feed into Conditional Splits (e.g., “If repayment < $2000…”). Be merged into Thank You pages, Emails, or SMS. Trigger different flows or offers.
0 votes
Vote to help us prioritize this feature
Sign in to join the discussion
Sign in