aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2016-10-29 13:11:37 +0200
committerGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2016-10-29 13:11:37 +0200
commit00f446d1557165cba90d0d3ec17404d3fdce84cd (patch)
tree4ec6a8553f12226da35418467a9a4fa0a627e5ec
parenta7301a43faeb391138478cb462493c3e025296ea (diff)
Disable "mark all as read" before confirmation script is loaded
https://github.com/FreshRSS/FreshRSS/issues/1342
-rw-r--r--CHANGELOG.md1
-rw-r--r--app/layout/aside_feed.phtml2
-rw-r--r--app/layout/nav_menu.phtml2
-rwxr-xr-xapp/views/helpers/pagination.phtml2
-rw-r--r--p/scripts/main.js1
5 files changed, 5 insertions, 3 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index acec03f39..6873530f4 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -42,6 +42,7 @@
* Fix some messages during installation [#1339](https://github.com/FreshRSS/FreshRSS/pull/1339)
* UI
* Fix CSS line-height bug with `<sup>` in dates (English, Russian, Turkish) [#1340](https://github.com/FreshRSS/FreshRSS/pull/1340)
+ * Disable *Mark all as read* before confirmation script is loaded [#1342](https://github.com/FreshRSS/FreshRSS/issues/1342)
* Download icon 💾 for podcasts [#1236](https://github.com/FreshRSS/FreshRSS/issues/1236)
* SimplePie
* Fix auto-discovery of RSS feeds in Web pages served as `text/xml` [#1264](https://github.com/FreshRSS/FreshRSS/issues/1264)
diff --git a/app/layout/aside_feed.phtml b/app/layout/aside_feed.phtml
index 94c281b7f..3e1ee44dd 100644
--- a/app/layout/aside_feed.phtml
+++ b/app/layout/aside_feed.phtml
@@ -85,7 +85,7 @@
<li class="item"><a href="<?php echo _url('subscription', 'index', 'id', '------'); ?>"><?php echo _t('gen.action.manage'); ?></a></li>
<li class="item"><a href="<?php echo _url('feed', 'actualize', 'id', '------'); ?>"><?php echo _t('gen.action.actualize'); ?></a></li>
<li class="item">
- <?php $confirm = FreshRSS_Context::$user_conf->reading_confirm ? 'confirm' : ''; ?>
+ <?php $confirm = FreshRSS_Context::$user_conf->reading_confirm ? 'confirm" disabled="disabled' : ''; ?>
<button class="read_all as-link <?php echo $confirm; ?>"
form="mark-read-aside"
formaction="<?php echo _url('entry', 'read', 'get', 'f_------'); ?>"
diff --git a/app/layout/nav_menu.phtml b/app/layout/nav_menu.phtml
index c02232242..f6d824d55 100644
--- a/app/layout/nav_menu.phtml
+++ b/app/layout/nav_menu.phtml
@@ -83,7 +83,7 @@
<div class="stick" id="nav_menu_read_all">
<form id="mark-read-menu" method="post">
- <?php $confirm = FreshRSS_Context::$user_conf->reading_confirm ? 'confirm' : ''; ?>
+ <?php $confirm = FreshRSS_Context::$user_conf->reading_confirm ? 'confirm" disabled="disabled' : ''; ?>
<button class="read_all btn <?php echo $confirm; ?>"
form="mark-read-menu"
formaction="<?php echo Minz_Url::display($mark_read_url); ?>"
diff --git a/app/views/helpers/pagination.phtml b/app/views/helpers/pagination.phtml
index eb3114fcd..893451af9 100755
--- a/app/views/helpers/pagination.phtml
+++ b/app/views/helpers/pagination.phtml
@@ -27,7 +27,7 @@
</a>
<?php } elseif ($url_mark_read) { ?>
<button id="bigMarkAsRead"
- class="as-link <?php echo FreshRSS_Context::$user_conf->reading_confirm ? 'confirm' : ''; ?>"
+ class="as-link <?php echo FreshRSS_Context::$user_conf->reading_confirm ? 'confirm" disabled="disabled' : ''; ?>"
form="mark-read-pagination"
formaction="<?php echo Minz_Url::display($url_mark_read); ?>"
type="submit">
diff --git a/p/scripts/main.js b/p/scripts/main.js
index 51323a969..078bec682 100644
--- a/p/scripts/main.js
+++ b/p/scripts/main.js
@@ -1126,6 +1126,7 @@ function init_confirm_action() {
return confirm(str_confirmation);
});
+ $('button.confirm').removeAttr('disabled');
}
function init_print_action() {