You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(I was originally gonna post this on Material-UI, but realized this library is the cause)
Passing a custom component using MaskedInput to MUI's TextField's inputProps property seems to be passed all the way to the actual <input> element, which causes this error to appear in the console: index.js:1 Warning: React does not recognize the `inputComponent` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `inputcomponent` instead. If you accidentally passed it from a parent component, remove it from the DOM element.
The issue is present in the latest release. (^5.4.7)
I have searched the issues of this repository and believe that this is not a duplicate.
Current Behavior 😯
Expected Behavior 🤔
No errors as-is with Material-UI/text-mask, without having to resort to a workarounds such as { inputProps, ...props }: CustomProps. inputProps is specifically an issue here as it's used with MUI, but I believe the true solution is to discard all invalid input properties.
(I was originally gonna post this on Material-UI, but realized this library is the cause)
Passing a custom component using
MaskedInput
to MUI'sTextField
'sinputProps
property seems to be passed all the way to the actual<input>
element, which causes this error to appear in the console:index.js:1 Warning: React does not recognize the `inputComponent` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `inputcomponent` instead. If you accidentally passed it from a parent component, remove it from the DOM element.
Current Behavior 😯
Expected Behavior 🤔
No errors as-is with Material-UI/text-mask, without having to resort to a workarounds such as
{ inputProps, ...props }: CustomProps
.inputProps
is specifically an issue here as it's used with MUI, but I believe the true solution is to discard all invalid input properties.Steps to Reproduce 🕹
Use a MaskedInput with some inputProps
https://codesandbox.io/s/delicate-meadow-2j75c
https://github.com/Avasam/speedrun.com_global_scoreboard_webapp/blob/develop/tournament-scheduler/src/Components/ScheduleManagement/ScheduleWizard/NonZeroNumberInput.tsx
The text was updated successfully, but these errors were encountered: