-
-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #328 from everfu/dev
Dev
- Loading branch information
Showing
29 changed files
with
334 additions
and
240 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,7 +37,7 @@ page: | |
404: Page not found | ||
|
||
home: | ||
home: Home | ||
home: Recommend | ||
sticky: Sticky | ||
new: New | ||
read: Unread | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,7 +37,7 @@ page: | |
404: Page not found | ||
|
||
home: | ||
home: Home | ||
home: Recommend | ||
sticky: Sticky | ||
new: New | ||
read: Unread | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,7 +46,7 @@ nav: | |
console: 中控台 | ||
|
||
home: | ||
home: 首页 | ||
home: 推荐 | ||
sticky: 置顶 | ||
new: 最新 | ||
read: 未读 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,7 +46,7 @@ nav: | |
console: 中控台 | ||
|
||
home: | ||
home: 首頁 | ||
home: 推薦 | ||
sticky: 置頂 | ||
new: 最新 | ||
read: 未讀 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
- const { server, site } = theme.artalk | ||
|
||
script. | ||
function updatePostsBasedOnComments() { | ||
const location = window.location | ||
const posts = Array.from(document.querySelectorAll('.recent-post-item[onclick] .post_cover a')).map(item => item.href.replace(location, GLOBAL_CONFIG.root)) | ||
|
||
function get() { | ||
fetch(`!{server}/api/v2/stats/page_comment?page_keys=${posts.join(',')}&site_name=!{site}`).then(res => res.json()) | ||
.then(item => { | ||
item = item.data | ||
posts.forEach(post => { | ||
const comment = item[post] | ||
if (comment > !{count}) { | ||
const postElement = document.querySelector(`.recent-post-item[onclick*="${post}"]`); | ||
if (postElement) { | ||
const infoTopTips = postElement.querySelector(".recent-post-info-top-tips"), | ||
originalSpan = infoTopTips ? infoTopTips.querySelector(".original") : null; | ||
if (originalSpan) { | ||
const hotTip = createHotTipElement(); | ||
infoTopTips.insertBefore(hotTip, originalSpan); | ||
} | ||
} | ||
} | ||
}) | ||
}) | ||
.catch(error => console.error("Error fetching comments:", error)); | ||
} | ||
|
||
function createHotTipElement() { | ||
const hotTip = document.createElement("span"); | ||
hotTip.classList.add("hot-tip"); | ||
|
||
const icon = document.createElement("i"); | ||
icon.classList.add("solitude", "st-fire-fill"); | ||
hotTip.appendChild(icon); | ||
|
||
const commentCount = document.createTextNode("!{_p('hot-tip')}"); | ||
hotTip.appendChild(commentCount); | ||
|
||
return hotTip; | ||
} | ||
|
||
get() | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,6 @@ | |
if use | ||
case use[0] | ||
when 'Twikoo' | ||
include ./twikoo | ||
include ./twikoo | ||
when 'Artalk' | ||
include ./artalk |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "hexo-theme-solitude", | ||
"version": "1.13.3", | ||
"version": "1.13.4", | ||
"description": "A beautiful, powerful, and efficient Hexo theme developed by EverFu.", | ||
"main": "package.json", | ||
"scripts": { | ||
|
@@ -26,7 +26,7 @@ | |
"url": "https://github.com/everfu/hexo-theme-solitude/issues", | ||
"email": "[email protected]" | ||
}, | ||
"homepage": "https://www.efu.me/", | ||
"homepage": "https://everfu.github.io/Solitude/", | ||
"author": "Hexo-Theme-Solitude<[email protected]>", | ||
"license": "MIT" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -89,4 +89,7 @@ | |
height 20px | ||
|
||
img | ||
border-radius 200px | ||
border-radius 200px | ||
width 100% | ||
height 100% | ||
object-fit cover |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.