Fix next slide detection in generic plugin

This commit is contained in:
Antonin Stefanutti 2023-08-03 15:51:09 +02:00 committed by Antonin Stefanutti
parent 5d83d4345e
commit 8c3057140a

View File

@ -78,6 +78,7 @@ class Generic {
return false;
}
for (let key of this.keys) {
this.isNextSlideDetected = false;
await this.page.keyboard.press(key);
// TODO: use mutation event directly instead of relying on a timeout
// TODO: detect cycle to avoid infinite navigation for frameworks
@ -92,7 +93,6 @@ class Generic {
nextSlide() {
this.currentSlide++;
this.isNextSlideDetected = false;
}
async currentSlideIndex() {