-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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
[SwipeableDrawer][material] onTransitionEnter prop throws an error starting in version 5.14.7 #38843
Comments
Hey @jay-herrera, thanks for the report! Could you share an example of your code, as it was working before? Preferably a CodeSandbox example. Could you share the documentation you refer to as well? I don't see the |
Hey, @DiegoAndai ! Here is an example of the new functionality, which throws an Error: Here is an example of it working without an error in version 5.14.5: According to the docs, SwipableDrawer should also expose all props of the Drawer component, which in turn should expose the props of the Modal component when the varient is temporary (which is the default). The Modal Component has the prop onTransitionExited, which is described as: A function called when a transition has exited. The funtionality does actually appear to be intact (the function is appropriately called after the animation finishes), but the error suggests a problem. |
this is happening after material Modal is using useModal hook. Opened a PR to fix the issue #38868 |
Duplicates
Latest version
Steps to reproduce 🕹
Link to live example:
Steps:
Current behavior 😯
This Error is produced:
Warning: Unknown event handler property
onTransitionExited
. It will be ignored.I assume that this is because the prop is no longer recognized on the component, even though it should be according to the documentation.
Expected behavior 🤔
The onTransitionExited handler should be called after the animation ends
Context 🔦
My team uses client side routing to manage a drawer's open state. The technique works, and has worked previously by allowing the closing animation to play through, then adjusting routing accordingly. Now, there is no direct way to fire a function at the end of the closing animation.
Your environment 🌎
npx @mui/envinfo
The text was updated successfully, but these errors were encountered: