Lamp Heading

Section heading with a lamp-like glow, gradient underline, particles, and light rays.

Blade Runner

Legacy

Mad Max: Fury Road

THE MATRIX

Ghost in the Shell

Stranger Things

Lamp Heading turns a plain section heading into a hanging desk lamp: the text sits above a glowing gradient underline, and thin light rays plus drifting particles fall from the beam. The glow color and heading text are props, and the whole effect is animated with Framer Motion. Built with React and Tailwind CSS. A strong fit for hero sections, feature page titles, and dark themed landing pages that need a single warm focal point.

Installation

Usage

import { LampHeading } from "@/components/ui/lamp-heading";
// Basic usage with default settings
<LampHeading text="Featured Products" />
 
// Custom styling with className
<LampHeading
  text="About Us"
  className="text-3xl font-bold tracking-tight"
  textSize="3xl"
/>
 
// Custom gradient colors with via color
<LampHeading
  text="Our Services"
  gradientColors={{
    from: "#8a2be2",
    via: "#ff69b4",
    to: "#ff8c00"
  }}
/>
 
// Modified glow effect with particles
<LampHeading
  text="Portfolio"
  glowIntensity={1.2}
  glowSize={35}
  direction="above"
  showParticles={true}
  showLightRays={true}
/>

Props

PropTypeDefaultDescription
textstringRequiredThe text content of the heading
classNamestringundefinedAdditional CSS classes to apply for styling the heading
gradientColorsobject{ from: "#FF33C7", via: "#CD35FF", to: "#4533F7" }The gradient colors used for the underline and effects. Object with 'from', optional 'via', and 'to'
lineHeightnumber4The height of the underline in pixels
lampHeightnumber80The height of the lamp cone effect in pixels
glowIntensitynumber1.0The intensity of the glow effect (0-2)
glowSizenumber30The size of the glow effect in pixels
animationSpeednumber4The speed of animations in seconds
direction"above" | "below""below"The direction of the lamp effect (above or below the text)
showParticlesbooleantrueWhether to show floating particles effect
showLightRaysbooleanfalseWhether to show light rays emerging from the underline
interactivebooleantrueWhether the lamp responds to hover interactions
textSize"sm" | "md" | "lg" | "xl" | "2xl" | "3xl" | "4xl""4xl"The size of the text
pulseEffectbooleantrueWhether to show a subtle pulse animation on the underline
particleCountnumber8The number of floating particles to render (used when showParticles is true)