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

Unified Diff: templates/default.tmpl

Issue 29551738: Issue 5634 - Replaced logo and refactored navbar width and colors (Closed) Base URL: https://hg.adblockplus.org/web.adblockplus.org
Patch Set: Minor refactoring, added fonts, added install background-color Created Sept. 25, 2017, 3:48 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « static/img/header-logo-2x.png ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: templates/default.tmpl
===================================================================
--- a/templates/default.tmpl
+++ b/templates/default.tmpl
@@ -71,51 +71,56 @@
</head>
<body>
<noscript>
<link rel="stylesheet" href="/css/noscript-desktop.css" media="(min-width: 1000px)"/>
<link rel="stylesheet" href="/css/noscript-mobile.css" media="(max-width: 1000px)"/>
</noscript>
- {% macro pageitem(name) %}
- {% if name == page %}
- <li class="selected">{{get_string(name, "menu")}}</li>
- {% else %}
- <li>{{name|linkify}}{{get_string(name, "menu")}}</a></li>
- {% endif %}
+ {% macro pageitem(pagename) %}
+ <li{{ " class=\"selected\"" if pagename == page else "" }}>
+ {{ pagename | linkify }}{{ get_string(pagename, "menu") }}</a>
+ </li>
{% endmacro %}
- <header>
- {{"index"|linkify(id="logo", class="sprite", itemprop="image")}}</a>
- <nav>
- <ul>
- {% if localefile == "index" %}
- <li class="selected first">{{get_string("installation", "menu")}}</li>
- {% else %}
- <li class="install-link first">{{"index"|linkify}}{{get_string("installation", "menu")}} <span class="sprite install-link-icon"></span></a></li>
- {% endif %}
- {% for name in ["about", "features", "bugs", "contribute"] %}
- {{pageitem(name)}}
+ <nav class="navbar accent">
+ <div class="container">
+ {{ "index" | linkify(class="navbar-brand") }}
+ <img
+ alt="{{ "Adblock Plus" | translate("logo-alt", "Logo alt text") }}"
+ title="{{ "Adblock Plus" | translate("logo-title", "Logo tooltip text") }}"
+ src="/img/header-logo.png"
+ srcset="/img/header-logo-2x.png">
+ </a>
+ <ul class="navbar-nav">
+ {% for name in ["about", "features", "bugs", "contribute", "locale", "installation"] %}
+ {% if name == "locale" %}
+ <li id="language" class="dropdown">
+ <a href="#" id="current-language" class="dropdown-toggle">
+ {{ config.get("langnames", locale) }} ({{ locale | upper }})
+ </a>
+ <ul id="language-selector" class="dropdown-menu secondary">
+ {% for available_locale in available_locales %}
+ <li class="language-entry">
+ {{ page | linkify(available_locale) }}
+ {{ config.get("langnames", available_locale) }} ({{ available_locale | upper }})
+ </a>
+ </li>
+ {% endfor %}
+ </ul>
+ </li>
+ {% elif name == "installation" %}
+ <li class="install-link">
+ {{ "index" | linkify }}{{ get_string("installation", "menu") }}</a>
+ </li>
+ {% else %}
+ {{ pageitem(name) }}
+ {% endif %}
{% endfor %}
- <li id="language">
- <div id="current-language">
- {{ config.get("langnames", locale) }} ({{ locale | upper }})
- <span id="language-arrow" class="sprite"></span>
- </div>
- <ul id="language-selector">
- {% for available_locale in available_locales %}
- <li class="language-entry">
- {{ page | linkify(available_locale) }}
- {{ config.get("langnames", available_locale) }} ({{ available_locale | upper }})
- </a>
- </li>
- {% endfor %}
- </ul>
- </li>
</ul>
<a href="#" id="hamburger"></a>
</nav>
</header>
<div id="content" {% if localefile == "index" %}class="{{page}}"{% endif %}>
{% if abbnotification %}
<? include abb-notification ?>
« no previous file with comments | « static/img/header-logo-2x.png ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld