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
If possible, include a link to a codesandbox with a minimal reproduction
No response
Possible fix
Modify the logic within the FileButton component to safely reset the input value only when inputRef is not null. The following code modification has been tested locally and resolves the issue:
if(inputRef?.current){inputRef.current.value="";}
It looks like a simple and safe snippet of code.
### Self-service
- [X] I would be willing to implement a fix for this issue
The text was updated successfully, but these errors were encountered:
Dependencies check up
What version of @mantine/* packages do you have in package.json?
7.13.2
What package has an issue?
@mantine/core
What framework do you use?
Next.js
In which browsers you can reproduce the issue?
Chrome
Describe the bug
When using the following logic in tsx:
The following error is thrown when resetting the input, and
handleReset
have no way to skip it:mantine/packages/@mantine/core/src/components/FileButton/FileButton.tsx
Line 76 in fbcee92
If possible, include a link to a codesandbox with a minimal reproduction
No response
Possible fix
Modify the logic within the
FileButton
component to safely reset the input value only wheninputRef
is not null. The following code modification has been tested locally and resolves the issue:It looks like a simple and safe snippet of code.
The text was updated successfully, but these errors were encountered: