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

[Select] MenuListProps missing property 'component' #17579

Closed
2 tasks done
urielvan opened this issue Sep 26, 2019 · 5 comments
Closed
2 tasks done

[Select] MenuListProps missing property 'component' #17579

urielvan opened this issue Sep 26, 2019 · 5 comments
Labels
component: select This is the name of the generic UI component, not the React module! typescript

Comments

@urielvan
Copy link

urielvan commented Sep 26, 2019

  • The issue is present in the latest release.
  • I have searched the issues of this repository and believe that this is not a duplicate.

Current Behavior 😯

  <Select
    MenuProps={{
      MenuListProps: {
       // here Typescript throws error, saying not assignable
       // while it does change the wrapping component from ul to div
        component: "div"
      }
    }}
  >

Expected Behavior 🤔

No Typescript errors should be shown

Steps to Reproduce 🕹

https://codesandbox.io/s/ancient-platform-3ldzt

Context 🔦

I have a select that may contains 1400+ options, so I think I may replace the MenuList component to a virtualized one, referring https://material-ui.com/zh/components/lists/#virtualized-list

Your Environment 🌎

Tech Version
Material-UI v4.4.3
React
Browser
TypeScript v3.6.3, v3.5.2
etc.
@oliviertassinari oliviertassinari changed the title [Typescript] MenuListProps missing property 'component' [prop component] MenuListProps missing property 'component' Dec 1, 2019
@gitw2billy
Copy link

First time open source contributor here - just started working on this issue

@peterkrieg
Copy link

Just created PR: #21564 to take care of this! I was about to create an isssue and had a codesandbox of behavior reproduced but luckily found this issue first 🙂

@oliviertassinari oliviertassinari added the component: select This is the name of the generic UI component, not the React module! label Jun 25, 2020
@B3Kay
Copy link

B3Kay commented Jun 29, 2020

I have the same issue with the Typography component.

@oliviertassinari oliviertassinari changed the title [prop component] MenuListProps missing property 'component' [Select] MenuListProps missing property 'component' Aug 22, 2020
@mnajdova
Copy link
Member

Related to #21210 & #15827

@ZeeshanTamboli
Copy link
Member

It works in the latest version. Hence, closing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: select This is the name of the generic UI component, not the React module! typescript
Projects
None yet
7 participants