Baseline Widely available
HTMLProgressElement
æ¥å£ç position
åªè¯»å±æ§è¿å <progress>
å
ç´ çå½åè¿åº¦ã
对äºç¡®å®çè¿åº¦æ¡è¿åå½åå¼é¤ä»¥æå¤§å¼çç»æï¼ä¹å°±æ¯è¯´ï¼å®æ¯ä»äº 0.0
å 1.0
ä¹é´çåæ°ã
对äºä¸ç¡®å®çè¿åº¦æ¡è¯¥å¼æ»æ¯ -1
ã
ç¡®å®çè¿åº¦æ¡ï¼<progress id="pBar"></progress>ä½ç½®ï¼ <span>0</span>
JavaScript
const pBar = document.getElementById("pBar");
const span = document.getElementsByTagName("span")[0];
pBar.max = 100;
pBar.value = 0;
setInterval(() => {
pBar.value = pBar.value < pBar.max ? pBar.value + 1 : 0;
span.textContent = pBar.position;
}, 100);
è§è æµè§å¨å
¼å®¹æ§
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4