Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Turn off grey box when mousedown in Mobile Safari

On Mobile Safari, when you click on an element it gets a grey box around it between mousedown and mouseup.

How do you turn this off?

like image 908
Rich Bradshaw Avatar asked Jun 03 '10 15:06

Rich Bradshaw


1 Answers

I was looking for the answer as well, and found it in the jQTouch CSS source code. Just add this to your definitions: -webkit-tap-highlight-color: rgba(0,0,0,0); Note that the box shows up for anything with a "click" or "touchend" listener (I think), so for best results, toss it under body { }

like image 170
hr4dish Avatar answered Sep 27 '22 22:09

hr4dish