Lightbulb icon

A free pencil-style lightbulb icon, drawn by code from 1 arc, 1 polyline and 2 lines. Use it as an SVG, a React component, or by name. MIT licensed.

lightbulb

01Use it

Use lightbulb

One package, four ways in. The icon inherits currentColor and is decorative unless you give it a title. Install it with npm i @matita/icons.

React

import { Lightbulb } from '@matita/icons/react';

<Lightbulb size={24} />

// or by name
import { SketchIcon } from '@matita/icons/react';
<SketchIcon name="lightbulb" />

JavaScript

import { Lightbulb, toSvg } from '@matita/icons';

toSvg(Lightbulb, { size: 24 });   // SVG string

SVG

<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linecap="round" stroke-linejoin="round" overflow="visible" class="sketch-icon sketch-icon-lightbulb" data-sketch="" aria-hidden="true"><path d="M8.03 14.1C7.8 13.73 6.97 12.67 6.62 11.88C6.28 11.09 5.93 10.19 5.95 9.35C5.96 8.51 6.31 7.59 6.72 6.84C7.12 6.09 7.72 5.38 8.38 4.87C9.05 4.35 9.88 3.95 10.71 3.74C11.53 3.52 12.49 3.42 13.33 3.58C14.17 3.74 15.08 4.14 15.77 4.67C16.45 5.2 17.07 5.99 17.43 6.77C17.78 7.55 17.89 8.5 17.89 9.35C17.9 10.21 17.76 11.12 17.45 11.91C17.13 12.71 16.23 13.75 15.99 14.12" stroke-width="1.664"/><path d="M7.45 13.07Q8.27 14.67 8.93 16.34Q11.96 16.18 14.98 16.46Q15.72 15.08 16.31 13.63" stroke-width="1.552"/><path d="M8.54 18.48Q11.81 18.44 15.08 18.38" stroke-width="1.616"/><path d="M9.56 20.9Q11.96 20.78 14.35 20.91" stroke-width="1.68"/></svg>

Pencil variant

import '@matita/icons/pencil.css';
import { Lightbulb } from '@matita/icons/react';

<Lightbulb size={32} pencil />

The file is icons/lightbulb.svg in the package (pencil/lightbulb.svg for the pencil variant). Matita 0.2.1.

02How it's drawn

The recipe for lightbulb

Lightbulb is not stored as a drawing. It is a recipe of 1 arc, 1 polyline and 2 lines on a 24 by 24 grid, and a small program draws it like a pencil would. The wobble comes from the name, so it always comes out the same.

A · Recipe
A 12 9.5 6 135 405;
P 7.8 13.7 9 16.5 15 16.5 16.2 13.7;
L 9 18.5 15 18.5;
L 10 21 14 21
B · Plotted
C · Drawn
How it works

03Takes, sizes, pencil

Same icon, every way

Pass a seed for another take of the same recipe. The wobble is capped, so it still reads at 16 px.

seed 0
seed 1
seed 2
seed 3
seed 4

Five seeds of lightbulb. Seed 0 is the default.

16 px
20 px
24 px
32 px
48 px
96 px

True pixel sizes.

Ink
Pencil