【问题标题】:fixed position element judder in chrome on android when scrolled滚动时,android上chrome中的固定位置元素抖动
【发布时间】:2013-06-30 06:05:31
【问题描述】:

我有一个 div,其中包含一个已旋转的锚点,并且 position: 固定在屏幕的左上角。当进行任何滚动时,它会在我的 atrix hd 中疯狂地跳跃。 -webkit-overflow-scrolling: divs css 中的 touch 什么都不做。如果这可能很重要,这是我的元视口 &lt;meta name="viewport" content="width=100%, initial-scale=1, maximum-scale=1, minimum-scale=1, user-scalable=no"/&gt; 有问题的 div 的 html <div id="shop" class="center"> <a href="#" class="railway"> SHOP </a> </div> 的CSS #shop { position: fixed; left: -72px; top: 14px; background-color: #F03C2E; -ie-transform: rotate(314deg); -moz-transform: rotate(314deg); -o-transform: rotate(314deg); -webkit-transform: rotate(314deg); transform: rotate(314deg); width: 192px; z-index: 10; test-align: center; }

【问题讨论】:

    标签: android mobile position fixed


    【解决方案1】:

    我不知道你的#shop 元素放在哪里,但也许你和我一样。

    如果一个容器有 position: fixed; 并且它的父容器也有它,那么滚动时的这种跳跃行为也会出现在我的 chrome 中的 google nexus 上。

    解决方案: 固定容器中的固定容器没有意义,从其中一个中删除固定位置属性。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-08-30
      • 2012-10-09
      • 2017-11-24
      • 2014-12-15
      • 2022-11-16
      • 2016-07-03
      • 2012-05-05
      • 1970-01-01
      相关资源
      最近更新 更多