<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ThinkChat2.0新版上線,更智能更精彩,支持會話、畫圖、視頻、閱讀、搜索等,送10W Token,即刻開啟你的AI之旅 廣告
                js實現進度條效果:這里實際上是用了兩個div嵌套,一個設置寬度,另一個初始寬度為0,設置背景顏色,通過定時器改變寬度 ``` <style> .fa{ width: 400px; margin-bottom: 30px; border: 1px solid red;; } .son{ width: 0px; height: 40px; background-color: #f0f; text-align: center; line-height: 40px; } </style> <div class="fa"> <div class="son"> <span>0</span><span>%</span> </div> </div> <button id="but">安裝</button> <script> // 邏輯:1.利用定時器來進行遞增操作(width、百分數) // 2.當變量 達到400px時,是停止定時器 let but = document.getElementById('but'); let div = document.getElementsByTagName('div'); let span = document.getElementsByTagName('span'); let timer = null; but.onclick = function(){ let num = 0; if(timer==null){ timer = setInterval(()=>{ num +=1; // 給寬進行遞增 div[1].style.width = num+'px'; // 給百分比遞增 span[0].innerText = Math.ceil(num/400*100); if(num==400){ clearInterval(timer); } },10); } } </script> ``` 效果圖: ![](https://img.kancloud.cn/7e/69/7e69f8ac7eb91f2a3adeaf413964f0b5_463x159.png)
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看