Skip to content
This repository has been archived by the owner on Aug 19, 2022. It is now read-only.

Don't apply :hover if disabled #686

Closed
philiptzou opened this issue Apr 24, 2016 · 6 comments
Closed

Don't apply :hover if disabled #686

philiptzou opened this issue Apr 24, 2016 · 6 comments

Comments

@philiptzou
Copy link

I found Radium doesn't support :disabled so far but this might be a good idea since :active, :focus and :hover are already supported.

@philiptzou
Copy link
Author

philiptzou commented Apr 26, 2016

@ianobermiller I see. But actually :disabled is quite different from other pseudo selectors.

For example, the "disabled" attribute of "reset" button is controlled by a state that if other inputs/textareas are all empty. In this case a click on the reset button will clean all other inputs/textareas box and cause itself disabled.

In traditional CSS, the style :hover, :active and :focus can be overridden by :disabled. But since we are using JS events to simulate the behavior, at least the :hover behavior is still working and there's no way to override it.

@philiptzou
Copy link
Author

philiptzou commented Apr 26, 2016

In another hand... I think my problem is actually that, should :hover be disabled when the element has the attribute "disabled"?

@ianobermiller
Copy link
Contributor

That seems fair!

@ianobermiller ianobermiller reopened this Apr 26, 2016
@ianobermiller ianobermiller changed the title Need :disabled support (?) Don't apply :hover if disabled Apr 26, 2016
@jooyunghan
Copy link
Contributor

Check this PR, #689

I had the same problem and made some workaround. I hope this change will help you.

@alexlande
Copy link
Contributor

Resolved by #689

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

No branches or pull requests

4 participants