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

<a> buttons have different cursor behaviour to <button> buttons. #21479

Closed
bardiharborow opened this issue Dec 31, 2016 · 5 comments
Closed

<a> buttons have different cursor behaviour to <button> buttons. #21479

bardiharborow opened this issue Dec 31, 2016 · 5 comments

Comments

@bardiharborow
Copy link
Member

bardiharborow commented Dec 31, 2016

232e86d removed .btn { cursor: pointer; }, but kept [role="button"] { cursor: pointer; }, which causes <a class="btn" role="button"> to behave differently to <button class="btn">.

/cc @mdo

@mdo
Copy link
Member

mdo commented Dec 31, 2016

Hmm, yeah that's a tough one. Will noodle on it.

@martpie
Copy link

martpie commented Jan 10, 2017

Btw, should a.btn still have a cursor: pointer? If I get Buttons shouldn’t have a hand cursor correctly, it's more about the shape than the action.

@patrickhlauke
Copy link
Member

Btw, should a.btn still have a cursor: pointer?

if it behaves like a button (triggers a behavior, rather than acting as a link to another page/part of the current page), then in theory yes. But as some authors will apply .btn for things like calls to action that are in fact links to another page, it's a tough one to untangle one way of another...

@patrickhlauke
Copy link
Member

But in general, assuming authors give the correct role="button" to links that act as buttons, then you'd probably want something like

[role="button"] { cursor: default; }

and possibly even things like role="tab"

@mdo
Copy link
Member

mdo commented Jan 25, 2017

Fixed with #21812.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants