mirror of
https://github.com/msfjarvis/msfjarvis.dev.git
synced 2024-06-03 04:18:56 +05:30
46 lines
1.6 KiB
HTML
46 lines
1.6 KiB
HTML
{{ define "styles" }}
|
|
{{ $.Scratch.Set "style_opts" (dict "src" "scss/pages/post.scss" "dest" "css/post.css") }}
|
|
{{ end }}
|
|
|
|
{{ define "main" }}
|
|
{{ $dateFormat := .Site.Params.dateFormat | default "Jan 2 2006" }}
|
|
|
|
<div class="flex-wrapper">
|
|
<div class="post__container">
|
|
<div class="post">
|
|
<header class="post__header">
|
|
<h1 id="post__title">{{.Title}}</h1>
|
|
<time datetime="{{ .Date }}" class="post__date"
|
|
>{{ .Date.Format $dateFormat }}</time>
|
|
</header>
|
|
<article class="post__content">
|
|
{{ partial "anchored-headings.html" .Content }}
|
|
{{ if or .Params.math .Site.Params.math }}
|
|
{{ partial "math.html" . }}
|
|
{{ end }}
|
|
</article>
|
|
{{ partial "tags.html" .}} {{ partial "post-pagination.html" .}}
|
|
{{ template "_internal/disqus.html" . }}
|
|
<footer class="post__footer">
|
|
{{ partial "social-icons.html" .}}
|
|
<p>{{ replace .Site.Copyright "{year}" now.Year }}</p>
|
|
</footer>
|
|
</div>
|
|
</div>
|
|
{{ if or .Params.toc .Site.Params.toc }}
|
|
<div class="toc-container">
|
|
{{ if .Site.Params.showPageTitleInTOC }} <div class="toc-post-title">{{ .Title }}</div> {{ end }}
|
|
{{ .TableOfContents }}
|
|
</div>
|
|
{{ end }}
|
|
</div>
|
|
|
|
{{ end }}
|
|
|
|
{{ define "scripts" }}
|
|
{{ if or .Params.toc .Site.Params.toc }}
|
|
<script src="/js/table-of-contents.js"></script>
|
|
{{ end }}
|
|
<script src="https://unpkg.com/prismjs@^1.2"></script>
|
|
{{ end }}
|