UIPin
ComponentsIconsIllustrationsMotionTemplatesApps
Boards
UIPin

Free, open-source UI components, icons, illustrations, motion, templates and apps, in one search. Every item links to its source and licence.

UIPin is free. If it saved you time, you can keep it running:

Buy me a coffee
ComponentsIconsIllustrationsMotionTemplatesAppsLibrariesCompareNew this weekMCP for agentsBoardsPrivacy

Components, icons and artwork belong to their authors and are shown under their open-source licences.

SmoothUI/Header 3

Navigation
1 of 6
Compiling

Theme it

Every preview, live

Brand colour

Corner radius

Font

Recolours shadcn’s tokens, Tailwind’s accent colours and colours set in the code. Red, amber and green classes stay, since they usually mean error, warning or success.

6 versions·1 library

  • Header 3
  • Header 1
  • Header 2
  • Header 4
  • Header 5
  • Header 6

Header 3

Header block with gradient logo and smooth animations

npx shadcn@latest add https://smoothui.dev/r/header-3.json
Open in v0 Docs Repo
Library
SmoothUI
License
MIT
Stack
React · Tailwind CSS · animated · base-ui
Packages
@base-ui/reactclass-variance-authoritylucide-reactmotion
Also adds
index, animated-group, animated-text, hero-header, logos, newsletter-form, app-icons, cast, component-meta, people, products, scenes, smoothui-schema
Size
200 lines

Code

components/smoothui/header-3/index.tsx

"use client";

import { Avatar } from "@/components/smoothui/avatar";
import SmoothButton from "@/components/smoothui/smooth-button";
import { getAllPeople, getAvatarUrl, getImageKitUrl } from "@/lib/smoothui-data";
import { ArrowDownRight, Star } from "lucide-react";
import { motion, useReducedMotion } from "motion/react";
import { AnimatedGroup, AnimatedText, HeroHeader } from "@/components/smoothui/shared";

interface HeroShowcaseProps {
  buttons?: {
    primary?: {
      text: string;
      url: string;
    };
    secondary?: {
      text: string;
      url: string;
    };
  };
  description?: string;
  heading?: string;
  reviews?: {
    count: number;
    avatars: {
      src: string;
      alt: string;
    }[];
    rating?: number;
  };
}

export function HeroShowcase({
  heading = "Build beautiful UIs, effortlessly.",
  description = "SmoothUI gives you the building blocks to create stunning, animated interfaces in minutes.",
  buttons = {
    primary: {
      text: "Get Started",
      url: "#link",
    },
    secondary: {
      text: "Watch demo",
      url: "#link",
    },
  },
  reviews = {
    avatars: getAllPeople()
      .slice(0, 5)
      .map((person) => ({
        alt: `${person.name} avatar`,
        src: getAvatarUrl(person.avatar, 90),
      })),
    count: 200,
    rating: 5.0,
  },
}: HeroShowcaseProps) {
  const shouldReduceMotion = useReducedMotion();
  return (
    <>
      <HeroHeader />
      <main>
        <motion.section
          animate={
            shouldReduceMotion
              ? { opacity: 1 }
              : { filter: "blur(0px)", opacity: 1, scale: 1 }
          }
          className="relative overflow-hidden bg-gradient-to-b from-background to-muted"
          initial={
            shouldReduceMotion
              ? { opacity: 1 }
              : { filter: "blur(12px)", opacity: 0, scale: 1.04 }
          }
          transition={
            shouldReduceMotion
              ? { duration: 0 }
              : {
                  duration: 0.35,
                  ease: [0.23, 1, 0.32, 1],
                  filter: { duration: 0.3, ease: [0.23, 1, 0.32, 1] },
                }
          }
        >
          <div className="mx-auto grid max-w-5xl items-center gap-10 px-6 py-24 lg:grid-cols-2 lg:gap-20">
            <AnimatedGroup
              className="mx-auto flex flex-col items-center text-center md:ml-auto lg:max-w-3xl lg:items-start lg:text-left"
              preset="blur-slide"
            >
              <AnimatedText
                as="h1"
                className="my-6 text-pretty font-bold text-4xl lg:text-6xl xl:text-7xl"
              >
                {heading}
              </AnimatedText>
              <AnimatedText
                as="p"
                className="mb-8 max-w-xl text-foreground/70 lg:text-xl"
                delay={0.12}
              >
                {description}
              </AnimatedText>
              <AnimatedGroup
                className="mb-12 flex w-fit flex-col items-center gap-4 sm:flex-row"
                preset="slide"
              >
                <span className="inline-flex items-center -space-x-4">
                  {reviews.avatars.map((avatar, index) => (
                    <motion.div
                      key={`${avatar.src}-${index}`}
                      style={{ display: "inline-block" }}
                      transition={{
                        damping: 20,
                        stiffness: 300,
                        type: "spring" as const,
                      }}
                      whileHover={shouldReduceMotion ? {} : { y: -8 }}
                    >
                      <Avatar
                        alt={avatar.alt}
                        className="size-12 overflow-hidden rounded-full border"
                        src={avatar.src}
                      />
                    </motion.div>
                  ))}
                </span>
                <div>
                  <div className="flex items-center gap-1">
                    {/* Stars follow the rating (filled up to the rounded
                        value) and are read as one sentence. */}
                    {reviews.rating === undefined ? null : (
                      <span className="sr-only">
                        Rated {reviews.rating.toFixed(1)} out of 5
                      </span>
                    )}
                    {[1, 2, 3, 4, 5].map((starNumber) => (
                      <Star
                        aria-hidden="true"
                        className={
                          starNumber <= Math.round(reviews.rating ?? 0)
                            ? "size-5 fill-amber text-amber"
                            : "size-5 text-foreground/25"
                        }
                        key={`star-${starNumber}`}
                      />
                    ))}
                    <span aria-hidden="true" className="mr-1 font-semibold">
                      {reviews.rating?.toFixed(1)}
                    </span>
                  </div>
                  <p className="text-left font-medium text-foreground/70">
                    from {reviews.count}+ reviews
                  </p>
                </div>
              </AnimatedGroup>
              <AnimatedGroup
                className="flex w-full flex-col justify-center gap-2 sm:flex-row lg:justify-start"
                preset="slide"
              >
                {buttons.primary ? (
                  <SmoothButton
                    asChild
                    className="w-full sm:w-auto"
                    variant="candy"
                  >
                    <a href={buttons.primary.url}>{buttons.primary.text}</a>
                  </SmoothButton>
                ) : null}
                {buttons.secondary ? (
                  <SmoothButton asChild variant="outline">
                    <a href={buttons.secondary.url}>
                      {buttons.secondary.text}
                      <ArrowDownRight className="size-4" />
                    </a>
                  </SmoothButton>
                ) : null}
              </AnimatedGroup>
            </AnimatedGroup>
            {/* Imagen completamente estática para que el blend mode funcione perfecto */}
            <div className="flex">
              <img
                alt="app screen"
                className="h-full w-full rounded-md object-cover"
                draggable={false}
                height={1842}
                src={getImageKitUrl("/images/hero-example_xertaz.png", {
                  format: "auto",
                  quality: 85,
                  width: 1200,
                })}
                width={2880}
              />
            </div>
          </div>
        </motion.section>
      </main>
    </>
  );
}
export default HeroShowcase;

More like this

Halftone Background

Kokonut UI·Backgrounds

Drape Background

Kokonut UI·Backgrounds

Glyph Background

Animate UI·BackgroundsMIT+

Fuzzy Text

React Bits·Text effectsMIT+

Dither Veil

React Bits·BackgroundsMIT+

Map

Eldora UI·Media & 3D

Antigravity

React Bits·BackgroundsMIT+

Laser Flow

React Bits·BackgroundsMIT+

Bubble Background

Animate UI·BackgroundsMIT+

Aspect Ratio

shadcn/ui·Data display

Novatrix Background

Eldora UI·Backgrounds

Gradient Background

Animate UI·BackgroundsMIT+

Gravity Stars Background

Animate UI·BackgroundsMIT+

ASCII Text

React Bits·Text effectsMIT+

Splash Cursor

React Bits·Cursor & effectsMIT+