Introducing Nuvyx UI v1.0.0

Docs
Matrix Code Rain

Matrix Code Rain

A customizable Matrix-style digital rain effect that can be used as a background or in a container.

Installation

Usage

import { MatrixCodeRain } from "@/components/ui/matrix-code-rain";
export default function MyComponent() {
  return (
    <div className="relative h-[400px] w-full overflow-hidden">
      <MatrixCodeRain />
 
      {/* Optional overlay content */}
      <div className="absolute inset-0 flex items-center justify-center">
        <div className="bg-black/50 p-6 rounded-lg text-white">
          <h1 className="text-3xl font-bold">Your Content Here</h1>
        </div>
      </div>
    </div>
  );
}

Props

PropTypeDefaultDescription
colorstring"#00ff00"The color of the matrix characters
charsetstring"0123#!$^&456789ABC"The set of characters to display in the animation
fontSizenumber16The size of the characters in pixels
fpsnumber20Frames per second - controls animation speed
opacitynumber0.05The opacity of the fade effect (0-1)
fullScreenbooleanfalseWhether to display the effect as a fullscreen background
widthstring"100%"The width of the container when not in fullscreen mode
heightstring"400px"The height of the container when not in fullscreen mode