在Mobile Safari / Webkit上禁用触摸屏上的文本突出显示放大镜 [英] Disable the text-highlighting magnifier on touch-hold on Mobile Safari / Webkit

查看:106
本文介绍了在Mobile Safari / Webkit上禁用触摸屏上的文本突出显示放大镜的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的iPhone网站中有一些元素,其中没有任何文字,但需要用户点击并按住它们(DIV)。这会导致文本突出显示/编辑循环/光标显示,这实在令人分心。

I have some elements in my iPhone website that don't have any text in them but require the user to click and hold on them (DIVs). This causes the text-highlighting/editing loop/cursor to show up, which is really distracting.

我知道有一个CSS规则用于删除触摸时可点击元素上显示的黑盒子。是否有类似的东西禁用文字放大镜?

I know there is a CSS rule for removing the black-box that shows up on clickable elements when they are touched. Is there anything like that to disable the text magnifier?

推荐答案

刚收到开发人员中心服务台的回复。我需要添加这个CSS规则:

Just got a response from the Developer Center help desk. I needed to add this CSS rule:

-webkit-user-select: none;

这篇关于在Mobile Safari / Webkit上禁用触摸屏上的文本突出显示放大镜的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆