(next, resuming)
| 530 | } |
| 531 | |
| 532 | #renderFrame (next, resuming) { |
| 533 | if (next) { |
| 534 | this.#lastUpdate = Date.now() |
| 535 | this.#frameIndex++ |
| 536 | if (this.#frameIndex >= this.#spinner.frames.length) { |
| 537 | this.#frameIndex = 0 |
| 538 | } |
| 539 | } |
| 540 | if (!resuming) { |
| 541 | this.#clearSpinner() |
| 542 | } |
| 543 | this.#stream.write(this.#spinner.frames[this.#frameIndex]) |
| 544 | this.#rendered = true |
| 545 | } |
| 546 | |
| 547 | #clearSpinner () { |
| 548 | if (!this.#rendered) { |
no test coverage detected