html - 前端开发:元素的点击时会产生黑色阴影层,ios设备会,安卓不会有
巴扎黑
巴扎黑 2017-04-18 09:49:33
0
3
536

前端开发:元素的点击时会产生黑色阴影层,ios设备会,安卓不会有
现在遇到的元素主要是input,前几天遇到一个p也有,这个是为什么?没有mac调试不了
(各种模拟器都没有这个问题)

巴扎黑
巴扎黑

reply all(3)
PHPzhong

-webkit-tap-highlight-color is an unsupported WebKit property that does not appear in the draft CSS specification.
Override the highlight color displayed when the user clicks on a link or clickable element in JavaScript on iOS.
This attribute can only set transparency. If transparency is not set, iOS Safari uses the default transparency. When the transparency is set to 0, this attribute is disabled; when the transparency is set to 1, the element is not visible when clicked.
Syntax:
-webkit-tap-highlight-color: color
Default value: inherit
Applicable to: link elements such as new window opening, img elements such as saving images, etc.

Peter_Zhu

outline: none;

洪涛
input[type=button]{
    -webkit-appearance:none;
    outline:none
}

Maybe overkill, but it works great on iOS.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template