第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

滾動(dòng)超出文檔中的特定點(diǎn)后激活動(dòng)畫

滾動(dòng)超出文檔中的特定點(diǎn)后激活動(dòng)畫

胡子哥哥 2023-11-02 22:20:40
我用js做了一個(gè)向上計(jì)數(shù)的計(jì)數(shù)器動(dòng)畫,但是當(dāng)我刷新頁面時(shí)計(jì)數(shù)器就開始向上計(jì)數(shù)動(dòng)畫(不管我在哪里,也不管我是否能看到它)。我希望計(jì)數(shù)器僅在計(jì)數(shù)器 div 位于視點(diǎn)中時(shí)(當(dāng)我向下滾動(dòng)并看到它時(shí))開始工作。超文本標(biāo)記語言<div class="content bg-warning">    <div class="row m-0 py-5 d-flex justify-content-center">        <div class="counter" data-count="2200" style="color: white; font-size: 32px; font-weight: bold;">0</div>    </div></div>js<script type="text/javascript">    $('.counter').each(function() {      var $this = $(this),          countTo = $this.attr('data-count');            $({ countNum: $this.text()}).animate({        countNum: countTo      },      {        duration: 8000,        easing:'linear',        step: function() {          $this.text(Math.floor(this.countNum));        },        complete: function() {          $this.text(this.countNum);          //alert('finished');        }      });      });</script>我該如何解決這個(gè)問題?
查看完整描述

目前暫無任何回答

  • 0 回答
  • 0 關(guān)注
  • 178 瀏覽
慕課專欄
更多

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)