Add a page and layout for nethack
This commit is contained in:
		
							parent
							
								
									16d5d9bee9
								
							
						
					
					
						commit
						942f04e68f
					
				
					 2 changed files with 37 additions and 0 deletions
				
			
		
							
								
								
									
										6
									
								
								content/nethack/index.md
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								content/nethack/index.md
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,6 @@
 | 
			
		|||
---
 | 
			
		||||
title: "Nethack"
 | 
			
		||||
date: 2022-04-13T08:43:46-07:00
 | 
			
		||||
draft: true
 | 
			
		||||
---
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										31
									
								
								layouts/nethack/single.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										31
									
								
								layouts/nethack/single.html
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,31 @@
 | 
			
		|||
{{ define "main" }}
 | 
			
		||||
<article class="post-single">
 | 
			
		||||
  <header>
 | 
			
		||||
    <div class="post-title">
 | 
			
		||||
      <h1>{{ .Title }}</h1>
 | 
			
		||||
      <div class="post-date"><time>{{ .Date | time.Format "Jan 2, 2006" }}</time></div>
 | 
			
		||||
    </div>
 | 
			
		||||
  </header>
 | 
			
		||||
  <section class="post-content">
 | 
			
		||||
    {{ .Content }}
 | 
			
		||||
  </section>
 | 
			
		||||
 | 
			
		||||
  {{ if .Params.tags }}
 | 
			
		||||
  <footer>
 | 
			
		||||
    <ul class="post-tags">
 | 
			
		||||
    {{ range .Params.tags }} {{ $href := print (absURL "tags/") (urlize .) }}
 | 
			
		||||
      <li><a href="{{ $href }}">{{ . }}</a></li>
 | 
			
		||||
    {{ end }}
 | 
			
		||||
    </ul>
 | 
			
		||||
  </footer>
 | 
			
		||||
  {{ end }}
 | 
			
		||||
 | 
			
		||||
  {{ $pages := where site.RegularPages "Type" "in" site.Params.mainSections }}
 | 
			
		||||
  {{ if and (gt (len $pages) 1) (in $pages . ) }}
 | 
			
		||||
  <nav class="post-nav">
 | 
			
		||||
    {{ with $pages.Next . }}<a class="prev" href="{{ .Permalink }}"><span>←</span><span>{{ .Name }}</span></a>{{ end }}
 | 
			
		||||
    {{ with $pages.Prev . }}<a class="next" href="{{ .Permalink }}"><span>{{ .Name }}</span><span>→</span></a>{{ end }}
 | 
			
		||||
  </nav>
 | 
			
		||||
  {{ end }}
 | 
			
		||||
</article>
 | 
			
		||||
{{ end }}
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue