mirror of
				https://github.com/BBaoVanC/bobatheme.git
				synced 2025-10-31 10:03:30 -05:00 
			
		
		
		
	
		
			
				
	
	
		
			103 lines
		
	
	
		
			2.9 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
			
		
		
	
	
			103 lines
		
	
	
		
			2.9 KiB
		
	
	
	
		
			HTML
		
	
	
	
	
	
| {{ define "main" }}
 | |
|     <div class="post-title">
 | |
|         <h1>
 | |
|             {{ .Title | markdownify }}
 | |
|             {{ if .Draft }}{{ partial "icon.html" "write" }}{{ end }}
 | |
|         </h1>
 | |
|     </div>
 | |
| 
 | |
|     {{ partial "post-metadata/full.html" . }}
 | |
| 
 | |
|     {{ with (.GetTerms "series") }}
 | |
|         {{ $series := slice }}
 | |
|         {{ range . }}
 | |
|             {{ $series = $series | append (printf `<a href="%s">%s</a>` .Permalink .LinkTitle) }}
 | |
|         {{ end }}
 | |
| 
 | |
|         <div class="series-box">
 | |
|             {{ partial "icon.html" "info" }}
 | |
|             {{ if gt (len $series) 1 }}
 | |
|                 This post is part of multiple series:
 | |
|             {{ else }}
 | |
|                 This post is part of a series:
 | |
|             {{ end }}
 | |
| 
 | |
|             {{ delimit $series ", " }}
 | |
|         </div>
 | |
|     {{ end }}
 | |
| 
 | |
| 
 | |
|     {{ if .Params.Toc }}
 | |
|         <div class="table-of-contents" aria-label="{{ i18n "aria_table_of_contents" }}">
 | |
|             <details>
 | |
|                 <summary>{{ i18n "table_of_contents" }}</summary>
 | |
|                 {{ .TableOfContents }}
 | |
|             </details>
 | |
|         </div>
 | |
|         <div class="table-of-contents print">
 | |
|             {{ i18n "table_of_contents" }}
 | |
|             {{ .TableOfContents }}
 | |
|         </div>
 | |
|     {{ end }}
 | |
| 
 | |
|     {{ with .Resources.GetMatch "feature" }}
 | |
|         <div class="post-media">
 | |
|             {{ partial "figure.html" (dict "src" . "border" true) }}
 | |
|         </div>
 | |
|     {{ end }}
 | |
| 
 | |
|     <div class="post-content">
 | |
|         {{ .Content }}
 | |
|     </div>
 | |
| 
 | |
|     {{ $related := .Site.RegularPages.Related . | first 10 }}
 | |
|     {{ with $related }}
 | |
|         <div class="related">
 | |
|             <hr>
 | |
|             <h2>{{ i18n "related_posts" }}</h2>
 | |
|             <div class="related-posts">
 | |
|                 {{ range . }}
 | |
|                     {{ .Render "summary/post" }}
 | |
|                 {{ end }}
 | |
|             </div>
 | |
|             <hr>
 | |
|         </div>
 | |
|     {{ end }}
 | |
| 
 | |
|     {{ if or .NextInSection .PrevInSection }}
 | |
|         <div class="prevnext">
 | |
|             {{ with .NextInSection }}
 | |
|                 <a class="prev" href="{{ .Permalink }}">
 | |
|                     <div class="prev-caption">
 | |
|                         ← {{ i18n "newer_post" }}
 | |
|                     </div>
 | |
|                     <div class="prev-post">
 | |
|                         {{ .Title | markdownify }}
 | |
|                     </div>
 | |
|                 </a>
 | |
|             {{ else }}
 | |
|                 <div class="prev"></div>
 | |
|             {{ end }}
 | |
| 
 | |
|             {{ with .PrevInSection }}
 | |
|                 <a class="next" href="{{ .Permalink }}">
 | |
|                     <div class="next-caption">
 | |
|                         {{ i18n "older_post" }} →
 | |
|                     </div>
 | |
|                     <div class="next-post">
 | |
|                         {{ .Title | markdownify }}
 | |
|                     </div>
 | |
|                 </a>
 | |
|             {{ else }}
 | |
|                 <div class="next"></div>
 | |
|             {{ end }}
 | |
|         </div>
 | |
|     {{ end }}
 | |
| 
 | |
|     {{ if .Params.comments }}
 | |
|         <div class="comments">
 | |
|             {{ partial "comments.html" . }}
 | |
|         </div>
 | |
|     {{ end }}
 | |
| {{ end }}
 |