Skip to content

Header Tabs

Record header (e.g. a customer): avatar initials, name + status pill, subtitle, action buttons, and an underline tab bar (links with aria-current and counts) that scrolls horizontally on mobile.

neo-corporate/layout/header-tabs
Open ↗

Source

import { cn } from "@/lib/utils";

export interface HeaderTabsProps {
  title?: string;
  status?: { label: string; tone: "success" | "warning" | "danger" | "neutral" };
  subtitle?: string;
  tabs?: { label: string; href: string; count?: number }[];
  activeHref?: string;
  className?: string;
}

const TONE = {
  success: "bg-da-success/12 text-da-success",
  warning: "bg-da-warning/20 text-da-fg",
  danger: "bg-da-danger/10 text-da-danger",
  neutral: "bg-da-muted text-da-muted-fg",
} as const;

/** Record header (e.g. a customer): avatar initials, name + status pill, subtitle, action buttons, and an underline tab bar (links with aria-current and counts) that scrolls horizontally on mobile. */
export function HeaderTabs({
  title = "Northwind Traders",
  status = { label: "Good standing", tone: "success" },
  subtitle = "Customer since 2023 · Net 30 · USD",
  tabs = [
    { label: "Overview", href: "#overview" },
    { label: "Invoices", href: "#invoices", count: 12 },
    { label: "Payments", href: "#payments", count: 38 },
    { label: "Contacts", href: "#contacts", count: 3 },
    { label: "Activity", href: "#activity" },
    { label: "Settings", href: "#settings" },
  ],
  activeHref = "#invoices",
  className,
}: HeaderTabsProps) {
  const initials = title
    .split(" ")
    .map((w) => w[0])
    .slice(0, 2)
    .join("");
  return (
    <header className={cn("border-b border-da-border bg-da-surface text-da-surface-fg", className)}>
      <div className="flex flex-wrap items-center gap-4 px-4 pt-6 sm:px-6 lg:px-8">
        <span aria-hidden className="grid size-12 place-items-center rounded-da-lg bg-da-accent font-da-display text-lg font-extrabold text-da-accent-fg">
          {initials}
        </span>
        <div className="min-w-[12rem] flex-1">
          <div className="flex flex-wrap items-center gap-2">
            <h1 className="font-da-display text-xl font-extrabold tracking-da-display">{title}</h1>
            <span className={cn("rounded-da-pill px-2 py-0.5 text-xs font-semibold", TONE[status.tone])}>{status.label}</span>
          </div>
          <p className="mt-0.5 text-sm text-da-muted-fg">{subtitle}</p>
        </div>
        <div className="flex gap-2">
          <button type="button" className="da-focus da-stroke h-9 rounded-da-md bg-da-surface px-3 text-sm font-semibold hover:border-da-border-strong">
            Send statement
          </button>
          <button type="button" className="da-focus h-9 rounded-da-md bg-da-primary px-3 text-sm font-semibold text-da-primary-fg hover:bg-da-primary/90">
            New invoice
          </button>
        </div>
      </div>
      <nav aria-label="Customer sections" className="mt-5 overflow-x-auto px-4 sm:px-6 lg:px-8">
        <ul className="flex gap-6">
          {tabs.map((t) => {
            const on = t.href === activeHref;
            return (
              <li key={t.href} className="shrink-0">
                <a
                  href={t.href}
                  aria-current={on ? "page" : undefined}
                  className={cn(
                    "da-focus da-transition flex items-center gap-1.5 border-b-2 pb-3 text-sm font-medium",
                    on ? "border-da-primary text-da-fg" : "border-transparent text-da-muted-fg hover:border-da-border-strong hover:text-da-fg",
                  )}
                >
                  {t.label}
                  {t.count !== undefined && (
                    <span className={cn("rounded-da-sm px-1.5 font-da-mono text-[11px]", on ? "bg-da-primary/10 text-da-primary" : "bg-da-muted")}>
                      {t.count}
                    </span>
                  )}
                </a>
              </li>
            );
          })}
        </ul>
      </nav>
    </header>
  );
}

export default HeaderTabs;

modules/neo-corporate/layout/header-tabs/index.tsx

Props

PropTypeDefaultDescription
titlestring—Heading.
status{ label: string; tone: "success" | "warning" | "danger" | "neutral" }—Status.
subtitlestring—Subtitle.
tabs{ label: string; href: string; count?: number }[]—Tabs.
activeHrefstring—Active Href.
classNamestring—Extra classes on the root.

Other app header variants in Neo Corporate

App header in other art directions

App Header

Two-tier app header: top bar with breadcrumbs, ⌘K search field, notification bell with counter and avatar; page band with big title, meta line, primary action and folder-style tabs.

BrutalistApp header

Header Compact

Dense 56px app header built from ruled cells: title with count chip, view tabs (yellow active cell), filter search, ink 'New' cell, and an optional strip of active filter chips.

BrutalistApp header

Header Editor

Document/editor header: back cell, version chip, inline-editable uppercase title, save-status chip (saved/saving/unsaved), Preview cell and a yellow Publish cell; actions wrap to a full-width bar on mobile.

BrutalistApp header

Header Stats

Dashboard welcome header: yellow band with eyebrow, big greeting, status sentence and two pressable actions, over a ruled KPI strip (2×2 on mobile, 4 across on desktop) with green delta chips.

BrutalistApp header

App Header

Floating frosted pill top bar (search with ⌘K hint, gradient notification counter, avatar menu button) above a page heading with a frosted segmented tab switcher and a gradient primary action.

GlassApp header

Header Document

Sticky glass editor header: breadcrumbs, inline-editable document title, saved/editing indicator, live viewers with green presence rings, gradient Share button and more menu.

GlassApp header

Header Greeting

Dashboard header with a time-of-day greeting and day summary, notification bell with gradient counter, a large glass “Ask Halo” search bar with gradient submit and quick-action chips.

GlassApp header

Header Meeting

In-call glass header pill: pulsing REC timer, meeting title, “Halo is taking notes” gradient chip, participant avatars, grid/speaker layout toggle, translate toggle and a red Leave button.

GlassApp header

App Header

Two-row app header: breadcrumbs, ⌘K search trigger and notification dot on top; view tabs with Filter / Display actions below. Includes a working command palette (Radix Dialog) with grouped, filterable, keyboard-navigable commands.

MinimalApp header

Header Detail

Detail-page header: breadcrumbs ending on a copyable mono id, title with status pill, a key/value meta row, action buttons and underline section tabs with counts.

MinimalApp header

Header Switcher

Vercel-style global top bar: logo then organization / project / environment switchers separated by slashes (production badge in red), with dropdown lists, help, notification dot and avatar.

MinimalApp header

Header Toolbar

List-page toolbar: title with count and New button, then a search field, removable key/value filter chips, an Add filter button and a list/board view toggle.

MinimalApp header

App Header

Path-style app header: slash-separated breadcrumb “Nord Studio / Projects / Oslo Opera” (last segment ink), live status with signal dot and last-edit time in mono, outline “Preview” and ink “Publish”.

Mono CleanApp header

Header Editor

Editor top bar in three zones: back arrow + editable page title, a centered square device switcher (desktop/tablet/mobile, radio semantics), and undo/redo text actions + save state + ink Publish.

Mono CleanApp header

Header Tabs

Settings-style header: title + domain subtitle, then a row of text tabs with an ink underline on the active one sitting on the hairline; scrolls horizontally on mobile.

Mono CleanApp header

Header Title

Big-title page header: a huge display title with a superscript mono count, then a ruled toolbar with text filters (slash separated, active underlined in signal) on the left and view options + ink action on the right.

Mono CleanApp header

App Header

Friendly app header: time-of-day serif greeting with the user’s name in italic sage, a calm subtitle, a rounded search field, bell with soft dot and an initials avatar.

Organic SoftApp header

Header Period

Report header: serif title with an italic period word that updates, a pill period switcher (radio semantics) and a soft export button; a wavy divider underneath.

Organic SoftApp header

Header Progress

Page header with a target ring: soft breadcrumb, serif title and description, and on the right a circular progress ring (sage stroke on sand) with the percentage and target label.

Organic SoftApp header

Header Tabs

Section header with pill tabs: serif title and a sage action on one row, then a sand track of pill links (active one cream with shadow, counts in small circles) that scrolls on mobile.

Organic SoftApp header

App Header

Friendly top header: “Good morning, Ana 👋” with a day summary; search pill, bell with red badge, periwinkle “New” button and emoji avatar on the right.

Soft FlatApp header

Header Board

Board page header: emoji tile, title and description, member emoji avatars, ink Share pill, then a pill view switcher (Board, List, Week) and a filter button.

Soft FlatApp header

Header Search

Search-first header: wide rounded search field with clear button, and emoji filter chips (Assigned to me, Due soon, Overdue, Done) that toggle to ink below.

Soft FlatApp header

Header Week

Week-planner header: round prev/next arrows around the week range (announced), a lavender “Today” pill and a mint progress pill with emoji and mini bar.

Soft FlatApp header