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

[DatePicker] Generated actions do not have type of button #733

Closed
pola88 opened this issue Jun 1, 2015 · 2 comments
Closed

[DatePicker] Generated actions do not have type of button #733

pola88 opened this issue Jun 1, 2015 · 2 comments
Labels
new feature New feature or request

Comments

@pola88
Copy link

pola88 commented Jun 1, 2015

Hi guys,

I have a problem to use the DatePicker component, when I select a day, this reloads the page. Do you know what I am missing?

Here is how I am using it:

import mui from 'material-ui';

let example = React.createClass( {
    _dataPickerChange: function() {
       .....
    },

   render: function() {
    return <div><mui.DatePicker onChange={this._dataPickerChange} /></div>;
   }
});

material-ui: 0.7.1

Thanks in advance,
PoLa.

@pola88
Copy link
Author

pola88 commented Jun 2, 2015

This happens when the DatePicker is into a form tag. the buttons submit the form.

@hai-cea
Copy link
Member

hai-cea commented Jun 19, 2015

@pola88 This happens because the buttons that are generated is not of type button. You could pass in custom actions and set the button type to button until we get this problem patched.

@hai-cea hai-cea changed the title DatePicker reloads the page [DatePicker] Generated actions do not have type of button Jun 19, 2015
@alitaheri alitaheri added new feature New feature or request and removed Enhancement labels Dec 8, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants