Skip to Content
BBRICKSv0.7.4
BlocksPayments

ReceiptCard

The transfer-proof modal's receipt (.receipt): a dashed soft box with its title and status, then the transfer's figures (date, reference, amount, creators paid, from, file). Goes inside the kit Modal; Close / Download are the modal's footer.

import { ReceiptCard } from '@ergasti/bricks';

Examples

Receipt

A key and value list in a receipt card, with an optional status and title. The status word comes from the TRNDR preset.

Pinned to TRNDR preset
Code
import { ReceiptCard } from '@ergasti/bricks';

function Receipt() {
  return (
    <div style={{ maxWidth: 460 }}>
      <ReceiptCard
        title="Payout 88531"
        status="paid"
        items={[
          { label: 'Date', value: '11 Nov 2026' },
          { label: 'Reference', value: '88531' },
          { label: 'Amount', value: 'EGP 96,420.00' },
          { label: 'Creators paid', value: 38 },
          { label: 'File', value: 'receipt-88531.pdf' },
        ]}
      />
    </div>
  );
}

Pending, with nothing to list yet

A pending receipt can start with no rows; the title and the status still show.

Pinned to TRNDR preset
Code
import { ReceiptCard } from '@ergasti/bricks';

function Pending() {
  return <div style={{ maxWidth: 460 }}><ReceiptCard title="Payout 88540" status="pending" items={[]} /></div>;
}

Props

Prop

Type

Design guidance

How the BRICKS design system uses ReceiptCard. Written in docs/content/components/ReceiptCard.md; the props above are read from the code, which wins where the two disagree.

The transfer-proof receipt: a dashed soft box with a title, a status pill and the transfer's figures; use it inside the kit Modal that shows a bank transfer's proof.

It reproduces the mock's .receipt in the Brand dashboard's "Transfer proof" modal (openProof()), opened from a payout batch's "View proof" button. The card is presentational: it takes the figures as KeyValue items, fetches nothing, and leaves Close / Download PDF to the modal's footer.

Anatomy

  1. Box (.kit-blk-receipt): 20px padding, 1.5px dashed border, radius 18, --soft fill.
  2. Head (.kit-blk-receipt-h): the title in the display face (18px, kit-disp) on the start side.
  3. Status pill: a StatusPill on the end side (default paid).
  4. Figures: a kit KeyValue description list (soft tiles in two columns): Date, Reference, Amount, Creators paid, From, File.

Variants

PropValueLookUse when
status'paid' (default)Green "Paid" pillThe transfer went through (the mock).
statusany other ConsoleStatus ('pending', 'scheduled', 'on_hold', …)That status's pill tone and wordsThe proof is shown before the batch settles.
titleomitted"Bank transfer receipt" / "إيصال التحويل البنكي"The default receipt.
titlea nodeYour titleName the batch ("Payout 88531").

States

StateHow
Defaultitems with the transfer's figures; status Paid.
Other statusstatus.
Money figure noteAn item with figure (e.g. 'payout_batch_total') turns its label into the figure's "?" MoneyNote term.
Long valuesKeyValue isolates each label and value (<bdi>), so a long reference or file name wraps inside its tile.

There is no loading or error state: render it once the proof is loaded, and show the modal's own error otherwise.

Types

KeyValueItem (items): { label, value, figure?, key? } each. Pass figure on the amount so its "?" note explains it.

Usage

import { Modal, Button, ReceiptCard } from '@ergasti/bricks';

<Modal
  open={open}
  onClose={close}
  title="Transfer proof"
  footer={<><Button onClick={close}>Close</Button><Button variant="ink" onClick={download}>Download PDF</Button></>}
>
  <p className="kit-muted">Uploaded by the TRNDR team when the payout was sent.</p>
  <ReceiptCard
    items={[
      { label: 'Date', value: '11 Nov 2026' },
      { label: 'Reference', value: '88531' },
      { label: 'Amount', value: 'EGP 96,420.00', figure: 'payout_batch_total' },
      { label: 'Creators paid', value: 38 },
      { label: 'From', value: 'TRNDR payouts account' },
      { label: 'File', value: 'receipt-88531.pdf' },
    ]}
  />
</Modal>
// A named batch that is still pending
<ReceiptCard title="Payout 88531" status="pending" items={items} />

Where it appears

  • Brand › Payouts › Transfer proof modal (openProof()), opened from the payout drawer (PayoutBatchDetail) "View proof" button.
  • Dashboard screen: Payments · Payouts (the open modal).

Guidelines

Do

  • Keep it to the transfer's facts, in the mock's order: date, reference, amount, creators paid, from, file.
  • Write the amount as formatted money ("EGP 96,420.00") and mark it with figure.
  • Put Close / Download in the modal footer, not inside the receipt.

Don't

  • Don't add actions or links inside the box: it is a read-only record.
  • Don't use it for a wallet top-up's proof: the ledger opens those via ProofLink; reuse this card only if the content is a bank receipt.
  • Don't exceed about six figures; a longer record belongs in a drawer with KeyValue.

RTL and Arabic

  • The head and the tile grid follow the document direction; the pill sits on the left in Arabic.
  • Default title: "إيصال التحويل البنكي"; the pill's words come from the preset's statuses.
  • Pass Arabic money as the provider formats it ("96,420.00 ج.م"); keep references and file names Latin, they are isolated.

Tokens

--soft (box fill), plus the KeyValue tile and StatusPill tokens (--card, --ink, --ink-3, status tones). The dashed border is a fixed #C9CBD4.

Accessibility

  • The figures are a <dl> (KeyValue): each label is a <dt>, each value a <dd>, so screen readers pair them.
  • The status pill has words, never colour alone.
  • The title is bold text, not a heading: the modal's <h2> is the heading. The modal handles focus and Esc.

Found in the source

  • No roles, ARIA attributes or key handling are set in this component's own source; it renders native elements and the components it composes.

Read from the component's source and tests. See Accessibility for the patterns the library follows.

  • PayoutBatchDetail: the payout drawer that links to this proof.
  • KeyValue: the bare figure list, for records without the receipt frame.
  • Modal: the container.

See also: StatusPill · useLanguage · PayoutWindowCard · WalletHealthCard · WalletLedger

Source

src/blocks/payments/ReceiptCard.tsx (line 16) on GitHub.

On this page