aboutsummaryrefslogtreecommitdiffhomepage
path: root/app/Resources/views/baggy/view.twig
diff options
context:
space:
mode:
authorNicolas Lœuillet <nicolas@loeuillet.org>2015-03-02 21:23:19 +0100
committerNicolas Lœuillet <nicolas@loeuillet.org>2015-03-02 21:23:19 +0100
commitba7b9d48d407f87690a3fdc199b37714d2a52897 (patch)
treea15611f10d09749e82011e0d51532af3de8cfabd /app/Resources/views/baggy/view.twig
parentfca3c757233940cbe4c431e3e05fe74893225fe0 (diff)
parent3e30422cdae3cc45f44c3039c2d38b99121dd9e9 (diff)
downloadwallabag-ba7b9d48d407f87690a3fdc199b37714d2a52897.tar.gz
wallabag-ba7b9d48d407f87690a3fdc199b37714d2a52897.tar.zst
wallabag-ba7b9d48d407f87690a3fdc199b37714d2a52897.zip
Merge pull request #1132 from wallabag/v2-theme
V2 theme
Diffstat (limited to 'app/Resources/views/baggy/view.twig')
-rwxr-xr-xapp/Resources/views/baggy/view.twig102
1 files changed, 0 insertions, 102 deletions
diff --git a/app/Resources/views/baggy/view.twig b/app/Resources/views/baggy/view.twig
deleted file mode 100755
index 1afd9df6..00000000
--- a/app/Resources/views/baggy/view.twig
+++ /dev/null
@@ -1,102 +0,0 @@
1{% extends "layout.twig" %}
2{% block menu %}
3{% include '_menu.twig' %}
4{% endblock %}
5{% block title %}{{ entry.title|raw }} ({{ entry.url | e | getDomain }}){% endblock %}
6{% block content %}
7 {% include '_highlight.twig' %}
8 <div id="article_toolbar">
9 <ul class="links">
10 <li class="topPosF"><a href="#top" title="{% trans "Back to top" %}" class="tool top icon icon-arrow-up-thick"><span>{% trans "Back to top" %}</span></a></li>
11 <li><a href="{{ entry.url|e }}" target="_blank" title="{% trans "original" %} : {{ entry.title|e }}" class="tool link icon icon-link"><span>{{ entry.url | e | getDomain }}</span></a></li>
12 <li><a title="{% trans "Mark as read" %}" class="tool icon icon-check {% if entry.is_read == 0 %}archive-off{% else %}archive{% endif %}" href="javascript: void(null);" id="markAsRead"><span>{% trans "Toggle mark as read" %}</span></a></li>
13 <li><a title="{% trans "Favorite" %}" class="tool icon icon-star {% if entry.is_fav == 0 %}fav-off{% else %}fav{% endif %}" href="javascript: void(null);" id="setFav"><span>{% trans "Toggle favorite" %}</span></a></li>
14 <li><a title="{% trans "Delete" %}" class="tool delete icon icon-trash" href="./?action=delete&amp;id={{ entry.id|e }}"><span>{% trans "Delete" %}</span></a></li>
15 {% if constant('SHARE_TWITTER') == 1 %}<li><a href="https://twitter.com/home?status={{entry.title|url_encode}}%20{{ entry.url|url_encode }}%20via%20@wallabagapp" target="_blank" class="tool twitter icon icon-twitter" title="{% trans "Tweet" %}"><span>{% trans "Tweet" %}</span></a></li>{% endif %}
16 {% if constant('SHARE_MAIL') == 1 %}<li><a href="mailto:?subject={{ entry.title|url_encode }}&amp;body={{ entry.url|url_encode }}%20via%20@wallabagapp" class="tool email icon icon-mail" title="{% trans "Email" %}"><span>{% trans "Email" %}</span></a></li>{% endif %}
17 {% if constant('SHARE_SHAARLI') == 1 %}<li><a href="{{ constant('SHAARLI_URL') }}/index.php?post={{ entry.url|url_encode }}&amp;title={{ entry.title|url_encode }}" target="_blank" class="tool shaarli" title="{% trans "shaarli" %}"><span>{% trans "shaarli" %}</span></a></li>{% endif %}
18 {% if constant('SHARE_DIASPORA') == 1 %}<li><a href="{{ constant('DIASPORA_URL') }}/bookmarklet?url={{ entry.url|url_encode }}&title={{ entry.title|url_encode }}&notes=&v=1&noui=1&jump=doclose" target="_blank" class="tool diaspora icon-image icon-image--diaspora" title="{% trans "diaspora" %}"><span>{% trans "diaspora" %}</span></a></li>{% endif %}
19 {% if constant('FLATTR') == 1 %}{% if flattr.status == constant('FLATTRABLE') %}<li><a href="http://flattr.com/submit/auto?url={{ entry.url }}" class="tool flattr icon icon-flattr" target="_blank" title="{% trans "flattr" %}"><span>{% trans "flattr" %}</span></a></li>{% elseif flattr.status == constant('FLATTRED') %}<li><a href="{{ flattr.flattrItemURL }}" class="tool flattr icon icon-flattr" target="_blank" title="{% trans "flattr" %}"><span>{% trans "flattr" %}</span> ({{ flattr.numFlattrs }})</a></li>{% endif %}{% endif %}
20 {% if constant('CARROT') == 1 %}<li><a href="https://secure.carrot.org/GiveAndGetBack.do?url={{ entry.url|url_encode }}&title={{ entry.title|url_encode }}" class="tool carrot icon-image icon-image--carrot" target="_blank" title="{% trans "carrot" %}"><span>Carrot</span></a></li>{% endif %}
21 {% if constant('SHOW_PRINTLINK') == 1 %}<li><a title="{% trans "Print" %}" class="tool icon icon-print" href="javascript: window.print();"><span>{% trans "Print" %}</span></a></li>{% endif %}
22 {% if constant('EPUB') == 1 %}<li><a href="./?epub&amp;method=id&amp;value={{ entry.id|e }}" title="Generate ePub file">EPUB</a></li>{% endif %}
23 {% if constant('MOBI') == 1 %}<li><a href="./?mobi&amp;method=id&amp;value={{ entry.id|e }}" title="Generate Mobi file">MOBI</a></li>{% endif %}
24 {% if constant('PDF') == 1 %}<li><a href="./?pdf&amp;method=id&amp;value={{ entry.id|e }}" title="Generate PDF file">PDF</a></li>{% endif %}
25 <li><a href="mailto:hello@wallabag.org?subject=Wrong%20display%20in%20wallabag&amp;body={{ entry.url|url_encode }}" title="{% trans "Does this article appear wrong?" %}" class="tool bad-display icon icon-delete"><span>{% trans "Does this article appear wrong?" %}</span></a></li>
26 </ul>
27 </div>
28 <div id="article">
29 <header class="mbm">
30 <h1>{{ entry.title|raw }}</h1>
31 </header>
32 <aside class="tags">
33 tags: {% for tag in tags %}<a href="./?view=tag&amp;id={{ tag.id }}">{{ tag.value }}</a> {% endfor %}<a href="./?view=edit-tags&amp;id={{ entry.id|e }}" title="{% trans "Edit tags" %}">✎</a>
34 </aside>
35 <article>
36 {{ content | raw }}
37 </article>
38 </div>
39 <script src="{{ poche_url }}themes/_global/js/restoreScroll.js"></script>
40 <script type="text/javascript">
41 $(document).ready(function() {
42
43 // toggle read property of current article
44 $('#markAsRead').click(function(){
45 $("body").css("cursor", "wait");
46 $.ajax( { url: './?action=toggle_archive&id={{ entry.id|e }}' }).done(
47 function( data ) {
48 if ( data == '1' ) {
49 if ( $('#markAsRead').hasClass("archive-off") ) {
50 $('#markAsRead').removeClass("archive-off");
51 $('#markAsRead').addClass("archive");
52 }
53 else {
54 $('#markAsRead').removeClass("archive");
55 $('#markAsRead').addClass("archive-off");
56 }
57 }
58 else {
59 alert('Error! Pls check if you are logged in.');
60 }
61 });
62 $("body").css("cursor", "auto");
63 });
64
65 // toggle favorite property of current article
66 $('#setFav').click(function(){
67 $("body").css("cursor", "wait");
68 $.ajax( { url: './?action=toggle_fav&id={{ entry.id|e }}' }).done(
69 function( data ) {
70 if ( data == '1' ) {
71 if ( $('#setFav').hasClass("fav-off") ) {
72 $('#setFav').removeClass("fav-off");
73 $('#setFav').addClass("fav");
74 }
75 else {
76 $('#setFav').removeClass("fav");
77 $('#setFav').addClass("fav-off");
78 }
79 }
80 else {
81 alert('Error! Pls check if you are logged in.');
82 }
83 });
84 $("body").css("cursor", "auto");
85 });
86
87 $(window).scroll(function(e){
88 var scrollTop = $(window).scrollTop();
89 var docHeight = $(document).height();
90 var scrollPercent = (scrollTop) / (docHeight);
91 var scrollPercentRounded = Math.round(scrollPercent*100)/100;
92 savePercent({{ entry.id|e }}, scrollPercentRounded);
93 });
94
95 retrievePercent({{ entry.id|e }});
96
97 $(window).resize(function(){
98 retrievePercent({{ entry.id|e }});
99 });
100 });
101 </script>
102{% endblock %}