Receivables activity feed
Recent invoice activity across the organisation: drafts, sends, payments, reminders and credit notes, each row opening its invoice, with loading, empty and error states. Also exports ArRowPanel, the titled card of short rows the receivables home is built from.
Component: A piece you place inside your own screens: a table, a form, a card or a dialog. You decide the layout around it. Pages vs components
Ready to connect to Dolfin. Loads data through SDK hooks, with appearance and behaviour you can customise. Requires DolfinProvider.
Installation
Needs the Dolfin registry token. The CLI copies the source into your app.
bunx --bun shadcn@4.23.0 add @dolfin/ar-activity-feedAlso installs: base-theme, base-page, base-money, ui-ar-activity-feed.
Usage
import { ArActivityFeed } from "@/components/dolfin/ar/activity-feed";
// Place it anywhere inside your <DolfinProvider>.
<ArActivityFeed />Renders inside DolfinProvider (set it up once). By default it loads its own data through the SDK. Supplied-data examples show how to override that behavior.
API reference
| Prop | Type | Description |
|---|---|---|
entries | readonly ArActivityEntry[] | Your own events, newest first: the feed then makes no request. |
loading | boolean | |
error | Error | |
onRetry | () => void | |
limit | number | How many events to load; defaults to 5. |
title | string | |
empty | string | |
toRow | (entry: ArActivityEntry, row: ArPanelRow) => ArPanelRow | Builds each row; defaults to number, what happened, customer, time and any amount received. |
className | string |
Customisation
Without editing the source, you can change:
- Class names
className- Messages
ar.activity.emptyar.activity.errorar.activity.titlear.homear.invoice.statesar.invoiceFallbackar.panelErrorar.panelLoadingbase.states
Or edit the installed file directly: it is your code. See theming for colours and fonts.
Hooks
The SDK hooks this component uses. Use them directly from @dolfinai/react to build your own version.
useArActivityuseDolfinLocaleuseMessagesFiles
Written to your app by the install command:
components/dolfin/ar/activity-feed.tsx186 lines