Momentum Button

NewPremium

Button maintains physics inertia after cursor leaves. Flick the cursor across it and watch it continue moving with realistic momentum and spring-back.

buttonsphysicsmomentuminertiavelocityspring

Installation

Terminalbash
npx motioncraft add momentum-button

Usage

momentum-button.tsxtsx
import { MomentumButton } from "@/components/buttons/premium-buttons";

<MomentumButton>
  Flick Me
</MomentumButton>

Props

PropTypeDefaultDescription
children*ReactNodeButton content
classNamestringAdditional CSS classes
onClick() => voidClick handler

Related Components