diff options
author | Samy Pessé <samypesse@gmail.com> | 2015-03-11 22:02:46 +0100 |
---|---|---|
committer | Samy Pessé <samypesse@gmail.com> | 2015-03-11 22:02:46 +0100 |
commit | 50bc89d9d9653113d8fd2965094c68cb10b8529b (patch) | |
tree | dfde2a00e5686a9235c3d808c8d1515264475580 | |
parent | 743a88f53af9a0a2a5d9d601b91f59ddafd48144 (diff) | |
download | gitbook-50bc89d9d9653113d8fd2965094c68cb10b8529b.zip gitbook-50bc89d9d9653113d8fd2965094c68cb10b8529b.tar.gz gitbook-50bc89d9d9653113d8fd2965094c68cb10b8529b.tar.bz2 |
Fix define of introduction from summary
-rw-r--r-- | lib/book.js | 1 | ||||
-rw-r--r-- | package.json | 2 | ||||
-rw-r--r-- | theme/templates/website/includes/summary.html | 2 |
3 files changed, 3 insertions, 2 deletions
diff --git a/lib/book.js b/lib/book.js index aee425c..04b4969 100644 --- a/lib/book.js +++ b/lib/book.js @@ -420,6 +420,7 @@ Book.prototype.parseSummary = function() { .then(function(content) { return summary.parser.summary(content, { entryPoint: that.readmeFile, + entryPointTitle: "", files: that.files }); }); diff --git a/package.json b/package.json index 66a3b58..a27402f 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,7 @@ "resolve": "0.6.3", "fs-extra": "0.16.5", "fstream-ignore": "1.0.2", - "gitbook-parsers": "0.5.2", + "gitbook-parsers": "0.5.3", "nunjucks": "git+https://github.com/mozilla/nunjucks.git#0f8b21b8df7e8e852b2e1889388653b7075f0d09", "nunjucks-autoescape": "0.1.1", "nunjucks-filter": "0.1.0", diff --git a/theme/templates/website/includes/summary.html b/theme/templates/website/includes/summary.html index 6aa523b..9b9de32 100644 --- a/theme/templates/website/includes/summary.html +++ b/theme/templates/website/includes/summary.html @@ -8,7 +8,7 @@ {% if item.level != "0" %} <b>{{ item.level }}.</b> {% endif %} - {% if item.introduction %}{% i18n "SUMMARY_INTRODUCTION" %}Introduction{% endi18n %}{% else %}{{ item.title }}{% endif %} + {% if item.introduction and not item.title %}{% i18n "SUMMARY_INTRODUCTION" %}Introduction{% endi18n %}{% else %}{{ item.title }}{% endif %} </a> {% else %} <a target="_blank" href="{{ item.path }}"> |