|
1 | 1 | <!DOCTYPE html> |
2 | 2 | <html lang="{{- site.Language -}}"> |
3 | 3 | <head> |
4 | | - {{- block "head" . -}} |
5 | | - {{- partial "head/base.html" . -}} |
6 | | - {{- block "styles" . -}} |
7 | | - {{- partial "head/style.html" . -}} |
8 | | - {{- end -}} |
9 | | - {{- end -}} |
10 | | - |
| 4 | + {{- partial "head/base.html" . -}} |
| 5 | + {{- partial "head/style.html" . -}} |
11 | 6 | {{- if templates.Exists "partials/extend_head.html" -}} |
12 | 7 | {{- partial "extend_head.html" . -}} |
13 | 8 | {{- end -}} |
14 | 9 | </head> |
15 | 10 |
|
16 | 11 | <body> |
17 | | - {{- block "container" . -}} |
18 | | - {{- $container := "container" -}} |
19 | | - {{- if site.Params.fullWidthTheme -}} |
20 | | - {{- $container = print $container " full" -}} |
21 | | - {{- else if site.Params.centerTheme -}} |
22 | | - {{- $container = print $container " center" -}} |
23 | | - {{- end -}} |
24 | | - |
25 | | - |
26 | | - <div class="theme-container"> |
27 | | - {{- /* container */}} |
28 | | - <div class="{{- $container -}}"> |
29 | | - {{- /* site header */}} |
30 | | - <header class="site-header"> |
31 | | - {{- block "header" . -}} |
32 | | - {{- partial "header.html" . -}} |
33 | | - {{- end -}} |
34 | | - </header> |
35 | | - |
36 | | - {{- /* site main */}} |
37 | | - <main class="site-main"> |
38 | | - {{- block "main" . -}} |
39 | | - {{ if .Title -}} |
40 | | - <h1 class="post-title">{{ .Title | plainify }}</h1> |
41 | | - {{- end -}} |
| 12 | + {{- $container := "container" -}} |
| 13 | + {{- if site.Params.fullWidthTheme -}} |
| 14 | + {{- $container = print $container " full" -}} |
| 15 | + {{- else if site.Params.centerTheme -}} |
| 16 | + {{- $container = print $container " center" -}} |
| 17 | + {{- end -}} |
42 | 18 |
|
43 | | - {{- /* site main content */}} |
44 | | - {{ .Content }} |
| 19 | + {{- /* theme container */}} |
| 20 | + <div class="theme-container"> |
| 21 | + {{- /* container */}} |
| 22 | + <div class="{{- $container -}}"> |
| 23 | + {{- /* site header */}} |
| 24 | + <header class="site-header"> |
| 25 | + {{- block "header" . -}} |
| 26 | + {{- partial "header.html" . -}} |
| 27 | + {{- end -}} |
| 28 | + </header> |
| 29 | + |
| 30 | + {{- /* site main */}} |
| 31 | + <main class="site-main"> |
| 32 | + {{- block "main" . -}} |
| 33 | + {{ if .Title -}} |
| 34 | + <h1 class="post-title">{{ .Title | plainify }}</h1> |
45 | 35 | {{- end -}} |
46 | | - {{- /* end main content */}} |
47 | | - </main> |
48 | 36 |
|
49 | | - {{- /* site footer */}} |
50 | | - <footer class="site-footer"> |
51 | | - {{- block "footer" . -}} |
52 | | - {{- partial "footer.html" . -}} |
53 | | - {{- end -}} |
54 | | - </footer> |
55 | | - </div> |
| 37 | + {{- /* site main content */}} |
| 38 | + {{ .Content }} |
| 39 | + {{- end -}} |
| 40 | + {{- /* end main content */}} |
| 41 | + </main> |
| 42 | + |
| 43 | + {{- /* site footer */}} |
| 44 | + <footer class="site-footer"> |
| 45 | + {{- block "footer" . -}} |
| 46 | + {{- partial "footer.html" . -}} |
| 47 | + {{- end -}} |
| 48 | + </footer> |
56 | 49 | </div> |
57 | | - {{- end -}} |
58 | | - |
59 | | - {{- block "scripts" . -}} |
60 | | - {{- $copy := resources.Get "scripts/copy.js" | js.Build -}} |
61 | | - {{- $menu := resources.Get "scripts/menu.js" | js.Build -}} |
62 | | - {{- $print := resources.Get "scripts/print.js" | js.Build -}} |
63 | | - {{- $theme := resources.Get "scripts/theme.js" | js.Build -}} |
64 | | - {{- $bundle := slice $menu $theme $copy $print | resources.Concat "bundle.js" -}} |
65 | | - {{- if hugo.IsProduction -}} |
66 | | - {{- $bundle = $bundle | resources.Minify -}} |
67 | | - {{- end -}} |
68 | | - <script type="text/javascript" src="{{ $bundle.RelPermalink }}"></script> |
69 | | - {{- end -}} |
| 50 | + </div> |
70 | 51 |
|
| 52 | + {{- partial "scripts/base.html" . -}} |
71 | 53 | {{- if templates.Exists "partials/extend_footer.html" -}} |
72 | 54 | {{- partial "extend_footer.html" . -}} |
73 | 55 | {{- end -}} |
|
0 commit comments