Menu

Advanced Hand-Drawn Charts: Sketchy Styles & Scroll Animations

In Part 1, we introduced our custom <BarChart /> component. Now, let’s push the boundaries with even more “sketchy” styles and interactive animations.

1. Sketchy Outlines

The sketchy-outline style combines the minimalist outline look with the hand-drawn distortion filter. It looks like a quick napkin sketch.

100 Napkin 60 Paper 20 Digital

2. Sketchy Fill

The sketchy style fills the bars but keeps the distorted edges and adds a border. It feels like a marker drawing.

85 Marker 65 Pen 45 Pencil

3. Scroll-Triggered Animations

By default, charts animate when the page loads. But what if the chart is further down the page? You want it to animate when the user sees it.

Use trigger="visible" to enable scroll-triggered animations.

Scroll down to see the chart animate!

100 Seen 0 Unseen

4. Mixing Colors & Styles

You can combine these new styles with our existing color palettes.

Green Sketchy Outline

90 Eco 75 Bio

Red Sketchy Fill

80 Hot 40 Warm

Usage Code

Here’s how to implement the scroll-triggered sketchy chart:

<BarChart 
  data={[
    { label: 'A', value: 10 },
    { label: 'B', value: 20 }
  ]}
  style="sketchy"
  color="blue"
  trigger="visible"
/>

Enjoy your sketchy data!