diff --git a/templates/archives.html b/templates/archives.html index 8b9a19b9..00f94424 100644 --- a/templates/archives.html +++ b/templates/archives.html @@ -13,7 +13,7 @@
文章 - [[${siteStatsFinder.getStats().post}]]
+ th:with='postRandomImg=${#strings.contains(theme.config.layout.postRandomImg,"?") ? theme.config.layout.postRandomImg+"&" : theme.config.layout.postRandomImg+"?"}'>
diff --git a/templates/assets/css/related-posts-six.css b/templates/assets/css/related-posts-six.css index ee9c7c5a..ce41da5a 100644 --- a/templates/assets/css/related-posts-six.css +++ b/templates/assets/css/related-posts-six.css @@ -3,7 +3,6 @@ .relatedPosts-list { display: flex; flex-wrap: wrap; - justify-content: space-between; } .relatedPosts>.relatedPosts-list>div { background: #363636; diff --git a/templates/assets/libs/gpt/post-ai.js b/templates/assets/libs/gpt/post-ai.js index b7d7f0b2..0088561f 100644 --- a/templates/assets/libs/gpt/post-ai.js +++ b/templates/assets/libs/gpt/post-ai.js @@ -17,43 +17,44 @@ let keys = GLOBAL_CONFIG.source.postAi.keys; let Referers = GLOBAL_CONFIG.source.postAi.Referers; - let post = document.querySelector('#post') - const interface = { - name: "AI-摘要", - aiToggle: "切换", - version: "Tianli GPT", - button: ["介绍自己", "生成本文简介", "推荐相关文章", "前往主页"], - } - // 插入html结构 - const post_ai_box = document.createElement('div'); - post_ai_box.className = 'post-ai'; - post.insertBefore(post_ai_box, post.firstChild); + // let post = document.querySelector('#post') + // const interface = { + // name: "AI-摘要", + // aiToggle: "切换", + // version: "Tianli GPT", + // button: ["介绍自己", "生成本文简介", "推荐相关文章", "前往主页"], + // } + // // 插入html结构 + // const post_ai_box = document.createElement('div'); + // post_ai_box.className = 'post-ai'; + // post.insertBefore(post_ai_box, post.firstChild); + // + // var PostAI = ` + //
+ // + //
${interface.name}
` + // if (switchBtn) { + // PostAI += `
${interface.aiToggle}
`; + // } + // PostAI += ` `; + // if (modeName == 'local') { + // PostAI += `
${gptName} GPT
`; + // } else { + // PostAI += `
${interface.version}
`; + // } + // PostAI += ` + //
+ //
AI初始化中...
+ //
+ //
${interface.button[0]}
+ //
${interface.button[1]}
+ //
${interface.button[2]}
+ //
${interface.button[3]}
+ //
前往tianli博客
+ //
`; + // + // post_ai_box.innerHTML = PostAI; - var PostAI = ` -
- -
${interface.name}
` - if (switchBtn) { - PostAI += `
${interface.aiToggle}
`; - } - PostAI += ` `; - if (modeName == 'local') { - PostAI += `
${gptName} GPT
`; - } else { - PostAI += `
${interface.version}
`; - } - PostAI += ` -
-
AI初始化中...
-
-
${interface.button[0]}
-
${interface.button[1]}
-
${interface.button[2]}
-
${interface.button[3]}
-
前往tianli博客
-
`; - - post_ai_box.innerHTML = PostAI; // 当前随机到的ai摘要到index let lastAiRandomIndex = -1; let animationRunning = true; // 标志变量,控制动画函数的运行 diff --git a/templates/assets/zhheo/zhheoblog.css b/templates/assets/zhheo/zhheoblog.css index 27f763dd..02ad355d 100644 --- a/templates/assets/zhheo/zhheoblog.css +++ b/templates/assets/zhheo/zhheoblog.css @@ -1369,9 +1369,9 @@ blockquote footer cite::before { transition: all 0.3s ease 0s; } -@media screen and (max-width: 900px) { - .layout > div:first-child { - width: 100% !important; +@media screen and (max-width: 1200px) { + .layout>div:first-child { + width:100%!important } } @@ -6754,9 +6754,9 @@ a.console_switchbutton { } } -@media screen and (max-width: 900px) { +@media screen and (max-width: 1200px) { #aside-content { - display: none; + display:none } } diff --git a/templates/category.html b/templates/category.html index 1bcfb8d3..1d80cbdb 100644 --- a/templates/category.html +++ b/templates/category.html @@ -35,7 +35,7 @@
+ th:with='postRandomImg=${#strings.contains(theme.config.layout.postRandomImg,"?") ? theme.config.layout.postRandomImg+"&" : theme.config.layout.postRandomImg+"?"}'>
+ postRandomImg=${#strings.contains(theme.config.layout.postRandomImg,"?") ? theme.config.layout.postRandomImg+"&" : theme.config.layout.postRandomImg+"?"}'>
+ postRandomImg=${#strings.contains(theme.config.layout.postRandomImg,"?") ? theme.config.layout.postRandomImg+"&" : theme.config.layout.postRandomImg+"?"}'>
+ @@ -55,7 +56,6 @@
- @@ -86,8 +86,8 @@ - - + + diff --git a/templates/modules/post-list.html b/templates/modules/post-list.html index e5ae9910..59507ffb 100644 --- a/templates/modules/post-list.html +++ b/templates/modules/post-list.html @@ -3,7 +3,7 @@ + postRandomImg=${#strings.contains(theme.config.layout.postRandomImg,"?") ? theme.config.layout.postRandomImg+"&" : theme.config.layout.postRandomImg+"?"}'>
diff --git a/templates/modules/post/relatedPosts.html b/templates/modules/post/relatedPosts.html index 9e6d95e7..29cde02e 100644 --- a/templates/modules/post/relatedPosts.html +++ b/templates/modules/post/relatedPosts.html @@ -3,7 +3,8 @@ +containsTitle = ${#strings.contains(recommandPosts,post.spec.title)}, +postRandomImg=${#strings.contains(theme.config.layout.postRandomImg,'?') ? theme.config.layout.postRandomImg+'&' : theme.config.layout.postRandomImg+'?'}">