Skip to Content
Kokonut UI

CD-15Cards

Spending Ring

A spending breakdown you spin like a dial; flick the ring and it settles with a category under the marker.

Install with
no extra packages

PROOnboarding Checklist and more like it are in Kokonut UI Pro

Installation

Spending Ring is a free, open-source React component in the Kokonut UI Cards collection. Add it with the shadcn CLI, which copies the source into components/kokonutui/spending-ring.tsx, so the code is yours to change.

npx shadcn@latest add @kokonutui/spending-ring

Usage

import SpendingRing from "@/components/kokonutui/spending-ring";

export default function Example() {
  return <SpendingRing />;
}

Props

title
stringDefault "October spending"
categories
SpendingCategory[]Default built-in
currency
stringDefault "USD"
className
string

Extra classes for the root element.

SpendingCategory

namerequired
string
amountrequired
number
change
number

Change from last month, in percent.

strokerequired
string

Tailwind classes for the segment stroke and the legend dot.

dotrequired
string

Dependencies

NeedsVersionComes from
cn from lib/utils.tsshadcn init
React19Your app
Tailwind CSS4Your app

No provider, font or global CSS to set up: the file works as soon as it lands.