diff options
Diffstat (limited to 'templates/includes')
-rw-r--r-- | templates/includes/book/footer.html | 15 | ||||
-rw-r--r-- | templates/includes/book/progress.html | 10 |
2 files changed, 25 insertions, 0 deletions
diff --git a/templates/includes/book/footer.html b/templates/includes/book/footer.html new file mode 100644 index 0000000..48f4bf9 --- /dev/null +++ b/templates/includes/book/footer.html @@ -0,0 +1,15 @@ +<div class="page-footer"> + {% if _input == "README.md" %} + <a href="{{ basePath }}/{{ progress.current.next.path }}" class="navigation-link">Start</a> + {% else %} + {% if progress.current.next %} + {% if progress.current.next.path %} + <a href="{{ basePath }}/{{ progress.current.next.path }}" class="navigation-link next">Next</a> + {% else %} + <div class="navigation-link coming-soon">Coming soon</div> + {% endif %} + {% else %} + <div class="navigation-link finished">Finished!</div> + {% endif %} + {% endif %} +</div>
\ No newline at end of file diff --git a/templates/includes/book/progress.html b/templates/includes/book/progress.html new file mode 100644 index 0000000..d0e3193 --- /dev/null +++ b/templates/includes/book/progress.html @@ -0,0 +1,10 @@ +<div class="book-progress"> + <div class="bar"> + <div class="inner" style="width: {{ progress.percent }}%;min-width: {{ progress.prevPercent }}%;"></div> + </div> + <div class="chapters"> + {% for p in progress.chapters %} + <a href="{{ basePath }}/{{ p.path }}" title="{{ p.title }}" class="chapter {% if p.done %}done{% endif %} {% if p.level.length == 1 %}new-chapter{% endif %}" data-progress="{{ p.level }}" style="left: {{ p.percent }}%;"></a> + {% endfor %} + </div> +</div>
\ No newline at end of file |