Skip to content

Hero Terminal

Developer-first hero: full-width uppercase headline, copyable install command button, and an ink terminal window that replays a git merge → publish session line by line with a blinking yellow cursor.

brutalist/section/hero-terminal
Open ↗

Source

"use client";

import { useEffect, useState } from "react";
import { useReducedMotion } from "motion/react";
import { cn } from "@/lib/utils";

export interface HeroTerminalLine {
  kind: "cmd" | "out" | "ok";
  text: string;
}

export interface HeroTerminalProps {
  kicker?: string;
  title?: string;
  description?: string;
  primaryCta?: { label: string; href: string };
  install?: string;
  lines?: HeroTerminalLine[];
  className?: string;
}

const DEFAULT_LINES: HeroTerminalLine[] = [
  { kind: "cmd", text: "git merge feature/ai-summaries" },
  { kind: "out", text: "3 PRs labelled: feature, improvement" },
  { kind: "cmd", text: "npx shipyard publish --channel all" },
  { kind: "out", text: "Drafting release notes for v4.2.0…" },
  { kind: "out", text: "Summary: “AI summaries for every release”" },
  { kind: "ok", text: "✓ changelog  ✓ in-app widget  ✓ slack  ✓ email (8,214)" },
];

const LINE_STYLE: Record<HeroTerminalLine["kind"], string> = {
  cmd: "text-da-primary",
  out: "opacity-80",
  ok: "font-bold text-da-success",
};

export function HeroTerminal({
  kicker = "[ for engineering teams ]",
  title = "Merge the PR. The changelog writes itself.",
  description = "Shipyard listens to your repo, drafts release notes from labels and commits, and publishes them everywhere your users look — from one command or zero.",
  primaryCta = { label: "Start shipping free", href: "#signup" },
  install = "npx shipyard init",
  lines = DEFAULT_LINES,
  className,
}: HeroTerminalProps) {
  const reduce = useReducedMotion();
  const [tick, setTick] = useState(0);
  const [copied, setCopied] = useState(false);
  // Replay the terminal line by line (all lines visible immediately with reduced motion).
  const shown = reduce ? lines.length : Math.min(tick, lines.length);

  useEffect(() => {
    if (reduce) return;
    const id = window.setInterval(() => setTick((n) => (n >= lines.length ? n : n + 1)), 650);
    return () => window.clearInterval(id);
  }, [reduce, lines.length]);

  return (
    <section className={cn("da-section da-stroke-b bg-da-bg text-da-fg", className)}>
      <div className="da-container">
        <p className="font-da-mono text-xs font-bold tracking-da-label text-da-muted-fg uppercase">{kicker}</p>
        <h1 className="mt-4 max-w-5xl font-da-display text-[clamp(2.75rem,7vw,5.5rem)] leading-[0.95] tracking-da-display uppercase">{title}</h1>
        <div className="mt-8 grid gap-10 lg:grid-cols-[1fr_1.3fr] lg:items-start">
          <div>
            <p className="max-w-md text-lg text-da-muted-fg">{description}</p>
            <div className="mt-8 flex flex-wrap items-stretch gap-4">
              <a
                href={primaryCta.href}
                className="da-focus da-transition da-stroke inline-flex items-center bg-da-primary px-6 py-3.5 font-bold text-da-primary-fg shadow-da-md hover:translate-x-[6px] hover:translate-y-[6px] hover:shadow-none"
              >
                {primaryCta.label}
              </a>
              <button
                type="button"
                onClick={async () => {
                  await navigator.clipboard.writeText(install);
                  setCopied(true);
                  window.setTimeout(() => setCopied(false), 1500);
                }}
                className="da-focus da-stroke flex items-center gap-3 bg-da-surface px-4 font-da-mono text-sm font-bold text-da-surface-fg"
              >
                <span aria-hidden>$</span>
                {install}
                <span className="da-stroke-l pl-3 text-xs uppercase" aria-live="polite">
                  {copied ? "Copied" : "Copy"}
                </span>
              </button>
            </div>
          </div>

          <figure className="da-stroke bg-da-fg text-da-bg shadow-da-lg">
            <div className="flex items-center gap-2 border-b-[length:var(--da-border-width)] border-current px-4 py-2.5">
              <span aria-hidden className="size-3 bg-da-danger" />
              <span aria-hidden className="size-3 bg-da-warning" />
              <span aria-hidden className="size-3 bg-da-success" />
              <figcaption className="ml-3 font-da-mono text-xs font-bold tracking-da-label uppercase">~/acme-web — zsh</figcaption>
            </div>
            <pre className="min-h-72 overflow-x-auto p-5 font-da-mono text-sm leading-7 whitespace-pre-wrap" aria-label="Terminal session">
              {lines.map((l, i) => (
                <span key={i} className={cn("block", LINE_STYLE[l.kind], i >= shown && "invisible")}>
                  {l.kind === "cmd" && <span aria-hidden className="text-da-bg">$ </span>}
                  {l.text}
                </span>
              ))}
              <span aria-hidden className="inline-block h-5 w-2.5 translate-y-1 animate-pulse bg-da-primary motion-reduce:animate-none" />
            </pre>
          </figure>
        </div>
      </div>
    </section>
  );
}

export default HeroTerminal;

modules/brutalist/section/hero-terminal/index.tsx

Props

PropTypeDefaultDescription
kickerstring—Mono label above the headline.
titlestring—Headline (h1).
descriptionstring—Supporting paragraph.
primaryCta{ label: string; href: string }—Main CTA.
installstring"npx shipyard init"Command copied by the copy button.
linesHeroTerminalLine[]—{ kind: cmd|out|ok, text } lines of the terminal.
classNamestring—Classes on the <section>.

Other hero variants in Brutalist

Hero in other art directions

Hero Centered

Centered hero over the mesh: frosted badge, headline with gradient-text ending, gradient + frosted CTAs, then a wide glass ‘live call’ window with four video tiles, live transcript and an AI capture chip.

GlassHero

Hero Mesh

Split hero over the glass mesh: frosted announcement pill, headline with gradient-text second half, gradient + frosted CTAs, and a layered composition of glass cards (AI meeting recap, floating video update, recording pill) gently bobbing.

GlassHero

Hero Stack

Split hero with a fanned 3D stack of three glass cards (AI recap, async video, synced tasks) tilted in perspective, spreading apart with a spring on hover.

GlassHero

Hero Waitlist

Minimal waitlist hero with a central glow: badge, big headline, a glass pill email form with gradient submit (pending, success, error states) and a stack of gradient avatars with the waitlist count.

GlassHero

Hero Cli

Developer-first centered hero on a dotted grid: version badge, headline, an install command field with copy-to-clipboard, a docs button and a terminal window showing the command output.

MinimalHero

Hero Glow

Centered hero with announcement pill, gradient-ink headline, two CTAs, a single soft indigo glow over a masked hairline grid, and an HTML product window (incident list) fading out at the bottom.

MinimalHero

Hero Metrics

Editorial left-aligned hero with an oversized tight headline, copy and CTAs on one baseline, a row of three hairline-separated mono metrics and a text wordmark strip of customers.

MinimalHero

Hero Split

Two-column hero: eyebrow, headline, copy, checklist and two CTAs on the left; on the right a hairline card showing a live incident timeline with colored status dots and a resolved badge.

MinimalHero

Hero Browser

Split hero: copy on the left, a large monochrome browser frame on the right showing a mock studio portfolio (nav, giant name, image grid with mono captions) and a signal-dot “Published” badge.

Mono CleanHero

Hero Giant

Type-led hero: a mono label, an enormous tightly-tracked headline across the full width, then a 12-col row with copy + ink button on the left and mono key facts on the right, over a full-bleed gray image frame with caption.

Mono CleanHero

Hero Grid

Visible-grid hero: hairline 12-column guides behind the content, headline + copy + ink CTA in the left columns, and a ruled index list of featured templates on the right whose rows invert on hover.

Mono CleanHero

Hero Statement

Quiet manifesto hero: a single large statement set in the display face with generous line height and an orange signal dot after a key word, bottom-anchored mono footnotes and a scroll cue; nearly full-height.

Mono CleanHero

Hero Band

Stripe-style hero on a deep blue gradient band with a slanted bottom edge: headline and CTAs on the left, a stacked pair of payment UI cards (invoice + payment success) on the right.

Neo CorporateHero

Hero Dashboard

Split hero: eyebrow, strong headline, copy, blue + bordered CTAs and a compliance line; on the right a finance dashboard mock (KPIs, bar chart, invoice table).

Neo CorporateHero

Hero Demo

Enterprise demo-request hero: copy + check bullets + quote on the left, a bordered lead form (name, work email, company, size, submit) with validation-ready fields and success state on the right.

Neo CorporateHero

Hero Proof

Centered proof-first hero on a faint grid: announcement badge, headline, CTAs, a four-stat bordered strip and a customer wordmark row.

Neo CorporateHero

Hero Arch

Split hero: eyebrow with sprout icon, large serif headline with an italic sage highlight, calm copy, pill CTAs; on the right a tall arch-topped illustration (sun + rolling hills) with a floating stat chip.

Organic SoftHero

Hero Centered

Centered serif hero floating over two soft organic blobs (sage and clay), a hand-drawn underline under the italic highlight, pill CTAs and a row of three calm stats.

Organic SoftHero

Hero Editorial

Magazine-style hero: oversized serif headline across the width with an italic line, a collage of three organic shapes (arch, circle with leaf, pebble) and a pull-quote column; scroll cue.

Organic SoftHero

Hero Footprint

Product hero: copy + CTAs on the left, a soft rounded footprint card on the right with a donut chart of emissions by source, legend with percentages and a gentle “biggest lever” tip.

Organic SoftHero

Hero Illustrated

Split hero: butter badge, rounded headline, pill CTAs and avatar-dot social proof on the left; a flat pastel kanban illustration made of shapes (columns, tinted cards, circles) with a floating “done” chip on the right.

Soft FlatHero

Hero Planner

Centered hero with a big rounded headline and pill CTAs above a full-width weekly planner mock-up: five day columns with date numbers and pastel task chips (fewer columns on small screens).

Soft FlatHero

Hero Signup

Sign-up hero on a large butter panel: headline with a peach marker-highlighted phrase, white pill email form with success state, check perks and a 5-star rating line.

Soft FlatHero

Hero Tiles

Hero with a left headline block and ink CTA next to a 2×2 grid of pastel feature tiles (peach, mint, lavender, butter) with white icon squares, the right column offset downward.

Soft FlatHero