post.html 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. ---
  2. layout: base
  3. ---
  4. {% include header.html type="post" %}
  5. <div class="container-md">
  6. <div class="row">
  7. <div class="col-xl-8 offset-xl-2 col-lg-10 offset-lg-1">
  8. {% if page.gh-repo %}
  9. {% assign gh_split = page.gh-repo | split:'/' %}
  10. {% assign gh_user = gh_split[0] %}
  11. {% assign gh_repo = gh_split[1] %}
  12. <div id="header-gh-btns">
  13. {% if page.gh-badge.size > 0 %}
  14. {% for badge in page.gh-badge %}
  15. {% case badge %}
  16. {% when 'star'%}
  17. <iframe src="https://ghbtns.com/github-btn.html?user={{ gh_user }}&repo={{ gh_repo }}&type=star&count=true" frameborder="0" scrolling="0" width="120px" height="20px"></iframe>
  18. {% when 'watch'%}
  19. <iframe src="https://ghbtns.com/github-btn.html?user={{ gh_user }}&repo={{ gh_repo }}&type=watch&v=2&count=true" frameborder="0" scrolling="0" width="120px" height="20px"></iframe>
  20. {% when 'fork'%}
  21. <iframe src="https://ghbtns.com/github-btn.html?user={{ gh_user }}&repo={{ gh_repo }}&type=fork&count=true" frameborder="0" scrolling="0" width="120px" height="20px"></iframe>
  22. {% when 'follow'%}
  23. <iframe src="https://ghbtns.com/github-btn.html?user={{ gh_user }}&type=follow&count=true" frameborder="0" scrolling="0" width="220px" height="20px"></iframe>
  24. {% endcase %}
  25. {% endfor %}
  26. {% endif %}
  27. </div>
  28. {% endif %}
  29. <article role="main" class="blog-post">
  30. {{ content }}
  31. </article>
  32. {% if page.tags.size > 0 %}
  33. <div class="blog-tags">
  34. Tags:
  35. {% if site.link-tags %}
  36. {% for tag in page.tags %}
  37. <a href="{{ '/tags' | relative_url }}#{{- tag -}}">{{- tag -}}</a>
  38. {% endfor %}
  39. {% else %}
  40. {{ page.tags | join: ", " }}
  41. {% endif %}
  42. </div>
  43. {% endif %}
  44. {% if page.social-share %}
  45. {% include social-share.html %}
  46. {% endif %}
  47. <ul class="pagination blog-pager">
  48. {% if page.previous.url %}
  49. <li class="page-item previous">
  50. <a class="page-link" href="{{ page.previous.url | relative_url }}" data-toggle="tooltip" data-placement="top" title="{{page.previous.title}}">&larr; Previous Post</a>
  51. </li>
  52. {% endif %}
  53. {% if page.next.url %}
  54. <li class="page-item next">
  55. <a class="page-link" href="{{ page.next.url | relative_url }}" data-toggle="tooltip" data-placement="top" title="{{page.next.title}}">Next Post &rarr;</a>
  56. </li>
  57. {% endif %}
  58. </ul>
  59. {% include comments.html %}
  60. </div>
  61. </div>
  62. </div>