';
- var height = '';
- var src = '';
- page.logo.split(' ').forEach(function(item) {
- if (item.includes('px')) {
- height = item;
- } else {
- src = item;
- }
- });
- if (height.length > 0) {
- el += '';
+ if (page.logo && page.logo.src && cover.includes('logo')) {
+ el += '
';
+ if (page.logo.large) {
+ el += '';
} else {
- el += '';
+ el += '';
}
el += '
';
}
diff --git a/layout/_partial/main/post_list/wiki_card.ejs b/layout/_partial/main/post_list/wiki_card.ejs
index 7c47c8e..3f2e308 100644
--- a/layout/_partial/main/post_list/wiki_card.ejs
+++ b/layout/_partial/main/post_list/wiki_card.ejs
@@ -1,44 +1,31 @@
-<% if (post.logo) { %>
- <%
- var arr = post.logo.split(' ');
- var height = '';
- var src = '';
- arr.forEach(function(item) {
- var px = item.match(/[0-9]*px/i);
- if (px && px.length > 0) {
- px = px[0];
- height = px;
- } else {
- src = item;
+<%
+function layoutDiv() {
+ var el = '';
+ if (post.logo && post.logo.src) {
+ el += '';
+ el += '
-
';
+ return el;
+}
+%>
+<%- layoutDiv() %>
diff --git a/layout/_partial/sidebar/index.ejs b/layout/_partial/sidebar/index.ejs
index 3b094fb..936ec74 100755
--- a/layout/_partial/sidebar/index.ejs
+++ b/layout/_partial/sidebar/index.ejs
@@ -6,7 +6,7 @@ if (page.sidebar == undefined) {
} else if (page.layout == 'wiki' && page.content) {
page.sidebar = ['toc', 'wiki_more'];
} else {
- page.sidebar = ['welcome', 'recent'];
+ page.sidebar = theme.sidebar.widgets.layout;
}
}
function layoutFooterDiv() {
diff --git a/source/css/_layout/base.styl b/source/css/_layout/base.styl
index ea97f9f..67135ce 100644
--- a/source/css/_layout/base.styl
+++ b/source/css/_layout/base.styl
@@ -109,7 +109,7 @@ ol ul, ol ol
table:not([class])
border-collapse: collapse
overflow: auto
- display: inline-block
+ margin: 1rem 0
max-width: 100%
vertical-align: text-top
th
diff --git a/source/css/_layout/navbar.styl b/source/css/_layout/navbar.styl
index e4b83e2..51ae334 100644
--- a/source/css/_layout/navbar.styl
+++ b/source/css/_layout/navbar.styl
@@ -25,19 +25,6 @@ nav.cap
a+a
margin-left: 4px
-.md .tag-plugin.navbar
- nav.cap
- margin: 0
- padding: 1px
- background: var(--block)
- border-radius: 6px
- a
- margin: 1px
- padding: 0.5em 0.75rem
- &:hover
- background: #fff
- color: var(--text-p1)
-
// 面包屑导航
.breadcrumb-navigation
diff --git a/source/css/_layout/partial/cover.styl b/source/css/_layout/partial/cover.styl
index 27f7a65..096313c 100644
--- a/source/css/_layout/partial/cover.styl
+++ b/source/css/_layout/partial/cover.styl
@@ -9,12 +9,14 @@
.l_cover .cover-wrap
margin-bottom: 0
max-width: 500px
- .logo
+ .preview
margin-bottom: 2rem
img
object-fit: contain
max-height: 35vh
max-width: 100%
+ @media screen and (max-width: 500px)
+ max-width: 60%
.cover-title
font-weight: 700
font-size: 1.5rem
diff --git a/source/css/_layout/partial/read_next.styl b/source/css/_layout/partial/read_next.styl
index 43310f6..9476ae6 100644
--- a/source/css/_layout/partial/read_next.styl
+++ b/source/css/_layout/partial/read_next.styl
@@ -12,6 +12,6 @@
color: $color-hover
&.read
color: var(--text-p3)
- font-size: $fs12
+ font-size: $fs14
&.unread
- font-size: $fsh2
+ font-size: 1.75rem
diff --git a/source/css/_layout/partial/related_posts.styl b/source/css/_layout/partial/related_posts.styl
index 4923124..5ee1d36 100644
--- a/source/css/_layout/partial/related_posts.styl
+++ b/source/css/_layout/partial/related_posts.styl
@@ -22,8 +22,8 @@ div.related-posts-wrap
flex-direction: column
overflow: hidden
width: 360px
- opacity: 0.7
- trans1: opacity 0.5s
+ // opacity: 0.7
+
border: 1px solid var(--hover-block)
.img
height: 180px
@@ -32,6 +32,7 @@ div.related-posts-wrap
width: 100%
height: 100%
object-fit: cover
+ trans1: transform 1s
@media screen and (max-width: $device-tablet)
width: 300px
.img
@@ -56,7 +57,8 @@ div.related-posts-wrap
overflow: hidden
-webkit-line-clamp: 3
&:hover
- opacity: 1
+ img
+ transform: scale(1.04)
a+a
margin-left: $gap
diff --git a/source/css/_layout/post_list.styl b/source/css/_layout/post_list.styl
index 39495c1..d44512d 100644
--- a/source/css/_layout/post_list.styl
+++ b/source/css/_layout/post_list.styl
@@ -29,7 +29,7 @@
margin-left: 0.5rem
.post-list .post-card:hover
box-shadow: 0 2px 8px 0px rgba(0, 0, 0, 0.04), 0 4px 16px 0px rgba(0, 0, 0, 0.04)
- .logo img
+ .preview img
transform: scale(1.1)
.excerpt .readmore
color: $color-link
@@ -85,9 +85,9 @@
justify-content: center
-.post-list .post-card.wiki article .logo
+.post-list .post-card.wiki article .preview
display: flex
- width: 180px
+ width: 200px
margin: 1rem
align-items: center
img
@@ -99,9 +99,10 @@
flex: 1
overflow: hidden
word-wrap: break-word
- .title
- font-weight: 600
- font-size: $fs-h3
+ .post-title
+ margin-top: 0.5rem
+ font-weight: 500
+ font-size: 1.75rem
>p
margin: 0.5rem 0
font-size: $fs14
diff --git a/source/css/_layout/sidebar.styl b/source/css/_layout/sidebar.styl
index dd16971..6ea1141 100644
--- a/source/css/_layout/sidebar.styl
+++ b/source/css/_layout/sidebar.styl
@@ -125,7 +125,7 @@ nav.menu
line-height: 0
.social-wrap
display: grid
- grid-gap: $gap * 0.5 $gap * 0.5
+ grid-gap: $gap * 0.25 $gap * 0.25
grid-template-columns: repeat(auto-fill, 32px)
a
display: inline-block
diff --git a/source/css/_layout/tag-plugins/about.styl b/source/css/_layout/tag-plugins/about.styl
index 84467a8..8aa6c46 100644
--- a/source/css/_layout/tag-plugins/about.styl
+++ b/source/css/_layout/tag-plugins/about.styl
@@ -42,7 +42,7 @@
color: $color-hover
background: none
a+a
- margin-left: 1rem
+ margin-left: 1.5rem
.about-header+.about-body
margin-top: 1.5rem
diff --git a/source/css/_layout/tag-plugins/navbar.styl b/source/css/_layout/tag-plugins/navbar.styl
new file mode 100644
index 0000000..a35ff66
--- /dev/null
+++ b/source/css/_layout/tag-plugins/navbar.styl
@@ -0,0 +1,12 @@
+.md .tag-plugin.navbar
+ nav.cap
+ margin: 0
+ padding: 1px
+ background: var(--block)
+ border-radius: 6px
+ a
+ margin: 1px
+ padding: 0.5em 0.75rem
+ &:hover
+ background: #fff
+ color: var(--text-p1)
diff --git a/source/css/_plugins/common/loading.styl b/source/css/_plugins/common/loading.styl
index 74e819a..c7fd1d4 100644
--- a/source/css/_plugins/common/loading.styl
+++ b/source/css/_plugins/common/loading.styl
@@ -1,6 +1,7 @@
svg.loading
display: block
position: absolute
+ color: var(--text-p3)
z-index: -1
width: 100%
height: 2rem
- <% if (height.length > 0) { %>
-
- <% } else { %>
-
- <% } %>
-
-<% } %>
-
- <%
+ el += '/>';
+ el += '
';
+ }
+ el += '';
var cat = '';
site.pages.filter(function (p) {
return p.layout == 'index' && p.title && p.wiki && p.wiki.includes(post.wiki)
}).limit(1).each(function(p) {
cat = p.title;
});
- %>
- <% if (cat) { %>
-
+ if (cat) {
+ el += '
- <% } %>
- ';
+ }
+ el += '<%- post.wiki || post.title %>
- <% if (post.description) { %> -<%- post.description %>
- <% } else if (post.excerpt) { %> - <%- strip_html(post.excerpt) %> - <% } %> -' + (post.wiki || post.title || post.seo_title) + '
'; + el += '' + post.description + '
'; + el += '