Amount input
canonAmount or count typed as a mask: digits and separators only, thousands grouped as you type, a dot read by context (12.345 = thousands, 12.5 = decimal), nothing typed is ever cut off silently.
Merged to origin/main 28 September 2026 (acrm MR !4089). Replaces raw <input type="number"> for amounts on 16 app surfaces (advances, benefits, expenses, KPI, costs, documents, pricing, assets, budgets, vehicles, cash desk, orders, phones). Raw value contract -?\d*(\.\d*)? unchanged for hosts. Dot rule and no-silent-truncation per AD 28 Sep 2026; caret anchoring after the decimal comma fixed in number-core (caretInFormatted), shared with RecordRail. Canon 28 Sep 2026 (AD approved M3; /ds renders the stories from the main build).
Used in 12 files · 9 areas · 13× — components/clen-tymu, components/dialog, components/org, components/products, pages/OrderDetailPage, pages/PokladnaDetailPage …
Keyboard
- Typing digits,
,and.works as described in Usage; letters and other characters are ignored. - Arrow ↑ / ↓ increment / decrement by one (replacement for the native number stepper).
- The caret stays after the same digit while grouping spaces appear or disappear, including right after the decimal comma (
12,+5→12,5). - Tab / Shift+Tab move focus normally; on blur an undecided dot (
12.5) becomes12,5.
ARIA
- Native
<input type="text">withinputMode="decimal"/"numeric"— mobile keyboards show digits. - Accessible name from the wrapping DS
Fieldlabel orariaLabel. aria-describedbylinks the hint / error under a DSFieldautomatically (useFieldDescribedBy); a host can passdescribedByexplicitly.aria-invalid="true"when the host marks the value invalid, and for a count (decimals={0}) left with an undecided dot (12.3) on blur — that value is not saved.- The unit suffix is
aria-hidden; the unit must be part of the label.
Focus
- Standard DS input focus ring on the shell (
.acrm-inputwrap:focus-within). - No focus traps; the field never moves focus on its own.
Contrast
- Text uses
--fgon--surface-100(AA). - Suffix uses the muted tone of
.acrm-amount-suffix; it repeats information already in the label, so it is not the only carrier of meaning. - Error state uses the DS field error ink (
--critical-ink) plusaria-invalid.
Known limits
- The dot rule applies to locales with a decimal comma (cs). In a decimal-dot locale (en) the comma is a grouping separator and the dot is always decimal.
- A refused keystroke gives no audible feedback — the value simply does not change.
Source: docs/text-field/amount-input.a11y.md · GitLab