jekyll-theme-cirno 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE +21 -0
- data/README.md +27 -0
- data/_includes/extra_head.html +0 -0
- data/_includes/extra_script.html +0 -0
- data/_includes/footer.html +13 -0
- data/_includes/google-analytics.html +8 -0
- data/_includes/head.html +12 -0
- data/_includes/header.html +20 -0
- data/_includes/post_footer.html +4 -0
- data/_layouts/archives.html +21 -0
- data/_layouts/default.html +18 -0
- data/_layouts/home.html +36 -0
- data/_layouts/page.html +4 -0
- data/_layouts/post.html +32 -0
- data/_layouts/tags.html +5 -0
- data/_sass/_archives.scss +5 -0
- data/_sass/_base.scss +123 -0
- data/_sass/_cirno.scss +10 -0
- data/_sass/_footer.scss +17 -0
- data/_sass/_header.scss +23 -0
- data/_sass/_home.scss +63 -0
- data/_sass/_layout.scss +18 -0
- data/_sass/_normalize.scss +341 -0
- data/_sass/_post.scss +112 -0
- data/_sass/_syntax.scss +224 -0
- data/_sass/_var.scss +22 -0
- data/assets/main.scss +3 -0
- metadata +156 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 843b5e2d727bd94aea483da0644219ffa16aa624ac66c41e314bba23a926595a
|
4
|
+
data.tar.gz: ef27ee652ebfd2a54501be332a7a65eaf2ee1cc91ce71935ead1390ccc698cac
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 974ff1a6513a5e56225f13d928cd24660c55911fa37e0dd0cbfe027516dd1c6be8ec852b44f3977b1d4c6440372edd9d65c3a9c3029f9bbda73d45b483d55685
|
7
|
+
data.tar.gz: 61154ac85f696f02ae35943bf15b13ef890cecc391af90ba1a2d339ed41dee9a11686ff9e74d64d1044dfeb7ea5a5ba17c0ae787124ae3162633a2f5ed0192b5
|
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2018 阿卡琳
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
# jekyll-theme-cirno
|
2
|
+
|
3
|
+
## Installation
|
4
|
+
|
5
|
+
Add this line to your Jekyll site's `Gemfile`:
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
gem "jekyll-theme-cirno"
|
9
|
+
```
|
10
|
+
|
11
|
+
And add this line to your Jekyll site's `_config.yml`:
|
12
|
+
|
13
|
+
```yaml
|
14
|
+
theme: jekyll-theme-cirno
|
15
|
+
```
|
16
|
+
|
17
|
+
And then execute:
|
18
|
+
|
19
|
+
$ bundle
|
20
|
+
|
21
|
+
Or install it yourself as:
|
22
|
+
|
23
|
+
$ gem install jekyll-theme-cirno
|
24
|
+
|
25
|
+
## License
|
26
|
+
|
27
|
+
The theme is available as open source under the terms of the [MIT License](./LICENSE).
|
File without changes
|
File without changes
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<footer class="footer">
|
2
|
+
<section>
|
3
|
+
<span>©{{ "now" | date: "%Y" }}</span>
|
4
|
+
<span>♥
|
5
|
+
<a href="https://github.com/hufan-akari" target="_blank">阿卡琳</a>
|
6
|
+
</span>
|
7
|
+
</section>
|
8
|
+
<section>
|
9
|
+
Powered by
|
10
|
+
<a href="https://jekyllrb.com" target="_blank">Jekyll</a> with
|
11
|
+
<a href="https://github.com/hufan-akari/jekyll-theme-cirno" target="_blank">❆ Cirno theme</a>
|
12
|
+
</section>
|
13
|
+
</footer>
|
@@ -0,0 +1,8 @@
|
|
1
|
+
<script>
|
2
|
+
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
|
3
|
+
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
|
4
|
+
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
|
5
|
+
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
|
6
|
+
ga('create', '{{ site.google_analytics }}', 'auto');
|
7
|
+
ga('send', 'pageview');
|
8
|
+
</script>
|
data/_includes/head.html
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
<head>
|
2
|
+
<meta charset="utf-8" />
|
3
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
4
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
5
|
+
{% seo %}
|
6
|
+
<link rel="stylesheet" href="{{ "/assets/main.css" | relative_url }}" />
|
7
|
+
{% feed_meta %}
|
8
|
+
{% if jekyll.environment == 'production' and site.google_analytics %}
|
9
|
+
{% include google-analytics.html %}
|
10
|
+
{% endif %}
|
11
|
+
{% include extra_head.html %}
|
12
|
+
</head>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<header class="header">
|
2
|
+
<a class="header-title" href="{{ '/' | relative_url }}">{{ site.title | escape }}</a>
|
3
|
+
<nav>
|
4
|
+
{% unless site.cirno.header_pages == false %}
|
5
|
+
{%- assign page_paths = site.cirno.header_pages -%}
|
6
|
+
{%- for path in page_paths -%}
|
7
|
+
{%- assign my_page = site.pages | where: "path", path | first -%}
|
8
|
+
{%- if my_page.title -%}
|
9
|
+
<a href="{{ my_page.url | relative_url }}">
|
10
|
+
{{ my_page.title | escape }}
|
11
|
+
</a>
|
12
|
+
{%- elsif path == "feed.xml" -%}
|
13
|
+
<a href="{{ my_page.url | relative_url }}">
|
14
|
+
RSS
|
15
|
+
</a>
|
16
|
+
{%- endif -%}
|
17
|
+
{%- endfor -%}
|
18
|
+
{% endunless %}
|
19
|
+
</nav>
|
20
|
+
</header>
|
@@ -0,0 +1,21 @@
|
|
1
|
+
---
|
2
|
+
layout: default
|
3
|
+
---
|
4
|
+
<section class="stretch">
|
5
|
+
{%- for post in site.posts -%}
|
6
|
+
{%- capture this_year -%}{{ post.date | date: "%Y" }}{%- endcapture -%}
|
7
|
+
{%- capture next_year -%}{{ post.previous.date | date: "%Y" }}{%- endcapture -%}
|
8
|
+
{%- if forloop.first -%}
|
9
|
+
<h2 id="{{ this_year }}-ref">{{this_year}}</h2>
|
10
|
+
<ul>
|
11
|
+
{%- endif -%}
|
12
|
+
<li><a href="{{ post.url }}">{{ post.title }}</a></li>
|
13
|
+
{%- if forloop.last -%}
|
14
|
+
</ul>
|
15
|
+
{%- elsif this_year != next_year -%}
|
16
|
+
</ul>
|
17
|
+
<h2 id="{{ next_year }}-ref">{{next_year}}</h2>
|
18
|
+
<ul>
|
19
|
+
{%- endif -%}
|
20
|
+
{%- endfor -%}
|
21
|
+
</section>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html lang="{{ page.lang | default: site.lang | default: " en " }}">
|
3
|
+
{%- include head.html -%}
|
4
|
+
<body class="{{ page.layout | default: 'default' }}">
|
5
|
+
<main class="{{ page.layout | default: 'default' }}">
|
6
|
+
{%- assign hide_header = post.hide_header | default: layout.hide_header | default: site.cirno.hide_header -%}
|
7
|
+
{%- unless hide_header-%}
|
8
|
+
{%- include header.html -%}
|
9
|
+
{%- endunless -%}
|
10
|
+
{{ content }}
|
11
|
+
{%- assign hide_footer = post.hide_footer | default: layout.hide_footer | default: site.cirno.hide_footer -%}
|
12
|
+
{%- unless hide_footer -%}
|
13
|
+
{%- include footer.html -%}
|
14
|
+
{%- endunless -%}
|
15
|
+
</main>
|
16
|
+
{% include extra_script.html %}
|
17
|
+
</body>
|
18
|
+
</html>
|
data/_layouts/home.html
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
---
|
2
|
+
layout: default
|
3
|
+
---
|
4
|
+
<ul class="post-list stretch">
|
5
|
+
{%- assign posts = paginator.posts | default: site.posts -%}
|
6
|
+
{%- for post in posts -%}
|
7
|
+
<li class="post-card">
|
8
|
+
<section class="post-title">
|
9
|
+
<a class="post-link" href="{{ post.url | relative_url }}">{{ post.title | escape }}</a>
|
10
|
+
</section>
|
11
|
+
<section class="post-meta">
|
12
|
+
<time>{{ post.date | date_to_long_string }}</time>
|
13
|
+
</section>
|
14
|
+
<section class="post-excerpt">
|
15
|
+
<p>{{ post.excerpt | strip_html }}</p>
|
16
|
+
</section>
|
17
|
+
</li>
|
18
|
+
{%- endfor -%}
|
19
|
+
</ul>
|
20
|
+
{%- if paginator.total_pages > 1 -%}
|
21
|
+
<footer class="pagination">
|
22
|
+
<a href="{{ paginator.previous_page_path }}" class="previous" {% unless paginator.previous_page %}disabled{% endunless %}>
|
23
|
+
<svg viewBox="0 0 24 24" height="24" width="24" xmlns="http://www.w3.org/2000/svg">
|
24
|
+
<path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/>
|
25
|
+
<path d="M0 0h24v24H0z" fill="none"/>
|
26
|
+
</svg>
|
27
|
+
</a>
|
28
|
+
<span class="page_number ">{{ paginator.page }} / {{ paginator.total_pages }}</span>
|
29
|
+
<a href="{{ paginator.next_page_path }}" class="next" {% unless paginator.next_page %}disabled{% endunless %}>
|
30
|
+
<svg viewBox="0 0 24 24" height="24" width="24" xmlns="http://www.w3.org/2000/svg">
|
31
|
+
<path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/>
|
32
|
+
<path d="M0 0h24v24H0z" fill="none"/>
|
33
|
+
</svg>
|
34
|
+
</a>
|
35
|
+
</footer>
|
36
|
+
{%- endif -%}
|
data/_layouts/page.html
ADDED
data/_layouts/post.html
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
---
|
2
|
+
layout: default
|
3
|
+
---
|
4
|
+
{%- if page.cover -%}
|
5
|
+
<section class="post-cover">
|
6
|
+
<img src="{{ page.cover }}" alt="cover of {{ page.title | escape }}" />
|
7
|
+
</section>
|
8
|
+
{%- endif -%}
|
9
|
+
<article class="stretch flex">
|
10
|
+
<header class="post-header">
|
11
|
+
<h1 class="headline">{{ page.title | escape }}</h1>
|
12
|
+
{%- assign tags_length = page.tags | size -%}
|
13
|
+
{%- if tags_length > 0 -%}
|
14
|
+
<div class="tags">
|
15
|
+
{%- for tag in page.tags -%}
|
16
|
+
<span class="tag">{{ tag | escape }}</span>
|
17
|
+
{%- endfor -%}
|
18
|
+
</div>
|
19
|
+
{%- endif -%}
|
20
|
+
<section class="post-meta">
|
21
|
+
<time class="post-date" datetime="{{ page.date | date_to_xmlschema }}">
|
22
|
+
{{ page.date | date_to_long_string }}
|
23
|
+
</time>
|
24
|
+
<span>•</span>
|
25
|
+
<span>{{ page.author | default: site.author }}</span>
|
26
|
+
</section>
|
27
|
+
</header>
|
28
|
+
<div class="content stretch">
|
29
|
+
{{ content }}
|
30
|
+
</div>
|
31
|
+
{%- include post_footer.html -%}
|
32
|
+
</article>
|
data/_layouts/tags.html
ADDED
data/_sass/_base.scss
ADDED
@@ -0,0 +1,123 @@
|
|
1
|
+
html {
|
2
|
+
box-sizing: border-box;
|
3
|
+
font-family: $font-family;
|
4
|
+
font-size: 1.25em;
|
5
|
+
line-height: 1.5;
|
6
|
+
text-align: justify;
|
7
|
+
|
8
|
+
@media screen and (max-width: $pad-width) {
|
9
|
+
font-size: 1.125em;
|
10
|
+
}
|
11
|
+
@media screen and (max-width: $phone-width) {
|
12
|
+
font-size: 1em;
|
13
|
+
}
|
14
|
+
}
|
15
|
+
|
16
|
+
*,
|
17
|
+
*::before,
|
18
|
+
*::after {
|
19
|
+
box-sizing: inherit;
|
20
|
+
}
|
21
|
+
|
22
|
+
ul {
|
23
|
+
list-style: none;
|
24
|
+
margin: 0;
|
25
|
+
padding: 0;
|
26
|
+
}
|
27
|
+
|
28
|
+
a,
|
29
|
+
a:visited {
|
30
|
+
text-decoration: none;
|
31
|
+
color: $theme-color;
|
32
|
+
}
|
33
|
+
|
34
|
+
figure.highlight {
|
35
|
+
margin: 0;
|
36
|
+
}
|
37
|
+
|
38
|
+
pre {
|
39
|
+
padding: 0.5rem;
|
40
|
+
}
|
41
|
+
|
42
|
+
code,
|
43
|
+
pre {
|
44
|
+
font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier,
|
45
|
+
monospace;
|
46
|
+
}
|
47
|
+
|
48
|
+
table {
|
49
|
+
border-collapse: collapse;
|
50
|
+
border-spacing: 0;
|
51
|
+
empty-cells: show;
|
52
|
+
border: 1px solid #cbcbcb;
|
53
|
+
|
54
|
+
caption {
|
55
|
+
color: #000;
|
56
|
+
font: italic 85%/1 arial, sans-serif;
|
57
|
+
padding: 1em 0;
|
58
|
+
text-align: center;
|
59
|
+
}
|
60
|
+
|
61
|
+
td,
|
62
|
+
th {
|
63
|
+
border-left: 1px solid #cbcbcb; /* inner column border */
|
64
|
+
border-width: 0 0 0 1px;
|
65
|
+
font-size: inherit;
|
66
|
+
margin: 0;
|
67
|
+
overflow: visible; /*to make ths where the title is really long work*/
|
68
|
+
padding: 0.5em 1em; /* cell padding */
|
69
|
+
|
70
|
+
&:first-child,
|
71
|
+
&:first-child {
|
72
|
+
border-left-width: 0;
|
73
|
+
}
|
74
|
+
}
|
75
|
+
|
76
|
+
thead {
|
77
|
+
background-color: #e0e0e0;
|
78
|
+
color: #000;
|
79
|
+
text-align: left;
|
80
|
+
vertical-align: bottom;
|
81
|
+
}
|
82
|
+
|
83
|
+
td {
|
84
|
+
background-color: transparent;
|
85
|
+
}
|
86
|
+
|
87
|
+
tr:nth-child(2n) td {
|
88
|
+
background-color: #f2f2f2;
|
89
|
+
}
|
90
|
+
}
|
91
|
+
|
92
|
+
hr {
|
93
|
+
border: 0;
|
94
|
+
height: 1px;
|
95
|
+
background-image: linear-gradient(
|
96
|
+
to right,
|
97
|
+
rgba(0, 0, 0, 0),
|
98
|
+
rgba(0, 0, 0, 0.75),
|
99
|
+
rgba(0, 0, 0, 0)
|
100
|
+
);
|
101
|
+
text-align: center;
|
102
|
+
margin: 49.5px 0;
|
103
|
+
|
104
|
+
&::after {
|
105
|
+
content: "\2746";
|
106
|
+
display: inline-block;
|
107
|
+
position: relative;
|
108
|
+
top: -18px;
|
109
|
+
padding: 0 10px;
|
110
|
+
background: white;
|
111
|
+
color: $theme-color;
|
112
|
+
font-size: 24px;
|
113
|
+
}
|
114
|
+
}
|
115
|
+
|
116
|
+
.flex {
|
117
|
+
display: flex;
|
118
|
+
flex-direction: column;
|
119
|
+
}
|
120
|
+
|
121
|
+
.stretch {
|
122
|
+
flex: 1 0 auto;
|
123
|
+
}
|
data/_sass/_cirno.scss
ADDED
data/_sass/_footer.scss
ADDED
data/_sass/_header.scss
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
.header {
|
2
|
+
border-top: 2px solid gray;
|
3
|
+
border-bottom: 1px solid gray;
|
4
|
+
background: #24292e;
|
5
|
+
|
6
|
+
& > .header-title {
|
7
|
+
font-size: 2rem;
|
8
|
+
}
|
9
|
+
|
10
|
+
a,
|
11
|
+
a:visited {
|
12
|
+
color: #ffffffbf;
|
13
|
+
transition: 0.5s color ease;
|
14
|
+
|
15
|
+
&:hover {
|
16
|
+
color: #fff;
|
17
|
+
}
|
18
|
+
}
|
19
|
+
|
20
|
+
@media print {
|
21
|
+
display: none;
|
22
|
+
}
|
23
|
+
}
|
data/_sass/_home.scss
ADDED
@@ -0,0 +1,63 @@
|
|
1
|
+
.post-list {
|
2
|
+
@extend %magic-padding;
|
3
|
+
|
4
|
+
.post-card {
|
5
|
+
margin: 2rem auto;
|
6
|
+
|
7
|
+
&:hover img {
|
8
|
+
transform: scale(1.2);
|
9
|
+
opacity: 0.8;
|
10
|
+
}
|
11
|
+
}
|
12
|
+
|
13
|
+
.post-link {
|
14
|
+
display: flex;
|
15
|
+
flex-direction: column;
|
16
|
+
}
|
17
|
+
|
18
|
+
.post-image {
|
19
|
+
max-height: 15rem;
|
20
|
+
width: 100%;
|
21
|
+
overflow: hidden;
|
22
|
+
& > img {
|
23
|
+
max-height: 15rem;
|
24
|
+
width: 100%;
|
25
|
+
object-fit: cover;
|
26
|
+
transition: transform 0.5s ease-in-out, opacity 0.5s ease-in-out;
|
27
|
+
}
|
28
|
+
}
|
29
|
+
|
30
|
+
.post-title {
|
31
|
+
font-size: 1.2rem;
|
32
|
+
}
|
33
|
+
|
34
|
+
.post-meta {
|
35
|
+
font-size: 0.8rem;
|
36
|
+
color: gray;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
|
40
|
+
.pagination {
|
41
|
+
@extend %magic-padding;
|
42
|
+
|
43
|
+
display: flex;
|
44
|
+
justify-content: space-between;
|
45
|
+
box-sizing: border-box;
|
46
|
+
width: 100%;
|
47
|
+
min-height: 62px;
|
48
|
+
align-items: center;
|
49
|
+
|
50
|
+
.next,
|
51
|
+
.previous {
|
52
|
+
& > svg {
|
53
|
+
fill: $theme-color;
|
54
|
+
height: 48px;
|
55
|
+
width: 48px;
|
56
|
+
}
|
57
|
+
|
58
|
+
&[disabled] {
|
59
|
+
opacity: 0.5;
|
60
|
+
pointer-events: none;
|
61
|
+
}
|
62
|
+
}
|
63
|
+
}
|