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] Add outlined variant #11346

Merged
merged 6 commits into from
May 12, 2018
Merged

Conversation

leMaik
Copy link
Member

@leMaik leMaik commented May 12, 2018

This adds a new outlined variant to the Button, as seen here.

The border and radius matches the specs (yup, 23% opacity…). Unfortunately, there is nothing said about the dark style, so I don't really know which value to put there. It looks pretty good imho. 😉

Light:
image

Dark:
image

Related to #11342 and #11284

@leMaik
Copy link
Member Author

leMaik commented May 12, 2018

@oliviertassinari Riddle me this. 😄 Why did this unrelated test break?

@oliviertassinari oliviertassinari added design: material This is about Material Design, please involve a visual or UX designer in the process component: button This is the name of the generic UI component, not the React module! labels May 12, 2018
@mbrookes
Copy link
Member

Just as an aside, the states (hover, focus etc.) are (obviously) v1 style, so this variant is a bit of a hybrid of v1 and v2.

@leMaik
Copy link
Member Author

leMaik commented May 12, 2018

@mbrookes Indeed, let's say this is a "backported MD v1 outlined button"

The hover and focus look pretty similar in MDI v2 to me. 🤔 Once we have a solution for the new focus/hover states, it will look exactly as in the specs. The font size is also different in the new specs.

@mbrookes
Copy link
Member

The hover and focus look pretty similar in MDI v2 to me.

image

Hover is close, but focus isn't. I can find the the spec for the ripple in the new guidelines though.

image

Once we have a solution for the new focus/hover states, it will look exactly as in the specs.

Changing it is arguably a breaking change though.

@leMaik
Copy link
Member Author

leMaik commented May 12, 2018

Oh, you're right. Our hover looks like the new focus.The ripple effect for the pressed state looks like the old ripple effect.

Changing it is arguably a breaking change though.

Yes, but not if we add this as an opt-in MD2 theme and keep the "hybrid" solution anyway.

@leMaik leMaik merged commit 0629128 into mui:v1-beta May 12, 2018
@leMaik leMaik deleted the outlined-button branch May 12, 2018 15:25
<Button variant="outlined" disabled className={classes.button}>
Disabled
</Button>
<Button variant="outlined" href="#flat-buttons" className={classes.button}>
Copy link
Member

Choose a reason for hiding this comment

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

href="#outlined-buttons"

>
Does something
</Button>
</div>
Copy link
Member

Choose a reason for hiding this comment

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

I'm removing the rather pointless "Link disabled" and "Does something" examples from the FlatButton demo in another PR (they've been on my hit-list for ages!), so no need to add them here.

@mbrookes
Copy link
Member

NVM, I'll fix it in my PR.

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! design: material This is about Material Design, please involve a visual or UX designer in the process
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants