Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release new version #255

Merged
merged 7 commits into from
Sep 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Bug Report | Bug 报告
description: Something isn't working as expected
#title: ""
labels:
labels:
- bug
#assignees: ""
body:
Expand All @@ -20,7 +20,7 @@ body:
I made sure I checked
我确认我已经检查过了
options:
- label: I am using Keep version 3.7.3 or later.
- label: I am using Keep version 3.8.1 or later.
required: true
- label: I have already read the [Troubleshooting page of Hexo](https://hexo.io/docs/troubleshooting) and [Keep documents](https://keep-docs.xpoet.cn/tutorial/get-start/install-theme.html).
required: true
Expand Down Expand Up @@ -86,7 +86,7 @@ body:
id: hexo-config
attributes:
label: Hexo Configuration | Hexo 配置
description: |
description: |
"Paste configuration from Hexo `_config.yml`
粘贴 Hexo `_config.yml` 中的内容
render: YAML
Expand All @@ -97,7 +97,7 @@ body:
id: keep-config
attributes:
label: Keep Configuration | Keep 配置
description: |
description: |
Paste ONLY CHANGED CONFIGURATION from Keep `_config.yml`
只粘贴 Keep 主题配置文件 `_config.yml` 中修改过的部分
render: YAML
Expand All @@ -108,7 +108,7 @@ body:
id: other-info
attributes:
label: Other Information | 其它信息
description: |
description: |
e.g. Browser, System
例如:浏览器,操作系统
validations:
Expand Down
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/feature-request.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Feature Request | 功能需求
description: Suggest an idea for this project
#title: ""
labels:
labels:
- feature request
#assignees: ""
body:
Expand All @@ -20,7 +20,7 @@ body:
I made sure I checked
我确认我已经检查过了
options:
- label: I am using Keep version 3.7.3 or later.
- label: I am using Keep version 3.8.1 or later.
required: true
- label: I have already read the [Troubleshooting page of Hexo](https://hexo.io/docs/troubleshooting) and [Keep documents](https://keep-docs.xpoet.cn/tutorial/get-start/install-theme.html).
required: true
Expand Down
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/other.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Other | 其他
description: Not a feature request or bug report
#title: ""
labels:
labels:
- question
#assignees: ""
body:
Expand All @@ -20,7 +20,7 @@ body:
I made sure I checked
我确认我已经检查过了
options:
- label: I am using Keep version 3.7.3 or later.
- label: I am using Keep version 3.8.1 or later.
required: true
- label: I have already read the [Troubleshooting page of Hexo](https://hexo.io/docs/troubleshooting) and [Keep documents](https://keep-docs.xpoet.cn/tutorial/get-start/install-theme.html).
required: true
Expand Down
4 changes: 2 additions & 2 deletions layout/_partial/post/reward-author.ejs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<div class="reward-author-container border-box flex-center">
<button class="keep-button border-box flex-center reward-btn tooltip tooltip-img"
<div class="reward-btn keep-button border-box flex-center tooltip tooltip-img"
data-tooltip-content="<%= theme?.post?.reward?.text || __('post.reward') %>"
data-tooltip-img-url="<%= theme?.post?.reward?.img_link %>"
data-tooltip-img-trigger="click"
data-tooltip-img-style="top: -8px;"
>
<i class="fa-solid fa-hand-holding-heart"></i>
</button>
</div>
</div>
2 changes: 1 addition & 1 deletion layout/article-content.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
<ul class="post-tags-box border-box">
<% page.tags.forEach((tag) => { %>
<li class="tag-item border-box">
<a href="<%- url_for(tag.path) %>"><i class="icon fas fa-hashtag"></i><%= tag.name %></a>&nbsp;
<i class="icon fas fa-hashtag"></i>&nbsp;<a href="<%- url_for(tag.path) %>"><%= tag.name %></a>
</li>
<% }) %>
</ul>
Expand Down
20 changes: 17 additions & 3 deletions source/css/layout/_partial/article-meta-info.styl
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
$home-page-font-size = 0.92rem
$post-page-font-size = 0.86rem
$meta-icon-interspace = 0.3rem


.article-meta-info-container {
Expand Down Expand Up @@ -91,9 +92,16 @@ $post-page-font-size = 0.86rem


.article-category {
word-spacing -1rem

.category-item {

&:first-child {
margin-left $meta-icon-interspace
}

.category-separator {
margin 0 0.05rem
margin 0 $meta-icon-interspace

i.icon {
font-size $home-page-font-size * 0.7
Expand All @@ -108,15 +116,21 @@ $post-page-font-size = 0.86rem


.article-tag {
word-spacing -1rem

.tag-item {
margin-right 0.1rem
margin-right $meta-icon-interspace

&:first-child {
margin-left $meta-icon-interspace
}

&:last-child {
margin-right 0
}

.tag-separator {
margin-right 0.1rem
margin-right $meta-icon-interspace * 0.5

i.icon {
font-size $home-page-font-size * 0.7
Expand Down
1 change: 1 addition & 0 deletions source/css/layout/_partial/first-screen.styl
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ $first-screen-img = $temp-img ? $temp-img : '/images/bg.svg'
font-size var(--first-screen-font-size)
line-height 1.8
text-align center
opacity 0

.dark-mode & {
color var(--first-screen-font-color-dark)
Expand Down
6 changes: 3 additions & 3 deletions source/css/layout/_partial/post/reward-author.styl
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@


.reward-btn {
width 2.6rem
height 2.6rem
width 3rem
height 3rem
border-radius 50%

i {
font-size 1rem
font-size 1.2rem
}
}
}
19 changes: 3 additions & 16 deletions source/css/layout/article-content.styl
Original file line number Diff line number Diff line change
Expand Up @@ -274,28 +274,15 @@ $spacer-padding = 2rem
align-items center
justify-content flex-start
width 100%
font-size 1rem

+keep-tablet() {
font-size 0.9rem

.tag-item {
margin-right 0.4rem

.icon {
font-size 0.82rem
}
}
}
font-size 0.96rem


.tag-item {
margin-right 0.5rem
margin-right 0.4rem
line-height 2

.icon {
margin-right 0.2rem
font-size 0.92rem
font-size 0.88rem
}
}
}
Expand Down
13 changes: 8 additions & 5 deletions source/js/header-shrink.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,19 @@

KEEP.initHeaderShrink = () => {
KEEP.utils.headerShrink = {
headerDom: document.querySelector('.header-wrapper'),
headerWrapperDom: null,
isHeaderShrink: false,
headerHeight: 70,

init() {
this.headerHeight = this.headerDom.getBoundingClientRect().height
this.headerWrapperDom = document.querySelector('.header-wrapper')
if (this.headerWrapperDom) {
this.headerHeight = this.headerWrapperDom.getBoundingClientRect().height
}
},

headerShrink() {
const scrollTop = document.body.scrollTop || document.documentElement.scrollTop
const headerWrapperDom = document.querySelector('.header-wrapper')
const { enable, header_transparent } = KEEP.theme_config?.style?.first_screen || {}
const isHeaderTransparent =
enable === true &&
Expand All @@ -22,13 +25,13 @@ KEEP.initHeaderShrink = () => {
this.isHeaderShrink = true
document.body.classList.add('header-shrink')
if (isHeaderTransparent) {
headerWrapperDom.classList.add('transparent-2')
this.headerWrapperDom.classList.add('transparent-2')
}
} else if (this.isHeaderShrink && scrollTop <= this.headerHeight) {
this.isHeaderShrink = false
document.body.classList.remove('header-shrink')
if (isHeaderTransparent) {
headerWrapperDom.classList.remove('transparent-2')
this.headerWrapperDom.classList.remove('transparent-2')
}
}
},
Expand Down