Account

Backgrounds

Creative

Cursor Glow

Trails a little behind the pointer and fades when it leaves. Off on touch screens, where there is no hover to follow.

Install

Included with Creative: needs your API key. Initialize and log in once.

Terminal
npx @galactrex/ui add cursor-glow

Usage

Example
import { CursorGlow } from "@/components/galactrex/cursor-glow";

<section className="relative overflow-hidden">
  <CursorGlow />
  <h1 className="relative">Light follows you</h1>
</section>

Source

Installs to components/galactrex/cursor-glow.tsx, with the shared motion primitives beside it.

Source for this component comes with its plan. Install it with the command above, or open your licensed copy here.

See plans

Props

PropTypeDefaultDescription
sizenumber420Diameter in px.
intensitynumber0.16Strength at the centre, 0 to 1.
lagnumber0.5How far it trails; 0 sticks to the pointer.
colorstringvar(--gxui-glow)Glow colour.
classNamestring—Extra classes for the outer element.

Variants

  • Trailing. Eases after the pointer.
  • Pinned. `lag={0}` sticks to it.

Accessibility

  • Decorative only and aria-hidden; never takes pointer events (it listens on the parent).
  • Not rendered on touch screens.

Motion and reduced motion

  • Spring-follow on transform only.
  • Reduced motion: follows without the trailing ease.