Skip to content

Commit

Permalink
fix issue when disabling autoPlay config flag at runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
hakimel committed Mar 11, 2024
1 parent 1748a55 commit 76ec60a
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion dist/reveal.esm.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/reveal.esm.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/reveal.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/reveal.js.map

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions js/controllers/backgrounds.js
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,11 @@ export default class Backgrounds {

this.Reveal.slideContent.stopEmbeddedContent( this.previousBackground, { unloadIframes: !this.Reveal.slideContent.shouldPreload( this.previousBackground ) } );

// Clear the previous background if it was removed from DOM
if( !this.previousBackground.closest( 'body' ) ) {
this.previousBackground = null;
}

}

// Start content in the current background
Expand Down

0 comments on commit 76ec60a

Please sign in to comment.