mantine
mantine copied to clipboard
`slide-left` transition looks off on modal with `size` set
What package has an issue
@mantine/core
Describe the bug
If you set size to a big value (~900) in a Modal, the transition slide-left looks off when the modal is opened.
The transitionDuration is to make the problem more apparent but it still looks off without it.
In which browser did the problem occur
Chrome, Firefox
If possible, please include a link to a codesandbox with the reproduced problem
https://codesandbox.io/s/mantine-playground-forked-ktf2rw?file=/src/App.tsx
Do you know how to fix the issue
No
Are you willing to participate in fixing this issue and create a pull request with the fix
Yes
Possible fix
Sorry, unfortunately I have no experience with mantine's codebase but since I'll start using this library for the months to come, I'd like to learn what I can. If someone has a clue to what's wrong, I'm willing to look into it.
Using withCloseButton={false} seems to make it look OK. I updated the codesandbox to show both behaviors
Using a smaller width (~600px) seems to make it look ok too, though I don't know why.
If I use 1000px, it looks wrong even though I'm trying it in a big enough viewport.
Fixed in 5.2.7 – https://codesandbox.io/s/mantine-playground-forked-ub6nd5?file=/src/App.tsx Thanks @hotgen!