I purposely set the margin-top on :active to make the thumb vertically off-center. This way there is more of a chance it won't be hidden behind the user's finger when they're using it.
Here's a screenshot from the iOS simulator showing the off-center and larger :active style of the thumb.
Because we only want the larger range thumb on non-hover devices, this uses the hover media query to provide a smaller thumb to those devices:
Because the Adjusters are in a horizontally scrollable container, using the range sliders on touch devices can be tough or:
This PR attempts to make them more usable by increasing the range thumb size for devices without
hover
support.This is limited to browsers that recognize the
::-webkit-slider-thumb
selector. That's a non-standard selector for the range slider thumb.With these changes, by default, the pertinent CSS for the thumb is:
I purposely set the
margin-top
on:active
to make the thumb vertically off-center. This way there is more of a chance it won't be hidden behind the user's finger when they're using it.Here's a screenshot from the iOS simulator showing the off-center and larger
:active
style of the thumb.Because we only want the larger range thumb on non-hover devices, this uses the
hover
media query to provide a smaller thumb to those devices:hover
is a new(er) media query: https://www.w3.org/TR/mediaqueries-4/#hover