@rebornloki-dev/jerry-cursor
v1.0.0
Published
Custom animated cursor with magnetic hover and click ripple effects.
Maintainers
Readme
jerry-cursor
A lightweight custom cursor package with:
- smooth trailing ring
- hover-aware cursor states
- magnetic hover effect for links/buttons
- click ripple feedback
It works as a normal npm package and injects its own styles at runtime.
Install
npm install @rebornloki-dev/jerry-cursorQuick start
Auto-init:
import "@rebornloki-dev/jerry-cursor";Manual init:
import { createCursor } from "@rebornloki-dev/jerry-cursor";
const cursor = createCursor({
speed: 0.12,
magnetic: true,
ripple: true,
});
cursor?.destroy();Options
speed(number, default0.12)hideDefaultCursor(boolean, defaulttrue)ripple(boolean, defaulttrue)magnetic(boolean, defaulttrue)magneticStrength(number, default0.15)linkSelector(string)imageSelector(string)textSelector(string)magneticSelector(string)
Accessibility behavior
The cursor does not activate on:
- touch/coarse-pointer devices
prefers-reduced-motion: reduce
Publishing
npm run build
npm login
npm publish --access public