MCPcopy Index your code
hub / github.com/nodejs/node / updateProgressBar

Method updateProgressBar

deps/v8/tools/js/web-api-helper.mjs:106–117  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

104 }
105
106 updateProgressBar() {
107 // Create a circular progress bar, starting at 12 o'clock.
108 this.progressNode.style.backgroundImage = `conic-gradient(
109 var(--primary-color) 0%,
110 var(--primary-color) ${this.progress * 100}%,
111 var(--surface-color) ${this.progress * 100}%)`;
112 this.progressTextNode.innerText =
113 this.processedBytes ? formatBytes(this.processedBytes, 1) : '';
114 if (this.root.className == 'loading') {
115 window.requestAnimationFrame(() => this.updateProgressBar());
116 }
117 }
118
119 readFile(file) {
120 this.dispatchEvent(new CustomEvent('fileuploadstart', {

Callers 1

asyncReadFileMethod · 0.95

Calls 1

formatBytesFunction · 0.90

Tested by

no test coverage detected