Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Delta Between Two Patch Sets: includes/subscriptionList.tmpl

Issue 29337807: Issue 3097 - Refactored subscriptions list table on adblockplus.org/en/subscriptions (Closed)
Left Patch Set: Changed table into unordered list, refactored list markup, refactored main css and templates to support multiple footer elements Created Feb. 27, 2016, 4:16 p.m.
Right Patch Set: Removed extra whitespace Created July 29, 2016, 10:52 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « no previous file | pages/subscriptions.tmpl » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 {# 1 {#
2 # This file is part of the Adblock Plus website, 2 # This file is part of the Adblock Plus website,
3 # Copyright (C) 2006-2016 Eyeo GmbH 3 # Copyright (C) 2006-2016 Eyeo GmbH
4 # 4 #
5 # Adblock Plus is free software: you can redistribute it and/or modify 5 # Adblock Plus is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License version 3 as 6 # it under the terms of the GNU General Public License version 3 as
7 # published by the Free Software Foundation. 7 # published by the Free Software Foundation.
8 # 8 #
9 # Adblock Plus is distributed in the hope that it will be useful, 9 # Adblock Plus is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of 10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 # GNU General Public License for more details. 12 # GNU General Public License for more details.
13 # 13 #
14 # You should have received a copy of the GNU General Public License 14 # You should have received a copy of the GNU General Public License
15 # along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>. 15 # along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
16 #} 16 #}
17 17
18 {%- macro process_subscription(subscription, parent=None) %} 18 {%- macro process_subscription(subscription, parent=None) %}
19 <li> 19 <li>
20 <article class="subscription {% if subscription["deprecated"] %}deprecated{% endif %}"> 20 <article class="subscription {% if subscription["deprecated"] %}deprecated{% endif %}">
21 <div class="subscription-content"> 21 <div class="subscription-content">
22 <div class="subscription-summary"> 22 <div class="subscription-summary">
23 <h1>{{ subscription["name"] }}</h1> 23 <h1>{{ subscription["name"] }}</h1>
24 <p> 24 <p>
25 <span class="sr-only">{{ "Specialization"|translate("specialization" ) }}:</span> 25 {{ "Specialization"|translate("specialization") }}:
Thomas Greiner 2016/07/15 16:07:53 Detail: Not sure what "sr-only" means but it's not
juliandoucette 2016/07/19 22:29:17 My mistake. "sr" stands for "screen reader". I f
26 {{ subscription["specialization"] }} 26 {{ subscription["specialization"] }}
27 </p> 27 </p>
28 {%- if subscription["supplements"] %} 28 {%- if subscription["supplements"] %}
29 <p>{{ "supplement for"|translate("supplements_prefix") }} {{ ' / '.joi n(subscription["supplements"]) }} {{ " "|translate("supplements_suffix") }}.</p> 29 <p>
Thomas Greiner 2016/07/15 16:07:53 Detail: Mind splitting this content (and the conte
juliandoucette 2016/07/19 22:29:16 Done.
30 {{ "supplement for"|translate("supplements_prefix") }}
31 {{ ' / '.join(subscription["supplements"]) }}
32 {{ " "|translate("supplements_suffix") }}.
33 </p>
30 {%- endif %} 34 {%- endif %}
31 </div> 35 </div>
32 </div> 36 </div>
33 <footer class="subscription-details"> 37 <footer class="subscription-details">
34 <div class="subscription-authors"> 38 <div class="subscription-authors">
Thomas Greiner 2016/07/15 16:07:53 Detail: Since you've decided to use `<footer>` for
juliandoucette 2016/07/19 22:29:16 Good idea.
35 {%- if subscription["maintainer"] %} 39 {%- if subscription["maintainer"] %}
36 <p>{{ "by"|translate("maintainer_prefix") }} {{ subscription["maintain er"] }} {{ " "|translate("maintainer_suffix") }}</p> 40 <address>
41 {{ "by"|translate("maintainer_prefix") }}
42 {{ subscription["maintainer"] }}
43 {{ " "|translate("maintainer_suffix") }}
44 </address>
37 {%- endif %} 45 {%- endif %}
38 {%- set is_first = True %} 46 {%- set is_first = True %}
39 <p> 47 <p>
40 {% for key, default in (('homepage', 'Homepage'), ('forum', 'Forum'), ('contact', 'Contact page'), ('faq', 'FAQ'), ('blog', 'Blog'), ('changelog', 'Ch angelog'), ('policy', 'Policy')) -%} 48 {% for key, default in (('homepage', 'Homepage'), ('forum', 'Forum'), ('contact', 'Contact page'), ('faq', 'FAQ'), ('blog', 'Blog'), ('changelog', 'Ch angelog'), ('policy', 'Policy')) -%}
41 {%- set url = subscription[key] -%} 49 {%- set url = subscription[key] -%}
42 {%- if url -%} 50 {%- if url -%}
43 {%- if not is_first %}, {% endif -%} 51 {%- if not is_first %}, {% endif -%}
44 {%- set is_first = False -%} 52 {%- set is_first = False -%}
45 <a href="{{ url }}">{{ default|translate(key) }}</a> 53 <a href="{{ url }}">{{ default|translate(key) }}</a>
46 {%- endif %} 54 {%- endif %}
47 {%- endfor %} 55 {%- endfor %}
48 </p> 56 </p>
49 </div> 57 </div>
50 <div class="subscription-links"> 58 <div class="subscription-links">
51 {%- if subscription["deprecated"] %} 59 {%- if subscription["deprecated"] %}
52 <p><strong>{{ "Note: This list is not optimized for Adblock Plus and m ay slow down your browsing experience."|translate("deprecation_warning") }}</str ong></p> 60 <p>
61 <strong>{{ "Note: This list is not optimized for Adblock Plus and ma y slow down your browsing experience."|translate("deprecation_warning") }}</stro ng>
62 </p>
53 {%- endif %} 63 {%- endif %}
54 <p> 64 <p>
55 {{ "Subscribe:"|translate("subscribe") }}{{ ' ' }} 65 {{ "Subscribe:"|translate("subscribe") }}{{ ' ' }}
56 {%- for title, url, complete in subscription["variants"] -%} 66 {%- for title, url, complete in subscription["variants"] -%}
57 <a href="abp:subscribe?location={{ url|urlencode }}&amp;title={{ tit le|urlencode }} 67 <a href="abp:subscribe?location={{ url|urlencode }}&amp;title={{ tit le|urlencode }}
58 {%- if parent and not complete -%} 68 {%- if parent and not complete -%}
59 {%- set main_title, main_url, main_complete = parent.variants[0] -%} 69 {%- set main_title, main_url, main_complete = parent.variants[0] -%}
60 &amp;requiresLocation={{ main_url|urlencode }}&amp;requiresTitle ={{ main_title|urlencode }} 70 &amp;requiresLocation={{ main_url|urlencode }}&amp;requiresTitle ={{ main_title|urlencode }}
61 {%- endif -%} 71 {%- endif -%}
62 ">{{ title }}</a>{%- if not loop.last %}, {% endif -%} 72 ">{{ title }}</a>{%- if not loop.last %}, {% endif -%}
63 {%- endfor %} 73 {%- endfor %}
64 </p> 74 </p>
65 </div> 75 </div>
(...skipping 21 matching lines...) Expand all
87 97
88 <ul class="subscriptions-list"> 98 <ul class="subscriptions-list">
89 {%- endif -%} 99 {%- endif -%}
90 {%- endif -%} 100 {%- endif -%}
91 {%- if subscription["type"] not in subscription["supplementsType"] -%} 101 {%- if subscription["type"] not in subscription["supplementsType"] -%}
92 {{ process_subscription(subscription) }} 102 {{ process_subscription(subscription) }}
93 {%- endif -%} 103 {%- endif -%}
94 {%- endfor %} 104 {%- endfor %}
95 </ul> 105 </ul>
96 {% endmacro %} 106 {% endmacro %}
LEFTRIGHT

Powered by Google App Engine
This is Rietveld