Entities 0.4.16: Number fields that take a comma, with limits checked on the server
Entities 0.4.16 changes how number and decimal fields take input: a comma or a dot works as the decimal point, and the minimum and maximum of a number field are now checked on the server. It needs PhoenixKit 2.26 or later.
Number and decimal fields are now plain text boxes with a decimal keyboard on phones, not browser number inputs. Digits grouped in threes are accepted, and the browser’s step check no longer silently blocks a submit. A decimal field keeps the places that were typed, so 5,10 is stored as 5.10.
The min and max of a number field used to be checked only by the browser. The server now checks them in the admin and in public forms, which also store numbers in the same shape as the admin.
Values of 10¹² or more, or text longer than 64 bytes, are now refused. A record that already holds such a value fails validation on its next save; use a text field for values like millisecond timestamps. An unreadable min or max is now ignored instead of crashing saves.
Upgrading
Update PhoenixKit to 2.26 or later. Check number fields that store very large values before editing those records.
Full release notes: Entities 0.4.16
0.4.16 · 16 September 2026
Changed
- Number and decimal fields use core’s
<.decimal_input>(#49). They now render a text control withinputmode="decimal"in both the full form andFieldInput, not<input type="number">, and parse input withPhoenixKit.Utils.Number.parse_decimal/2. A comma or a dot works as the decimal point, 3-digit grouping is accepted, and the browser’sstepcheck no longer silently blocks a submit. Adecimalfield keeps the scale that was typed (5,10is stored as5.10). min/maxare enforced on the server fornumberfields (#49). The browser used to be the only check. The public form endpoint now stores number/decimal values in the same shape as the admin form (a float or aDecimal) and applies the same bounds.- Values with a magnitude of 10¹² or more, or text longer than 64 bytes, are
now rejected in number/decimal fields (core’s
parse_decimal/2guard). A record that already stores a larger value fails validation on its next save. Use atextfield for values like millisecond timestamps. - Requires
phoenix_kit2.26 or later (~> 2.26). Earlier cores lack<.decimal_input>andNumber.parse_decimal/2. - Dependency lock:
phoenix_kit2.26.1,phoenix_live_view1.2.12,phoenix_kit_templates0.1.2,swoosh1.28.1.
Fixed
- A field definition with an unreadable
min/max("", a typo,"NaN") no longer crashes saves of that entity’s records. The bound is ignored, as the form builder already documented.
Entities 0.4.16. Install or update: {:phoenix_kit_entities, "~> 0.4"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.