Skip to content

Commit

Permalink
Update bootstrap3-gradients family
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information
Kwpolska committed Sep 28, 2015
1 parent 5651b59 commit 47579e1
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 18 deletions.
20 changes: 11 additions & 9 deletions v7/bootstrap3-gradients-jinja/templates/base_helper.tmpl
Expand Up @@ -26,6 +26,9 @@ dir="rtl"
lang="{{ lang }}">
<head>
<meta charset="utf-8">
{% if use_base_tag %}
<base href="{{ abs_link(permalink) }}">
{% endif %}
{% if description %}
<meta name="description" content="{{ description|e }}">
{% endif %}
Expand All @@ -35,12 +38,11 @@ lang="{{ lang }}">
{% else %}
<title>{{ title|e }} | {{ blog_title|e }}</title>
{% endif %}

{{ html_stylesheets() }}
<meta content="{{ theme_color }}" name="theme-color">
{{ html_feedlinks() }}
{% if permalink %}
<link rel="canonical" href="{{ abs_link(permalink) }}">
{% endif %}
<link rel="canonical" href="{{ abs_link(permalink) }}">

{% if favicons %}
{% for name, file, size in favicons %}
Expand Down Expand Up @@ -136,21 +138,21 @@ lang="{{ lang }}">
{% macro html_navigation_links() %}
{% for url, text in navigation_links[lang] %}
{% if isinstance(url, tuple) %}
<li class="dropdown"><a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">{{ text|e }} <b class="caret"></b></a>
<li class="dropdown"><a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">{{ text }} <b class="caret"></b></a>
<ul class="dropdown-menu">
{% for suburl, text in url %}
{% if rel_link(permalink, suburl) == "#" %}
<li class="active"><a href="{{ permalink }}">{{ text|e }} <span class="sr-only">{{ messages("(active)", lang) }}</span></a>
<li class="active"><a href="{{ permalink }}">{{ text }} <span class="sr-only">{{ messages("(active)", lang) }}</span></a>
{% else %}
<li><a href="{{ suburl }}">{{ text|e }}</a>
<li><a href="{{ suburl }}">{{ text }}</a>
{% endif %}
{% endfor %}
</ul>
{% else %}
{% if rel_link(permalink, url) == "#" %}
<li class="active"><a href="{{ permalink }}">{{ text|e }} <span class="sr-only">{{ messages("(active)", lang) }}</span></a>
<li class="active"><a href="{{ permalink }}">{{ text }} <span class="sr-only">{{ messages("(active)", lang) }}</span></a>
{% else %}
<li><a href="{{ url }}">{{ text|e }}</a>
<li><a href="{{ url }}">{{ text }}</a>
{% endif %}
{% endif %}
{% endfor %}
Expand Down
24 changes: 15 additions & 9 deletions v7/bootstrap3-gradients/templates/base_helper.tmpl
Expand Up @@ -26,17 +26,23 @@ dir="rtl" \
lang="${lang}">
<head>
<meta charset="utf-8">
% if use_base_tag:
<base href="${abs_link(permalink)}">
% endif
%if description:
<meta name="description" content="${description}">
<meta name="description" content="${description|h}">
%endif
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>${title|striphtml} | ${blog_title|striphtml}</title>
%if title == blog_title:
<title>${blog_title|h}</title>
%else:
<title>${title|h} | ${blog_title|h}</title>
%endif

${html_stylesheets()}
<meta content="${theme_color}" name="theme-color">
${html_feedlinks()}
%if permalink:
<link rel="canonical" href="${abs_link(permalink)}">
%endif
<link rel="canonical" href="${abs_link(permalink)}">

%if favicons:
%for name, file, size in favicons:
Expand Down Expand Up @@ -132,7 +138,7 @@ lang="${lang}">
<%def name="html_navigation_links()">
%for url, text in navigation_links[lang]:
% if isinstance(url, tuple):
<li class="dropdown"><a href="#" class="dropdown-toggle" data-toggle="dropdown">${text} <b class="caret"></b></a>
<li class="dropdown"><a href="#" class="dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">${text} <b class="caret"></b></a>
<ul class="dropdown-menu">
%for suburl, text in url:
% if rel_link(permalink, suburl) == "#":
Expand All @@ -157,7 +163,7 @@ lang="${lang}">
${rss_link}
%elif generate_rss:
%if len(translations) > 1:
%for language in translations:
%for language in sorted(translations):
<link rel="alternate" type="application/rss+xml" title="RSS (${language})" href="${_link('rss', None, language)}">
%endfor
%else:
Expand All @@ -166,7 +172,7 @@ lang="${lang}">
%endif
%if generate_atom:
%if len(translations) > 1:
%for language in translations:
%for language in sorted(translations):
<link rel="alternate" type="application/atom+xml" title="Atom (${language})" href="${_link('index_atom', None, language)}">
%endfor
%else:
Expand All @@ -176,7 +182,7 @@ lang="${lang}">
</%def>

<%def name="html_translations()">
%for langname in translations.keys():
%for langname in sorted(translations):
%if langname != lang:
<li><a href="${abs_link(_link("root", None, langname))}" rel="alternate" hreflang="${langname}">${messages("LANGUAGE", langname)}</a></li>
%endif
Expand Down

0 comments on commit 47579e1

Please sign in to comment.