Back

Form Input Formula Graph

This component renders a dynamic line graph that visualizes mathematical formulas in real-time. It automatically detects input fields on your page and uses their values as variables in your formula, so when users adjust sliders or type numbers, the graph updates instantly. Perfect for calculators, financial projections, or any scenario where you want to show how changing inputs affects an outcome.

0

Status

Working

Code Component

Yes

This is a part of the 300+ components, layouts, templates, UI Kits and code overrides from the SegmentUI. Learn More. We also have a library of freebies here

Instructions

  1. Copy and paste the Formula Graph component from SegmentUI into your Framer file.

  2. Add input fields to your page and give each one a name attribute matching the variables in your formula (e.g., name an input "P" for principal amount).

  3. In the component's properties, enter your formula using JavaScript syntax — variables from your inputs are auto-detected.

  4. Configure the X-Axis settings: set the variable name that represents your x-axis (like "t" for time), define min/max values, and add labels or prefixes/suffixes as needed.

  5. Customize appearance through the Line, Axis Appearance, and Tooltip property panels — adjust colors, fonts, show/hide dots, enable area fill, and style the tooltip.

How it Works

The component works by reading input values from your page and plugging them into a JavaScript formula you provide. You write the formula using standard JavaScript math (like P * Math.pow(1 + r/100, t)), where variables like P, r, and t match the name attributes of input fields on your page. The X-axis represents one variable (usually time), and the Y-axis shows the calculated result. You can customize everything from line colors and thickness to axis labels, number formatting (with prefixes like $ or suffixes like %), and tooltips that appear on hover.

If you're not comfortable writing JavaScript formulas, you can use an AI like ChatGPT or Claude. Just describe what you want to calculate in plain English, for example: "Give me a JavaScript formula for compound interest where P is the principal, r is the annual interest rate as a percentage, and t is the number of years." The AI will give you the exact formula to paste into the component.

Frequently Asked Questions

How do I customize a code component?

How do I customize a code component?

How do I customize a code component?

Can I get the code file for this?

Can I get the code file for this?

Can I get the code file for this?

I'm having issues with this component. What should I do?

I'm having issues with this component. What should I do?

I'm having issues with this component. What should I do?

How can i make this responsive?

How can i make this responsive?

How can i make this responsive?

What is SegmentUI Pro?

SegmentUI Pro is a UI kit and component library containing 500+ assets, components, power ups, upgrades, code overrides, layouts, design systems, Premium templates and a custom Framer code generator. You can preview the UI Kit here.

Additionally, we have a Figma Design system to compliment the Framer components.

Our mission is simple - give superpowers to designers. Everything from the first pixel, education to code components. It's an ever growing, ever evolving set of tools for designer without the hefty price tag.

vs

Who is SegmentUI Pro For?

SegmentUI Pro is for Framer designers and template creators who want to power up their designs

After creating multiple templates and client projects myself, I realised one thing - In order to make more revenue, you need to give more value. This was the main intent behind SegmentUI. To empower designers and to be able to allow them to deliver more value for the time they spend

SegmentUI Pro is for Framer designers and template creators who want to power up their designs

After creating multiple templates and client projects myself, I realised one thing - - In order to make more revenue, you need to give more value. This was the main intent behind SegmentUI. To power up designers to and to be able to allow them to deliver more value for the time they spend

SegmentUI Pro is for Framer designers and template creators who want to power up their designs

After creating multiple templates and client projects myself, I realised one thing - - In order to make more revenue, you need to give more value. This was the main intent behind SegmentUI. To power up designers to and to be able to allow them to deliver more value for the time they spend

A 360° Design Solution

Constantly updating, constantly evolving tools for Framer and Figma. Build more, design faster, sell more, charge more

Loved by Designers, Developers and Founders

See what our 8000+ customers have to say

Unlock everything with a one time payment

For the fraction of your next project, you can boost your workflow by 10 folds

Happy ! Use discount code for a special holiday discount!

Pro

$109

One Time Payment

Full Access to the Figma UI Kit

Full Access to the Framer UI Kit

Full Access to the Framer Code Components & CMS Upgrades

Full Access to Framer Plugins

Full Access to 4 Premium Framer Templates

Full Access to Framer Code Genie GPT

Request Components & Layouts

Get Updates Forever

Light, Dark & Dynamic Modes

Use for Unlimited Projects

Commercial License Only

Use for personal and client projects

Pro Creator

$199

One Time Payment

Everything in Pro

Template & Commercial License

Use UI Kit to create unlimited client projects and templates

Frequently Asked

For anything not covered here, mail us at hello@segmentui.com

General

What is SegmentUI?

Is it for Figma or Framer?

How do I access after purchasing?

License

Is atttribution required?

How does the licenses work?

Can I use it to create client projects?

Can I use it to create Framer templates?

Do my clients need to pay after I purchase?

Pricing

Is there a free version?

Do you have a student discount?

Will I get future updates if I purchase now?

Is this a one time payment or a subscription?

What is the difference between Pro and Pro Creator Access?

Supercharge Your Design Workflow

1000+ variations of styles, components, interactions, layouts, transforms, code overrides, code components for Framer & Figma. Power Up Now!

A 360° Design Solution

Constantly updating, constantly evolving tools for Framer and Figma. Build more, design faster, sell more, charge more

Loved by Designers, Developers and Founders

See what our 8000+ customers have to say

Unlock everything with a one time payment

For the fraction of your next project, you can boost your workflow by 10 folds

Happy ! Use discount code for a special holiday discount!

Pro

$109

One Time Payment

Full Access to the Figma UI Kit

Full Access to the Framer UI Kit

Full Access to the Framer Code Components & CMS Upgrades

Full Access to Framer Plugins

Full Access to 4 Premium Framer Templates

Full Access to Framer Code Genie GPT

Request Components & Layouts

Get Updates Forever

Light, Dark & Dynamic Modes

Use for Unlimited Projects

Commercial License Only

Use for personal and client projects

Pro Creator

$199

One Time Payment

Everything in Pro

Template & Commercial License

Use UI Kit to create unlimited client projects and templates

Frequently Asked

For anything not covered here, mail us at hello@segmentui.com

General

What is SegmentUI?

Is it for Figma or Framer?

How do I access after purchasing?

License

Is atttribution required?

How does the licenses work?

Can I use it to create client projects?

Can I use it to create Framer templates?

Do my clients need to pay after I purchase?

Pricing

Is there a free version?

Do you have a student discount?

Will I get future updates if I purchase now?

Is this a one time payment or a subscription?

What is the difference between Pro and Pro Creator Access?

Supercharge Your Design Workflow

1000+ variations of styles, components, interactions, layouts, transforms, code overrides, code components for Framer & Figma. Power Up Now!

A 360° Design Solution

Constantly updating, constantly evolving tools for Framer and Figma. Build more, design faster, sell more, charge more

Loved by Designers, Developers and Founders

See what our 8000+ customers have to say

Unlock everything with a one time payment

For the fraction of your next project, you can boost your workflow by 10 folds

Happy ! Use discount code for a special holiday discount!

Pro

$109

One Time Payment

Full Access to the Figma UI Kit

Full Access to the Framer UI Kit

Full Access to the Framer Code Components & CMS Upgrades

Full Access to Framer Plugins

Full Access to 4 Premium Framer Templates

Full Access to Framer Code Genie GPT

Request Components & Layouts

Get Updates Forever

Light, Dark & Dynamic Modes

Use for Unlimited Projects

Commercial License Only

Use for personal and client projects

Pro Creator

$199

One Time Payment

Everything in Pro

Template & Commercial License

Use UI Kit to create unlimited client projects and templates

Frequently Asked

For anything not covered here, mail us at hello@segmentui.com

General

What is SegmentUI?

Is it for Figma or Framer?

How do I access after purchasing?

License

Is atttribution required?

How does the licenses work?

Can I use it to create client projects?

Can I use it to create Framer templates?

Do my clients need to pay after I purchase?

Pricing

Is there a free version?

Do you have a student discount?

Will I get future updates if I purchase now?

Is this a one time payment or a subscription?

What is the difference between Pro and Pro Creator Access?

Supercharge Your Design Workflow

1000+ variations of styles, components, interactions, layouts, transforms, code overrides, code components for Framer & Figma. Power Up Now!