Set invalid number value instead of losing it
Since #8487 (closed), we use NaN value when the input is invalid. But the side effect is that when the user input bad value (e.g. too much digits), he lost the value entered.
I think we should set the invalid value because the "apply_factor" since #8668 (closed) always round the value set by the client. So we always have a valid value if the value is a number (and null if not).