Getting rid of link-click “flash” indicator in iOs UIWebView

筅森魡賤 提交于 2019-12-03 06:59:34

问题


My iPad app uses a lot of UIWeb views to display content. The user clicks small images with links to pull up a smaller view with additional content. When you tap a link in a UIWebview, the link highlights gray for a moment to indicate the click. In the case of links in an in an image, the whole image rectangle flashes gray for a moment, and it's pretty ugly. Is there any way to disable this behavior?


回答1:


Sure, use the -webkit-tap-highlight-color CSS property:

  <style type="text/css">
  a {
      -webkit-tap-highlight-color:rgba(0,0,0,0);
  }       
  </style>


来源:https://stackoverflow.com/questions/3772477/getting-rid-of-link-click-flash-indicator-in-ios-uiwebview

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!