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

[RaisedButton] Cannot override styles #644

Closed
timnity opened this issue May 14, 2015 · 6 comments
Closed

[RaisedButton] Cannot override styles #644

timnity opened this issue May 14, 2015 · 6 comments
Labels
component: button This is the name of the generic UI component, not the React module!

Comments

@timnity
Copy link

timnity commented May 14, 2015

when I use this
<RaisedButton style={{marginLeft: 300}} type="submit" label="Login" secondary={true} />
the RaisedButton component will display tow layer

@mmrtnz
Copy link
Contributor

mmrtnz commented May 19, 2015

Hi @timnity, can you please provide a screenshot and/or code example of what you are doing?

@MycChiu
Copy link

MycChiu commented May 30, 2015

I think i am experiencing the same problem. When I use inline style to alter raisedButton

var buttonStyle = {
    'height': 90,
    'width': 90,
    'margin': 5
};
//skipping other codes to rendering
 <RaisedButton style={buttonStyle} label="1-2"/>

the button itself will be resized, but when you hover over the button, the color change will only happen around the default area.

I tried to used the ThemeManager to override the style but haven't got it to work yet.

@hai-cea hai-cea changed the title Customization style RaisedButton will separate two layer [RaisedButton] Can not override styles Jun 19, 2015
@hai-cea hai-cea changed the title [RaisedButton] Can not override styles [RaisedButton] Cannot override styles Jun 19, 2015
@alshain
Copy link
Contributor

alshain commented Jun 23, 2015

+1, I have the same issue

<RaisedButton label="Import Files" style={{margin-right: 0}} />

@sothychan
Copy link

@alshain Your style object is wrong. Material-UI requires camelCase so you need to change it to this

<RaisedButton label="Import Files" style={{marginRight: 0}} />

@sothychan
Copy link

@MycChiu Try removing the quotes from your property keys. It works fine for me.

@alshain
Copy link
Contributor

alshain commented Oct 7, 2015

@sothychan You're right! There was another issue though, in that custom styles didn't work when you used a RaisedButton inside a ToolbarGroup

e579df5

@zannager zannager added the component: button This is the name of the generic UI component, not the React module! label Dec 23, 2022
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

No branches or pull requests

7 participants