File tree Expand file tree Collapse file tree 2 files changed +29
-1
lines changed Expand file tree Collapse file tree 2 files changed +29
-1
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ how the input and output of the data is handled.
1717| Options | - `currency `_ |
1818| | - `divisor `_ |
1919| | - `grouping `_ |
20+ | | - `html5 `_ |
2021| | - `rounding_mode `_ |
2122| | - `scale `_ |
2223+-------------+---------------------------------------------------------------------+
@@ -90,6 +91,21 @@ be set back on your object.
9091
9192.. include :: /reference/forms/types/options/rounding_mode.rst.inc
9293
94+ html5
95+ ~~~~~
96+
97+ **type **: ``boolean `` **default **: ``false ``
98+
99+ .. versionadded :: 5.2
100+
101+ This option was introduced in Symfony 5.2.
102+
103+ If set to true, the HTML input will be rendered as a native HTML5 type="number" form.
104+
105+ .. caution ::
106+
107+ As HTML5 number format is normalized, it is incompatible with ``grouping `` option.
108+
93109scale
94110~~~~~
95111
Original file line number Diff line number Diff line change @@ -15,7 +15,8 @@ the input.
1515+-------------+-----------------------------------------------------------------------+
1616| Rendered as | ``input `` ``text `` field |
1717+-------------+-----------------------------------------------------------------------+
18- | Options | - `rounding_mode `_ |
18+ | Options | - `html5 `_ |
19+ | | - `rounding_mode `_ |
1920| | - `scale `_ |
2021| | - `symbol `_ |
2122| | - `type `_ |
@@ -57,6 +58,17 @@ Field Options
5758
5859 The ``rounding_mode `` option was introduced in Symfony 5.1.
5960
61+ html5
62+ ~~~~~
63+
64+ **type **: ``boolean `` **default **: ``false ``
65+
66+ .. versionadded :: 5.2
67+
68+ This option was introduced in Symfony 5.2.
69+
70+ If set to true, the HTML input will be rendered as a native HTML5 type="number" form.
71+
6072scale
6173~~~~~
6274
You can’t perform that action at this time.
0 commit comments