Trash icon
A free pencil-style trash icon, drawn by code from 1 line and 2 polylines. Use it as an SVG, a React component, or by name. MIT licensed.
01Use it
Use trash
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 { Trash } from '@matita/icons/react';
<Trash size={24} />
// or by name
import { SketchIcon } from '@matita/icons/react';
<SketchIcon name="trash" />JavaScript
import { Trash, toSvg } from '@matita/icons';
toSvg(Trash, { size: 24 }); // SVG stringSVG
<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-trash" data-sketch="" aria-hidden="true"><path d="M3.56 6.65Q12.09 5.94 20.62 6.5" stroke-width="1.68"/><path d="M8.85 6.95Q9.27 5.46 9.47 3.93Q12.08 4.06 14.69 4.1Q15.02 5.35 15.16 6.64" stroke-width="1.616"/><path d="M6.13 6.2Q6.72 13.08 6.9 19.99Q12.01 20.03 17.12 19.92Q17.9 13.2 18.15 6.43" stroke-width="1.68"/></svg>Pencil variant
import '@matita/icons/pencil.css';
import { Trash } from '@matita/icons/react';
<Trash size={32} pencil />The file is icons/trash.svg in the package (pencil/trash.svg for the pencil variant). Matita 0.3.0.
02How it's drawn
The recipe for trash
Trash is not stored as a drawing. It is a recipe of 1 line and 2 polylines 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.
L 4 6.5 20 6.5;
P 9 6.5 9.5 4 14.5 4 15 6.5;
P 6 6.5 7 20 17 20 18 6.5
trash as a number: 1583631877
Shapes: L line, P polyline, Z closed shape, R rectangle, C circle, E ellipse, A arc, Q curve, O dot. Separate shapes with ;. Edits stay on this page.
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.
Five seeds of trash. Seed 0 is the default.
True pixel sizes.