manage: save scrollY in onbeforeunload (less buggy)
This commit is contained in:
		
							parent
							
								
									1df76c6929
								
							
						
					
					
						commit
						8bec1d61bd
					
				|  | @ -61,11 +61,7 @@ function initGlobalEvents() { | |||
|   }; | ||||
| 
 | ||||
|   // remember scroll position on normal history navigation
 | ||||
|   document.addEventListener('visibilitychange', () => { | ||||
|     if (document.visibilityState != 'visible') { | ||||
|       rememberScrollPosition(); | ||||
|     } | ||||
|   }); | ||||
|   window.onbeforeunload = rememberScrollPosition; | ||||
| 
 | ||||
|   for (const [className, checkbox] of [ | ||||
|     ['enabled-only', $('#manage.onlyEnabled')], | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user