Просмотр исходного кода

Ne pas boucler à la fin de la navigation dans les articles

Corrige https://github.com/marienfressinaud/FreshRSS/issues/407
Alternative à https://github.com/marienfressinaud/FreshRSS/pull/409 qui conserve le fait que l'article se ferme, et plus simple.
Alexandre Alapetite 12 лет назад
Родитель
Сommit
2c6d010dba
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      p/scripts/main.js

+ 3 - 1
p/scripts/main.js

@@ -172,12 +172,14 @@ function mark_favorite(active) {
 }
 }
 
 
 function toggleContent(new_active, old_active) {
 function toggleContent(new_active, old_active) {
-	old_active.removeClass("active").removeClass("current");
+	old_active.removeClass("active");
 
 
 	if (new_active.length === 0) {
 	if (new_active.length === 0) {
 		return;
 		return;
 	}
 	}
 
 
+	old_active.removeClass("current");
+
 	if (does_lazyload) {
 	if (does_lazyload) {
 		new_active.find('img[data-original], iframe[data-original]').each(function () {
 		new_active.find('img[data-original], iframe[data-original]').each(function () {
 			this.setAttribute('src', this.getAttribute('data-original'));
 			this.setAttribute('src', this.getAttribute('data-original'));