Closed cityremade closed 3 months ago
To clarify further:
this element is of type number only. I am concerned with complexity if we put text and number inputs together. Should they be separate elements?
Another case is numeric entry with formatting like separators and currency symbols - this is a mix of numeric argument (in an input of type text) and string display. Where does it go from here? Wasn't this special input meant for editing fields in tables? It takes a lot of space in numeric.mjs
It is used in numeric entry.
Another use of numeric input is the slider element. Slight difference in use as slider/range would never bounce to null/undefined.
Let me know your thoughts.
mapp.language is assigned as mapp.user.language and will always have a value.
hence formatterParams.locale
will always have a value and doesn't need to be checked before creating the localeValue as const.
undefined
is not a number hence only null and NaN need to be checked in the condition for the value.
onblur=${e => { if (e.target.value === '') e.target.classList.remove('invalid'); }}
When .invalid class is on it is toggled off when input is emptied and on blur. Otherwise the .invalid style would be left there on cleared and valid (null) input. One of edge cases: null => set value out of range => failed checks => invalid => set back to null => blur => no longer invalid 😂
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code
Added an element for input of type 'number'. Used in numeric entry as a test area.
Includes validation if min/max defined in parameters.