Registry
Split
The two-column workhorse: children flow into equal panels.
---
layout: split
title: Two ways to tell it
---
<div>
Narrative on the left: why decks belong in git, diffed and
reviewed like everything else you ship.
</div>
<div>
<MetricCard value="42%" label="Activation lift" delta="+18%" />
<MetricCard value="1,200" label="Teams onboarded" />
</div>Installation
camp add splitOr with any shadcn-compatible CLI:
bunx shadcn@latest add https://campfire-deck.vercel.app/r/split.jsonCopy the source into layouts/split.tsx. It imports cn from
@/lib/utils — scaffolded by camp init, or camp add utils:
import type { ComponentProps } from "react";
import { cn } from "@/lib/utils";
export type SplitLayoutProps = ComponentProps<"main"> & {
/** From the slide's `title` frontmatter. */
title?: string;
};
/** The two-column workhorse: children flow into equal side-by-side panels. */
export default function SplitLayout({
title,
className,
children,
...props
}: SplitLayoutProps) {
return (
<main
className={cn("flex h-full flex-col gap-10 p-24", className)}
data-slot="split-layout"
{...props}
>
{title ? (
<h1 className="font-bold font-heading text-6xl tracking-tight">
{title}
</h1>
) : null}
<div
className="grid flex-1 grid-cols-2 items-center gap-16 text-2xl leading-relaxed"
data-slot="split-layout-panels"
>
{children}
</div>
</main>
);
}Usage
The slide body's top-level children become the columns — two children, two equal panels. Text vs. visual, before vs. after, us vs. them:
---
layout: split
title: Before / After
---
<Callout>Decks rot in proprietary tools.</Callout>
<Callout tone="primary">The repo is the deck.</Callout>For the specialized problem/solution narrative, use Problem / Solution.
API Reference
Follows the layout contract and exposes
data-slot="split-layout" and split-layout-panels.
Prop
Type