欧美亚洲中文,在线国自产视频,欧洲一区在线观看视频,亚洲综合中文字幕在线观看

      1. <dfn id="rfwes"></dfn>
          <object id="rfwes"></object>
        1. 站長資訊網(wǎng)
          最全最豐富的資訊網(wǎng)站

          Css3實現(xiàn)無縫滾動防抖

          這篇文章主要介紹了Css3實現(xiàn)無縫滾動防抖的方法,幫助大家解決圖片抖動,感興趣的朋友可以了解下

          問題

          圖片加文字的無縫滾動,在手機(jī)端的效果總體還行,但是圖片在手機(jī)某些瀏覽器會抖得膩害!

          錯誤寫法

          不能用left,margin-left,像這種寫法:

          .donghua.active{
          animation: scoll ease-in-out 1s infinite alternate;
          -webkit-animation: scoll ease-in-out 1s infinite alternate;
          }
          @keyframes scoll {
          from {
          left: 0;
          }
          to {
          left: -353px;
          }
          }
          -webkit-@keyframes scoll {
          from {
          left: 0;
          }
          to {
          left: -353px;
          }
          }

          解決方法

          里面的某個元素在手機(jī)端會抖動的膩害,改用二維的translate像這樣:

          .donghua.active{
          animation: scoll ease-in-out 1s infinite alternate;
          -webkit-animation: scoll ease-in-out 1s infinite alternate;
          }
          @keyframes scoll {
          0% {
          transform: translate(0px, 0px);
          }

          100% {
          transform: translate(0px, -353px);
          }
          }
          @-webkit-keyframes scoll {
          0% {
          transform: translate(0px, 0px);
          }

          100% {
          transform: translate(0px, -353px);
          }
          }

          以上就是Css3實現(xiàn)無縫滾動防抖的詳細(xì)內(nèi)容,更多關(guān)于CSS3 無縫滾動 防抖的資料請關(guān)注腳本之家其它相關(guān)文章!

          文章來源:腳本之家,原文鏈接:https://www.jb51.net/css/745016.html

          Css3實現(xiàn)無縫滾動防抖

          申請創(chuàng)業(yè)報道,分享創(chuàng)業(yè)好點(diǎn)子。點(diǎn)擊此處,共同探討創(chuàng)業(yè)新機(jī)遇!

          贊(0)
          分享到: 更多 (0)
          網(wǎng)站地圖   滬ICP備18035694號-2    滬公網(wǎng)安備31011702889846號