[website] Improve Base UI hero section demo#38255
Conversation
|
@michaldudak & @oliviertassinari hey y'all! I'll need your help with some of the unchecked items: Enable the Escape key to close the modal. Scrollbar layout shift after the Modal's transition. Add a transition to the Select list box + menu dropdown Add a transition to the Slider component |
Weird, whether the Modal uses portals or not shouldn't affect the behavior of the Escape key. I'll look into it.
This is apparent on Windows as the scrollbar disappears whenever the Modal is shown, causing a layout shift. As I use Windows, I can tackle it as well.
We'll have to wait until #38280 is done for these. |
|
Sweet, thanks for the help! I think we can merge these improvements without the animation. It'd definitely be great to have it but I don't want to use Material UI components for that to make it as pure as possible! |
Netlify deploy previewhttps://deploy-preview-38255--material-ui.netlify.app/ Bundle size report |
|
I fixed the layout shift, but the inability to close the modal with the Escape key is more tricky. It may be a subtle bug within the Modal or Focus Trap, as the modal body doesn't get focused after it's open and does not respond to keyboard events. I'll spend some more time on this tomorrow. |
There was a problem hiding this comment.
Let's merge it in its current state and create an issue with the Escape key not working (#38468)
|
The modal animation feel so much better with a stable layout, how did you solve it? I have updated #36622 (comment) with checkboxes to keep track of what's done for clarity. |


Following @oliviertassinari's feedback on the original page PR (#36622 (comment)). This PR is limiting itself, for the sake of scope, to the hero section demo only. There are other page improvements reported there but those will happen in a different one.
labelelement rather thanp.https://deploy-preview-38255--material-ui.netlify.app/base-ui/
The items below will come later once an overarching animation strategy for Base is figured out (#38280).