Skip to content

Receipt Card

A lightly textured receipt pairs precise item rows with a torn paper edge.

LIVE PREVIEWInteract with the component
Just React. No extra dependencies.

Copy the component and its CSS module into your project.

CSS Modules

Usage

Matches your current playground settings.

jsx
import ReceiptCard from "./ReceiptCard";
export default function Example() {
return (
<ReceiptCard
title={"OBJECTS / STUDIO"}
subtitle={"Small editions, considered details"}
items={[
{
"id": "vase",
"label": "Ceramic study",
"detail": "Sand / edition 04",
"value": "£48.00"
},
{
"id": "print",
"label": "Form print",
"detail": "Uncoated paper / A3",
"value": "£24.00"
},
{
"id": "delivery",
"label": "Delivery",
"value": "£4.00"
}
]}
totalLabel={"TOTAL"}
total={"£76.00"}
footer={"Thank you for supporting\nindependent design."}
color={"#373029"}
paperColor={"#e9dfce"}
/>
);
}

Using Receipt Card

Provide labels and formatted values through items. Calculate totals and format currencies in your application, then pass total and totalLabel for display.

Use detail for secondary information below an item label. The torn edge is drawn with CSS and does not require a texture image or external asset.

Props

NameTypeRequiredDefaultDescription
titleReactNodeNoundefinedReceipt heading.
subtitleReactNodeNoundefinedOptional text below the heading.
itemsArray<{ id?, label, detail?, value }>No[]Display rows with caller-formatted values.
totalLabelReactNodeNoundefinedLabel for the final row.
totalReactNodeNoundefinedCaller-formatted total; the component does not calculate amounts.
footerReactNodeNoundefinedOptional footer content.
colorstringNo"#373029"Ink colour.
paperColorstringNo"#e9dfce"Receipt surface colour.
classNamestringNo""Additional classes on the root element.
styleCSSPropertiesNoundefinedInline styles for sizing, typography and appearance.

Related components

A paper flap lifts in 3D as a message slides out of its envelope.

A suspended badge swings naturally after you drag and release its handle.

Fine metallic grooves catch a shifting iridescent pointer highlight.

A precision-cut card with chamfered corners and a folded accent.