forked from akkuman/ink-theme-story
-
Notifications
You must be signed in to change notification settings - Fork 0
/
_head.html
81 lines (77 loc) · 3.21 KB
/
_head.html
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
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta http-equiv="Cache-Control" content="no-siteapp">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=1, minimum-scale=1, maximum-scale=1">
<meta name="renderer" content="webkit">
<meta name="google" value="notranslate">
<meta name="robots" content="index,follow">
<!-- Twitter -->
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="{{.Site.Title}}">
<meta name="twitter:description" content="{{.Site.Subtitle}}">
<meta name="twitter:image:src" content="{{.Site.Url}}{{.Site.Logo}}">
<!-- Facebook -->
<meta property="og:url" content="{{.Site.Url}}">
<meta property="og:title" content="{{.Site.Title}}">
<meta property="og:description" content="{{.Site.Subtitle}}">
<meta property="og:site_name" content="{{.Site.Title}}">
<meta property="og:image" content="{{.Site.Url}}{{.Site.Logo}}">
<meta property="og:type" content="website">
<meta name="robots" content="noodp">
<!-- Google Plus -->
<meta itemprop="name" content="{{.Site.Title}}">
<meta itemprop="description" content="{{.Site.Subtitle}}">
<meta itemprop="image" content="{{.Site.Url}}{{.Site.Logo}}">
<!-- Canonical URL -->
<link rel="canonical" href="{{.Site.Url}}">
<link rel="shortcut icon" href="{{.Site.Root}}/favicon.png">
<link rel="apple-itouch-icon" href="{{.Site.Root}}/favicon.png">
<!--
<link rel="stylesheet" href="{{.Site.Root}}/bundle/index.css">
-->
<link type="text/css" rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/4.0.0/css/bootstrap.min.css">
<link type="text/css" rel="stylesheet" href="{{.Site.Root}}/bundle/css/prism.css">
<link type="text/css" rel="stylesheet" href="{{.Site.Root}}/bundle/css/zoom.css">
<link type="text/css" rel="stylesheet" href="{{.Site.Root}}/bundle/css/main.css">
<script src="https://cdn.bootcss.com/jquery/2.2.4/jquery.min.js"></script>
<!--[if lt IE 9]>
<script src="http://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
<script src="http://cdn.staticfile.org/respond.js/1.3.0/respond.min.js"></script>
<![endif]-->
<!-- cPlayer Start -->
<script>var cPlayers = [];var cPlayerOptions = [];</script>
<!-- cPlayer End -->
<script type="text/javascript">
var timeSinceLang = {
year: '{{i18n "since_year"}}',
month: '{{i18n "since_month"}}',
day: '{{i18n "since_day"}}',
hour: '{{i18n "since_hour"}}',
minute: '{{i18n "since_minute"}}',
second: '{{i18n "since_second"}}'
};
var root = '{{.Site.Root}}';
</script>
{{if .Develop}}
<script type="text/javascript">
var conn, reloadTimer, connectTimer;
var connect = function() {
conn = new WebSocket('ws://' + location.host + '/live');
conn.onmessage = function(event) {
if (event.data === 'change') {
if (reloadTimer) clearTimeout(reloadTimer);
reloadTimer = setTimeout(function() {
window.location.reload();
}, 200);
}
};
conn.onclose = function() {
if (connectTimer) clearTimeout(connectTimer);
connectTimer = setTimeout(function() {
connect();
}, 1000);
};
};
connect();
</script>
{{end}}