Sonar pings sweeping a field of glyphs, lighting up drifting shoals
| Name | Type | Default | Description |
|---|---|---|---|
colors | [string, string] | ["#7C5CFF", "#FF9FFC"] | Colour of the resting shoals and colour of the echo where a ping strikes them, blended in OKLab. The crest of a strike burns toward white. |
backgroundColor | string | "#0A0A0A" | Colour of the open water. |
mode | "auto" | "glow" | "ink" | "auto" | glow adds light for dark backgrounds, ink prints coloured glyphs for light ones. auto picks from the background brightness. |
charset | string | " ·+×○◎◉" | Glyphs the field is drawn with, sorted by how much ink each one uses, so any string works as a brightness ramp. · • ● + × ○ ◎ ◉ □ ■ ◇ ◆ △ ▲ are drawn as crisp vector shapes; anything else uses fontFamily. |
fontFamily | string | system monospace | Font for characters that are not built-in shapes. Use a font that is already loaded on the page. |
glyphSize | number | 11 | Size of each glyph in pixels. |
spacing | number | 1 | Gap between glyphs as a multiple of their size, from 0.7 (packed) to 3 (airy). |
glyphWeight | number | 1 | Stroke weight of the built-in shapes, from 0.4 to 3. |
density | number | 0.5 | How much of the water the shoals cover, from 0 (a few faint contacts) to 1 (crowded). |
scale | number | 1 | Size of the shoals. Larger values make fewer, broader shapes. |
drift | number | 1 | How fast the shoals drift and reshape, from 0 (still) to 5. |
driftAngle | number | 20 | Direction the shoals drift, in degrees. 0 drifts to the right, 90 upward. |
ambient | number | 0.35 | How visible the shoals are between pings, from 0 (only pings reveal them) to 1. |
autoPing | boolean | true | Send pings from the origin on a steady rhythm. |
interval | number | 3.4 | Seconds between automatic pings. |
originX | number | 0.5 | Horizontal position the automatic pings start from, from 0 (left) to 1 (right). Values outside that range move it off-frame. |
originY | number | 0.5 | Vertical position the automatic pings start from, from 0 (top) to 1 (bottom). Values above 1 let them rise from below the frame. |
pingSpeed | number | 1 | How fast each wavefront travels outward. |
range | number | 1 | How far a ping travels before it fades out. |
ringWidth | number | 1 | Thickness of the wavefront. |
persistence | number | 0.6 | Seconds a shoal keeps glowing after a wavefront passes, like phosphor on a sonar screen. |
reveal | number | 0.5 | How much faint structure around the shoals a ping uncovers as it passes, from 0 to 1. |
glow | number | 0.12 | Soft bloom around the brightest glyphs, from 0 to 3. |
intensity | number | 1 | Overall exposure. |
speed | number | 1 | Time scale for everything: drift, pings and their rhythm. |
interactive | boolean | true | Respond to the pointer. |
clickPing | boolean | true | Clicking sends a ping from that point. Every click adds its own wavefront, so pings overlap freely. |
echo | boolean | true | The pointer becomes an object in the water: wavefronts break around it, leaving a soft shadow behind, and bounce back as a smaller echo. |
echoStrength | number | 1 | Strength of the pointer's echo and shadow, from 0 to 2. |
paused | boolean | false | Freeze the field. Reduced-motion users always get a still frame. |
quality | number | 1 | Resolution scale from 0.25 to 1. Lower values are cheaper on large screens. |
ref | { ping } | — | ping(x, y) sends a ping from a point given as fractions of the width and height. Without arguments it starts from the origin. |
children | ReactNode | — | Content placed over the background. |
className | string | — | Classes for the root element. It fills its parent, with a 240px minimum height. |
style | CSSProperties | — | Inline styles for the root element. |
colors[string, string]Colour of the resting shoals and colour of the echo where a ping strikes them, blended in OKLab. The crest of a strike burns toward white.
["#7C5CFF", "#FF9FFC"]backgroundColorstringColour of the open water.
"#0A0A0A"mode"auto" | "glow" | "ink"glow adds light for dark backgrounds, ink prints coloured glyphs for light ones. auto picks from the background brightness.
"auto"charsetstringGlyphs the field is drawn with, sorted by how much ink each one uses, so any string works as a brightness ramp. · • ● + × ○ ◎ ◉ □ ■ ◇ ◆ △ ▲ are drawn as crisp vector shapes; anything else uses fontFamily.
" ·+×○◎◉"fontFamilystringFont for characters that are not built-in shapes. Use a font that is already loaded on the page.
system monospaceglyphSizenumberSize of each glyph in pixels.
11spacingnumberGap between glyphs as a multiple of their size, from 0.7 (packed) to 3 (airy).
1glyphWeightnumberStroke weight of the built-in shapes, from 0.4 to 3.
1densitynumberHow much of the water the shoals cover, from 0 (a few faint contacts) to 1 (crowded).
0.5scalenumberSize of the shoals. Larger values make fewer, broader shapes.
1driftnumberHow fast the shoals drift and reshape, from 0 (still) to 5.
1driftAnglenumberDirection the shoals drift, in degrees. 0 drifts to the right, 90 upward.
20ambientnumberHow visible the shoals are between pings, from 0 (only pings reveal them) to 1.
0.35autoPingbooleanSend pings from the origin on a steady rhythm.
trueintervalnumberSeconds between automatic pings.
3.4originXnumberHorizontal position the automatic pings start from, from 0 (left) to 1 (right). Values outside that range move it off-frame.
0.5originYnumberVertical position the automatic pings start from, from 0 (top) to 1 (bottom). Values above 1 let them rise from below the frame.
0.5pingSpeednumberHow fast each wavefront travels outward.
1rangenumberHow far a ping travels before it fades out.
1ringWidthnumberThickness of the wavefront.
1persistencenumberSeconds a shoal keeps glowing after a wavefront passes, like phosphor on a sonar screen.
0.6revealnumberHow much faint structure around the shoals a ping uncovers as it passes, from 0 to 1.
0.5glownumberSoft bloom around the brightest glyphs, from 0 to 3.
0.12intensitynumberOverall exposure.
1speednumberTime scale for everything: drift, pings and their rhythm.
1interactivebooleanRespond to the pointer.
trueclickPingbooleanClicking sends a ping from that point. Every click adds its own wavefront, so pings overlap freely.
trueechobooleanThe pointer becomes an object in the water: wavefronts break around it, leaving a soft shadow behind, and bounce back as a smaller echo.
trueechoStrengthnumberStrength of the pointer's echo and shadow, from 0 to 2.
1pausedbooleanFreeze the field. Reduced-motion users always get a still frame.
falsequalitynumberResolution scale from 0.25 to 1. Lower values are cheaper on large screens.
1ref{ ping }ping(x, y) sends a ping from a point given as fractions of the width and height. Without arguments it starts from the origin.
—childrenReactNodeContent placed over the background.
—classNamestringClasses for the root element. It fills its parent, with a 240px minimum height.
—styleCSSPropertiesInline styles for the root element.
—