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

[Button] Remove style-propable mixin from flat-button-label #3197

Merged
merged 1 commit into from
Feb 6, 2016

Conversation

newoga
Copy link
Contributor

@newoga newoga commented Feb 5, 2016

No description provided.

@newoga newoga changed the title Remove style-propable mixin from flat-button-label [Button] Remove style-propable mixin from flat-button-label Feb 5, 2016
@newoga newoga added the Core label Feb 6, 2016

return (
<span style={this.prepareStyles(mergedRootStyles)}>{label}</span>
<span style={prepareStyles(styles.root, style)}>{label}</span>
Copy link
Member

Choose a reason for hiding this comment

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

from what I understand from the transformer chain that is prepareStyles it only takes 1 argument. so style will probably be ignored. I think you should Object.assign({},...) this too.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh geez, good catch! I actually had meant to enable a warning for that too so we could catch it similarly to callOnce.

I think I might do that but not commit it because it's probably going to complain a lot with all the mixin implementations often using prepareStyles with multiple arguments.

Copy link
Member

Choose a reason for hiding this comment

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

a warning is interesting 👍 It will catch all these misuses. good idea 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

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

image

😆 😆 The docs site got very angry with me.

Copy link
Member

Choose a reason for hiding this comment

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

😱 😱 😱 😱 😱 😱

@alitaheri
Copy link
Member

All good 👍 😁

@@ -61,19 +71,16 @@ const FlatButtonLabel = React.createClass({
style,
} = this.props;

const contextKeys = this.constructor.getRelevantContextKeys(this.state.muiTheme);
Copy link
Member

Choose a reason for hiding this comment

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

👍 We should get rid of this ContextPure too.

oliviertassinari added a commit that referenced this pull request Feb 6, 2016
[Button] Remove style-propable mixin from flat-button-label
@oliviertassinari oliviertassinari merged commit 53394d5 into mui:master Feb 6, 2016
@oliviertassinari
Copy link
Member

@newoga Thanks!

@newoga newoga deleted the #2852/flat-button-label branch February 6, 2016 23:19
@zannager zannager added the component: button This is the name of the generic UI component, not the React module! label Mar 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: button This is the name of the generic UI component, not the React module!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants