Closed jlubben closed 3 years ago
@lambertwang Fyi
Also I find it confusing that MaskedTextField
doesn't have its own interface. TextFieldProps
lists a bunch of masked options but this isn't applicable to TextField...
Linked this to the TextField epic issue, closing out this particular instance as we won't be solving this outside of component convergence
Inside of MaskedInput, we have the _onInputChanged method. Let's say we have an arbitrary mask "99999" and the current input string is "12345". in the case that the beginning of the string is exactly "1234" I want to allow the mask to change to also allow alphebtical letters on the 5th character to yield something like "1234A". However, after _onInputChange calls my input change via this.props.onChanged(value), it never provides a way for an updated mask. Therefore, it retains the old mask and this causes problems.
It should be possible to allow the masks to change on the fly.