This commit is contained in:
parent
15699af640
commit
ab7e9c9ed2
@ -1,10 +1,48 @@
|
||||
{{- define "baseof" -}}
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<html lang="{{ .Site.LanguageCode | default "en-US" }}">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>{{ .Title }}</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
{{ partial "favicon.html" . }}
|
||||
<title>{{ block "title" . }}{{ .Title }} | {{ .Site.Title }}{{ end }}</title>
|
||||
{{ partial "seo_tags.html" . }}
|
||||
|
||||
<!-- Load Theme Styles -->
|
||||
{{ $style := print (default "original" .Site.Params.themeStyle) ".css" | resources.Get | minify }}
|
||||
<link href="{{ $style.RelPermalink }}" rel="stylesheet">
|
||||
|
||||
{{ if (.Page.Store.Get "hasCodeBlock") }}
|
||||
{{ $syntax := resources.Get "syntax.css" | minify }}
|
||||
<link href="{{ $syntax.RelPermalink }}" rel="stylesheet">
|
||||
{{ end }}
|
||||
|
||||
{{ with .Params.style }}
|
||||
{{ $extra := resources.Get . | minify }}
|
||||
<link href="{{ $extra.RelPermalink }}" rel="stylesheet">
|
||||
{{ end }}
|
||||
|
||||
</head>
|
||||
<body>
|
||||
{{ block "main" . }}{{ end }}
|
||||
|
||||
<!-- Site Container -->
|
||||
<div class="container">
|
||||
|
||||
<!-- Site Header (Reuses Bearcub's Partial) -->
|
||||
{{ partial "header.html" . }}
|
||||
|
||||
<!-- Main Content Block (Where Custom Pages Inject Content) -->
|
||||
<main class="content">
|
||||
{{ block "main" . }}{{ end }}
|
||||
</main>
|
||||
|
||||
<!-- Footer (Reuses Bearcub's Partial) -->
|
||||
{{ partial "footer.html" . }}
|
||||
</div>
|
||||
|
||||
<!-- Load Scripts -->
|
||||
{{ partial "scripts.html" . }}
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
{{- end -}}
|
||||
|
||||
@ -1,4 +1,22 @@
|
||||
{{ define "main" }}
|
||||
<h1>{{ .Title }}</h1>
|
||||
{{ .Content }}
|
||||
{{ end }}
|
||||
<section class="post-list">
|
||||
<header>
|
||||
<h1>{{ .Title }}</h1>
|
||||
{{ with .Content }}
|
||||
<p>{{ . }}</p>
|
||||
{{ end }}
|
||||
</header>
|
||||
|
||||
<ul class="posts">
|
||||
{{ range .Pages }}
|
||||
<li class="post-item">
|
||||
<h2><a href="{{ .RelPermalink }}">{{ .Title }}</a></h2>
|
||||
<p class="post-meta">{{ .Date.Format "January 2, 2006" }}</p>
|
||||
{{ with .Summary }}
|
||||
<p>{{ . }} <a href="{{ .RelPermalink }}">Read more...</a></p>
|
||||
{{ end }}
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</section>
|
||||
{{ end }}
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
<header class="post-header">
|
||||
<h1>{{ .Title }}</h1>
|
||||
<p class="post-meta">
|
||||
{{ .Date.Format "January 2, 2006" }} |
|
||||
{{ .Date.Format "January 2, 2006" }} |
|
||||
{{ if .Params.author }}By {{ .Params.author }}{{ end }}
|
||||
</p>
|
||||
</header>
|
||||
|
||||
@ -5,11 +5,6 @@
|
||||
<a href="/blog/" class="button">Read the Blog</a>
|
||||
</section>
|
||||
|
||||
<section class="about">
|
||||
<h2>About Me</h2>
|
||||
<p>A short introduction about yourself or your website.</p>
|
||||
</section>
|
||||
|
||||
<section class="latest-posts">
|
||||
<h2>Latest Blog Posts</h2>
|
||||
<ul>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user