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

[NumberInput][base-ui] Warn when changing control mode with useControlled #38757

Merged
merged 6 commits into from
Sep 14, 2023

Conversation

sai6855
Copy link
Contributor

@sai6855 sai6855 commented Sep 2, 2023

closes: #38513

@sai6855 sai6855 added package: base-ui Specific to @mui/base enhancement This is not a bug, nor a new feature component: number field This is the name of the generic UI component, not the React module! labels Sep 2, 2023
@mui-bot
Copy link

mui-bot commented Sep 2, 2023

Netlify deploy preview

https://deploy-preview-38757--material-ui.netlify.app/

Bundle size report

Details of bundle changes (Toolpad)
Details of bundle changes

Generated by 🚫 dangerJS against 57a1c1e

@sai6855 sai6855 marked this pull request as draft September 2, 2023 12:23
@sai6855 sai6855 requested a review from mj12albert September 2, 2023 17:21
@sai6855 sai6855 marked this pull request as ready for review September 2, 2023 17:21
@sai6855
Copy link
Contributor Author

sai6855 commented Sep 2, 2023

Off topic can we return isControlled boolean in useControlled to avoid code duplication like this ?

Copy link
Member

@mj12albert mj12albert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good ~ thanks for working on this

@sai6855 Note that this will need to be handled differently once the internal state is refactored with useControllableReducer 😬

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: number field This is the name of the generic UI component, not the React module! enhancement This is not a bug, nor a new feature package: base-ui Specific to @mui/base
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[base-ui][useNumberInput] Warn when changing control mode with useControlled
3 participants