-
-
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
Autocomplete component breaks when slotProps are provided for textfield override in theme #44194
Comments
@yogeshkrishnani-alation
Here's a working sandbox: https://stackblitz.com/edit/vitejs-vite-fygb6l?file=src%2FApp.jsx |
Duplicate of #44145 |
@mj12albert Thanks for the quick response! I understand now that When I try to pass disableUnderline through slotProps, the Autocomplete component still breaks. I've shared a sandbox link here for reference: https://stackblitz.com/edit/vitejs-vite-6rklm8?file=src%2FApp.jsx. Previously, we used InputProps to pass disableUnderline, but during the MUI upgrade from v5 to v6, it was replaced by slotProps.input. The issue I’m facing is that when the Do you think there’s room for improvement in how MUI handles overrides or provides error feedback in cases like this? |
@yogeshkrishnani-alation It's not supported yet 😓 see #43606 |
@mj12albert I would describe it as being supported since it's part of the official documentation and the mui version upgrade/migration script, but not fully functional due to some existing open issues like #43606. |
Steps to reproduce
Link to live example: https://stackblitz.com/edit/vitejs-vite-6rklm8?file=src%2FApp.jsx
Steps:
Current behavior
Autocomplete component is not working
Expected behavior
Autocomplete component should work as expected
Context
If we replace slotProps with InputProps, autocomplete is working as expected. However, that's not ideal, as InputProps is deprecated and will be removed in v7.
Your environment
npx @mui/envinfo
Search keywords: autocomplete, slotProps, textfield, override, theme
The text was updated successfully, but these errors were encountered: