Logo

dev-resources.site

for different kinds of informations.

I developed a Figma plugin, which generates a colour palette using a bezier curve…

Published at
1/7/2025
Categories
figma
figmaplugin
webdev
productivity
Author
prathameshkoshti
Author
16 person written this
prathameshkoshti
open
I developed a Figma plugin, which generates a colour palette using a bezier curve…

Inception

Last November, I started working on my design system after finalising the Border styles, Spacing units, and Typography styles. I then moved on to selecting the colour palette for the design system, and I struggled a lot, I mean a lot! It's a tedious task to choose colours.

I browsed through a few videos on YouTube and came across this wonderful YouTube video from UX Tools. In the video, Jordan clearly explains how to select a colour palette for a design system. I had to reiterate the process several times to achieve a good colour palette. So, an idea came into my mind: why not make this task a bit easier? Hence, I decided to make a Figma plugin to create a colour palette using the bézier curve editor.

I asked myself what basic inputs I needed to create a colour palette for this plugin.

  1. A colour picker with a bézier curve editor for selecting the colour and curve
  2. A step number input field for selecting the number of colours in one swatch
  3. A text field for naming the colour swatch

These were the basic inputs needed for the palette generator to work. I developed the plugin with the above inputs. The other two inputs are very straightforward, but the colour picker with a bézier editor makes the plugin so special.

The editor comprises two inputs: a hue range slider and a cubic bézier curve editor. The hue range slider ranges from 0 to 360, where its value indicates the selected hue, which is also reflected on the bézier curve HSV colour picker. The cubic bézier curve editor plays a major role in the editor. It lets users select the start and end points of the curve, along with handle points for these points. The start point indicates a colour point from which the swatch colour will start, and the endpoint indicates at what colour the swatch will end. The handle points are used to manage the curvature of the bézier curve. Using these inputs for different hues, you can create a colour palette.

More inputs…

After building the basic inputs, I went on to add a few more useful inputs, such as:

  1. Auto-generate the swatch name: The name will be auto-generated per the hue value.
  2. Curve styles preset: The presets dropdown allows you to select a few curve styles, such as Sine, Quad, Cubic, Linear (although it's not a curve, it can be created using a cubic curve), and easing (ease-in, ease-out, and ease-in-out).
  3. Freehand mode toggle: When this mode is toggled on, users can freely select the handle points of the curve however they want it to be. When toggled off, users can select preset curves from the dropdown. In this mode, the start and end points of the curve can be edited, but the handle points for these points.

Outcomes

Bezier Palette Studio

Colour Palette

When the user is satisfied with all the inputs, they can click on Generate Swatch to create a colour swatch. The swatch will appear as an accordion on the right side, as shown in the above image. After generating the swatch, the user can:

  1. Edit the swatch
  2. Duplicate the swatch (if the user wants to have the same bezier curve for all the other colour swatches)
  3. Delete the swatch

Each accordion will hold a colour swatch along with the following info:

  • Name of the swatch
  • The colours of the swatch: Each colour will have its number, hex code, token, and contrast ratio for black and white.

Integration and Export

After generating the colour palette, and when the user is satisfied with what they have generated, they can perform the following actions on the palette:

  1. Get tokens: Export your palette as JSON tokens, ready for integration into your design systems or development workflows.
  2. Export palette: Instantly export palettes as organised frames within your Figma file for easy sharing and collaboration.
  3. Create styles: Streamline your workflow by, creating reusable styles directly in your Figma file with one click.

Building this plugin has been quite a ride, and I'm excited to see how it'll help speed up your colour palette creation. No more manual tweaking or endless back-and-forth - pick your colours, adjust the curves, and you're good to go! I hope you will use this plugin in your next project. Let me know what you think. Your feedback helps make the plugin even better!

You can try this plugin in Figma, as it's already published in the Figma Community.

This plugin is open-sourced on GitHub. If you have any suggestions or want to contribute to the plugin, you are always welcome to create a new issue in the Github repository.

figma Article's
30 articles in total
Favicon
10 Figma Shortcuts to Design Faster
Favicon
I developed a Figma plugin, which generates a colour palette using a bezier curve…
Favicon
Figma for Programmers
Favicon
Best Figma plugins for design and development in 2025
Favicon
iPhone 16 Mockup for Figma
Favicon
Breaking Down Figma Prototyping: A No-Nonsense Guide for Beginners
Favicon
Componentes no Figma — Um guia para te ajudar a começar!
Favicon
Como o Figma Virou Parte do Meu Dia a Dia no Front-End
Favicon
gluestack-ui v2.0 Design Kit
Favicon
Best Figma Plugins for Designers
Favicon
Figma Components: Supercharge Your Design System
Favicon
De la Maquette au Code : Comment Figma Simplifie l’Intégration Front-End
Favicon
I used [ Figma] to bring this concept to life and truly enjoyed every step of the process.
Favicon
Figma x IA : La révolution des interfaces est en marche
Favicon
Evento sobre HTML Gratuito da Alura: Responsividade
Favicon
Invitation to cooperate in the project "Making Paid Templates Free"
Favicon
Turn a Figma Design Into a Working Dashboard App in 5 Minutes
Favicon
Designing with gluestack-ui: Essential Practices for Consistent Results
Favicon
What is Figma? Features, Pricing, and How to Get Started
Favicon
Webinar Sobre Figma Gratuito Com Certificado da EBAC
Favicon
Deep Exploration of Reinforcement Learning in Fine-Tuning Language Models: RLHF, PPO, and DPO
Favicon
Introducing the new Material Tailwind: Rebuilt from the Ground Up
Favicon
Adobe XD vs Figma: A Comprehensive Comparison for Designers
Favicon
Yo! I Built My First Figma Plugin
Favicon
Generate Figma Designs with AI
Favicon
Website for pixel-perfect development training (In Progress, looking for contributors)
Favicon
Creating Figma Unions
Favicon
Design Smarter with Figma Auto Layout
Favicon
Figma to React Native: Convert designs to clean code in a click
Favicon
Codia AI Figma to code:HTML, CSS, React, Vue, iOS, Android, macOS, Flutter, ReactNative, Tailwind, Web, Native, …

Featured ones: