diff options
author | Samy Pessé <samypesse@gmail.com> | 2015-01-21 20:26:29 +0100 |
---|---|---|
committer | Samy Pessé <samypesse@gmail.com> | 2015-01-21 20:26:29 +0100 |
commit | 4f9ece1ec114901d817c77e584b933f195ece923 (patch) | |
tree | 7d4940657bde1ea09f2f5b644ce12a44e795d4d5 /theme | |
parent | 748f0046098ece68547bb86cd72e75e76655a260 (diff) | |
download | gitbook-4f9ece1ec114901d817c77e584b933f195ece923.zip gitbook-4f9ece1ec114901d817c77e584b933f195ece923.tar.gz gitbook-4f9ece1ec114901d817c77e584b933f195ece923.tar.bz2 |
Fix display of summary in website
Diffstat (limited to 'theme')
-rw-r--r-- | theme/templates/ebook/summary.html | 3 | ||||
-rw-r--r-- | theme/templates/website/includes/summary.html | 5 |
2 files changed, 3 insertions, 5 deletions
diff --git a/theme/templates/ebook/summary.html b/theme/templates/ebook/summary.html index 9a67d28..2e540a6 100644 --- a/theme/templates/ebook/summary.html +++ b/theme/templates/ebook/summary.html @@ -4,10 +4,9 @@ {% macro articles(_articles) %} {% for item in _articles %} - {% set externalLink = item.path|isExternalLink %} <li> {% if item.path %} - {% if !externalLink %} + {% if item.external %} <a href="{{ basePath }}/{{ item.path|contentLink }}">{{ item.title }}</a> {% else %} <a target="_blank" href="{{ item.path }}">{{ item.title }}</a> diff --git a/theme/templates/website/includes/summary.html b/theme/templates/website/includes/summary.html index ffe9f16..39f5295 100644 --- a/theme/templates/website/includes/summary.html +++ b/theme/templates/website/includes/summary.html @@ -1,9 +1,8 @@ {% macro articles(_articles) %} {% for item in _articles %} - {% set externalLink = item.path|isExternalLink %} - <li class="chapter {% if item.path == _input %}active{% endif %}" data-level="{{ item.level }}" {% if item.path and not externalLink %}data-path="{{ item.path|contentLink }}"{% endif %}> + <li class="chapter {% if item.path == _input %}active{% endif %}" data-level="{{ item.level }}" {% if item.path and not item.external %}data-path="{{ item.path|contentLink }}"{% endif %}> {% if item.path %} - {% if not externalLink %} + {% if not item.external %} <a href="{{ basePath }}/{{ item.path|contentLink }}"> <i class="fa fa-check"></i> {% if item.level != "0" %} |