forked from eddiesigner/liebling
-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.hbs
110 lines (90 loc) · 3.53 KB
/
default.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
<!DOCTYPE html>
<html lang="{{@site.locale}}">
<head>
{{!-- Document Settings --}}
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
{{!-- Base Meta --}}
<title>{{meta_title}}</title>
<meta name="HandheldFriendly" content="True" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
{{!-- Preload assets --}}
<link rel="preload" href="{{asset "css/app.css"}}" as="style" />
<link rel="preload" href="{{asset "js/manifest.js"}}" as="script" />
<link rel="preload" href="{{asset "js/vendor.js"}}" as="script" />
<link rel="preload" href="{{asset "js/app.js"}}" as="script" />
{{!-- This #block helper will try to preload page-specific assets --}}
{{{block "preload"}}}
{{!-- styles / scripts --}}
<link rel="stylesheet" type="text/css" href="{{asset "css/app.css"}}" media="screen" />
{{!-- fonts / icons --}}
<link rel="stylesheet" href="https://use.typekit.net/eyj8xkd.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/iconoir-icons/iconoir@main/css/iconoir.css" />
{{!-- This #block helper will inject a stylesheet for a specific page --}}
{{{block "styles"}}}
{{!-- This #block helper will pull data from the hero partial
to inject styles of the hero image to make it responsive --}}
{{{block "herobackground"}}}
{{!-- This tag outputs SEO meta+structured data and other important settings --}}
{{ghost_head}}
{{!-- This style overrides the accent color to match the one from the Admin --}}
<style>
:root {
--primary-subtle-color: var(--ghost-accent-color) !important;
}
</style>
{{!-- These variables are used to make the search form work --}}
<script>
// @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt Expat
const ghostHost = "{{@site.url}}"
// @license-end
</script>
{{#if @custom.enable_native_search}}
<script>
const nativeSearchEnabled = true
</script>
{{/if}}
{{#if @custom.search_api_key}}
<script>
const ghostSearchApiKey = "{{@custom.search_api_key}}"
</script>
{{/if}}
{{!-- This variable disbale the fade animation when it's enabled --}}
{{#if @custom.disable_fade_animation}}
<style>
:root {
--show-fade-animation: 0;
}
</style>
{{/if}}
{{!-- This script sets the correct theme mode (light or dark) --}}
<script>
if (typeof Storage !== 'undefined') {
const currentSavedTheme = localStorage.getItem('theme')
if (currentSavedTheme && currentSavedTheme === 'dark') {
document.documentElement.setAttribute('data-theme', 'dark')
} else {
document.documentElement.setAttribute('data-theme', 'light')
}
}
</script>
</head>
<body class="{{body_class}}">
{{!-- All the main content gets inserted here, index.hbs, post.hbs, etc --}}
{{{body}}}
{{!-- Search form --}}
{{^if @custom.enable_native_search}}
{{> search}}
{{/if}}
{{!-- The footer --}}
{{> footer}}
{{!-- Common scripts shared between pages --}}
<script defer src="{{asset "js/manifest.js"}}"></script>
<script defer src="{{asset "js/vendor.js"}}"></script>
<script defer src="{{asset "js/app.js"}}"></script>
{{!-- The #block helper will pull in data from the #contentFor other template files --}}
{{{block "scripts"}}}
{{!-- Ghost outputs important scripts and data with this tag --}}
{{ghost_foot}}
</body>
</html>