(batch_done = 0, batch_size = 1, cidd = "")
| 117 | } |
| 118 | |
| 119 | function updBatchProgress(batch_done = 0, batch_size = 1, cidd = "") { |
| 120 | const done_str = `${batch_done}/${batch_size}`; |
| 121 | if (cidd) { |
| 122 | console.log(`cid: ${cidd['cid']} | scan complete (${done_str})`); |
| 123 | } |
| 124 | |
| 125 | const batch_progress_bar = batchProgressBar(batch_size); |
| 126 | if (!batch_progress_bar) return; |
| 127 | |
| 128 | batch_progress_bar.setAttribute("progress-label", "Batch progress"); |
| 129 | batch_progress_bar.setAttribute("progress-ratio", done_str); |
| 130 | batch_progress_bar.style.backgroundPosition = (100 * (1. - batch_done/batch_size)).toFixed(2)+"%"; |
| 131 | } |
| 132 | |
| 133 | function updMediaProgress(media_done = 0, media_total = 1) { |
| 134 | const media_progress_bar = mediaProgressBar(); |
no test coverage detected