diff options
Diffstat (limited to 'themes')
-rw-r--r-- | themes/_global/js/autoClose.js | 13 | ||||
-rw-r--r-- | themes/_global/js/keyboard.js | 9 | ||||
-rwxr-xr-x | themes/baggy/config.twig | 2 | ||||
-rwxr-xr-x | themes/default/config.twig | 2 |
4 files changed, 22 insertions, 4 deletions
diff --git a/themes/_global/js/autoClose.js b/themes/_global/js/autoClose.js index e9145b7e..c3ce744f 100644 --- a/themes/_global/js/autoClose.js +++ b/themes/_global/js/autoClose.js | |||
@@ -1,6 +1,15 @@ | |||
1 | $(document).ready(function() { | 1 | $(document).ready(function() { |
2 | current_url = window.location.href | 2 | if (location.search.match("&closewin=true")) { |
3 | if (current_url.match("&closewin=true")) { | 3 | if (window.opener) { |
4 | var msgDiv = $("div.messages"); | ||
5 | var msg = msgDiv.children("p").text(); | ||
6 | var status = msgDiv.hasClass("success") ? | ||
7 | 'success' : 'unknown'; | ||
8 | var url = $(".tool.link")[0].href; | ||
9 | window.opener.postMessage({"wallabag-status": status, | ||
10 | "wallabag-msg": msg, | ||
11 | "wallabag-url": url }, "*"); | ||
12 | } | ||
4 | window.close(); | 13 | window.close(); |
5 | } | 14 | } |
6 | }); | 15 | }); |
diff --git a/themes/_global/js/keyboard.js b/themes/_global/js/keyboard.js index 48f60a09..04000f47 100644 --- a/themes/_global/js/keyboard.js +++ b/themes/_global/js/keyboard.js | |||
@@ -63,6 +63,9 @@ function actionArticle(id) { | |||
63 | case 77: | 63 | case 77: |
64 | markReadArticle(id); // m key letter | 64 | markReadArticle(id); // m key letter |
65 | break; | 65 | break; |
66 | case 78: | ||
67 | markReadAndNextArticle(id); // n letter | ||
68 | break; | ||
66 | } | 69 | } |
67 | 70 | ||
68 | }, false); | 71 | }, false); |
@@ -86,6 +89,12 @@ function markReadArticle(id) { | |||
86 | } | 89 | } |
87 | } | 90 | } |
88 | 91 | ||
92 | function markReadAndNextArticle(id) { | ||
93 | if (id) { | ||
94 | window.location = window.location.origin + window.location.pathname + '?action=archive_and_next&id=' + id; | ||
95 | } | ||
96 | } | ||
97 | |||
89 | function homeNavigation() { | 98 | function homeNavigation() { |
90 | selectedArticle = $('.entrie:first'); | 99 | selectedArticle = $('.entrie:first'); |
91 | window.addEventListener("keydown", function (event) { | 100 | window.addEventListener("keydown", function (event) { |
diff --git a/themes/baggy/config.twig b/themes/baggy/config.twig index 511959a8..2d4ffd70 100755 --- a/themes/baggy/config.twig +++ b/themes/baggy/config.twig | |||
@@ -17,7 +17,7 @@ | |||
17 | <h3>{% trans "Browser Addons" %}</h3> | 17 | <h3>{% trans "Browser Addons" %}</h3> |
18 | <ul> | 18 | <ul> |
19 | <li><a href="https://addons.mozilla.org/firefox/addon/wallabag/" target="_blank">{% trans "Standard Firefox Add-On" %}</a></li> | 19 | <li><a href="https://addons.mozilla.org/firefox/addon/wallabag/" target="_blank">{% trans "Standard Firefox Add-On" %}</a></li> |
20 | <li><button onclick="activateSocialFeature(this)">{% trans "Mozilla Services (Social API) Extension" %}</button></li> | 20 | {% if https %}<li><button onclick="activateSocialFeature(this)">{% trans "Mozilla Services (Social API) Extension" %}</button></li>{% else %}<li>{% trans "Mozilla Services (Social API) Extension needs an https connection" %}</li>{% endif %} |
21 | <li><a href="https://chrome.google.com/webstore/detail/wallabag/bepdcjnnkglfjehplaogpoonpffbdcdj" target="_blank">{% trans "Chrome Extension" %}</a></li> | 21 | <li><a href="https://chrome.google.com/webstore/detail/wallabag/bepdcjnnkglfjehplaogpoonpffbdcdj" target="_blank">{% trans "Chrome Extension" %}</a></li> |
22 | </ul> | 22 | </ul> |
23 | <h3>{% trans "Mobile Apps" %}</h3> | 23 | <h3>{% trans "Mobile Apps" %}</h3> |
diff --git a/themes/default/config.twig b/themes/default/config.twig index e39826c3..24e3e570 100755 --- a/themes/default/config.twig +++ b/themes/default/config.twig | |||
@@ -17,7 +17,7 @@ | |||
17 | <h3>Browser Plugins</h3> | 17 | <h3>Browser Plugins</h3> |
18 | <ul> | 18 | <ul> |
19 | <li><a href="https://addons.mozilla.org/firefox/addon/wallabag/" target="_blank">{% trans "Standard Firefox Add-On" %}</a></li> | 19 | <li><a href="https://addons.mozilla.org/firefox/addon/wallabag/" target="_blank">{% trans "Standard Firefox Add-On" %}</a></li> |
20 | <li><button onclick="activateSocialFeature(this)">{% trans "Mozilla Services (Social API) Extension" %}</button></li> | 20 | {% if https %}<li><button onclick="activateSocialFeature(this)">{% trans "Mozilla Services (Social API) Extension" %}</button></li>{% else %}<li>{% trans "Mozilla Services (Social API) Extension needs an https connection" %}</li>{% endif %} |
21 | <li><a href="https://chrome.google.com/webstore/detail/wallabag/bepdcjnnkglfjehplaogpoonpffbdcdj" target="_blank">{% trans "Chrome Extension" %}</a></li> | 21 | <li><a href="https://chrome.google.com/webstore/detail/wallabag/bepdcjnnkglfjehplaogpoonpffbdcdj" target="_blank">{% trans "Chrome Extension" %}</a></li> |
22 | </ul> | 22 | </ul> |
23 | <h3>Mobile Apps</h3> | 23 | <h3>Mobile Apps</h3> |