The Wayback Machine - https://web.archive.org/web/20240930174247/https://github.com/mantinedev/mantine/issues/1129
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Notification autoClose prop triggers React warning #1129

Closed
akhrarovsaid opened this issue Mar 29, 2022 · 1 comment
Closed

Notification autoClose prop triggers React warning #1129

akhrarovsaid opened this issue Mar 29, 2022 · 1 comment

Comments

@akhrarovsaid
Copy link

akhrarovsaid commented Mar 29, 2022

What package has an issue

@mantine/notifications

Describe the bug

When using @mantine/notifications package version 4.1.0, providing the autoClose prop triggers the following React warning:

Warning: React does not recognize the 'autoClose' prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase 'autoclose' instead. If you accidentally passed it from a parent component, remove it from the DOM element.

The component still behaves as expected aside from throwing this warning.

In which browser did the problem occur

Chrome Version 99.0.4844.84 (Official Build) (64-bit)

If possible, please include a link to a codesandbox with the reproduced problem

https://codesandbox.io/s/mantine-dev-notification-autoclose-bug-4kfzi1?file=/src/App.tsx

Do you know how to fix the issue

No response

Are you willing to participate in fixing this issue and create a pull request with the fix

No response

Possible fix

Prevent passing 'autoClose' prop to underlying HTML element.

@akhrarovsaid akhrarovsaid changed the title Notification autoClose props triggers React warning Notification autoClose prop triggers React warning Mar 29, 2022
@rtivital
Copy link
Member

rtivital commented Apr 3, 2022

Fixed in 4.1.2

@rtivital rtivital closed this as completed Apr 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants