()
| 60 | // ─── Rendering ──────────────────────────────────────────── |
| 61 | |
| 62 | function _render() { |
| 63 | if (!_container) return; |
| 64 | _container.innerHTML = ""; |
| 65 | |
| 66 | const sorted = [..._sections].sort((a, b) => a.start - b.start); |
| 67 | |
| 68 | for (const section of sorted) { |
| 69 | _container.appendChild(_makeSectionEl(section)); |
| 70 | } |
| 71 | } |
| 72 | |
| 73 | function _makeSectionEl(section) { |
| 74 | const pctStart = (section.start / _duration) * 100; |
no test coverage detected