Skip to content

Red Thread

A thread with Verlet physics that follows the cursor, pulls taut against its anchor and swings.

Plan
Free · MIT
Dependencies
React only
Props
11 (8 adjustable)

Free forever

MIT license, for personal and commercial projects. See installation

Move the cursor

Made with Furin: Pill Nav · Metal Button · Copy Morph

Props

PropTypeDefaultDescription
childrenReactNode""Optional content of the container; the thread is drawn on top without blocking clicks.
colorstring"#E8452C"Color of the thread.
segmentsnumber28How many segments the thread has: more segments mean smoother curves and more computation.
thicknessnumber3Thickness of the thread in px.
gravitynumber1400Strength of gravity in px/s²: 0 floats, higher hangs heavier.
stiffnessnumber0.95How inextensible the thread is, from 0.05 (elastic) to 1 (doesn't stretch).
anchor"none" | "center" | "top" | { x: number; y: number }"top"Fixed end: "none" (the thread just follows the cursor), "center", "top" or a point { x, y } as fractions from 0 to 1.
lengthnumber0Total length of the thread in px; 0 computes it from the container size.
glownumber0.7Intensity of the glow around the thread, from 0 to 1.
classNamestring""Extra CSS class for the container.
styleCSSProperties"{}"Inline styles for the container.

Installation

Install it

1Install the package

npm i furin-ui

2Import it

import { RedThread } from "furin-ui";

Also with pnpm add furin-ui, yarn add furin-ui or bun add furin-ui. Each component ships its own CSS and imports it for you.

Dependencies

React
18 or later
Other libraries
none
License
MIT

Each file ships its own CSS: there's nothing else to install.

Keep exploring

  • A bell with sound and a notification count.

    Interaction

  • A radial menu that fans open.

    Interaction