<span id="pfnzv"></span>
      <form id="pfnzv"><span id="pfnzv"></span></form><address id="pfnzv"><span id="pfnzv"><nobr id="pfnzv"></nobr></span></address>
      <form id="pfnzv"><dfn id="pfnzv"><listing id="pfnzv"></listing></dfn></form>

        <sub id="pfnzv"><address id="pfnzv"></address></sub>
          <address id="pfnzv"><form id="pfnzv"><listing id="pfnzv"></listing></form></address>
          <address id="pfnzv"><address id="pfnzv"><nobr id="pfnzv"></nobr></address></address>

            <address id="pfnzv"></address>
            0712-2888027 189-8648-0214
            微信公眾號

            孝感風信網絡科技有限公司微信公眾號

            當前位置:主頁 > 技術支持 > Javascript/JQuery > Jquery countUp.js數字變換和滾動事件監聽的實現代碼片段

            Jquery countUp.js數字變換和滾動事件監聽的實現代碼片段

            時間:2024-08-20來源:風信官網 點擊: 1237次
            Jquery countUp.js數字變換和滾動事件監聽的實現代碼片段,以下代碼為項目開發中的片段,實現方法思路僅供參考。

            $(function () {
                exposure._init();

                var videoNum = 0 || count.video;
                var teacherNum = 0 || count.teacher;
                var userNum = 0 || count.user;
                var csrfToken = $('meta[name="csrf-token"]').attr("content");
                //數字變換和滾動事件
                var options = {
                    useEasing: true,
                    useGrouping: true,
                    separator: '',
                    decimal: '.',
                    prefix: '',
                    suffix: ''
                };
                var countUp1 = new CountUp("videoNumSpan", 0, videoNum, 0, 2.5, options);
                var countUp2 = new CountUp("teacherNumSpan", 0, teacherNum, 0, 2.5, options);
                var countUp3 = new CountUp("userNumspan", 0, userNum, 0, 2.5, options);

                $(window).scroll(function () {
                    //數字開始滾動
                    if ($(window).scrollTop() >= jQuery("#videoNumSpan").offset().top - jQuery(window).height()) {
                        countUp1.start();
                        countUp2.start();
                        countUp3.start();
                    }
                });    
             
            });
            欄目列表
            推薦內容
            熱點內容
            展開
            国产精久久久久无码AV动漫|最新亚洲精品国偷自产在线|2021亚洲色中文字幕在线|最新无码av中文字专区 情欲美妇紧致敏感 国产免费AⅤ片在线播放 人妻爽爽免费在线视频 51精品国产人成在线观看 色偷偷av一区二区三区
            <span id="pfnzv"></span>
                <form id="pfnzv"><span id="pfnzv"></span></form><address id="pfnzv"><span id="pfnzv"><nobr id="pfnzv"></nobr></span></address>
                <form id="pfnzv"><dfn id="pfnzv"><listing id="pfnzv"></listing></dfn></form>

                  <sub id="pfnzv"><address id="pfnzv"></address></sub>
                    <address id="pfnzv"><form id="pfnzv"><listing id="pfnzv"></listing></form></address>
                    <address id="pfnzv"><address id="pfnzv"><nobr id="pfnzv"></nobr></address></address>

                      <address id="pfnzv"></address>