single.html 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. {{ partial "header.html" . }}
  2. <link rel="stylesheet"
  3. href="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@9.16.2/build/styles/github.min.css">
  4. <script src="//cdn.jsdelivr.net/gh/highlightjs/cdn-release@9.16.2/build/highlight.min.js"></script>
  5. <script>hljs.initHighlightingOnLoad();</script>
  6. <div class="main-container blog-article">
  7. <section>
  8. <div class="container">
  9. <div class="row justify-content-center">
  10. <div class="col-md-12 col-lg-12">
  11. <article>
  12. <div class="article__title text-center">
  13. <h1 class="h2">{{ .Title }}</h1>
  14. {{ $pub := .Date.Format "02 January 2006" }}
  15. {{ $last := .Lastmod.Format "02 January 2006" }}
  16. <span>Published on {{ $pub }} in</span>
  17. <span>
  18. {{ $categories := .Params.categories }}
  19. {{ range $index, $element := $categories }}
  20. <a href="{{ "/categories/" | relLangURL }}{{ $element | urlize }}">{{ $element }}</a>
  21. {{ if (ne (add $index 1) (len $categories)) }}
  22. /
  23. {{ end }}
  24. {{ end }}
  25. </span>
  26. {{ $read := .ReadingTime }}
  27. - <span>{{ .ReadingTime }} minute{{ if gt $read 1 }}s{{ end }} read</span>
  28. {{ if and (ne $pub $last) (.Lastmod.After .Date) }}
  29. <span> - Last modified on {{ $last }}</span>
  30. {{ end }}
  31. {{ if .IsTranslated }}
  32. - <span>Read in
  33. {{ range .Translations }}
  34. <a href="{{ .Permalink }}">{{ .Lang }}</a>
  35. {{ end }}
  36. </span>
  37. {{ end }}
  38. </div>
  39. <!--end article title-->
  40. <div class="article__body">
  41. {{ .Content }}
  42. </div>
  43. <div class="article__share text-center">
  44. <a class="btn bg--facebook btn--icon" href="#">
  45. <span class="btn__text">
  46. <i class="socicon socicon-facebook"></i>
  47. Share on Facebook
  48. </span>
  49. </a>
  50. <a class="btn bg--twitter btn--icon" href="#">
  51. <span class="btn__text">
  52. <i class="socicon socicon-twitter"></i>
  53. Share on Twitter
  54. </span>
  55. </a>
  56. </div>
  57. </article>
  58. <!--end item-->
  59. </div>
  60. </div>
  61. <!--end of row-->
  62. </div>
  63. <!--end of container-->
  64. </section>
  65. <section class="space--sm">
  66. <div class="container">
  67. <div class="row">
  68. <div class="col-md-12">
  69. <hr>
  70. </div>
  71. </div>
  72. <!--end of row-->
  73. </div>
  74. <!--end of container-->
  75. </section>
  76. <section>
  77. <div class="container">
  78. <div class="row justify-content-center">
  79. <div class="col-md-12 col-lg-12">
  80. <div class="comments">
  81. {{ template "_internal/disqus.html" . }}
  82. </div>
  83. <!--end comments-->
  84. <!-- <div class="comments-form">
  85. <h4>Leave a comment</h4>
  86. <form class="row">
  87. <div class="col-md-6">
  88. <label>Your Name:</label>
  89. <input type="text" name="Name" placeholder="Type name here" />
  90. </div>
  91. <div class="col-md-6">
  92. <label>Email Address:</label>
  93. <input type="email" name="email" placeholder="you@mailprovider.com" />
  94. </div>
  95. <div class="col-md-12">
  96. <label>Comment:</label>
  97. <textarea rows="4" name="Message" placeholder="Message"></textarea>
  98. </div>
  99. <div class="col-md-3">
  100. <button class="btn btn--primary" type="submit">Submit Comment</button>
  101. </div>
  102. </form>
  103. </div> -->
  104. </div>
  105. </div>
  106. <!--end of row-->
  107. </div>
  108. <!--end of container-->
  109. </section>
  110. {{ partial "latest.html" . }}
  111. </div>
  112. {{ partial "footer.html" . }}