Browse Source

fix exception when stepping backwards through code highlights #3524

Hakim El Hattab 1 year ago
parent
commit
bbd0d3e4f7
3 changed files with 1 additions and 1 deletions
  1. 0 0
      plugin/highlight/highlight.esm.js
  2. 0 0
      plugin/highlight/highlight.js
  3. 1 1
      plugin/highlight/plugin.js

File diff suppressed because it is too large
+ 0 - 0
plugin/highlight/highlight.esm.js


File diff suppressed because it is too large
+ 0 - 0
plugin/highlight/highlight.js


+ 1 - 1
plugin/highlight/plugin.js

@@ -138,7 +138,7 @@ const Plugin = {
 
 					// Scroll highlights into view as we step through them
 					fragmentBlock.addEventListener( 'visible', Plugin.scrollHighlightedLineIntoView.bind( Plugin, fragmentBlock, scrollState ) );
-					fragmentBlock.addEventListener( 'hidden', Plugin.scrollHighlightedLineIntoView.bind( Plugin, fragmentBlock.previousSibling, scrollState ) );
+					fragmentBlock.addEventListener( 'hidden', Plugin.scrollHighlightedLineIntoView.bind( Plugin, fragmentBlock.previousElementSibling, scrollState ) );
 
 				} );
 

Some files were not shown because too many files changed in this diff