hexo-theme-stellar 1.15.1 → 1.16.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_config.yml +8 -8
- package/layout/_partial/head.ejs +4 -4
- package/layout/_partial/main/navbar/list_wiki.ejs +1 -3
- package/layout/_partial/plugins/comments/beaudar/layout.ejs +10 -29
- package/layout/_partial/plugins/comments/giscus/layout.ejs +10 -27
- package/layout/_partial/plugins/comments/layout.ejs +17 -2
- package/layout/_partial/plugins/comments/script.ejs +2 -2
- package/layout/_partial/plugins/comments/utterances/layout.ejs +10 -29
- package/layout/_partial/sidebar/header.ejs +43 -8
- package/layout/_partial/sidebar/index.ejs +50 -0
- package/layout/_partial/sidebar/widgets/recent.ejs +8 -7
- package/layout/_partial/sidebar/widgets/toc.ejs +5 -1
- package/layout/index.ejs +1 -3
- package/package.json +1 -1
- package/scripts/events/lib/doc_tree.js +91 -90
- package/scripts/helpers/related_posts.js +1 -3
- package/scripts/helpers/utils.js +20 -0
- package/scripts/tags/folders.js +4 -6
- package/scripts/tags/lib/tabs.js +5 -9
- package/scripts/tags/split.js +6 -8
- package/scripts/tags/timeline.js +3 -5
- package/source/css/_common/blockquote.styl +10 -0
- package/source/css/_common/device.styl +11 -10
- package/source/css/_layout/list.styl +2 -1
- package/source/css/_layout/main.styl +4 -2
- package/source/css/_layout/md.styl +6 -13
- package/source/css/_layout/partial/bread-nav.styl +1 -1
- package/source/css/_layout/partial/navbar.styl +8 -1
- package/source/css/_layout/partial/related.styl +1 -2
- package/source/css/_layout/sidebar/sidebar.styl +4 -4
- package/source/css/_layout/sidebar/toc_wiki.styl +1 -1
- package/source/css/_layout/sidebar/widgets.styl +6 -3
- package/source/css/_layout/tag-plugins/common.styl +7 -7
- package/source/css/_layout/tag-plugins/link.styl +7 -7
- package/source/css/_layout/tag-plugins/split.styl +7 -1
- package/source/css/_layout/tag-plugins/timeline.styl +2 -4
- package/source/js/plugins/timeline.js +1 -1
- package/layout/_partial/sidebar/logo.ejs +0 -69
|
@@ -82,31 +82,31 @@ set_text_black()
|
|
|
82
82
|
set_darkmode_tags()
|
|
83
83
|
.tag-plugin[color='red']
|
|
84
84
|
--theme-border: mix($c-red, black, 70)
|
|
85
|
-
--theme-bg: mix($c-red, black,
|
|
85
|
+
--theme-bg: mix($c-red, black, 35)
|
|
86
86
|
|
|
87
87
|
.tag-plugin[color='orange']
|
|
88
88
|
--theme-border: mix($c-orange, black, 70)
|
|
89
|
-
--theme-bg: mix($c-orange, black,
|
|
89
|
+
--theme-bg: mix($c-orange, black, 35)
|
|
90
90
|
|
|
91
91
|
.tag-plugin[color='yellow']
|
|
92
92
|
--theme-border: mix($c-yellow, black, 70)
|
|
93
|
-
--theme-bg: mix($c-yellow, black,
|
|
93
|
+
--theme-bg: mix($c-yellow, black, 30)
|
|
94
94
|
|
|
95
95
|
.tag-plugin[color='green']
|
|
96
96
|
--theme-border: mix($c-green, black, 70)
|
|
97
|
-
--theme-bg: mix($c-green, black,
|
|
97
|
+
--theme-bg: mix($c-green, black, 30)
|
|
98
98
|
|
|
99
99
|
.tag-plugin[color='cyan']
|
|
100
100
|
--theme-border: mix($c-cyan, black, 70)
|
|
101
|
-
--theme-bg: mix($c-cyan, black,
|
|
101
|
+
--theme-bg: mix($c-cyan, black, 30)
|
|
102
102
|
|
|
103
103
|
.tag-plugin[color='blue']
|
|
104
104
|
--theme-border: mix($c-blue, black, 70)
|
|
105
|
-
--theme-bg: mix($c-blue, black,
|
|
105
|
+
--theme-bg: mix($c-blue, black, 35)
|
|
106
106
|
|
|
107
107
|
.tag-plugin[color='purple']
|
|
108
108
|
--theme-border: mix($c-purple, black, 70)
|
|
109
|
-
--theme-bg: mix($c-purple, black,
|
|
109
|
+
--theme-bg: mix($c-purple, black, 40)
|
|
110
110
|
|
|
111
111
|
.tag-plugin[color='light']
|
|
112
112
|
--theme-border: white
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
.md .tag-plugin.link
|
|
2
|
-
max-width:
|
|
2
|
+
max-width: 100%
|
|
3
3
|
margin: 1em auto
|
|
4
4
|
display: flex
|
|
5
5
|
justify-content: center
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
justify-content: space-between
|
|
13
13
|
align-items: center
|
|
14
14
|
cursor: pointer
|
|
15
|
-
min-width 280px
|
|
16
|
-
max-width: 100%
|
|
15
|
+
// min-width 280px
|
|
16
|
+
// max-width: 100%
|
|
17
17
|
width: 320px
|
|
18
18
|
@media screen and (max-width: $device-mobile-375)
|
|
19
19
|
width: 100%
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
.md .link-card.rich
|
|
32
32
|
flex-direction: column
|
|
33
33
|
align-items: stretch
|
|
34
|
-
width:
|
|
34
|
+
width: 460px
|
|
35
35
|
text-align: justify
|
|
36
36
|
|
|
37
37
|
.md .link-card
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
flex-shrink: 0
|
|
51
51
|
>.top
|
|
52
52
|
display: flex
|
|
53
|
-
margin:
|
|
53
|
+
margin: 1rem 1rem 0.75rem
|
|
54
54
|
overflow: hidden
|
|
55
55
|
max-width: 'calc(100% - %s * 2)' % 1rem
|
|
56
56
|
align-items: center
|
|
@@ -67,10 +67,10 @@
|
|
|
67
67
|
txt-ellipsis()
|
|
68
68
|
max-width: 100%
|
|
69
69
|
>.bottom
|
|
70
|
-
margin: 0
|
|
70
|
+
margin: 0 1rem 1rem
|
|
71
71
|
.title
|
|
72
72
|
font-size: $fs-15
|
|
73
|
-
margin:
|
|
73
|
+
margin-bottom: 0.5rem
|
|
74
74
|
|
|
75
75
|
.md .link-card
|
|
76
76
|
line-height: 1.2
|
|
@@ -4,6 +4,8 @@
|
|
|
4
4
|
grid-template-columns: repeat(auto-fill, "calc((100% - 1 * %s) / 2)" % 16px)
|
|
5
5
|
>.cell
|
|
6
6
|
margin: 1rem 0
|
|
7
|
+
p:first-child>strong:only-child
|
|
8
|
+
font-size: $fs-h4
|
|
7
9
|
>.cell>
|
|
8
10
|
p
|
|
9
11
|
line-height: 1.5
|
|
@@ -29,4 +31,8 @@
|
|
|
29
31
|
background: var(--block)
|
|
30
32
|
&[bg='card']>.cell
|
|
31
33
|
background: var(--card)
|
|
32
|
-
box-shadow: $boxshadow-card
|
|
34
|
+
box-shadow: $boxshadow-card
|
|
35
|
+
trans2 box-shadow transform
|
|
36
|
+
&:hover
|
|
37
|
+
transform: translateY(-1px)
|
|
38
|
+
box-shadow: $boxshadow-card-float
|
|
@@ -192,11 +192,9 @@
|
|
|
192
192
|
border-color: var(--block)
|
|
193
193
|
|
|
194
194
|
.tag-plugin.timeline .body blockquote
|
|
195
|
-
|
|
196
|
-
box-shadow: none
|
|
197
|
-
border-left: 4px solid var(--block-border)
|
|
195
|
+
background: none
|
|
198
196
|
border-radius: 0
|
|
199
|
-
|
|
197
|
+
padding: 0 0.5rem
|
|
200
198
|
margin: 0.75rem 0
|
|
201
199
|
p
|
|
202
200
|
font-size: $fs-13
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
<%
|
|
2
|
-
var proj;
|
|
3
|
-
if (page.layout === 'wiki' && page.wiki) {
|
|
4
|
-
proj = theme.wiki.projects[page.wiki];
|
|
5
|
-
}
|
|
6
|
-
function layoutTitle(main, url, sub) {
|
|
7
|
-
var el = '';
|
|
8
|
-
el += '<a class="title" href="' + url_for(url || "/") + '">';
|
|
9
|
-
el += '<div class="main" ff="title">' + main + '</div>';
|
|
10
|
-
if (sub) {
|
|
11
|
-
let arr = sub.split('|');
|
|
12
|
-
if (arr.length > 1) {
|
|
13
|
-
el += '<div class="sub normal cap">' + arr[0].trim() + '</div>';
|
|
14
|
-
el += '<div class="sub hover cap" style="opacity:0">' + arr[1].trim() + '</div>';
|
|
15
|
-
} else if (arr.length > 0) {
|
|
16
|
-
el += '<div class="sub cap">' + arr[0] + '</div>';
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
el += '</a>';
|
|
20
|
-
return el;
|
|
21
|
-
}
|
|
22
|
-
function layoutDiv() {
|
|
23
|
-
var el = '';
|
|
24
|
-
if (page.layout == 'wiki' && proj && proj.index != false) {
|
|
25
|
-
el += '<div class="logo-wrap wiki">';
|
|
26
|
-
// all products
|
|
27
|
-
el += '<a style="filter: grayscale(100%)" class="wiki-home cap" href="' + url_for(config.wiki_dir) + '">';
|
|
28
|
-
el += '<svg aria-hidden="true" viewBox="0 0 16 16" width="1rem" height="1rem" fill="currentColor"><path fill-rule="evenodd" d="M7.78 12.53a.75.75 0 01-1.06 0L2.47 8.28a.75.75 0 010-1.06l4.25-4.25a.75.75 0 011.06 1.06L4.81 7h7.44a.75.75 0 010 1.5H4.81l2.97 2.97a.75.75 0 010 1.06z"></path></svg>';
|
|
29
|
-
el += __('btn.all_wiki');
|
|
30
|
-
el += '</a>';
|
|
31
|
-
// this product
|
|
32
|
-
if (proj == undefined) {
|
|
33
|
-
// 如果没有项目名,则使用menu中显示的名字
|
|
34
|
-
if (page.menu_id && theme.sidebar.menu[page.menu_id] && md_link(theme.sidebar.menu[page.menu_id])) {
|
|
35
|
-
proj = {
|
|
36
|
-
path: md_link(theme.sidebar.menu[page.menu_id]),
|
|
37
|
-
wiki: __(md_text(theme.sidebar.menu[page.menu_id]))
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
if (proj != undefined) {
|
|
42
|
-
let main = proj.name || proj.title || page.wiki || page.title;
|
|
43
|
-
let url = proj.homepage.path;
|
|
44
|
-
let sub = proj.subtitle;
|
|
45
|
-
el += layoutTitle(main, url, sub);
|
|
46
|
-
}
|
|
47
|
-
} else {
|
|
48
|
-
el += '<div class="logo-wrap">';
|
|
49
|
-
if (md_text(theme.sidebar.logo.avatar)) {
|
|
50
|
-
el += '<a class="avatar" href="' + url_for(md_link(theme.sidebar.logo.avatar) || "/") + '">';
|
|
51
|
-
if (theme.style.animated_avatar.animate) {
|
|
52
|
-
el += '<div class="bg" style="opacity:0;background-image:url(' + theme.style.animated_avatar.background + ');"></div>';
|
|
53
|
-
}
|
|
54
|
-
el += '<img no-lazy class="avatar" src="' + md_text(theme.sidebar.logo.avatar) + '">';
|
|
55
|
-
el += '</a>';
|
|
56
|
-
}
|
|
57
|
-
let main = md_text(theme.sidebar.logo.title);
|
|
58
|
-
if (main) {
|
|
59
|
-
let url = md_link(theme.sidebar.logo.title);
|
|
60
|
-
let sub = config.subtitle;
|
|
61
|
-
el += layoutTitle(main, url, sub);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
el += '</div>';
|
|
65
|
-
return el;
|
|
66
|
-
}
|
|
67
|
-
%>
|
|
68
|
-
|
|
69
|
-
<%- layoutDiv() %>
|