Bevel Frame
Picture frame for inside a card: small rounded corners with a thin white outline at low opacity inside the edge in dark mode. Give it a height or aspect ratio; it clips what is inside.
The source comes with full access.
One payment of $149 opens the source right here and lets the CLI install every paid component, with lifetime updates.
Installation
pnpm dlx shadcn@latest add @01orbital/bevel-framenpx shadcn@latest add @01orbital/bevel-frameyarn dlx shadcn@latest add @01orbital/bevel-framebunx --bun shadcn@latest add @01orbital/bevel-frameUsage
import { BevelFrame } from "@/components/media/bevel-frame"
import {
Card,
CardDescription,
CardHeader,
CardTitle,
} from "@/components/ui/card"
// The copy: change text here, not in the markup.
const COPY = {
title: "Layered currents",
description:
"A picture well with small corners; in dark mode a hairline sits inside the edge.",
image: "https://01orbital.dev/art/kit/layered-currents-553717.png",
imageAlt: "A painting of scattered blue and coral dots",
} as const
// The frame does the clipping; the Card around it only supplies the 8px gutter.
export default function BevelFrameDemo() {
return (
<Card className="w-full max-w-sm rounded-lg p-2 pb-6">
<BevelFrame>
<img
src={COPY.image}
alt={COPY.imageAlt}
className="h-56 w-full object-cover"
/>
</BevelFrame>
<CardHeader className="gap-2">
<CardTitle>{COPY.title}</CardTitle>
<CardDescription>{COPY.description}</CardDescription>
</CardHeader>
</Card>
)
}This example installs with everything it uses:
pnpm dlx shadcn@latest add @01orbital/bevel-frame-demonpx shadcn@latest add @01orbital/bevel-frame-demoyarn dlx shadcn@latest add @01orbital/bevel-frame-demobunx --bun shadcn@latest add @01orbital/bevel-frame-demoAPI reference
A picture well for inside a card. Clips its content to small rounded corners. In dark mode, a 1px white outline at 10% opacity sits inside the edge.
Give it a height or an aspect ratio. A scene placed with absolute inset-0 adds no height of its own.
It accepts the HTML attributes of the element it renders.
Dependencies
npm: cn. The CLI installs it for you.
Used in blocks
6 blocks are built with Bevel Frame:
Alternating Screenshot Feature Rows
Bevel Card
Calendar Event Card
Dark Frame Card
Three Screenshot Feature Cards
Two Screenshot Feature Cards
Last updated on