admin管理员组文章数量:1401673
I have to use title
attribute to show the entire text in case the label size decreases and forces an ellipsis
. Now the problem is my page might be accessed by touch interface users and they might not have the option to hover (apart from galaxy note users).
I was hoping someone is aware of a control within HTML5/HTML for touch devices which will toast the title text on the screen next to a div on tapping the div for plete text.
I have to use title
attribute to show the entire text in case the label size decreases and forces an ellipsis
. Now the problem is my page might be accessed by touch interface users and they might not have the option to hover (apart from galaxy note users).
I was hoping someone is aware of a control within HTML5/HTML for touch devices which will toast the title text on the screen next to a div on tapping the div for plete text.
Share Improve this question edited Mar 15, 2013 at 7:15 loxxy 13.1k2 gold badges27 silver badges57 bronze badges asked Mar 15, 2013 at 5:41 ShouvikShouvik 11.8k17 gold badges60 silver badges89 bronze badges1 Answer
Reset to default 4See usage of title & abuse of title tags. HTML5 has not spoken on this so far.
You might need to implement the double tab event yourself using js or use jquery doubletap
Alternatively, hover event is implemented by many mobiles devices to be fired on the first tap... fiddle
CSS
span {
width: 100px;
display: block;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
span:hover {
overflow: visible;
}
HTML Code
<span>Test test test test test test</span>
本文标签: javascriptReplacement for Title attribute that work in touch screen environmentStack Overflow
版权声明:本文标题:javascript - Replacement for Title attribute that work in touch screen environment - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744267290a2598008.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论