databook-theme 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.txt +21 -21
  3. data/README.MD +1 -1
  4. data/_includes/blog/blog.liquid +50 -50
  5. data/_includes/blog/features.liquid +36 -36
  6. data/_includes/blog/full.liquid +3 -3
  7. data/_includes/blog/list.liquid +41 -41
  8. data/_includes/blog/post.liquid +6 -6
  9. data/_includes/components/analytics.google.liquid +11 -11
  10. data/_includes/components/analytics.liquid +11 -11
  11. data/_includes/components/comments.disqus.liquid +17 -17
  12. data/_includes/components/comments.gitalk.liquid +22 -22
  13. data/_includes/components/comments.liquid +13 -13
  14. data/_includes/components/navmenu.items.liquid +51 -51
  15. data/_includes/components/navmenu.liquid +4 -4
  16. data/_includes/components/pagination.liquid +83 -83
  17. data/_includes/components/prevnext.liquid +1 -1
  18. data/_includes/components/search.baidu.liquid +7 -7
  19. data/_includes/components/search.bing.liquid +6 -6
  20. data/_includes/components/search.google.liquid +6 -6
  21. data/_includes/components/search.liquid +21 -21
  22. data/_includes/components/social_button.liquid +9 -9
  23. data/_includes/components/social_link.liquid +14 -14
  24. data/_includes/components/title.liquid +41 -41
  25. data/_includes/components/toc.liquid +28 -28
  26. data/_includes/custom/analytics.liquid +3 -3
  27. data/_includes/custom/blog.liquid +3 -3
  28. data/_includes/custom/body.liquid +3 -3
  29. data/_includes/custom/comments.liquid +3 -3
  30. data/_includes/custom/favicon.liquid +11 -0
  31. data/_includes/custom/footer.liquid +3 -3
  32. data/_includes/custom/head.liquid +3 -3
  33. data/_includes/custom/katex.liquid +15 -15
  34. data/_includes/custom/mathjax.liquid +19 -19
  35. data/_includes/custom/search.liquid +3 -3
  36. data/_includes/extensions/toc.liquid +182 -182
  37. data/_includes/functions/get_config.liquid +11 -11
  38. data/_includes/functions/get_config_data.liquid +23 -23
  39. data/_includes/functions/get_icon.liquid +5 -5
  40. data/_includes/functions/get_page_meta.liquid +74 -60
  41. data/_includes/functions/get_page_thumbnail.liquid +22 -23
  42. data/_includes/functions/get_page_title.liquid +7 -7
  43. data/_includes/functions/get_recent_posts.liquid +17 -17
  44. data/_includes/functions/get_taxonomy_link.liquid +9 -9
  45. data/_includes/head/head.liquid +11 -12
  46. data/_includes/head/meta.liquid +50 -41
  47. data/_includes/head/requirements.liquid +87 -87
  48. data/_includes/head/styles.liquid +10 -10
  49. data/_includes/js/codes.js +116 -116
  50. data/_includes/js/scrollspy.js +16 -16
  51. data/_includes/layout/article.liquid +74 -71
  52. data/_includes/layout/footer.liquid +53 -53
  53. data/_includes/layout/header.liquid +31 -31
  54. data/_includes/layout/hero.liquid +29 -29
  55. data/_includes/layout/page.liquid +33 -33
  56. data/_includes/layout/pagehead.liquid +17 -17
  57. data/_includes/layout/sidebar.liquid +178 -178
  58. data/_includes/localize +29 -29
  59. data/_includes/notice +6 -6
  60. data/_includes/version +1 -1
  61. data/_layouts/article.liquid +10 -10
  62. data/_layouts/default.liquid +132 -131
  63. data/_layouts/home.liquid +20 -20
  64. data/_layouts/page.liquid +9 -9
  65. data/_layouts/post.liquid +9 -9
  66. data/_layouts/system.liquid +35 -35
  67. data/_layouts/taxonomy.liquid +67 -67
  68. data/_sass/_databook.scss +42 -42
  69. data/_sass/_debug.scss +7 -7
  70. data/_sass/_variables.scss +24 -24
  71. data/_sass/base/_mixins.scss +32 -32
  72. data/_sass/base/_normalize.scss +45 -45
  73. data/_sass/base/_responsive.scss +28 -28
  74. data/_sass/components/_archive.scss +49 -49
  75. data/_sass/components/_blog.scss +249 -249
  76. data/_sass/components/_forms.scss +30 -30
  77. data/_sass/components/_hero.scss +70 -70
  78. data/_sass/components/_misc.scss +3 -3
  79. data/_sass/components/_notice.scss +27 -27
  80. data/_sass/components/_notification.scss +10 -10
  81. data/_sass/components/_post.scss +19 -19
  82. data/_sass/components/_sidebar.scss +303 -303
  83. data/_sass/components/_tabs.scss +67 -67
  84. data/_sass/components/_text.scss +27 -27
  85. data/_sass/components/_toc.scss +50 -50
  86. data/_sass/layout/_article.scss +211 -211
  87. data/_sass/layout/_body.scss +26 -26
  88. data/_sass/layout/_footer.scss +75 -75
  89. data/_sass/layout/_header.scss +124 -124
  90. data/_sass/layout/_main.scss +8 -8
  91. data/_sass/layout/_misc.scss +7 -7
  92. data/_sass/layout/_navbar.scss +323 -323
  93. data/_sass/layout/_sidebar.scss +115 -115
  94. data/_sass/layout/_wrapper.scss +7 -7
  95. data/_sass/theme/_scheme.scss +112 -112
  96. data/_sass/typography/_article.scss +49 -49
  97. data/_sass/typography/_doc.scss +104 -104
  98. data/_sass/typography/_highlight.scss +208 -208
  99. data/_sass/typography/_markdown.scss +18 -18
  100. data/_sass/typography/_table.scss +119 -119
  101. data/_sass/typography/_typography.scss +103 -108
  102. data/_sass/utilities/_thinscrollbar.scss +35 -35
  103. data/assets/databook/css/databook.scss +6 -6
  104. data/assets/databook/js/databook.js +8 -8
  105. data/assets/databook/js/search.js +47 -47
  106. data/assets/databook/version.json +9 -9
  107. data/assets/search.json +30 -30
  108. metadata +8 -8
  109. data/_includes/head/opengraph.liquid +0 -1
@@ -1,131 +1,132 @@
1
- {%- assign html_attr = "" -%}
2
-
3
- {%- comment -%}html_class{%- endcomment -%}
4
- {%- assign html_class = "js-disabled" -%}
5
- {%- if jekyll.environment == "development" %}
6
- {%- assign html_class = html_class | append: " is-debug" -%}
7
- {%- endif -%}
8
- {%- if site.class %}
9
- {%- assign html_class = html_class | append: site.class -%}
10
- {%- endif -%}
11
- {%- if layout.class %}
12
- {%- assign html_class = html_class | append: layout.class -%}
13
- {%- endif -%}
14
- {%- if page.class %}
15
- {%- assign html_class = html_class | append: page.class -%}
16
- {%- endif -%}
17
- {%- if html_class.size > 0 -%}
18
- {%- assign html_attr = html_attr | append: " class='" | append: html_class | append: "'" -%}
19
- {%- endif -%}
20
-
21
- {%- comment -%}lang{%- endcomment -%}
22
- {%- if site.language -%}
23
- {%- assign html_attr = html_attr | append: " lang='" | append: site.language | append: "'" -%}
24
- {%- endif -%}
25
-
26
- {%- comment -%}html_style{%- endcomment -%}
27
- {%- assign html_style = "" -%}
28
- {%- if html_style.size > 0 -%}
29
- {%- assign html_attr = html_attr | append: " style='" | append: html_style | append: "'" -%}
30
- {%- endif -%}
31
-
32
- {%- comment -%}data{%- endcomment -%}
33
- {%- assign color_scheme = page.color_scheme | default: layout.color_scheme | default: site.color_scheme | default: false -%}
34
- {%- if color_scheme -%}
35
- {%- assign html_attr = html_attr | append: " data-color-scheme='" | append: color_scheme | append: "'" -%}
36
- {%- endif -%}
37
-
38
- {%- assign accent_color = page.accent_color | default: layout.accent_color | default: site.accent_color | default: false -%}
39
- {%- if accent_color -%}
40
- {%- assign html_attr = html_attr | append: " data-accent-color='" | append: accent_color | append: "'" -%}
41
- {%- endif -%}
42
-
43
- {%- comment -%}sidebar_data{%- endcomment -%}
44
- {%- assign sidebar_data = nil -%}
45
- {%- if layout.hero or page.hero -%}
46
- {%- else -%}
47
- {%- include functions/get_config_data.liquid key="sidebar" -%}
48
- {%- assign sidebar_data = return -%}
49
- {%- endif -%}
50
- {%- assign has_sidebar = false -%}
51
- {%- if sidebar_data -%}
52
- {%- assign has_sidebar = true -%}
53
- {%- endif -%}
54
-
55
- {%- comment -%}header_data{%- endcomment -%}
56
- {%- include functions/get_config_data.liquid key="header" -%}
57
- {%- assign header_data = return | default: nil -%}
58
-
59
- {%- comment -%}hero_data{%- endcomment -%}
60
- {%- include functions/get_config_data.liquid key="hero" -%}
61
- {%- assign hero_data = return | default: nil -%}
62
-
63
- {%- comment -%}footer_data{%- endcomment -%}
64
- {%- include functions/get_config_data.liquid key="footer" -%}
65
- {%- assign footer_data = return | default: nil -%}
66
-
67
- {%- comment -%}wrapper_class{%- endcomment -%}
68
- {%- assign wrapper_class = "l-wrapper" -%}
69
- {%- if page.layout -%}
70
- {%- assign wrapper_class = wrapper_class | append: " l-wrapper--layout-" | append: page.layout -%}
71
- {%- endif -%}
72
- {%- if page.wide or layout.wide -%}
73
- {%- assign wrapper_class = wrapper_class | append: " is-wide" -%}
74
- {%- endif -%}
75
- {%- if has_sidebar -%}
76
- {%- assign wrapper_class = wrapper_class | append: " has-sidebar" -%}
77
- {%- endif -%}
78
- {%- if hero_data.overflow or header_data.translucent -%}
79
- {%- assign wrapper_class = wrapper_class | append: " has-background" -%}
80
- {%- endif -%}
81
-
82
-
83
- {%- capture __PAGE_TITLE -%}
84
- {%- include functions/get_page_title.liquid -%}
85
- {%- endcapture -%}
86
-
87
- {%- comment -%}
88
- Html begin
89
- {%- endcomment -%}
90
-
91
- <!DOCTYPE html>
92
- <html {{- html_attr -}}>
93
- {% include head/head.liquid %}
94
- <body>
95
- <div class="{{- wrapper_class -}}">
96
-
97
- {%- comment -%}l-sidebar{%- endcomment -%}
98
- {%- if sidebar_data -%}
99
- {%- include layout/sidebar.liquid data=sidebar_data -%}
100
- {%- endif -%}
101
-
102
- <main class="l-main">
103
- {%- comment -%}l-header{%- endcomment -%}
104
- {%- unless layout.hide_header or page.hide_header -%}
105
- {%- include layout/header.liquid data=header_data has_sidebar=has_sidebar -%}
106
- {%- endunless -%}
107
-
108
- {%- comment -%}l-hero{%- endcomment -%}
109
- {%- if hero_data -%}
110
- {%- include layout/hero.liquid data=hero_data -%}
111
- {%- endif -%}
112
-
113
- {%- comment -%}l-body{%- endcomment -%}
114
- <div class="l-body">
115
- {{- content -}}
116
-
117
- {%- include components/comments.liquid -%}
118
- </div>
119
-
120
- {%- comment -%}l-footer{%- endcomment -%}
121
- {%- unless layout.hide_footer or page.hide_footer -%}
122
- {%- include layout/footer.liquid data=footer_data -%}
123
- {%- endunless -%}
124
- </main>
125
-
126
- </div>
127
-
128
- {%- include custom/body.liquid -%}
129
-
130
- </body>
131
- </html>
1
+ {%- assign html_attr = "" -%}
2
+
3
+ {%- comment -%}html_class{%- endcomment -%}
4
+ {%- assign html_class = "js-disabled" -%}
5
+ {%- if jekyll.environment == "development" %}
6
+ {%- assign html_class = html_class | append: " is-debug" -%}
7
+ {%- endif -%}
8
+ {%- if site.class %}
9
+ {%- assign html_class = html_class | append: site.class -%}
10
+ {%- endif -%}
11
+ {%- if layout.class %}
12
+ {%- assign html_class = html_class | append: layout.class -%}
13
+ {%- endif -%}
14
+ {%- if page.class %}
15
+ {%- assign html_class = html_class | append: page.class -%}
16
+ {%- endif -%}
17
+ {%- if html_class.size > 0 -%}
18
+ {%- assign html_attr = html_attr | append: " class='" | append: html_class | append: "'" -%}
19
+ {%- endif -%}
20
+
21
+ {%- comment -%}lang{%- endcomment -%}
22
+ {%- assign lang = page.lang | default: site.lang -%}
23
+ {%- if lang -%}
24
+ {%- assign html_attr = html_attr | append: " lang='" | append: lang | append: "'" -%}
25
+ {%- endif -%}
26
+
27
+ {%- comment -%}html_style{%- endcomment -%}
28
+ {%- assign html_style = "" -%}
29
+ {%- if html_style.size > 0 -%}
30
+ {%- assign html_attr = html_attr | append: " style='" | append: html_style | append: "'" -%}
31
+ {%- endif -%}
32
+
33
+ {%- comment -%}data{%- endcomment -%}
34
+ {%- assign color_scheme = page.color_scheme | default: layout.color_scheme | default: site.color_scheme | default: false -%}
35
+ {%- if color_scheme -%}
36
+ {%- assign html_attr = html_attr | append: " data-color-scheme='" | append: color_scheme | append: "'" -%}
37
+ {%- endif -%}
38
+
39
+ {%- assign accent_color = page.accent_color | default: layout.accent_color | default: site.accent_color | default: false -%}
40
+ {%- if accent_color -%}
41
+ {%- assign html_attr = html_attr | append: " data-accent-color='" | append: accent_color | append: "'" -%}
42
+ {%- endif -%}
43
+
44
+ {%- comment -%}sidebar_data{%- endcomment -%}
45
+ {%- assign sidebar_data = nil -%}
46
+ {%- if layout.hero or page.hero -%}
47
+ {%- else -%}
48
+ {%- include functions/get_config_data.liquid key="sidebar" -%}
49
+ {%- assign sidebar_data = return -%}
50
+ {%- endif -%}
51
+ {%- assign has_sidebar = false -%}
52
+ {%- if sidebar_data -%}
53
+ {%- assign has_sidebar = true -%}
54
+ {%- endif -%}
55
+
56
+ {%- comment -%}header_data{%- endcomment -%}
57
+ {%- include functions/get_config_data.liquid key="header" -%}
58
+ {%- assign header_data = return | default: nil -%}
59
+
60
+ {%- comment -%}hero_data{%- endcomment -%}
61
+ {%- include functions/get_config_data.liquid key="hero" -%}
62
+ {%- assign hero_data = return | default: nil -%}
63
+
64
+ {%- comment -%}footer_data{%- endcomment -%}
65
+ {%- include functions/get_config_data.liquid key="footer" -%}
66
+ {%- assign footer_data = return | default: nil -%}
67
+
68
+ {%- comment -%}wrapper_class{%- endcomment -%}
69
+ {%- assign wrapper_class = "l-wrapper" -%}
70
+ {%- if page.layout -%}
71
+ {%- assign wrapper_class = wrapper_class | append: " l-wrapper--layout-" | append: page.layout -%}
72
+ {%- endif -%}
73
+ {%- if page.wide or layout.wide -%}
74
+ {%- assign wrapper_class = wrapper_class | append: " is-wide" -%}
75
+ {%- endif -%}
76
+ {%- if has_sidebar -%}
77
+ {%- assign wrapper_class = wrapper_class | append: " has-sidebar" -%}
78
+ {%- endif -%}
79
+ {%- if hero_data.overflow or header_data.translucent -%}
80
+ {%- assign wrapper_class = wrapper_class | append: " has-background" -%}
81
+ {%- endif -%}
82
+
83
+
84
+ {%- capture __PAGE_TITLE -%}
85
+ {%- include functions/get_page_title.liquid -%}
86
+ {%- endcapture -%}
87
+
88
+ {%- comment -%}
89
+ Html begin
90
+ {%- endcomment -%}
91
+
92
+ <!DOCTYPE html>
93
+ <html {{- html_attr -}}>
94
+ {% include head/head.liquid %}
95
+ <body>
96
+ <div class="{{- wrapper_class -}}">
97
+
98
+ {%- comment -%}l-sidebar{%- endcomment -%}
99
+ {%- if sidebar_data -%}
100
+ {%- include layout/sidebar.liquid data=sidebar_data -%}
101
+ {%- endif -%}
102
+
103
+ <main class="l-main">
104
+ {%- comment -%}l-header{%- endcomment -%}
105
+ {%- unless layout.hide_header or page.hide_header -%}
106
+ {%- include layout/header.liquid data=header_data has_sidebar=has_sidebar -%}
107
+ {%- endunless -%}
108
+
109
+ {%- comment -%}l-hero{%- endcomment -%}
110
+ {%- if hero_data -%}
111
+ {%- include layout/hero.liquid data=hero_data -%}
112
+ {%- endif -%}
113
+
114
+ {%- comment -%}l-body{%- endcomment -%}
115
+ <div class="l-body">
116
+ {{- content -}}
117
+
118
+ {%- include components/comments.liquid -%}
119
+ </div>
120
+
121
+ {%- comment -%}l-footer{%- endcomment -%}
122
+ {%- unless layout.hide_footer or page.hide_footer -%}
123
+ {%- include layout/footer.liquid data=footer_data -%}
124
+ {%- endunless -%}
125
+ </main>
126
+
127
+ </div>
128
+
129
+ {%- include custom/body.liquid -%}
130
+
131
+ </body>
132
+ </html>
data/_layouts/home.liquid CHANGED
@@ -1,20 +1,20 @@
1
- ---
2
- layout: default
3
- hide_title: true
4
- comment: false
5
- toc: false
6
- ---
7
-
8
- {%- assign content_size = content | strip | strip_newlines | size -%}
9
-
10
- {%- if page.url == "/" and content_size > 0 -%}
11
- {%- include layout/page.liquid
12
- type = "home"
13
- content=content
14
- hide_title=true
15
- -%}
16
- {%- endif -%}
17
-
18
- {%- unless site.paginate_first_page_path -%}
19
- {%- include blog/blog.liquid -%}
20
- {%- endunless -%}
1
+ ---
2
+ layout: default
3
+ hide_title: true
4
+ comment: false
5
+ toc: false
6
+ ---
7
+
8
+ {%- assign content_size = content | strip | strip_newlines | size -%}
9
+
10
+ {%- if page.url == "/" and content_size > 0 -%}
11
+ {%- include layout/article.liquid
12
+ type = "home"
13
+ content=content
14
+ hide_title=true
15
+ -%}
16
+ {%- endif -%}
17
+
18
+ {%- unless site.paginate_first_page_path -%}
19
+ {%- include blog/blog.liquid -%}
20
+ {%- endunless -%}
data/_layouts/page.liquid CHANGED
@@ -1,9 +1,9 @@
1
- ---
2
- layout: default
3
- ---
4
-
5
- {%- include layout/article.liquid
6
- page = page
7
- content = content
8
- has_side = page.side
9
- -%}
1
+ ---
2
+ layout: default
3
+ ---
4
+
5
+ {%- include layout/article.liquid
6
+ page = page
7
+ content = content
8
+ has_side = page.side
9
+ -%}
data/_layouts/post.liquid CHANGED
@@ -1,9 +1,9 @@
1
- ---
2
- layout: default
3
- ---
4
-
5
- {%- include layout/article.liquid
6
- page=page
7
- content=content
8
- has_side=true
9
- -%}
1
+ ---
2
+ layout: default
3
+ ---
4
+
5
+ {%- include layout/article.liquid
6
+ page=page
7
+ content=content
8
+ has_side=true
9
+ -%}
@@ -1,35 +1,35 @@
1
- ---
2
- layout: default
3
- comment: false
4
- toc: false
5
- ---
6
-
7
- {%- assign hide_title = page.hide_title | default: layout.hide_title | default: false -%}
8
-
9
- {%- capture title -%}
10
- {%- include functions/get_page_title.liquid -%}
11
- {%- endcapture -%}
12
-
13
- {%- capture header -%}
14
- {%- unless hide_title -%}
15
- {%- include components/title.liquid
16
- title = title
17
- url = page.url
18
- meta = page.subtitle
19
- -%}
20
- {%- endunless -%}
21
- {%- endcapture -%}
22
-
23
- <div class="l-page">
24
-
25
- {%- unless hide_title -%}
26
- <div class="l-page__header">
27
- {{- header -}}
28
- </div>
29
- {%- endunless -%}
30
-
31
- <div class="l-page__content" >
32
- {{- content | markdownify -}}
33
- </div>
34
-
35
- </div>
1
+ ---
2
+ layout: default
3
+ comment: false
4
+ toc: false
5
+ ---
6
+
7
+ {%- assign hide_title = page.hide_title | default: layout.hide_title | default: false -%}
8
+
9
+ {%- capture title -%}
10
+ {%- include functions/get_page_title.liquid -%}
11
+ {%- endcapture -%}
12
+
13
+ {%- capture header -%}
14
+ {%- unless hide_title -%}
15
+ {%- include components/title.liquid
16
+ title = title
17
+ url = page.url
18
+ meta = page.subtitle
19
+ -%}
20
+ {%- endunless -%}
21
+ {%- endcapture -%}
22
+
23
+ <div class="l-page">
24
+
25
+ {%- unless hide_title -%}
26
+ <div class="l-page__header">
27
+ {{- header -}}
28
+ </div>
29
+ {%- endunless -%}
30
+
31
+ <div class="l-page__content" >
32
+ {{- content | markdownify -}}
33
+ </div>
34
+
35
+ </div>
@@ -1,67 +1,67 @@
1
- ---
2
- layout: system
3
- ---
4
-
5
- {%- assign taxonomy = "" | split: "" -%}
6
-
7
- {%- if page.taxonomy == "year" -%}
8
- {%- assign groups = site.posts | group_by_exp: "post", "post.date | date: '%Y'" | sort: "name" -%}
9
- {%- for group in groups -%}
10
- {%- assign item = "" | split: "" | push: group.name | push: group.items -%}
11
- {%- assign taxonomy = taxonomy | push: item -%}
12
- {%- endfor -%}
13
- {%- elsif page.taxonomy == "category" or page.taxonomy == "tag" -%}
14
- {%- if page.taxonomy == "category" -%}
15
- {%- assign collection = site.categories -%}
16
- {%- elsif page.taxonomy == "tag" -%}
17
- {%- assign collection = site.tags -%}
18
- {%- endif -%}
19
- {%- assign sizeGroups = collection | group_by_exp: "group", "group[1].size" | sort: "name" | reverse -%}
20
- {%- for sizeGroup in sizeGroups -%}
21
- {%- for group in sizeGroup.items -%}
22
- {%- assign item = "" | split: "" | push: group[0] | push: group[1] -%}
23
- {%- assign taxonomy = taxonomy | push: item -%}
24
- {%- endfor -%}
25
- {%- endfor -%}
26
- {%- elsif page.taxonomy == "author" -%}
27
- {%- assign collection = "" | split: "" -%}
28
- {%- for post in site.posts -%}
29
- {%- if post.authors -%}
30
- {%- for author in post.authors -%}
31
- {%- unless author.first -%}
32
- {%- assign item = "" | split: "" | push: author | push: post -%}
33
- {%- assign collection = collection | push: item -%}
34
- {%- endunless -%}
35
- {%- endfor -%}
36
- {%- elsif post.author -%}
37
- {%- unless post.author.first -%}
38
- {%- assign item = "" | split: "" | push: post.author | push: post -%}
39
- {%- assign collection = collection | push: item -%}
40
- {%- endunless -%}
41
- {%- endif -%}
42
- {%- endfor -%}
43
- {%- assign authorGroups = collection | group_by_exp: "item", "item[0]" | sort: "name" -%}
44
- {%- for authorGroup in authorGroups -%}
45
- {%- assign posts = "" | split: "" -%}
46
- {%- for item in authorGroup.items -%}
47
- {%- assign posts = posts | push: item[1] -%}
48
- {%- endfor -%}
49
- {%- assign item = "" | split: "" | push: authorGroup.name | push: posts -%}
50
- {%- assign taxonomy = taxonomy | push: item -%}
51
- {%- endfor -%}
52
- {%- endif -%}
53
-
54
- <div class="c-archive">
55
- {%- for group in taxonomy -%}
56
- {%- assign id = group[0] | url_encode -%}
57
- {%- assign posts = group[1] -%}
58
- <div class="c-archive__toggler" id="!/{{group[0]}}"></div>
59
- <a class="c-archive__link" href="#!/{{id}}">
60
- {{- group[0] -}}
61
- <span class="c-archive__count">{{- posts.size -}}</span>
62
- </a>
63
- <div class="c-archive__tab">
64
- {%- include blog/list.liquid posts=posts -%}
65
- </div>
66
- {%- endfor -%}
67
- </div>
1
+ ---
2
+ layout: system
3
+ ---
4
+
5
+ {%- assign taxonomy = "" | split: "" -%}
6
+
7
+ {%- if page.taxonomy == "year" -%}
8
+ {%- assign groups = site.posts | group_by_exp: "post", "post.date | date: '%Y'" | sort: "name" -%}
9
+ {%- for group in groups -%}
10
+ {%- assign item = "" | split: "" | push: group.name | push: group.items -%}
11
+ {%- assign taxonomy = taxonomy | push: item -%}
12
+ {%- endfor -%}
13
+ {%- elsif page.taxonomy == "category" or page.taxonomy == "tag" -%}
14
+ {%- if page.taxonomy == "category" -%}
15
+ {%- assign collection = site.categories -%}
16
+ {%- elsif page.taxonomy == "tag" -%}
17
+ {%- assign collection = site.tags -%}
18
+ {%- endif -%}
19
+ {%- assign sizeGroups = collection | group_by_exp: "group", "group[1].size" | sort: "name" | reverse -%}
20
+ {%- for sizeGroup in sizeGroups -%}
21
+ {%- for group in sizeGroup.items -%}
22
+ {%- assign item = "" | split: "" | push: group[0] | push: group[1] -%}
23
+ {%- assign taxonomy = taxonomy | push: item -%}
24
+ {%- endfor -%}
25
+ {%- endfor -%}
26
+ {%- elsif page.taxonomy == "author" -%}
27
+ {%- assign collection = "" | split: "" -%}
28
+ {%- for post in site.posts -%}
29
+ {%- if post.authors -%}
30
+ {%- for author in post.authors -%}
31
+ {%- unless author.first -%}
32
+ {%- assign item = "" | split: "" | push: author | push: post -%}
33
+ {%- assign collection = collection | push: item -%}
34
+ {%- endunless -%}
35
+ {%- endfor -%}
36
+ {%- elsif post.author -%}
37
+ {%- unless post.author.first -%}
38
+ {%- assign item = "" | split: "" | push: post.author | push: post -%}
39
+ {%- assign collection = collection | push: item -%}
40
+ {%- endunless -%}
41
+ {%- endif -%}
42
+ {%- endfor -%}
43
+ {%- assign authorGroups = collection | group_by_exp: "item", "item[0]" | sort: "name" -%}
44
+ {%- for authorGroup in authorGroups -%}
45
+ {%- assign posts = "" | split: "" -%}
46
+ {%- for item in authorGroup.items -%}
47
+ {%- assign posts = posts | push: item[1] -%}
48
+ {%- endfor -%}
49
+ {%- assign item = "" | split: "" | push: authorGroup.name | push: posts -%}
50
+ {%- assign taxonomy = taxonomy | push: item -%}
51
+ {%- endfor -%}
52
+ {%- endif -%}
53
+
54
+ <div class="c-archive">
55
+ {%- for group in taxonomy -%}
56
+ {%- assign id = group[0] | url_encode -%}
57
+ {%- assign posts = group[1] -%}
58
+ <div class="c-archive__toggler" id="!/{{group[0]}}"></div>
59
+ <a class="c-archive__link" href="#!/{{id}}">
60
+ {{- group[0] -}}
61
+ <span class="c-archive__count">{{- posts.size -}}</span>
62
+ </a>
63
+ <div class="c-archive__tab">
64
+ {%- include blog/list.liquid posts=posts -%}
65
+ </div>
66
+ {%- endfor -%}
67
+ </div>
data/_sass/_databook.scss CHANGED
@@ -1,42 +1,42 @@
1
- @import "variables";
2
-
3
- @import "base/normalize";
4
- @import "base/responsive";
5
- @import "base/mixins";
6
- @import "base/misc";
7
-
8
- @import "theme/scheme";
9
-
10
- @import "utilities/thinscrollbar";
11
-
12
- @import "layout/wrapper";
13
- @import "layout/main";
14
- @import "layout/header";
15
- @import "layout/body";
16
- @import "layout/footer";
17
- @import "layout/sidebar";
18
- @import "layout/navbar";
19
- @import "layout/article";
20
- @import "layout/misc";
21
-
22
- @import "components/archive";
23
- @import "components/blog";
24
- @import "components/forms";
25
- @import "components/hero";
26
- @import "components/notice";
27
- @import "components/post";
28
- @import "components/sidebar";
29
- @import "components/tabs";
30
- @import "components/toc";
31
- @import "components/misc";
32
-
33
- @import "typography/typography";
34
- @import "typography/article";
35
- @import "typography/doc";
36
- @import "typography/table";
37
- @import "typography/markdown";
38
- @import "typography/highlight";
39
-
40
- @import "debug";
41
-
42
- @import "custom";
1
+ @import "variables";
2
+
3
+ @import "base/normalize";
4
+ @import "base/responsive";
5
+ @import "base/mixins";
6
+ @import "base/misc";
7
+
8
+ @import "theme/scheme";
9
+
10
+ @import "utilities/thinscrollbar";
11
+
12
+ @import "layout/wrapper";
13
+ @import "layout/main";
14
+ @import "layout/header";
15
+ @import "layout/body";
16
+ @import "layout/footer";
17
+ @import "layout/sidebar";
18
+ @import "layout/navbar";
19
+ @import "layout/article";
20
+ @import "layout/misc";
21
+
22
+ @import "components/archive";
23
+ @import "components/blog";
24
+ @import "components/forms";
25
+ @import "components/hero";
26
+ @import "components/notice";
27
+ @import "components/post";
28
+ @import "components/sidebar";
29
+ @import "components/tabs";
30
+ @import "components/toc";
31
+ @import "components/misc";
32
+
33
+ @import "typography/typography";
34
+ @import "typography/article";
35
+ @import "typography/doc";
36
+ @import "typography/table";
37
+ @import "typography/markdown";
38
+ @import "typography/highlight";
39
+
40
+ @import "debug";
41
+
42
+ @import "custom";
data/_sass/_debug.scss CHANGED
@@ -1,7 +1,7 @@
1
- :root.is-debug {
2
- .h-debug {
3
- padding: .25rem;
4
- border: 2px dashed orange;
5
- background-color: #ffdd00;
6
- }
7
- }
1
+ :root.is-debug {
2
+ .h-debug {
3
+ padding: .25rem;
4
+ border: 2px dashed orange;
5
+ background-color: #ffdd00;
6
+ }
7
+ }