-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.pug
68 lines (53 loc) · 2.49 KB
/
index.pug
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
doctype html
html(lang='en')
head
meta(charset="UTF-8")
meta(name="format-detection" content="telephone=no")
meta(name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes, shrink-to-fit=no")
-setting = setting || {}
-keywords = setting.keywords
-description = setting.description
-author = setting.author
-title = setting.title
if keywords
meta(name="keywords" content=`${keywords}`)
if description
meta(name="description" content=`${description}`)
if author
meta(name="author" content=`${author}`)
meta(name= "robots" content="index,follow")
meta(http-equiv="x-dns-prefetch-control" content="on")
meta(http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1")
meta(name="renderer" content="webkit")
link(rel="shortcut icon" href=favicon ? `${favicon}` : '/favicon.ico' type="image/x-icon")
link(rel="stylesheet" href=hljscss)
each code in codes
if code.language == 'js' || code.language == 'javascript'
script ;(function(window){!{code.content}})(window);
if code.language == 'css' || code.language == 'style'
style !{code.content}
title= title
body
.content-wrapper
aside
.aside-wrapper
each side,key in sides
.catalog-section
h5 !{key}
each nav in side
ul
mixin sub-catalogs(list)
li
if list.title
a(href=list.path?list.path:false class=list.level?`lavel${list.level}`:false) !{list.title}
if list.children&&list.children.length
ul.sub-catalogs
each item,index in list.children
+sub-catalogs(item)
+sub-catalogs(nav)
div(class="aside-border transition")
article
.article-head
.title !{title}
.article-content
div !{contents}