sigilUI

Stack Diagram

A vertical stack of labeled layers with optional 3D tilt, hatching, and interactive hover states.

@sigil-ui/componentsReact

Preview

Live preview Interactive

Import

import { StackDiagram } from "@sigil-ui/components";

Usage

<StackDiagram title="Application layers" layers={[{ label: "Interface", children: "Pages and reusable components" }, { label: "Services", children: "Business logic and workflows", accent: true }, { label: "Storage", children: "Persistent application data", hatched: true }]} />

With title and tilt

<StackDiagram
  title="Architecture"
  tilt
  layers={[
    { label: "CDN" },
    { label: "App", hatched: true },
    { label: "Cache" },
    { label: "Storage", accent: true },
  ]}
/>

Non-interactive

<StackDiagram interactive={false} layers={[{ label: "A" }, { label: "B" }]} />

Props

PropTypeDefaultDescription
layersStackLayer[]—Array of { label, children?, hatched?, accent? } (required)
titlestring—Heading above the stack
gapstring"0.5rem"CSS gap between layers
tiltbooleanfalseApply 3D perspective tilt
interactivebooleantrueEnable hover highlight on layers
classNamestring—Additional CSS classes

Plus all standard <div> HTML attributes.