Right now, the TextInput component allows 2 values for the input's type attribute: "text" (the default) and "search." However, there are probably more text-ish types we should cover with this component, including:
- number
- month
- password
- tel
- url
- week
- date
- datetime-local
- time
See MDN for a full list of type values for inputs.
For some of these, we may build a wrapper component in the future to better handle/style certain elements (e.g. the calendar that pops up with type="date"), but for now we can allow the browser behavior to take over in circumstances we haven't covered yet.
Acceptance criteria
- Determine which types to include
- Add those types to the allowed values for the TextInput type prop
- Make sure none of the browser-specific UIs clash with the current implementation of TextInput
- Add examples to the docs? Maybe note that things like "date" will be handled by the browser for now.
[] Update the number input on the Menu demo page to be type="number" (already done)