search

Home  >  Q&A  >  body text

React Material UI component selection problem

If you go to "Select Component" in MUI https://mui.com/material-ui/react-select/

and open the drop-down menu for any selection. You'll notice that you won't be able to interact with the page until you close the dropdown.

Is there any solution to this problem? Can't even scroll after opening dropdown

P.S. I don't want to use NativeSelect.

P粉105971514P粉105971514236 days ago396

reply all(1)I'll reply

  • P粉012875927

    P粉0128759272024-04-01 10:02:32

    You may have an event listener for scrolling (see documentation): https://developer.mozilla.org/en-US/docs/Web/API/Document/scroll_event

    Then, when this happens, programmatically close the selection using the "open" tag on the selection component.

    reply
    0
  • Cancelreply