diff --git a/assets/css/app.css b/assets/css/app.css
index b5a40ce..fc978e0 100644
--- a/assets/css/app.css
+++ b/assets/css/app.css
@@ -186,6 +186,10 @@ textarea:focus {
box-shadow: 0 0 8px rgba(82, 168, 236, 0.6);
}
+input[type="number"] {
+ width: 40px;
+}
+
textarea {
border: 1px solid #ccc;
padding: 3px;
diff --git a/assets/js/item.js b/assets/js/item.js
index a6dc228..b2eeef3 100644
--- a/assets/js/item.js
+++ b/assets/js/item.js
@@ -329,10 +329,10 @@ Miniflux.Item = (function() {
var current_unread = false;
var response = JSON.parse(this.responseText);
- for(var feed_id in response['feeds']) {
+ for (var feed_id in response['feeds']) {
var current_feed = response['feeds'][feed_id];
- if (!latest_feeds_items.hasOwnProperty(feed_id) || current_feed.time > latest_feeds_items[feed_id]) {
+ if (! latest_feeds_items.hasOwnProperty(feed_id) || current_feed.time > latest_feeds_items[feed_id]) {
Miniflux.App.Log('feed ' + feed_id + ': New item(s)');
latest_feeds_items[feed_id] = current_feed.time;
@@ -345,22 +345,24 @@ Miniflux.Item = (function() {
Miniflux.App.Log('first_run: ' + first_run + ', current_unread: ' + current_unread + ', response.nbUnread: ' + response['nbUnread'] + ', nbUnreadItems: ' + nbUnreadItems);
- if (!document.hidden && (response['nbUnread'] !== nbUnreadItems || unreadItems)) {
+ if (! document.hidden && (response['nbUnread'] !== nbUnreadItems || unreadItems)) {
Miniflux.App.Log('Counter changed! Updating unread counter.');
unreadItems = false;
nbUnreadItems = response['nbUnread'];
updateCounters();
}
- else if (document.hidden && !first_run && current_unread) {
+ else if (document.hidden && ! first_run && current_unread) {
Miniflux.App.Log('New Unread! Updating pagetitle.');
unreadItems = true;
document.title = "↻ " + document.title;
- } else {
+ }
+ else {
Miniflux.App.Log('No update.');
}
Miniflux.App.Log('unreadItems: ' + unreadItems);
};
+
request.open("POST", "?action=latest-feeds-items", true);
request.send();
}
diff --git a/locales/cs_CZ/translations.php b/locales/cs_CZ/translations.php
index 123c83e..de9d41e 100644
--- a/locales/cs_CZ/translations.php
+++ b/locales/cs_CZ/translations.php
@@ -231,5 +231,5 @@ return array(
// 'Download favicons' => '',
// 'general' => '',
// 'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => '',
- // 'Frontend updatecheck interval in minutes' => '',
+ // 'Refresh interval in minutes for unread counter' => '',
);
diff --git a/locales/de_DE/translations.php b/locales/de_DE/translations.php
index 9c27769..0615ba6 100644
--- a/locales/de_DE/translations.php
+++ b/locales/de_DE/translations.php
@@ -231,5 +231,5 @@ return array(
'Download favicons' => 'Favicons herunterladen',
'general' => 'allgemein',
'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => 'Fehler bei der letzten Aktualisierung. Aktualisiere den Feed manuell und prüfe die %sKonsole%s anschließend auf Fehler!',
- // 'Frontend updatecheck interval in minutes' => '',
+ // 'Refresh interval in minutes for unread counter' => '',
);
diff --git a/locales/es_ES/translations.php b/locales/es_ES/translations.php
index 56dde05..94eaaf4 100644
--- a/locales/es_ES/translations.php
+++ b/locales/es_ES/translations.php
@@ -231,5 +231,5 @@ return array(
// 'Download favicons' => '',
// 'general' => '',
// 'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => '',
- // 'Frontend updatecheck interval in minutes' => '',
+ // 'Refresh interval in minutes for unread counter' => '',
);
diff --git a/locales/fr_FR/translations.php b/locales/fr_FR/translations.php
index 7d5e1b6..06965ce 100644
--- a/locales/fr_FR/translations.php
+++ b/locales/fr_FR/translations.php
@@ -231,5 +231,5 @@ return array(
'Download favicons' => 'Télécharger les icônes des sites web',
'general' => 'général',
'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => 'Une erreur est survenue pendant la dernière vérification. Actualisez, le flux manuellement and vérifiez les erreurs dans la %sconsole%s !',
- 'Frontend updatecheck interval in minutes' => 'Frontend updatecheck interval in minutes',
+ 'Refresh interval in minutes for unread counter' => 'Fréquence d\'actualisation en minute du compteur de non lus',
);
diff --git a/locales/it_IT/translations.php b/locales/it_IT/translations.php
index ed03c7f..91f2e38 100644
--- a/locales/it_IT/translations.php
+++ b/locales/it_IT/translations.php
@@ -231,5 +231,5 @@ return array(
// 'Download favicons' => '',
// 'general' => '',
// 'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => '',
- // 'Frontend updatecheck interval in minutes' => '',
+ // 'Refresh interval in minutes for unread counter' => '',
);
diff --git a/locales/pt_BR/translations.php b/locales/pt_BR/translations.php
index 2cb0c64..7b5e582 100644
--- a/locales/pt_BR/translations.php
+++ b/locales/pt_BR/translations.php
@@ -231,5 +231,5 @@ return array(
'Download favicons' => 'Download favicon',
// 'general' => '',
// 'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => '',
- // 'Frontend updatecheck interval in minutes' => '',
+ // 'Refresh interval in minutes for unread counter' => '',
);
diff --git a/locales/zh_CN/translations.php b/locales/zh_CN/translations.php
index 37c9b4b..e00da19 100644
--- a/locales/zh_CN/translations.php
+++ b/locales/zh_CN/translations.php
@@ -231,5 +231,5 @@ return array(
// 'Download favicons' => '',
// 'general' => '',
// 'An error occurred during the last check. Refresh the feed manually and check the %sconsole%s for errors afterwards!' => '',
- // 'Frontend updatecheck interval in minutes' => '',
+ // 'Refresh interval in minutes for unread counter' => '',
);
diff --git a/templates/config.php b/templates/config.php
index 25fa1a4..f1b4c49 100644
--- a/templates/config.php
+++ b/templates/config.php
@@ -35,9 +35,6 @@
= Helper\form_label(t('Theme'), 'theme') ?>
= Helper\form_select('theme', $theme_options, $values, $errors) ?>
- = Helper\form_label(t('Frontend updatecheck interval in minutes'), 'frontend_updatecheck_interval') ?>
- = Helper\form_number('frontend_updatecheck_interval', $values, $errors, array('min="0"')) ?>
-
= Helper\form_label(t('Auto-Update URL'), 'auto_update_url') ?>
= Helper\form_text('auto_update_url', $values, $errors, array('required')) ?>
@@ -65,6 +62,9 @@
= Helper\form_label(t('When there is nothing to read, redirect me to this page'), 'redirect_nothing_to_read') ?>
= Helper\form_select('redirect_nothing_to_read', $redirect_nothing_to_read_options, $values, $errors) ?>
+ = Helper\form_label(t('Refresh interval in minutes for unread counter'), 'frontend_updatecheck_interval') ?>
+ = Helper\form_number('frontend_updatecheck_interval', $values, $errors, array('min="0"')) ?>
+
= Helper\form_checkbox('nocontent', t('Do not fetch the content of articles'), 1, isset($values['nocontent']) && $values['nocontent'] == 1) ?>
= Helper\form_checkbox('favicons', t('Download favicons'), 1, isset($values['favicons']) && $values['favicons'] == 1) ?>