<view class="marquee" >
        <view class="content">
          <text>三分钟创建自己的刊物</text>
          <text style="display: inline-block; width: 5em;"></text>
          <text>三分钟创建自己的刊物</text>
          <text style="display: inline-block; width: 5em;"></text>
          <text>三分钟创建自己的刊物</text>
          <text style="display: inline-block; width: 5em;"></text>
        </view>
      </view>

@keyframes scrollX{ 0% { transform: translateX(0); } 100% { transform: translateX(-33.3%); } }
.marquee{
    width: 100%;
    height: 44px;
    line-height: 44px;
    background: #fff;
    border: none;
    display: block;
    margin: 0 auto;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: clip;
    position: relative;
    font-size: 14px;
}
.marquee .content{
    display: inline-block;
    position: relative;
    padding-right: 0px;
    animation: scrollX 5s linear infinite;
    white-space: nowrap;
}

数字滚动效果

相关文章:

  • 2021-06-11
  • 2022-01-02
  • 2022-12-23
  • 2021-11-27
  • 2022-03-06
  • 2021-06-03
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-12-27
  • 2022-12-23
  • 2021-10-18
  • 2021-10-05
  • 2021-07-27
  • 2021-09-11
相关资源
相似解决方案