Account

Backgrounds

Creative

Warp Field

Travel at speed: stars stretch into streaks as they near the edges. For launch moments, loading screens and space heroes.

Install

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

Terminal
npx @galactrex/ui add warp-field

Usage

Example
import { WarpField } from "@/components/galactrex/warp-field";

<section className="relative overflow-hidden">
  <WarpField />
  <h1 className="relative">Launching</h1>
</section>

Source

Installs to components/galactrex/warp-field.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
starsnumber260How many stars (capped at 800).
speednumber1.21 is a cruise, 4 is a jump.
originXnumber0.5Vanishing point across the width, 0 to 1.
originYnumber0.5Vanishing point down the height, 0 to 1.
opacitynumber0.8Line strength, 0 to 1.
colorstring"--gxui-ink"CSS colour or --gxui-* name.
classNamestring—Extra classes for the outer element.

Variants

  • Cruise. Calm forward travel.
  • Jump. `speed={4}` for hyperspace.

Accessibility

  • Decorative only and aria-hidden; never takes pointer events.
  • High speeds are intense; keep them for short moments.

Motion and reduced motion

  • One canvas, drawn once per frame.
  • Pauses offscreen.
  • Reduced motion: stars hold still as points.