Backgrounds

Vortex

Animated particle vortex effect with customizable colors, speed, and density.

The Vortex component creates an animated particle vortex effect using canvas-based rendering. It features customizable particle count, colors, speed, and radius with smooth animations and glow effects.

This component requires the simplex-noise package to be installed in your project.
pnpm add simplex-noise

Usage

Vortex Effect

Animated particle vortex with customizable parameters

<template>
  <MVortex
    :particle-count="1000"
    :base-hue="200"
    :base-speed="0.1"
    :range-speed="2.0"
    :base-radius="1"
    :range-radius="3"
    background-color="transparent"
    class="rounded-xl h-64"
  >
    <div class="text-center space-y-4">
      <h2 class="text-3xl font-bold text-white">
        Vortex Effect
      </h2>
      <p class="text-lg text-dimmed">
        Animated particle vortex with customizable parameters
      </p>
    </div>
  </MVortex>
</template>

Examples

Basic Vortex

Vortex Effect

Create mesmerizing vortex animations that draw users into your content with dynamic spiral motions

<template>
  <MVortex class="rounded-xl h-80">
    <div class="text-center space-y-6 p-8">
      <div class="mb-4">
        <div class="w-16 h-16 rounded-full bg-gradient-to-r from-purple-500 to-pink-500 flex items-center justify-center mx-auto">
          <UIcon
            name="i-lucide-tornado"
            class="w-8 h-8 text-white"
          />
        </div>
      </div>
      <h2 class="text-3xl font-bold text-white">
        Vortex Effect
      </h2>
      <p class="text-dimmed max-w-md mx-auto">
        Create mesmerizing vortex animations that draw users into your content with dynamic spiral motions
      </p>
      <UButton
        color="neutral"
        variant="solid"
        size="md"
      >
        Experience Vortex
      </UButton>
    </div>
  </MVortex>
</template>

Customize

Build in motion

Layered effects stay out of the way until you need them

Customize

Particle Count700
Range Y100
Base Hue220
Base Speed0
Range Speed1.5
Base Radius1
Range Radius2
Background Color

Props

Prop Type Default Description
classstring''CSS classes to apply to the container element.
containerClassstring''CSS classes to apply to the outer container.
particleCountnumber700Number of particles in the vortex.
rangeYnumber100Vertical range for particle positioning.
baseHuenumber220Base hue value for particle colors.
baseSpeednumber0.0Base speed of particle movement.
rangeSpeednumber1.5Range of speed variation for particles.
baseRadiusnumber1Base radius of particle trails.
rangeRadiusnumber2Range of radius variation for particles.
backgroundColorstring'#000000'Background color of the canvas. Accepts a Nuxt UI color token (e.g. primary) or any CSS color.

UI

This component's theme exposes the slots below. Override any of them per instance with the ui prop, or app-wide under ui.vortex in app.config.ts.

Prop Type Default Description
uiobject-Per-slot classes merged over the theme defaults.
Slot Props Description
root-relative h-full w-full
background-absolute inset-0 z-0 flex h-full w-full items-center justify-center bg-transparent
canvas-
content-relative z-10
Copyright © 2026