mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-11 08:25:46 +01:00
fixes navigator progress bar
This commit is contained in:
@@ -59,9 +59,6 @@ define(function() {
|
|||||||
|
|
||||||
if (elementInView(el)) {
|
if (elementInView(el)) {
|
||||||
index = parseInt(el.attr('data-index'), 10) + 1;
|
index = parseInt(el.attr('data-index'), 10) + 1;
|
||||||
if(index > count) {
|
|
||||||
index = count;
|
|
||||||
}
|
|
||||||
|
|
||||||
navigator.updateTextAndProgressBar();
|
navigator.updateTextAndProgressBar();
|
||||||
|
|
||||||
@@ -75,6 +72,7 @@ define(function() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
navigator.updateTextAndProgressBar = function() {
|
navigator.updateTextAndProgressBar = function() {
|
||||||
|
index = index > count ? count : index;
|
||||||
translator.translate('[[global:pagination.out_of, ' + index + ', ' + count + ']]', function(translated) {
|
translator.translate('[[global:pagination.out_of, ' + index + ', ' + count + ']]', function(translated) {
|
||||||
$('#pagination').html(translated);
|
$('#pagination').html(translated);
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user