Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Commitments Ledger About Block for React

A ledger of a nonprofit CRM's public promises: an ordered list of rows with the promise, how far along it is as a word and a progress bar, who owns it and when it was last checked, and a tally counted from the rows.

Framework
UI library

Preview

Preview width

Installation

Part of Pro
Pro unlocks the code and one-line install of every Pro button and text effect, plus the MCP for your AI editor.
Have Pro already? Sign in to open it.Opens here as soon as you're Pro.

Overview

A commitments ledger for React with Base UI, written for Pledgeboard, a fictional CRM that nonprofits keep their donors in. The company's public promises are an ordered list of rows that runs from rail to rail between hairlines. Each row gives the promise and what its percentage counts; its state as one word, Kept, On track or Slipping, with a progress bar in your foreground colour and the percent; the owner, by name and team; and when someone last checked it. Only a slipping promise has a status dot, so a healthy ledger is quiet and a slipping one is easy to find. A tally in the header, "2 kept, 2 on track, 1 slipping", is counted from the rows. On a phone the progress takes the full row and the owner and the check sit side by side under it. It's built from Progress, Status and Guides with a CSS entrance and your theme's tokens, with no script. For about and trust pages that show how a company keeps its word. The promises, names and figures are example data.

FAQ

How do I change the promises?

They are COMMITMENTS at the top of the file: each has a promise, a detail that says what the percentage counts, a value from 0 to 100, an owner and team, and checked, a relative phrase such as "2 weeks ago". The word is worked out from the value in stateOf: 100 is Kept, 60 and over is On track, anything lower is Slipping. The tally in the header is counted from the same list, so the two always agree.

Why does only a slipping promise get a dot?

When every row has a coloured marker, none of them stands out, and green and red cause trouble for readers who can't tell the two apart. Here the state is always written as a word, and the one state that needs attention adds a small dot. The progress bars are your foreground colour, so your primary colour stays free for the page's one call to action.

How do screen readers and keyboards handle it?

The list is an ordered list, each promise is an h3 and its details are a description list (progress, owner, checked), so a row reads as "Progress: Kept, 100%", then the owner and the date. The progress bar is decorative because the word and the percent say the same thing, and the status dot is hidden for the same reason. There are no controls, and the block has no state, so it renders on the server.

How do I keep the dates honest?

"Checked 3 days ago" is only true on the day you write it. Update the checked phrases whenever someone checks a promise, or compute them from a date in your own data with a relative-time formatter. This block takes the phrase as text on purpose, so it needs no year and no clock.

How are the lines drawn?

The rows are an ordered list with a hairline between each pair, from rail to rail. Guides draws the band's top rule, with a + on each rail, and the page's rails come from the spine. The ledger ends the block: the column has no bottom padding and there is no rule under the last row, because the next block's top rule is its foot.

How does it fit on a phone?

Below lg each row stacks: the promise and its detail, then the progress across the full width, then the owner and the check date side by side. From sm the three details sit on one line under the promise, and from lg they sit beside it. The header's tally goes under the heading on a phone, and nothing scrolls sideways at 320 pixels.

  • Pro

    Severity Ladder SLA About

    Support and contact

    An incident tool's four severities as bands, each with its response and resolution drawn as bars to scale on one log time axis, a compliance figure and a framed note on credits.

  • Pro

    A payroll co-op's report of seven measures over four quarters in Financial and Operational groups, a sparkline on every row, footnotes, and a quarter picker that rings one column.

  • Pro

    An accessibility pledge for a checker product: an accordion of the four principles with a conformance word and how each is met, beside an audit history rail of four audits.

  • Pro

    An ethics block for a survey tool: three requests as radio cards (hand over customer data, switch off a feature, share usage with an investor), each answered in three numbered steps and a named decider.

  • Pro

    A framed table of seven company figures for an open-startup tracker: last quarter, this quarter, the computed change and a thin bar toward each target, sortable by metric, change or progress.

  • Pro

    Guarantee Certificate About

    Principles and process

    A home-warranty guarantee drawn as a certificate: a seal in SVG above the title, three promises with ticks, the fine print behind a disclosure that stays in the page, and a Shine Button to start a claim, in a card in card.