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

Classes & Props: Checkbox #32

Merged
merged 2 commits into from
Oct 8, 2015
Merged

Classes & Props: Checkbox #32

merged 2 commits into from
Oct 8, 2015

Conversation

levithomason
Copy link
Member

No description provided.

@@ -19,8 +19,9 @@ import $ from 'jquery';
* <Checkbox type='toggle' />
*/
@radium
class Checkbox extends Component {
export default class Checkbox extends Component {
Copy link
Member Author

Choose a reason for hiding this comment

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

Export inline, instead of at the end of the file.

<div className={classes} style={this.props.style} ref='container'>
<input defaultChecked={this.props.defaultChecked} type='checkbox' name={name} ref='checkbox' />
<div className={classes} ref='container'>
<input {...checkboxProps} ref='checkbox' />
Copy link
Member Author

Choose a reason for hiding this comment

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

Only spread non class props, since classes belong on the containing div.

Copy link
Contributor

Choose a reason for hiding this comment

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

nifty, will we plan to implement this with every stardust component?

Copy link
Contributor

Choose a reason for hiding this comment

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

haha this way cleaner than trying to determine whether or not it's a className >.< +1

Copy link
Member Author

Choose a reason for hiding this comment

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

@athurman yep, every component is getting this update.

@athurman
Copy link
Contributor

athurman commented Oct 8, 2015

Looks good! 🌊 🐙

@eanplatter
Copy link
Contributor

🍂

levithomason added a commit that referenced this pull request Oct 8, 2015
@levithomason levithomason merged commit b14c41d into master Oct 8, 2015
@levithomason levithomason deleted the feature/checkbox-classes branch October 8, 2015 15:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants