1
0
mirror of https://github.com/hakimel/reveal.js.git synced 2025-07-29 02:40:21 +02:00

fix last slide not triggering slidechange in scroll view (closes #3715)

This commit is contained in:
Hakim El Hattab
2024-11-11 16:05:34 +01:00
parent 5a275f223b
commit fe4a6e82b0
5 changed files with 8 additions and 4 deletions

View File

@@ -449,6 +449,10 @@ export default class ScrollView {
rangeStart = trigger.range[1];
} );
// Ensure the last trigger extends to the end of the page, otherwise
// rounding errors can cause the last trigger to end at 0.999999...
this.slideTriggers[this.slideTriggers.length - 1].range[1] = 1;
}
/**