-
-
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
[DatePicker] first argument null for datepicker onchange #441
Comments
Because onChange is also passed to the TextField https://github.com/callemall/material-ui/blob/master/src/js/date-picker/date-picker.jsx#L64 and it has an event as its first argument. Looks like the intent is to funnel changes made in the textfield or dialog. Wouldn't hurt to be specific, property expansion can be confusing. I suggest renaming DatePicker.onChange to DatePicker.onDateChange and then wire up onDateChange to TextField.onChange and DatePickerDialog.onAccept. |
@jkruder Sounds like a reasonable approach. |
is there a reason why the date isnt returned as the first argument? https://github.com/callemall/material-ui/blob/master/src/js/date-picker/date-picker.jsx#L93
The text was updated successfully, but these errors were encountered: