

Every state


default


focus


custom


left-to-assign


over-total


person-added


filled-gbp


jpy


disabled
Props
| Prop | Type | Default | What it does |
|---|---|---|---|
| id | string | "split" | Id prefix for the fields. |
| name | string | "split" | Base form name: <name>-total, <name>-person-<n> and <name>-share-<n>. |
| totalLabel | string | "Total to split" | Label of the total field. |
| currency | string | "EUR" | Currency (ISO code); sets the symbol, its side and the decimals. JPY has none. |
| locale | string | "en-IE" | Locale for Intl.NumberFormat. |
| defaultTotal | number | 186.4 | Starting total. |
| defaultPeople | string[] | ["Ana", "Ben", "Chloe"] | Who or what the total is split over. |
| defaultShares | number[] | – | Starting shares, one per row; leave out for an equal split. |
| sharesLegend | string | "Shares" | Legend over the rows. |
| addLabel | string | "Add person" | Label of the add button. |
| equalLabel | string | "Split equally" | Label of the button that goes back to an equal split. |
| newPersonLabel | string | "Person" | Name a new row starts with, before its number. |
| disabled | boolean | – | Disables the whole split. |
| onChange | (value: { name: string; amount: number }[]) => void | – | Called when the split changes and the parts add up to the total. |
| className | string | – | Extra classes on the wrapper. |
More amount inputs
All 6amount-input-06 is in UI ProGet UI Pro, €199


