book_layout.html 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. {{ $current_page := . }}
  2. {{/* Check whether to show breadcrumb navigation. */}}
  3. {{ $show_breadcrumb := .Params.show_breadcrumb }}
  4. <div class="container-fluid docs">
  5. <div class="row flex-xl-nowrap">
  6. <div class="col-12 col-md-3 col-xl-2 docs-sidebar">
  7. {{ partial "book_sidebar" . }}
  8. </div>
  9. {{/* Show ToC by default. */}}
  10. {{ if ne .Params.toc false }}
  11. <div class="d-none d-xl-block col-xl-2 docs-toc">
  12. {{ partial "hooks/page_toc_start" . }}
  13. <ul class="nav toc-top">
  14. <li><a href="#" id="back_to_top" class="docs-toc-title">{{ i18n "on_this_page" }}</a></li>
  15. </ul>
  16. {{ .TableOfContents }}
  17. {{ partial "hooks/page_toc_end" . }}
  18. </div>
  19. {{ end }}
  20. <main class="col-12 col-md-9 col-xl-8 py-md-3 pl-md-5 docs-content" role="main">
  21. <article class="article">
  22. <div class="docs-article-container">
  23. {{ if $show_breadcrumb }}
  24. {{ partial "components/breadcrumb" $current_page }}
  25. {{ end }}
  26. <h1>{{ .Title }}</h1>
  27. <div class="article-style">
  28. {{ .Content }}
  29. </div>
  30. {{ partial "tags.html" . }}
  31. {{/* Show next/previous pages by default. */}}
  32. {{ if ne site.Params.book_section_pager false }}
  33. <div class="article-widget">
  34. {{ partial "section_pager" . }}
  35. </div>
  36. {{ end }}
  37. </div>
  38. <div class="body-footer">
  39. <p>{{ i18n "last_updated" }} {{ $.Lastmod | time.Format site.Params.locale.date_format }}</p>
  40. {{ partial "page_edit" . }}
  41. {{ partial "comments" . }}
  42. {{ partial "page_related" . }}
  43. </div>
  44. </article>
  45. {{ partial "site_footer" . }}
  46. </main>
  47. </div>
  48. </div>