aboutsummaryrefslogtreecommitdiffhomepage
path: root/themes
diff options
context:
space:
mode:
authorNicolas LÅ“uillet <nicolas@loeuillet.org>2014-02-19 15:17:13 +0100
committerNicolas LÅ“uillet <nicolas@loeuillet.org>2014-02-19 15:17:13 +0100
commit7785f0c75fd6db6c7db345a568093e7edb8b7573 (patch)
tree9054efb2de9d148bae289848b3023a34fb0020a7 /themes
parentfb5a9666ed99abe16b8823a98aed1a6dce03bb04 (diff)
parent01cd443441c401a82ae021e08dedd6709100be2c (diff)
downloadwallabag-7785f0c75fd6db6c7db345a568093e7edb8b7573.tar.gz
wallabag-7785f0c75fd6db6c7db345a568093e7edb8b7573.tar.zst
wallabag-7785f0c75fd6db6c7db345a568093e7edb8b7573.zip
Merge pull request #467 from mariroz/dev
"save a link" added to top menu (default theme) to toggle "save link" form, issue #461
Diffstat (limited to 'themes')
-rw-r--r--themes/default/_menu.twig5
-rwxr-xr-xthemes/default/_pocheit-form.twig22
-rw-r--r--themes/default/css/style.css13
-rw-r--r--themes/default/home.twig1
4 files changed, 40 insertions, 1 deletions
diff --git a/themes/default/_menu.twig b/themes/default/_menu.twig
index 02bec1dc..55583b3d 100644
--- a/themes/default/_menu.twig
+++ b/themes/default/_menu.twig
@@ -3,6 +3,9 @@
3 <li><a href="./?view=fav" {% if view == 'fav' %}class="current"{% endif %}>{% trans "favorites" %}</a></li> 3 <li><a href="./?view=fav" {% if view == 'fav' %}class="current"{% endif %}>{% trans "favorites" %}</a></li>
4 <li><a href="./?view=archive" {% if view == 'archive' %}class="current"{% endif %}>{% trans "archive" %}</a></li> 4 <li><a href="./?view=archive" {% if view == 'archive' %}class="current"{% endif %}>{% trans "archive" %}</a></li>
5 <li><a href="./?view=tags" {% if view == 'tags' %}class="current"{% endif %}>{% trans "tags" %}</a></li> 5 <li><a href="./?view=tags" {% if view == 'tags' %}class="current"{% endif %}>{% trans "tags" %}</a></li>
6 <li><a href="javascript: void(null);" id="pocheit">{% trans "save a link" %}</a><span id="pocheit-arrow"></span></li>
6 <li><a href="./?view=config" {% if view == 'config' %}class="current"{% endif %}>{% trans "config" %}</a></li> 7 <li><a href="./?view=config" {% if view == 'config' %}class="current"{% endif %}>{% trans "config" %}</a></li>
7 <li><a href="./?logout" title="{% trans "logout" %}">{% trans "logout" %}</a></li> 8 <li><a href="./?logout" title="{% trans "logout" %}">{% trans "logout" %}</a></li>
8 </ul> \ No newline at end of file 9 </ul>
10 {% include '_pocheit-form.twig' %}
11
diff --git a/themes/default/_pocheit-form.twig b/themes/default/_pocheit-form.twig
new file mode 100755
index 00000000..13096159
--- /dev/null
+++ b/themes/default/_pocheit-form.twig
@@ -0,0 +1,22 @@
1<div id="pocheit-form" class="messages info">
2 <center>
3 <form method="get" action="index.php">
4 <input required placeholder="example.com/article" class="addurl" id="plainurl" name="plainurl" type="url" />
5 <input type="submit" value="{% trans "save link!" %}" />
6 </form>
7 </center>
8</div>
9<script type="text/javascript">
10 $(document).ready(function() {
11
12 $("#pocheit-form").hide();
13
14 $("#pocheit").click(function(){
15 $("#pocheit-form").toggle();
16 $("#pocheit").toggleClass("current");
17 $("#pocheit-arrow").toggleClass("arrow-down");
18 });
19
20
21 });
22</script>
diff --git a/themes/default/css/style.css b/themes/default/css/style.css
index 2088ee2e..28675907 100644
--- a/themes/default/css/style.css
+++ b/themes/default/css/style.css
@@ -334,3 +334,16 @@ a.bad-display span,
334a.reading-time span { 334a.reading-time span {
335 background-repeat: no-repeat; 335 background-repeat: no-repeat;
336} 336}
337
338.arrow-down {
339 width: 0px;
340 height: 0px;
341 border-style: solid;
342 border-width: 10px 10px 0 10px;
343 border-color: #000 transparent transparent transparent;
344
345 position: absolute;
346 margin-top: 1.5em;
347 margin-left: -30px;
348}
349
diff --git a/themes/default/home.twig b/themes/default/home.twig
index cbe8c62f..21013ec8 100644
--- a/themes/default/home.twig
+++ b/themes/default/home.twig
@@ -46,4 +46,5 @@
46 {% endfor %} 46 {% endfor %}
47 {% endif %} 47 {% endif %}
48 {{ block('pager') }} 48 {{ block('pager') }}
49 {% if view == 'home' %}{% if nb_results > 1 %}<a title="{% trans "mark all the entries as read" %}" href="./?action=archive_all">{% trans "mark all the entries as read" %}</a>{% endif %}{% endif %}
49{% endblock %} 50{% endblock %}