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

Update: Make 404 pages support multiple languages, and increase the length of the article summary #417

Merged
merged 8 commits into from
Aug 31, 2024
1 change: 1 addition & 0 deletions languages/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ archive: Archive
archives: Archives
top: TOP
sticky: Sticky
go-back-home: Go Back Home


# ----------------------------------------
Expand Down
1 change: 1 addition & 0 deletions languages/ja.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ comment: コメント
comments: コメント
top: トップ
sticky: 屋根
go-back-home: トップページに戻ります

# ----------------------------------------
# 菜单翻译
Expand Down
1 change: 1 addition & 0 deletions languages/zh-CN.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ comment: 评论
comments: 评论
top: 置顶
sticky: 置顶
go-back-home: 回到首页

# ----------------------------------------
# 菜单翻译
Expand Down
1 change: 1 addition & 0 deletions languages/zh-TW.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ comment: 留言
comments: 留言
top: 頂端
sticky: 置頂
go-back-home: 回到首頁

# ----------------------------------------
# 菜单翻译
Expand Down
2 changes: 1 addition & 1 deletion layout/_partials/404-template.ejs
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code will not run correctly as the git conflict is not solved

Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
<h1>404<br>Page Not Found</h1>
</div>
<div class="nf-button">
<a href="/" class="button large center"><i class="fa-regular fa-house"></i> Go Back Home</a>
<a href="/" class="button large center"><i class="fa-regular fa-house"></i> go-back-home</a>
</div>
</div>
2 changes: 1 addition & 1 deletion layout/_partials/home-content.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
<% } else if (post.excerpt && post.excerpt !== "false") { %>
<%- render(post.excerpt, "markdown") %>
<% } else { %>
<%- truncate(strip_html(post.content), {length: 128}) %>
<%- truncate(strip_html(post.content), {length: 300}) %>
<% } %>
</div>

Expand Down