关于前端:移动端奇葩问题

1、ios 中有长按能够关上链接性能,如果阻止a标签默认事件,不要把链接写到href里,长按还是能关上。
如果有须要做feature AB的状况,也不要把链接写在a标签的href中,否则点击能够阻止,然而长按还能够跳转。

2、字体色彩突变款式须要留神:

1)写在具体的须要突变文字的标签里,不能写在父级元素上,IOS 15.3及以下零碎手机不反对,字体不会显示。
  如上面代码,须要把款式写在never-text 和never-fee元素上,而不是写在父级元素never-tip上。
2)须要写color款式做兼容,以便不反对该款式的设施也能够失常显示文字
<div class="never-tip">
    <span class="never-text">You could save $260 throughout the year.</span>
    <span class="never-fee">Only € 19.99/year</span>
</div>
<style>
  color: #E0BB83;
  background: linear-gradient(135deg, #F4E1B3 0%, #DBB278 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
</style>
````
![款式没做兼容,有问题的状况](https://upload-images.jianshu.io/upload_images/24159983-1f1ecb47aa258b6a.jpg?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
![失常展现状况](https://upload-images.jianshu.io/upload_images/24159983-a818302fa6ea7786.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)

评论

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

这个站点使用 Akismet 来减少垃圾评论。了解你的评论数据如何被处理