-
-
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
[Accordion] Accepts "component" prop, but TS says it shouldn't #36940
Labels
Comments
zachintosh
added
the
status: waiting for maintainer
These issues haven't been looked at yet by a maintainer
label
Apr 19, 2023
mj12albert
added
component: accordion
This is the name of the generic UI component, not the React module!
and removed
status: waiting for maintainer
These issues haven't been looked at yet by a maintainer
labels
Apr 20, 2023
@zachintosh Thanks for reporting this ~
This isn't working. It's also affecting other components that's using ( |
Would it make sense to add it to PaperTypeMap?
or InternalStandard Props?
|
@mj12albert are you working on this? |
@sai6855 Please go ahead ~ |
1 task
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Duplicates
Latest version
Steps to reproduce 🕹
Link to live example:
https://codesandbox.io/s/brave-night-r23fp0?file=/src/App.tsx
Steps:
Current behavior 😯
Applying the "component" prop on Accordion causes Typescript to throw an error, but it works as expected. The 'component' prop element is used.
Expected behavior 🤔
Either the prop types for Accordion need to be fixed or update Accordion to reject
component
.Context 🔦
This is comes from an oddly specific situation where we need to make Accordion also a Draggable (from another library). We can work around it, so it isn't preventing us from anything critical, but noticed this bug along the way.
Not critical in any way that we get this fixed. Just through we'd point it out in case it's an inconsistency that needs to be looked at.
Your environment 🌎
npx @mui/envinfo
Using Brave browser (Chromium) and VSCode
The text was updated successfully, but these errors were encountered: