appica-dev

Background Pattern

Component 2

About

A decorative dots/grid/hexagon/rings/checkerboard pattern painted behind page content, with an optional cursor-following spotlight highlight.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Background Pattern to your project and fits it to your theme.

Code

How Background Pattern is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

import { BackgroundPattern } from "@/components/ui/background-pattern";

export default function BackgroundPatternCellSize() {
  return (
    <div className="grid w-full max-w-2xl grid-cols-1 gap-4 sm:grid-cols-2">
      <BackgroundPattern
        variant="grid"
        cellSize={16}
        className="bg-background-subtle flex min-h-48 items-center justify-center overflow-hidden rounded-xl"
      >
        <span className="text-foreground-intense text-sm font-medium">
          cellSize 16
        </span>
      </BackgroundPattern>
      <BackgroundPattern
        variant="grid"
        cellSize={40}
        className="bg-background-subtle flex min-h-48 items-center justify-center overflow-hidden rounded-xl"
      >
        <span className="text-foreground-intense text-sm font-medium">
          cellSize 40
        </span>
      </BackgroundPattern>
    </div>
  );
}