Componentdata0.41 KB gzipZero dependencies

Stack

Stacked container with staggered angles and hover fan-out.

Preview

Live Preview
Open ↗

Installation

Tokens guide →

Add to your project via CLI (zero dependencies, code you own):

npx bigbullui add stack

Or install the full npm package:

npm install bigbullui

Usage

tsx6 lines
import { Stack } from "@/components/ui/stack"; <Stack fanOnHover>  <div>Ticket 1</div>  <div>Ticket 2</div></Stack>

Source code

stack.tsx + 1 helper

Zero third-party dependencies (2 local files shown in tabs below).

tsxstack.tsx52 lines
"use client"; import * as React from "react";import { cn } from "./lib/utils"; export interface StackProps extends React.HTMLAttributes<HTMLDivElement> {  children: React.ReactNode;  fanOnHover?: boolean;  className?: string;} export function Stack({  children,  fanOnHover = true,  className,  ...props}: StackProps) {  const childArray = React.Children.toArray(children);

Props

Interactive Prop Playground

Tweak parsed AST props below to generate ready-to-paste JSX.

tsx3 lines
import { Stack } from "@/components/ui/stack"; <Stack />
PropTypeDescription
childrenReact.ReactNodeChild elements rendered inside the component.
fanOnHoverbooleanToggles fan on hover. (Default: true)
classNamestringOptional Tailwind or custom CSS classes merged with component styles.