commit
7d00015e75
|
@ -446,6 +446,7 @@ spec:
|
|||
- $formkit: repeater
|
||||
if: $get(nav).value === 'custom-category'
|
||||
name: navCustomCategory
|
||||
key: navCustomCategory
|
||||
label: 自定义分类
|
||||
value: [ ]
|
||||
children:
|
||||
|
@ -455,6 +456,7 @@ spec:
|
|||
- $formkit: repeater
|
||||
if: $get(nav).value === 'custom-tag'
|
||||
name: navCustomTag
|
||||
key: navCustomTag
|
||||
label: 自定义标签
|
||||
value: [ ]
|
||||
children:
|
||||
|
@ -464,6 +466,7 @@ spec:
|
|||
- $formkit: repeater
|
||||
if: $get(nav).value === 'custom-url'
|
||||
name: navCustomUrl
|
||||
key: navCustomUrl
|
||||
label: 自定义路径
|
||||
value: [ ]
|
||||
children:
|
||||
|
@ -554,7 +557,7 @@ spec:
|
|||
- $formkit: group
|
||||
name: widgetss
|
||||
label: 侧边栏内容
|
||||
help: 目前提供的小部件有:profile(站点资料), wechat(微信), power(爱发电赞助), welcome(小板报), steam(Steam卡片), music(音乐卡片), friend-link(通讯录), recent-posts(近期文章), comments(最新评论), categories(文章分类), tags(文章标签), stat(统计), tags-stat(标签&归档&统计), adbox(广告区域)。你可以随意组合或排序,以逗号隔开。
|
||||
help: 目前提供的小部件有:profile(个人卡片), wechat(公众号), power(爱发电赞助), welcome(小板报), steam(Steam卡片), music(音乐卡片), friend-link(通讯录), recent-posts(最新文章), comments(最新评论), categories(文章分类), tags(文章标签), stat(统计), tags-stat(标签&归档&统计), adbox(广告区域)。你可以随意组合或排序,以逗号隔开。
|
||||
value:
|
||||
indexWidgets: profile,wechat,comments,recent-posts,categories,tags-stat
|
||||
postWidgets: profile,wechat,toc,comments,recent-posts,categories,tags-stat
|
||||
|
@ -2324,10 +2327,6 @@ spec:
|
|||
- group: style
|
||||
label: 样式
|
||||
formSchema:
|
||||
- $formkit: checkbox
|
||||
name: enableChangeColorScheme
|
||||
label: 允许访客切换配色
|
||||
value: true
|
||||
- $formkit: radio
|
||||
name: colorScheme
|
||||
label: 默认配色
|
||||
|
|
|
@ -310,7 +310,6 @@ img.post-copyright__author_img_front {
|
|||
display: -moz-box;
|
||||
display: -webkit-flex;
|
||||
display: -ms-flexbox;
|
||||
display: box;
|
||||
display: flex;
|
||||
margin: 10px
|
||||
}
|
||||
|
|
|
@ -0,0 +1,539 @@
|
|||
/* Logo 字体 */
|
||||
@font-face {
|
||||
font-family: "iconfont logo";
|
||||
src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834');
|
||||
src: url('https://at.alicdn.com/t/font_985780_km7mi63cihi.eot?t=1545807318834#iefix') format('embedded-opentype'),
|
||||
url('https://at.alicdn.com/t/font_985780_km7mi63cihi.woff?t=1545807318834') format('woff'),
|
||||
url('https://at.alicdn.com/t/font_985780_km7mi63cihi.ttf?t=1545807318834') format('truetype'),
|
||||
url('https://at.alicdn.com/t/font_985780_km7mi63cihi.svg?t=1545807318834#iconfont') format('svg');
|
||||
}
|
||||
|
||||
.logo {
|
||||
font-family: "iconfont logo";
|
||||
font-size: 160px;
|
||||
font-style: normal;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
/* tabs */
|
||||
.nav-tabs {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.nav-tabs .nav-more {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
height: 42px;
|
||||
line-height: 42px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
#tabs {
|
||||
border-bottom: 1px solid #eee;
|
||||
}
|
||||
|
||||
#tabs li {
|
||||
cursor: pointer;
|
||||
width: 100px;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
text-align: center;
|
||||
font-size: 16px;
|
||||
border-bottom: 2px solid transparent;
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
margin-bottom: -1px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
|
||||
#tabs .active {
|
||||
border-bottom-color: #f00;
|
||||
color: #222;
|
||||
}
|
||||
|
||||
.tab-container .content {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* 页面布局 */
|
||||
.main {
|
||||
padding: 30px 100px;
|
||||
width: 960px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.main .logo {
|
||||
color: #333;
|
||||
text-align: left;
|
||||
margin-bottom: 30px;
|
||||
line-height: 1;
|
||||
height: 110px;
|
||||
margin-top: -50px;
|
||||
overflow: hidden;
|
||||
*zoom: 1;
|
||||
}
|
||||
|
||||
.main .logo a {
|
||||
font-size: 160px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.helps {
|
||||
margin-top: 40px;
|
||||
}
|
||||
|
||||
.helps pre {
|
||||
padding: 20px;
|
||||
margin: 10px 0;
|
||||
border: solid 1px #e7e1cd;
|
||||
background-color: #fffdef;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
.icon_lists {
|
||||
width: 100% !important;
|
||||
overflow: hidden;
|
||||
*zoom: 1;
|
||||
}
|
||||
|
||||
.icon_lists li {
|
||||
width: 100px;
|
||||
margin-bottom: 10px;
|
||||
margin-right: 20px;
|
||||
text-align: center;
|
||||
list-style: none !important;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.icon_lists li .code-name {
|
||||
line-height: 1.2;
|
||||
}
|
||||
|
||||
.icon_lists .icon {
|
||||
display: block;
|
||||
height: 100px;
|
||||
line-height: 100px;
|
||||
font-size: 42px;
|
||||
margin: 10px auto;
|
||||
color: #333;
|
||||
-webkit-transition: font-size 0.25s linear, width 0.25s linear;
|
||||
-moz-transition: font-size 0.25s linear, width 0.25s linear;
|
||||
transition: font-size 0.25s linear, width 0.25s linear;
|
||||
}
|
||||
|
||||
.icon_lists .icon:hover {
|
||||
font-size: 100px;
|
||||
}
|
||||
|
||||
.icon_lists .svg-icon {
|
||||
/* 通过设置 font-size 来改变图标大小 */
|
||||
width: 1em;
|
||||
/* 图标和文字相邻时,垂直对齐 */
|
||||
vertical-align: -0.15em;
|
||||
/* 通过设置 color 来改变 SVG 的颜色/fill */
|
||||
fill: currentColor;
|
||||
/* path 和 stroke 溢出 viewBox 部分在 IE 下会显示
|
||||
normalize.css 中也包含这行 */
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.icon_lists li .name,
|
||||
.icon_lists li .code-name {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
/* markdown 样式 */
|
||||
.markdown {
|
||||
color: #666;
|
||||
font-size: 14px;
|
||||
line-height: 1.8;
|
||||
}
|
||||
|
||||
.highlight {
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.markdown img {
|
||||
vertical-align: middle;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.markdown h1 {
|
||||
color: #404040;
|
||||
font-weight: 500;
|
||||
line-height: 40px;
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
.markdown h2,
|
||||
.markdown h3,
|
||||
.markdown h4,
|
||||
.markdown h5,
|
||||
.markdown h6 {
|
||||
color: #404040;
|
||||
margin: 1.6em 0 0.6em 0;
|
||||
font-weight: 500;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.markdown h1 {
|
||||
font-size: 28px;
|
||||
}
|
||||
|
||||
.markdown h2 {
|
||||
font-size: 22px;
|
||||
}
|
||||
|
||||
.markdown h3 {
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.markdown h4 {
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.markdown h5 {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.markdown h6 {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
.markdown hr {
|
||||
height: 1px;
|
||||
border: 0;
|
||||
background: #e9e9e9;
|
||||
margin: 16px 0;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.markdown p {
|
||||
margin: 1em 0;
|
||||
}
|
||||
|
||||
.markdown>p,
|
||||
.markdown>blockquote,
|
||||
.markdown>.highlight,
|
||||
.markdown>ol,
|
||||
.markdown>ul {
|
||||
width: 80%;
|
||||
}
|
||||
|
||||
.markdown ul>li {
|
||||
list-style: circle;
|
||||
}
|
||||
|
||||
.markdown>ul li,
|
||||
.markdown blockquote ul>li {
|
||||
margin-left: 20px;
|
||||
padding-left: 4px;
|
||||
}
|
||||
|
||||
.markdown>ul li p,
|
||||
.markdown>ol li p {
|
||||
margin: 0.6em 0;
|
||||
}
|
||||
|
||||
.markdown ol>li {
|
||||
list-style: decimal;
|
||||
}
|
||||
|
||||
.markdown>ol li,
|
||||
.markdown blockquote ol>li {
|
||||
margin-left: 20px;
|
||||
padding-left: 4px;
|
||||
}
|
||||
|
||||
.markdown code {
|
||||
margin: 0 3px;
|
||||
padding: 0 5px;
|
||||
background: #eee;
|
||||
border-radius: 3px;
|
||||
}
|
||||
|
||||
.markdown strong,
|
||||
.markdown b {
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.markdown>table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0px;
|
||||
empty-cells: show;
|
||||
border: 1px solid #e9e9e9;
|
||||
width: 95%;
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
.markdown>table th {
|
||||
white-space: nowrap;
|
||||
color: #333;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.markdown>table th,
|
||||
.markdown>table td {
|
||||
border: 1px solid #e9e9e9;
|
||||
padding: 8px 16px;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
.markdown>table th {
|
||||
background: #F7F7F7;
|
||||
}
|
||||
|
||||
.markdown blockquote {
|
||||
font-size: 90%;
|
||||
color: #999;
|
||||
border-left: 4px solid #e9e9e9;
|
||||
padding-left: 0.8em;
|
||||
margin: 1em 0;
|
||||
}
|
||||
|
||||
.markdown blockquote p {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.markdown .anchor {
|
||||
opacity: 0;
|
||||
transition: opacity 0.3s ease;
|
||||
margin-left: 8px;
|
||||
}
|
||||
|
||||
.markdown .waiting {
|
||||
color: #ccc;
|
||||
}
|
||||
|
||||
.markdown h1:hover .anchor,
|
||||
.markdown h2:hover .anchor,
|
||||
.markdown h3:hover .anchor,
|
||||
.markdown h4:hover .anchor,
|
||||
.markdown h5:hover .anchor,
|
||||
.markdown h6:hover .anchor {
|
||||
opacity: 1;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.markdown>br,
|
||||
.markdown>p>br {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
|
||||
.hljs {
|
||||
display: block;
|
||||
background: white;
|
||||
padding: 0.5em;
|
||||
color: #333333;
|
||||
overflow-x: auto;
|
||||
}
|
||||
|
||||
.hljs-comment,
|
||||
.hljs-meta {
|
||||
color: #969896;
|
||||
}
|
||||
|
||||
.hljs-string,
|
||||
.hljs-variable,
|
||||
.hljs-template-variable,
|
||||
.hljs-strong,
|
||||
.hljs-emphasis,
|
||||
.hljs-quote {
|
||||
color: #df5000;
|
||||
}
|
||||
|
||||
.hljs-keyword,
|
||||
.hljs-selector-tag,
|
||||
.hljs-type {
|
||||
color: #a71d5d;
|
||||
}
|
||||
|
||||
.hljs-literal,
|
||||
.hljs-symbol,
|
||||
.hljs-bullet,
|
||||
.hljs-attribute {
|
||||
color: #0086b3;
|
||||
}
|
||||
|
||||
.hljs-section,
|
||||
.hljs-name {
|
||||
color: #63a35c;
|
||||
}
|
||||
|
||||
.hljs-tag {
|
||||
color: #333333;
|
||||
}
|
||||
|
||||
.hljs-title,
|
||||
.hljs-attr,
|
||||
.hljs-selector-id,
|
||||
.hljs-selector-class,
|
||||
.hljs-selector-attr,
|
||||
.hljs-selector-pseudo {
|
||||
color: #795da3;
|
||||
}
|
||||
|
||||
.hljs-addition {
|
||||
color: #55a532;
|
||||
background-color: #eaffea;
|
||||
}
|
||||
|
||||
.hljs-deletion {
|
||||
color: #bd2c00;
|
||||
background-color: #ffecec;
|
||||
}
|
||||
|
||||
.hljs-link {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
/* 代码高亮 */
|
||||
/* PrismJS 1.15.0
|
||||
https://prismjs.com/download.html#themes=prism&languages=markup+css+clike+javascript */
|
||||
/**
|
||||
* prism.js default theme for JavaScript, CSS and HTML
|
||||
* Based on dabblet (http://dabblet.com)
|
||||
* @author Lea Verou
|
||||
*/
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
color: black;
|
||||
background: none;
|
||||
text-shadow: 0 1px white;
|
||||
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
|
||||
text-align: left;
|
||||
white-space: pre;
|
||||
word-spacing: normal;
|
||||
word-break: normal;
|
||||
word-wrap: normal;
|
||||
line-height: 1.5;
|
||||
|
||||
-moz-tab-size: 4;
|
||||
-o-tab-size: 4;
|
||||
tab-size: 4;
|
||||
|
||||
-webkit-hyphens: none;
|
||||
-moz-hyphens: none;
|
||||
-ms-hyphens: none;
|
||||
hyphens: none;
|
||||
}
|
||||
|
||||
pre[class*="language-"]::-moz-selection,
|
||||
pre[class*="language-"] ::-moz-selection,
|
||||
code[class*="language-"]::-moz-selection,
|
||||
code[class*="language-"] ::-moz-selection {
|
||||
text-shadow: none;
|
||||
background: #b3d4fc;
|
||||
}
|
||||
|
||||
pre[class*="language-"]::selection,
|
||||
pre[class*="language-"] ::selection,
|
||||
code[class*="language-"]::selection,
|
||||
code[class*="language-"] ::selection {
|
||||
text-shadow: none;
|
||||
background: #b3d4fc;
|
||||
}
|
||||
|
||||
@media print {
|
||||
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
text-shadow: none;
|
||||
}
|
||||
}
|
||||
|
||||
/* Code blocks */
|
||||
pre[class*="language-"] {
|
||||
padding: 1em;
|
||||
margin: .5em 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
:not(pre)>code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
background: #f5f2f0;
|
||||
}
|
||||
|
||||
/* Inline code */
|
||||
:not(pre)>code[class*="language-"] {
|
||||
padding: .1em;
|
||||
border-radius: .3em;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.token.comment,
|
||||
.token.prolog,
|
||||
.token.doctype,
|
||||
.token.cdata {
|
||||
color: slategray;
|
||||
}
|
||||
|
||||
.token.punctuation {
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.namespace {
|
||||
opacity: .7;
|
||||
}
|
||||
|
||||
.token.property,
|
||||
.token.tag,
|
||||
.token.boolean,
|
||||
.token.number,
|
||||
.token.constant,
|
||||
.token.symbol,
|
||||
.token.deleted {
|
||||
color: #905;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
.token.attr-name,
|
||||
.token.string,
|
||||
.token.char,
|
||||
.token.builtin,
|
||||
.token.inserted {
|
||||
color: #690;
|
||||
}
|
||||
|
||||
.token.operator,
|
||||
.token.entity,
|
||||
.token.url,
|
||||
.language-css .token.string,
|
||||
.style .token.string {
|
||||
color: #9a6e3a;
|
||||
background: hsla(0, 0%, 100%, .5);
|
||||
}
|
||||
|
||||
.token.atrule,
|
||||
.token.attr-value,
|
||||
.token.keyword {
|
||||
color: #07a;
|
||||
}
|
||||
|
||||
.token.function,
|
||||
.token.class-name {
|
||||
color: #DD4A68;
|
||||
}
|
||||
|
||||
.token.regex,
|
||||
.token.important,
|
||||
.token.variable {
|
||||
color: #e90;
|
||||
}
|
||||
|
||||
.token.important,
|
||||
.token.bold {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.token.italic {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.token.entity {
|
||||
cursor: help;
|
||||
}
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,674 @@
|
|||
@font-face {
|
||||
font-family: "haofont"; /* Project id 4159149 */
|
||||
src: url('iconfont.eot?t=1697559754295'); /* IE9 */
|
||||
src: url('iconfont.eot?t=1697559754295#iefix') format('embedded-opentype'), /* IE6-IE8 */
|
||||
url('iconfont.woff2?t=1697559754295') format('woff2'),
|
||||
url('iconfont.woff?t=1697559754295') format('woff'),
|
||||
url('iconfont.ttf?t=1697559754295') format('truetype'),
|
||||
url('iconfont.svg?t=1697559754295#haofont') format('svg');
|
||||
}
|
||||
|
||||
.haofont {
|
||||
font-family: "haofont" !important;
|
||||
font-size: 16px;
|
||||
font-style: normal;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
.hao-icon-aifadian-line:before {
|
||||
content: "\e695";
|
||||
}
|
||||
|
||||
.hao-icon-zhanghao1:before {
|
||||
content: "\e696";
|
||||
}
|
||||
|
||||
.hao-icon-zuozhe:before {
|
||||
content: "\e694";
|
||||
}
|
||||
|
||||
.hao-icon-weixin1:before {
|
||||
content: "\e693";
|
||||
}
|
||||
|
||||
.hao-icon-bianji:before {
|
||||
content: "\e691";
|
||||
}
|
||||
|
||||
.hao-icon-check-circle:before {
|
||||
content: "\e77d";
|
||||
}
|
||||
|
||||
.hao-icon-dashboard:before {
|
||||
content: "\e6f7";
|
||||
}
|
||||
|
||||
.hao-icon-bullseye:before {
|
||||
content: "\eaff";
|
||||
}
|
||||
|
||||
.hao-icon-logo-moment:before {
|
||||
content: "\e690";
|
||||
}
|
||||
|
||||
.hao-icon-leetcode:before {
|
||||
content: "\ebf2";
|
||||
}
|
||||
|
||||
.hao-icon-gitlab:before {
|
||||
content: "\e692";
|
||||
}
|
||||
|
||||
.hao-icon-csdn:before {
|
||||
content: "\e68a";
|
||||
}
|
||||
|
||||
.hao-icon-dribbble:before {
|
||||
content: "\e87f";
|
||||
}
|
||||
|
||||
.hao-icon-yuque:before {
|
||||
content: "\e880";
|
||||
}
|
||||
|
||||
.hao-icon-linkedin:before {
|
||||
content: "\e73b";
|
||||
}
|
||||
|
||||
.hao-icon-youtube:before {
|
||||
content: "\e765";
|
||||
}
|
||||
|
||||
.hao-icon-Instagram:before {
|
||||
content: "\e68b";
|
||||
}
|
||||
|
||||
.hao-icon-slack:before {
|
||||
content: "\eca1";
|
||||
}
|
||||
|
||||
.hao-icon-baidu:before {
|
||||
content: "\e68c";
|
||||
}
|
||||
|
||||
.hao-icon-discord-line:before {
|
||||
content: "\e7af";
|
||||
}
|
||||
|
||||
.hao-icon-cnblogs:before {
|
||||
content: "\e68d";
|
||||
}
|
||||
|
||||
.hao-icon-juejin:before {
|
||||
content: "\e68e";
|
||||
}
|
||||
|
||||
.hao-icon-steam:before {
|
||||
content: "\ec22";
|
||||
}
|
||||
|
||||
.hao-icon-telegram:before {
|
||||
content: "\ec25";
|
||||
}
|
||||
|
||||
.hao-icon-toutiao:before {
|
||||
content: "\e68f";
|
||||
}
|
||||
|
||||
.hao-icon-weixin:before {
|
||||
content: "\e686";
|
||||
}
|
||||
|
||||
.hao-icon-douban:before {
|
||||
content: "\e687";
|
||||
}
|
||||
|
||||
.hao-icon-29:before {
|
||||
content: "\e688";
|
||||
}
|
||||
|
||||
.hao-icon-weixingongzhonghao:before {
|
||||
content: "\e689";
|
||||
}
|
||||
|
||||
.hao-icon-cainixihuan:before {
|
||||
content: "\e684";
|
||||
}
|
||||
|
||||
.hao-icon-eicon_map-2-line1:before {
|
||||
content: "\e685";
|
||||
}
|
||||
|
||||
.hao-icon-yuan:before {
|
||||
content: "\e833";
|
||||
}
|
||||
|
||||
.hao-icon-creative-commons-nd-line:before {
|
||||
content: "\e67a";
|
||||
}
|
||||
|
||||
.hao-icon-creative-commons-by-line:before {
|
||||
content: "\e67b";
|
||||
}
|
||||
|
||||
.hao-icon-creative-commons-nc-line:before {
|
||||
content: "\e67c";
|
||||
}
|
||||
|
||||
.hao-icon-copyright-line:before {
|
||||
content: "\e67d";
|
||||
}
|
||||
|
||||
.hao-icon-font:before {
|
||||
content: "\e67e";
|
||||
}
|
||||
|
||||
.hao-icon-stopwatch:before {
|
||||
content: "\e67f";
|
||||
}
|
||||
|
||||
.hao-icon-file-lines:before {
|
||||
content: "\e680";
|
||||
}
|
||||
|
||||
.hao-icon-square-poll-vertical:before {
|
||||
content: "\e681";
|
||||
}
|
||||
|
||||
.hao-icon-universal-access:before {
|
||||
content: "\e682";
|
||||
}
|
||||
|
||||
.hao-icon-hourglass-start:before {
|
||||
content: "\e683";
|
||||
}
|
||||
|
||||
.hao-icon-tongxunlu07:before {
|
||||
content: "\e679";
|
||||
}
|
||||
|
||||
.hao-icon-arrow-right:before {
|
||||
content: "\e600";
|
||||
}
|
||||
|
||||
.hao-icon-arrow-left:before {
|
||||
content: "\e601";
|
||||
}
|
||||
|
||||
.hao-icon-dice:before {
|
||||
content: "\e602";
|
||||
}
|
||||
|
||||
.hao-icon-copy:before {
|
||||
content: "\e603";
|
||||
}
|
||||
|
||||
.hao-icon-cube:before {
|
||||
content: "\e604";
|
||||
}
|
||||
|
||||
.hao-icon-circle-arrow-right:before {
|
||||
content: "\e605";
|
||||
}
|
||||
|
||||
.hao-icon-clock:before {
|
||||
content: "\e606";
|
||||
}
|
||||
|
||||
.hao-icon-book:before {
|
||||
content: "\e607";
|
||||
}
|
||||
|
||||
.hao-icon-calendar-alt:before {
|
||||
content: "\e608";
|
||||
}
|
||||
|
||||
.hao-icon-eye-outline:before {
|
||||
content: "\e609";
|
||||
}
|
||||
|
||||
.hao-icon-circle-half-stroke:before {
|
||||
content: "\e60a";
|
||||
}
|
||||
|
||||
.hao-icon-arrow-up:before {
|
||||
content: "\e60b";
|
||||
}
|
||||
|
||||
.hao-icon-file-word:before {
|
||||
content: "\e60c";
|
||||
}
|
||||
|
||||
.hao-icon-fire:before {
|
||||
content: "\e60d";
|
||||
}
|
||||
|
||||
.hao-icon-dove:before {
|
||||
content: "\e60e";
|
||||
}
|
||||
|
||||
.hao-icon-gear:before {
|
||||
content: "\e60f";
|
||||
}
|
||||
|
||||
.hao-icon-inbox:before {
|
||||
content: "\e610";
|
||||
}
|
||||
|
||||
.hao-icon-history:before {
|
||||
content: "\e611";
|
||||
}
|
||||
|
||||
.hao-icon-magnifying-glass:before {
|
||||
content: "\e612";
|
||||
}
|
||||
|
||||
.hao-icon-message:before {
|
||||
content: "\e613";
|
||||
}
|
||||
|
||||
.hao-icon-moon:before {
|
||||
content: "\e614";
|
||||
}
|
||||
|
||||
.hao-icon-shapes:before {
|
||||
content: "\e615";
|
||||
}
|
||||
|
||||
.hao-icon-shuffle:before {
|
||||
content: "\e616";
|
||||
}
|
||||
|
||||
.hao-icon-language:before {
|
||||
content: "\e617";
|
||||
}
|
||||
|
||||
.hao-icon-tags:before {
|
||||
content: "\e618";
|
||||
}
|
||||
|
||||
.hao-icon-train:before {
|
||||
content: "\e619";
|
||||
}
|
||||
|
||||
.hao-icon-warning:before {
|
||||
content: "\e61a";
|
||||
}
|
||||
|
||||
.hao-icon-circle-arrow-up-right-1:before {
|
||||
content: "\e61b";
|
||||
}
|
||||
|
||||
.hao-icon-fish:before {
|
||||
content: "\e61c";
|
||||
}
|
||||
|
||||
.hao-icon-envelope:before {
|
||||
content: "\e61d";
|
||||
}
|
||||
|
||||
.hao-icon-music:before {
|
||||
content: "\e61e";
|
||||
}
|
||||
|
||||
.hao-icon-fan:before {
|
||||
content: "\e61f";
|
||||
}
|
||||
|
||||
.hao-icon-heartbeat-bold:before {
|
||||
content: "\e620";
|
||||
}
|
||||
|
||||
.hao-icon-link:before {
|
||||
content: "\e621";
|
||||
}
|
||||
|
||||
.hao-icon-chevron-left:before {
|
||||
content: "\e622";
|
||||
}
|
||||
|
||||
.hao-icon-rocket:before {
|
||||
content: "\e623";
|
||||
}
|
||||
|
||||
.hao-icon-lightbulb:before {
|
||||
content: "\e624";
|
||||
}
|
||||
|
||||
.hao-icon-shoe-prints:before {
|
||||
content: "\e625";
|
||||
}
|
||||
|
||||
.hao-icon-images:before {
|
||||
content: "\e626";
|
||||
}
|
||||
|
||||
.hao-icon-box-archive:before {
|
||||
content: "\e627";
|
||||
}
|
||||
|
||||
.hao-icon-artstation:before {
|
||||
content: "\e628";
|
||||
}
|
||||
|
||||
.hao-icon-paper-plane:before {
|
||||
content: "\e629";
|
||||
}
|
||||
|
||||
.hao-icon-house-chimney:before {
|
||||
content: "\e62a";
|
||||
}
|
||||
|
||||
.hao-icon-grip-vertical:before {
|
||||
content: "\e62b";
|
||||
}
|
||||
|
||||
.hao-icon-bars:before {
|
||||
content: "\e62c";
|
||||
}
|
||||
|
||||
.hao-icon-arrows-left-right:before {
|
||||
content: "\e62d";
|
||||
}
|
||||
|
||||
.hao-icon-book-open:before {
|
||||
content: "\e62e";
|
||||
}
|
||||
|
||||
.hao-icon-list-ul:before {
|
||||
content: "\e62f";
|
||||
}
|
||||
|
||||
.hao-icon-comments:before {
|
||||
content: "\e630";
|
||||
}
|
||||
|
||||
.hao-icon-comment-sms:before {
|
||||
content: "\e631";
|
||||
}
|
||||
|
||||
.hao-icon-angles-right:before {
|
||||
content: "\e632";
|
||||
}
|
||||
|
||||
.hao-icon-tag:before {
|
||||
content: "\e633";
|
||||
}
|
||||
|
||||
.hao-icon-chevron-right:before {
|
||||
content: "\e634";
|
||||
}
|
||||
|
||||
.hao-icon-radio:before {
|
||||
content: "\e635";
|
||||
}
|
||||
|
||||
.hao-icon-forward:before {
|
||||
content: "\e636";
|
||||
}
|
||||
|
||||
.hao-icon-window-restore:before {
|
||||
content: "\e637";
|
||||
}
|
||||
|
||||
.hao-icon-backward:before {
|
||||
content: "\e638";
|
||||
}
|
||||
|
||||
.hao-icon-download:before {
|
||||
content: "\e639";
|
||||
}
|
||||
|
||||
.hao-icon-comment-medical:before {
|
||||
content: "\e63a";
|
||||
}
|
||||
|
||||
.hao-icon-paste:before {
|
||||
content: "\e63b";
|
||||
}
|
||||
|
||||
.hao-icon-arrow-rotate-right:before {
|
||||
content: "\e63c";
|
||||
}
|
||||
|
||||
.hao-icon-play:before {
|
||||
content: "\e63d";
|
||||
}
|
||||
|
||||
.hao-icon-circle-xmark:before {
|
||||
content: "\e63e";
|
||||
}
|
||||
|
||||
.hao-icon-angle-down:before {
|
||||
content: "\e63f";
|
||||
}
|
||||
|
||||
.hao-icon-chart-line:before {
|
||||
content: "\e640";
|
||||
}
|
||||
|
||||
.hao-icon-pencil:before {
|
||||
content: "\e641";
|
||||
}
|
||||
|
||||
.hao-icon-thumbtack:before {
|
||||
content: "\e642";
|
||||
}
|
||||
|
||||
.hao-icon-location-dot:before {
|
||||
content: "\e643";
|
||||
}
|
||||
|
||||
.hao-icon-fw-fire:before {
|
||||
content: "\e644";
|
||||
}
|
||||
|
||||
.hao-icon-calendar-days:before {
|
||||
content: "\e645";
|
||||
}
|
||||
|
||||
.hao-icon-angle-right:before {
|
||||
content: "\e646";
|
||||
}
|
||||
|
||||
.hao-icon-dice-d20:before {
|
||||
content: "\e647";
|
||||
}
|
||||
|
||||
.hao-icon-instagram:before {
|
||||
content: "\e648";
|
||||
}
|
||||
|
||||
.hao-icon-xmark:before {
|
||||
content: "\e649";
|
||||
}
|
||||
|
||||
.hao-icon-spinner:before {
|
||||
content: "\e64a";
|
||||
}
|
||||
|
||||
.hao-icon-bullhorn:before {
|
||||
content: "\e64b";
|
||||
}
|
||||
|
||||
.hao-icon-stream:before {
|
||||
content: "\e64c";
|
||||
}
|
||||
|
||||
.hao-icon-caret-left:before {
|
||||
content: "\e64d";
|
||||
}
|
||||
|
||||
.hao-icon-folder-open:before {
|
||||
content: "\e64e";
|
||||
}
|
||||
|
||||
.hao-icon-thumbs-up:before {
|
||||
content: "\e64f";
|
||||
}
|
||||
|
||||
.hao-icon-angle-double-down:before {
|
||||
content: "\e650";
|
||||
}
|
||||
|
||||
.hao-icon-sign-out-alt:before {
|
||||
content: "\e651";
|
||||
}
|
||||
|
||||
.hao-icon-angle-double-left:before {
|
||||
content: "\e652";
|
||||
}
|
||||
|
||||
.hao-icon-angle-double-right:before {
|
||||
content: "\e653";
|
||||
}
|
||||
|
||||
.hao-icon-angle-left:before {
|
||||
content: "\e654";
|
||||
}
|
||||
|
||||
.hao-icon-fw-eye:before {
|
||||
content: "\e655";
|
||||
}
|
||||
|
||||
.hao-icon-repeat:before {
|
||||
content: "\e656";
|
||||
}
|
||||
|
||||
.hao-icon-shuffle1:before {
|
||||
content: "\e657";
|
||||
}
|
||||
|
||||
.hao-icon-arrows-rotate:before {
|
||||
content: "\e658";
|
||||
}
|
||||
|
||||
.hao-icon-pause:before {
|
||||
content: "\e659";
|
||||
}
|
||||
|
||||
.hao-icon-heartbeat:before {
|
||||
content: "\e65a";
|
||||
}
|
||||
|
||||
.hao-icon-a-2:before {
|
||||
content: "\e65b";
|
||||
}
|
||||
|
||||
.hao-icon-jike:before {
|
||||
content: "\e65c";
|
||||
}
|
||||
|
||||
.hao-icon-heartbeat1:before {
|
||||
content: "\e65d";
|
||||
}
|
||||
|
||||
.hao-icon-rss:before {
|
||||
content: "\e65e";
|
||||
}
|
||||
|
||||
.hao-icon-qq:before {
|
||||
content: "\e65f";
|
||||
}
|
||||
|
||||
.hao-icon-github:before {
|
||||
content: "\e660";
|
||||
}
|
||||
|
||||
.hao-icon-bilibili:before {
|
||||
content: "\e661";
|
||||
}
|
||||
|
||||
.hao-icon-paper-plane1:before {
|
||||
content: "\e662";
|
||||
}
|
||||
|
||||
.hao-icon-hashtag:before {
|
||||
content: "\e663";
|
||||
}
|
||||
|
||||
.hao-icon-hand-heart-fill:before {
|
||||
content: "\e664";
|
||||
}
|
||||
|
||||
.hao-icon-plant-fill:before {
|
||||
content: "\e665";
|
||||
}
|
||||
|
||||
.hao-icon-qrcode:before {
|
||||
content: "\e666";
|
||||
}
|
||||
|
||||
.hao-icon-weibo:before {
|
||||
content: "\e667";
|
||||
}
|
||||
|
||||
.hao-icon-copyright:before {
|
||||
content: "\e668";
|
||||
}
|
||||
|
||||
.hao-icon-bolt:before {
|
||||
content: "\e669";
|
||||
}
|
||||
|
||||
.hao-icon-circle-info:before {
|
||||
content: "\e66a";
|
||||
}
|
||||
|
||||
.hao-icon-triangle-exclamation:before {
|
||||
content: "\e66b";
|
||||
}
|
||||
|
||||
.hao-icon-circle-check:before {
|
||||
content: "\e66c";
|
||||
}
|
||||
|
||||
.hao-icon-circle-minus:before {
|
||||
content: "\e66d";
|
||||
}
|
||||
|
||||
.hao-icon-circle-plus:before {
|
||||
content: "\e66e";
|
||||
}
|
||||
|
||||
.hao-icon-circle-dot:before {
|
||||
content: "\e66f";
|
||||
}
|
||||
|
||||
.hao-icon-scissors:before {
|
||||
content: "\e670";
|
||||
}
|
||||
|
||||
.hao-icon-arrow-down:before {
|
||||
content: "\e671";
|
||||
}
|
||||
|
||||
.hao-icon-dengpao:before {
|
||||
content: "\e672";
|
||||
}
|
||||
|
||||
.hao-icon-danmu:before {
|
||||
content: "\e673";
|
||||
}
|
||||
|
||||
.hao-icon-zonglan:before {
|
||||
content: "\e674";
|
||||
}
|
||||
|
||||
.hao-icon-linggan:before {
|
||||
content: "\e675";
|
||||
}
|
||||
|
||||
.hao-icon-sanmingzhi:before {
|
||||
content: "\e676";
|
||||
}
|
||||
|
||||
.hao-icon-keyboard:before {
|
||||
content: "\e677";
|
||||
}
|
||||
|
||||
.hao-icon-tiktok:before {
|
||||
content: "\e678";
|
||||
}
|
||||
|
Binary file not shown.
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
After Width: | Height: | Size: 153 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -6,7 +6,7 @@
|
|||
el: '#artalk-wrap',
|
||||
server: GLOBAL_CONFIG.source.artalk.artalkUrl,
|
||||
site: GLOBAL_CONFIG.source.artalk.siteName,
|
||||
pageKey: location.pathname,
|
||||
pageKey: location.pathname.replace(/\/page\/\d$/, ""),
|
||||
darkMode: false,
|
||||
countEl: '#ArtalkCount'
|
||||
}, null))
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
el: '#twikoo-wrap',
|
||||
envId: GLOBAL_CONFIG.source.twikoo.twikooUrl,
|
||||
region: '',
|
||||
path: location.pathname.replace(/\/page\/\d$/, ""),
|
||||
onCommentLoaded: function () {
|
||||
btf.loadLightbox(document.querySelectorAll('#twikoo .tk-content img:not(.tk-owo-emotion)'))
|
||||
typeof hljs === 'object' && hljs.highlightAll()
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
serverURL: GLOBAL_CONFIG.source.waline.serverURL,
|
||||
pageview: false,
|
||||
dark: 'html[data-theme="dark"]',
|
||||
path: window.location.pathname,
|
||||
path: window.location.pathname.replace(/\/page\/\d$/, ""),
|
||||
comment: false,
|
||||
locale:GLOBAL_CONFIG.source.waline.locale
|
||||
}, null))
|
||||
|
|
|
@ -1,13 +1,331 @@
|
|||
|
||||
|
||||
/* 获取直属子元素 */
|
||||
function getChildren(el, className) {
|
||||
for (let item of el.children) if (item.className === className) return item;
|
||||
return null;
|
||||
}
|
||||
|
||||
function parseExpression(expression, occupied) {
|
||||
if (expression === "${full}") {
|
||||
return occupied;
|
||||
}
|
||||
const match = expression.replaceAll("full", occupied).match(/^\$\{([<>=]{1,2}.+)\?(.+):(.+)}$/);
|
||||
if (match) {
|
||||
return eval(`occupied${match[1]} ? ${match[2]} : ${match[3]}`);
|
||||
}
|
||||
throw new Error(`Invalid expression "${expression}"`);
|
||||
}
|
||||
|
||||
function extractHeight(occupied, width, height) {
|
||||
const occupiedWidth = width.endsWith("%")
|
||||
? occupied * (Number(width.slice(0, -1)) / 100)
|
||||
: Number(width);
|
||||
height = height.replaceAll("cwidth", occupiedWidth);
|
||||
if (height.startsWith("${") && height.endsWith("}")) {
|
||||
return parseExpression(height, occupied);
|
||||
} else {
|
||||
return height;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// 跳转链接的卡片
|
||||
document.addEventListener("DOMContentLoaded", () => {
|
||||
|
||||
// 分栏 tab
|
||||
customElements.define(
|
||||
"hao-tabs",
|
||||
class HaoTabs extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.options = {
|
||||
id: this.getAttribute("id") || '',
|
||||
index: this.getAttribute("index") || ''
|
||||
};
|
||||
const id = this.options.id
|
||||
const index = this.options.index
|
||||
const _temp = getChildren(this, "_tpl");
|
||||
let _innerHTML = _temp.innerHTML.trim().replace(/^(<br>)|(<br>)$/g, "");
|
||||
let navs = "";
|
||||
let contents = "";
|
||||
let newIndex = 0;
|
||||
|
||||
_innerHTML.replace(
|
||||
/{tabs-item([^}]*)}([\s\S]*?){\/tabs-item}/g,
|
||||
function ($0, $1, $2) {
|
||||
newIndex +=1;
|
||||
let active =''
|
||||
if(index!='' && index!=null){
|
||||
if(newIndex == index){
|
||||
active = 'active';
|
||||
}
|
||||
}else{
|
||||
if(newIndex==1){
|
||||
active = 'active'
|
||||
}
|
||||
}
|
||||
navs += `
|
||||
<li class="tab ${active}"><button type="button" data-href="#${id}-${newIndex}">${$1}</button></li>
|
||||
`;
|
||||
contents += `
|
||||
<div class="tab-item-content ${active}" id="${id}-${newIndex}">
|
||||
${$2.trim().replace(/^(<br>)|(<br>)$/g, "")}
|
||||
<button type="button" class="tab-to-top" aria-label="scroll to top"><i class="haofont hao-icon-arrow-up"></i></button>
|
||||
</div>
|
||||
`;
|
||||
}
|
||||
);
|
||||
let htmlStr = `
|
||||
<div class="tabs" id="${this.options.id}">
|
||||
<ul class="nav-tabs">${navs}</ul>
|
||||
<div class="tab-contents">${contents}</div>
|
||||
</div>
|
||||
|
||||
`;
|
||||
this.innerHTML = htmlStr;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
// github仓库
|
||||
customElements.define(
|
||||
"hao-github",
|
||||
class GithubDom extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.owner = this.getAttribute("owner") || "";
|
||||
this.repo = this.getAttribute("repo") || "";
|
||||
if (this.owner.length === 0 || this.repo.length === 0) {
|
||||
return;
|
||||
}
|
||||
this.innerHTML = `
|
||||
<div class="github-box"><svg xmlns="http://www.w3.org/2000/svg" style="margin: auto; background: rgb(13,17,23); display: block; shape-rendering: auto;" width="100px" height="100px" viewBox="0 0 100 100" preserveAspectRatio="xMidYMid"><g transform="rotate(0 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-1.4322916666666667s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(30 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-1.3020833333333335s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(60 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-1.171875s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(90 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-1.0416666666666667s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(120 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.9114583333333334s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(150 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.78125s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(180 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.6510416666666667s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(210 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.5208333333333334s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(240 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.390625s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(270 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.2604166666666667s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(300 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="-0.13020833333333334s" repeatCount="indefinite"></animate></rect></g><g transform="rotate(330 50 50)"><rect x="48" y="21" rx="0" ry="0" width="4" height="12" fill="#85a2b6"><animate attributeName="opacity" values="1;0" keyTimes="0;1" dur="1.5625s" begin="0s" repeatCount="indefinite"></animate></rect></g></svg></div>`
|
||||
this.fetchDataAndRender();
|
||||
}
|
||||
async fetchDataAndRender() {
|
||||
try {
|
||||
const res = await this.fetchRepoInfo();
|
||||
const commits = await this.fetchRepoCommits();
|
||||
this.render(res, commits);
|
||||
} catch (error) {
|
||||
console.error("Error:", error);
|
||||
}
|
||||
}
|
||||
async fetchRepoInfo() {
|
||||
const response = await fetch(`/apis/api.plugin.halo.run/v1alpha1/plugins/HaoTag/github/repository?owner=${this.owner}&repo=${this.repo}`);
|
||||
const data = await response.json();
|
||||
return data.data.repository;
|
||||
}
|
||||
async fetchRepoCommits() {
|
||||
const response = await fetch(`https://api.github.com/repos/${this.owner}/${this.repo}/stats/participation`);
|
||||
const commits = await response.json();
|
||||
return commits.all;
|
||||
}
|
||||
render(res, commits) {
|
||||
let updatedAtDate = new Date(res.updatedAt);
|
||||
let currentYear = new Date().getFullYear();
|
||||
let dateFormatOptions = { month: 'long', day: 'numeric' };
|
||||
if (updatedAtDate.getFullYear() !== currentYear) {
|
||||
dateFormatOptions.year = 'numeric';
|
||||
}
|
||||
let updatedAt = updatedAtDate.toLocaleDateString("en-US", dateFormatOptions);
|
||||
let points = commits.map((value, index) => `${index*3},${value+1}`).join(' ');
|
||||
let polyline = this.generatePolyline(points);
|
||||
this.innerHTML = this.generateHTMLTemplate(res, polyline, updatedAt);
|
||||
}
|
||||
generatePolyline(points) {
|
||||
return `<polyline transform="translate(0, 28) scale(1,-1)" points="${points}" fill="transparent" stroke="#8cc665" stroke-width="2"></polyline>`;
|
||||
}
|
||||
generateHTMLTemplate(res, polyline, updatedAt) {
|
||||
return `<div class="github-box">
|
||||
<div class="github-box-flex">
|
||||
<div class="flex-auto">
|
||||
<a target="_blank" href="${res.url}" class="repo-title">
|
||||
${res.name}
|
||||
</a>
|
||||
<span class="repo-label">
|
||||
Public
|
||||
</span>
|
||||
<p class="repo-desc">
|
||||
${res.description || ""}
|
||||
</p>
|
||||
</div>
|
||||
<div class="commits-data">
|
||||
<span class="tooltipped tooltipped-s" aria-label="Past year of activity">
|
||||
<svg width="155" height="30">
|
||||
<defs>
|
||||
<linearGradient id="gradient-618008006" x1="0" x2="0" y1="1" y2="0">
|
||||
<stop offset="0%" stop-color="#0e4429"></stop>
|
||||
<stop offset="10%" stop-color="#006d32"></stop>
|
||||
<stop offset="25%" stop-color="#26a641"></stop>
|
||||
<stop offset="50%" stop-color="#39d353"></stop>
|
||||
</linearGradient>
|
||||
<mask id="sparkline-618008006" x="0" y="0" width="155" height="28">
|
||||
${polyline}
|
||||
</mask>
|
||||
</defs>
|
||||
<g transform="translate(0, 2.0)">
|
||||
<rect x="0" y="-2" width="155" height="30" style="stroke: none; fill: url(#gradient-618008006); mask: url(#sparkline-618008006)"></rect>
|
||||
</g>
|
||||
</svg>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="detail-label">
|
||||
<span class="mr-3">
|
||||
<span class="repo-language-color" style="background-color: ${res.primaryLanguage.color}"></span>
|
||||
<span>${res.primaryLanguage.name || "Unknown"}</span>
|
||||
</span>
|
||||
<span class="mr-3">
|
||||
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" class="mr-1">
|
||||
<path d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.751.751 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25Zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694Z"></path>
|
||||
</svg>
|
||||
${res.stargazerCount || 0}
|
||||
</span>
|
||||
<span class="mr-3">
|
||||
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" class="mr-1">
|
||||
<path d="M8.75.75V2h.985c.304 0 .603.08.867.231l1.29.736c.038.022.08.033.124.033h2.234a.75.75 0 0 1 0 1.5h-.427l2.111 4.692a.75.75 0 0 1-.154.838l-.53-.53.529.531-.001.002-.002.002-.006.006-.006.005-.01.01-.045.04c-.21.176-.441.327-.686.45C14.556 10.78 13.88 11 13 11a4.498 4.498 0 0 1-2.023-.454 3.544 3.544 0 0 1-.686-.45l-.045-.04-.016-.015-.006-.006-.004-.004v-.001a.75.75 0 0 1-.154-.838L12.178 4.5h-.162c-.305 0-.604-.079-.868-.231l-1.29-.736a.245.245 0 0 0-.124-.033H8.75V13h2.5a.75.75 0 0 1 0 1.5h-6.5a.75.75 0 0 1 0-1.5h2.5V3.5h-.984a.245.245 0 0 0-.124.033l-1.289.737c-.265.15-.564.23-.869.23h-.162l2.112 4.692a.75.75 0 0 1-.154.838l-.53-.53.529.531-.001.002-.002.002-.006.006-.016.015-.045.04c-.21.176-.441.327-.686.45C4.556 10.78 3.88 11 3 11a4.498 4.498 0 0 1-2.023-.454 3.544 3.544 0 0 1-.686-.45l-.045-.04-.016-.015-.006-.006-.004-.004v-.001a.75.75 0 0 1-.154-.838L2.178 4.5H1.75a.75.75 0 0 1 0-1.5h2.234a.249.249 0 0 0 .125-.033l1.288-.737c.265-.15.564-.23.869-.23h.984V.75a.75.75 0 0 1 1.5 0Zm2.945 8.477c.285.135.718.273 1.305.273s1.02-.138 1.305-.273L13 6.327Zm-10 0c.285.135.718.273 1.305.273s1.02-.138 1.305-.273L3 6.327Z"></path>
|
||||
</svg>
|
||||
${res.licenseInfo.nickname || "NO LICENCE"}
|
||||
</span>
|
||||
<span class="mr-3">
|
||||
<svg aria-label="fork" role="img" height="16" viewBox="0 0 16 16" version="1.1" width="16" class="mr-1">
|
||||
<path d="M5 5.372v.878c0 .414.336.75.75.75h4.5a.75.75 0 0 0 .75-.75v-.878a2.25 2.25 0 1 1 1.5 0v.878a2.25 2.25 0 0 1-2.25 2.25h-1.5v2.128a2.251 2.251 0 1 1-1.5 0V8.5h-1.5A2.25 2.25 0 0 1 3.5 6.25v-.878a2.25 2.25 0 1 1 1.5 0ZM5 3.25a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Zm6.75.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5Zm-3 8.75a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0Z"></path>
|
||||
</svg>
|
||||
${res.forks.totalCount || 0}
|
||||
</span>
|
||||
<a target="_blank" href="${res.url}/issues" class="mr-3">
|
||||
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" class="mr-1">
|
||||
<path d="M8 9.5a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z"></path><path d="M8 0a8 8 0 1 1 0 16A8 8 0 0 1 8 0ZM1.5 8a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0Z"></path>
|
||||
</svg>
|
||||
${res.issues.totalCount || 0}
|
||||
</a>
|
||||
<a target="_blank" href="${res.url}/pulls" class="mr-3">
|
||||
<svg aria-hidden="true" height="16" viewBox="0 0 16 16" version="1.1" width="16" class="mr-1">
|
||||
<path d="M1.5 3.25a2.25 2.25 0 1 1 3 2.122v5.256a2.251 2.251 0 1 1-1.5 0V5.372A2.25 2.25 0 0 1 1.5 3.25Zm5.677-.177L9.573.677A.25.25 0 0 1 10 .854V2.5h1A2.5 2.5 0 0 1 13.5 5v5.628a2.251 2.251 0 1 1-1.5 0V5a1 1 0 0 0-1-1h-1v1.646a.25.25 0 0 1-.427.177L7.177 3.427a.25.25 0 0 1 0-.354ZM3.75 2.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm0 9.5a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Zm8.25.75a.75.75 0 1 0 1.5 0 .75.75 0 0 0-1.5 0Z"></path>
|
||||
</svg>
|
||||
${res.pullRequests.totalCount || 0}
|
||||
</a>
|
||||
<span class="update-time">
|
||||
Updated on ${updatedAt || "Unknown"}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
`
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
// 彩虹虚线
|
||||
customElements.define(
|
||||
"hao-dotted",
|
||||
class DottedDom extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.startColor = this.getAttribute("begin") || "#ff6c6c";
|
||||
this.endColor = this.getAttribute("end") || "#1989fa";
|
||||
this.innerHTML = `
|
||||
<span class="tool_dotted" style="background-image: repeating-linear-gradient(-45deg, ${this.startColor} 0, ${this.startColor} 20%, transparent 0, transparent 25%, ${this.endColor} 0, ${this.endColor} 45%, transparent 0, transparent 50%)"></span>
|
||||
`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
// 进度条
|
||||
customElements.define(
|
||||
"hao-progress",
|
||||
class ProgressDom extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.options = {
|
||||
percentage: /^\d{1,3}%$/.test(this.getAttribute("pct"))
|
||||
? this.getAttribute("pct")
|
||||
: "50%",
|
||||
color: this.getAttribute("color") || "#ff6c6c",
|
||||
};
|
||||
this.innerHTML = `
|
||||
<span class="tool_progress">
|
||||
<div class="tool_progress__strip">
|
||||
<div class="tool_progress__strip-percent" style="width: ${this.options.percentage}; background: ${this.options.color};"></div>
|
||||
</div>
|
||||
<div class="tool_progress__percentage">${this.options.percentage}</div>
|
||||
</span>
|
||||
`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
// 小标记
|
||||
customElements.define(
|
||||
"hao-sign",
|
||||
class SignDom extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.options = {
|
||||
type: this.getAttribute("type"), // 小标签类型
|
||||
content: this.innerHTML, // 内容
|
||||
};
|
||||
this.render();
|
||||
}
|
||||
render() {
|
||||
this.innerHTML = `<span class="${this.options.type}">${this.options.content}</span>`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
// B站视频
|
||||
customElements.define(
|
||||
"hao-bilibili",
|
||||
class BiliBiliDom extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.options = {
|
||||
bvid: this.getAttribute("bvid"),
|
||||
page: +(this.getAttribute("page") || "1"),
|
||||
width: this.getAttribute("width") || "100%",
|
||||
height: this.getAttribute("height") || "500",
|
||||
autoplay: this.getAttribute("autoplay") || 0,
|
||||
};
|
||||
this.render();
|
||||
}
|
||||
render() {
|
||||
if (!this.options.bvid) return (this.innerHTML = "请填写正确的bvid");
|
||||
const realHeight = extractHeight(this.parentElement.offsetWidth, this.options.width, this.options.height);
|
||||
this.setAttribute("height", realHeight);
|
||||
this.innerHTML = `
|
||||
<iframe class="iframe-dom" allowfullscreen="true" scrolling="no" border="0" frameborder="no" framespacing="0" class="tool_vplayer" src="//player.bilibili.com/player.html?bvid=${this.options.bvid}&page=${this.options.page}&autoplay=${this.options.autoplay}" style="width:${this.options.width}; height:${realHeight}px;"></iframe>`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
// pdf
|
||||
customElements.define(
|
||||
"hao-pdf",
|
||||
class PDFDom extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.options = {
|
||||
src: this.getAttribute("src") || "",
|
||||
width: this.getAttribute("width") || "100%",
|
||||
height: this.getAttribute("height") || "500",
|
||||
};
|
||||
this.render();
|
||||
}
|
||||
render() {
|
||||
if (!this.options.src) return (this.innerHTML = "请填写正确的pdf链接");
|
||||
const realHeight = extractHeight(this.parentElement.offsetWidth, this.options.width, this.options.height);
|
||||
this.setAttribute("height", realHeight);
|
||||
this.innerHTML = `
|
||||
<div class="tool_pdf">
|
||||
<iframe class="iframe-dom" src="${this.options.src}" style="width:${this.options.width}; height:${realHeight}px;"></iframe>
|
||||
</div>`;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
customElements.define(
|
||||
"hao-introduction-card",
|
||||
class HaoIntroductionCard extends HTMLElement {
|
||||
|
|
|
@ -159,7 +159,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
const cardToc = document.getElementById("card-toc");
|
||||
cardToc?.remove();
|
||||
const $mobileTocButton = document.getElementById("mobile-toc-button")
|
||||
if($mobileTocButton){
|
||||
if ($mobileTocButton) {
|
||||
$('#mobile-toc-button').attr('style', 'display: none');
|
||||
}
|
||||
} else {
|
||||
|
@ -167,16 +167,29 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
tocSelector: '.toc-content',
|
||||
contentSelector: '.post-content',
|
||||
headingSelector: 'h1,h2,h3,h4,h5,h6',
|
||||
collapseDepth: 6,
|
||||
headingsOffset: 70,
|
||||
listItemClass: 'toc-item',
|
||||
activeLinkClass: 'active',
|
||||
activeListItemClass: 'active',
|
||||
headingsOffset: -400,
|
||||
scrollSmooth: true,
|
||||
scrollSmoothOffset: -70,
|
||||
tocScrollOffset: 50
|
||||
tocScrollOffset: 50,
|
||||
});
|
||||
|
||||
const $cardTocLayout = document.getElementById('card-toc')
|
||||
const $cardToc = $cardTocLayout.getElementsByClassName('toc-content')[0]
|
||||
|
||||
// toc元素點擊
|
||||
$cardToc.addEventListener('click', (ele) => {
|
||||
if (window.innerWidth < 900) {
|
||||
$cardTocLayout.classList.remove("open");
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Rightside
|
||||
*/
|
||||
|
@ -210,13 +223,19 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
: saveToLocal.set('aside-status', 'hide', 2)
|
||||
$htmlDom.toggle('hide-aside')
|
||||
},
|
||||
runMobileToc: () => {
|
||||
const $cardToc = document.getElementById("card-toc")
|
||||
if ($cardToc.classList.contains("open")) {
|
||||
$cardToc.classList.remove("open");
|
||||
} else {
|
||||
$cardToc.classList.add("open");
|
||||
}
|
||||
runMobileToc: item => {
|
||||
const tocEle = document.getElementById("card-toc");
|
||||
tocEle.style.transformOrigin = `right ${item.getBoundingClientRect().top + 17}px`;
|
||||
tocEle.style.transition = "transform 0.3s ease-in-out";
|
||||
tocEle.classList.toggle("open");
|
||||
tocEle.addEventListener(
|
||||
"transitionend",
|
||||
() => {
|
||||
tocEle.style.transition = "";
|
||||
tocEle.style.transformOrigin = "";
|
||||
},
|
||||
{ once: true }
|
||||
);
|
||||
},
|
||||
}
|
||||
|
||||
|
@ -230,7 +249,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
|||
rightSideFn.showOrHideBtn()
|
||||
break
|
||||
case "mobile-toc-button":
|
||||
rightSideFn.runMobileToc();
|
||||
rightSideFn.runMobileToc(this);
|
||||
break;
|
||||
case 'readmode':
|
||||
rightSideFn.switchReadMode()
|
||||
|
|
|
@ -60,9 +60,11 @@ body[data-type=music] #page {
|
|||
#page-header.not-top-img #nav .back-home-button,
|
||||
#page-header.not-top-img #nav a {
|
||||
color:#F7F7FA;
|
||||
|
||||
}
|
||||
|
||||
#page-header.not-top-img #nav .back-home-button:hover{
|
||||
color: var(--heo-card-bg);
|
||||
}
|
||||
|
||||
body[data-type=music] #footer,
|
||||
body[data-type=music] #nav-music {
|
||||
|
@ -588,4 +590,6 @@ body[data-type=music] #nav-music {
|
|||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
|
||||
}
|
|
@ -1 +1 @@
|
|||
.toc{overflow-y:auto}.toc>.toc-list{overflow:hidden;position:relative}.toc>.toc-list li{list-style:none}.js-toc{overflow-y:hidden}.toc-list{margin:0;padding-left:10px}a.toc-link{color:currentColor;height:100%}.is-collapsible{max-height:1000px;overflow:hidden;transition:all 300ms ease-in-out}.is-collapsed{max-height:0}.is-position-fixed{position:fixed !important;top:0}.is-active-link{font-weight:700}.toc-link::before{background-color:#EEE;content:' ';display:inline-block;height:inherit;left:0;margin-top:-1px;position:absolute;width:2px}.is-active-link::before{background-color:#54BC4B}
|
||||
.toc{overflow-y:auto}.toc>.toc-list{overflow:hidden;position:relative}.toc>.toc-list li{list-style:none}.js-toc{overflow-y:hidden}.toc-list{margin:0;padding-left:10px}a.toc-link{color:currentColor;height:100%}.is-collapsible{max-height:1000px;overflow:hidden;transition:all 300ms ease-in-out}.is-collapsed{max-height:0}.is-position-fixed{position:fixed !important;top:0}.is-active-link{font-weight:700}.toc-link::before{content:' ';display:inline-block;height:inherit;left:0;margin-top:-1px;position:absolute;width:2px}.is-active-link::before{background-color:#54BC4B}
|
||||
|
|
|
@ -479,7 +479,7 @@ window.onkeydown = function (e) {
|
|||
// document.querySelector('#algolia-search').addEventListener('wheel', (e) => {
|
||||
// e.preventDefault()
|
||||
// })
|
||||
document.querySelector('#console').addEventListener('wheel', (e) => {
|
||||
document.querySelector('#console') && document.querySelector('#console').addEventListener('wheel', (e) => {
|
||||
e.preventDefault()
|
||||
})
|
||||
// document.querySelector('#loading-box').addEventListener('wheel', (e) => {
|
||||
|
|
|
@ -12,7 +12,7 @@ if(GLOBAL_CONFIG.htmlType!='comments' && document.querySelector('#post-comment')
|
|||
//token获取见上方
|
||||
accessToken: GLOBAL_CONFIG.source.twikoo.accessToken,
|
||||
mailMd5: GLOBAL_CONFIG.source.comments.mailMd5,
|
||||
pageUrl: window.location.pathname,
|
||||
pageUrl: window.location.pathname.replace(/\/page\/\d$/, ""),
|
||||
barrageTimer: [],
|
||||
barrageList: [],
|
||||
siteName: GLOBAL_CONFIG.source.artalk.siteName,
|
||||
|
|
|
@ -1645,12 +1645,13 @@ blockquote footer cite::before {
|
|||
object-fit: cover;
|
||||
}
|
||||
|
||||
#recent-posts>.recent-post-item.col1.alternate .left_radius, #recent-posts>.recent-post-item.col1.alternate .right_radius {
|
||||
width:75%;
|
||||
@media screen and (min-width: 1300px) {
|
||||
#recent-posts > .recent-post-item.col1.alternate .left_radius, #recent-posts > .recent-post-item.col1.alternate .right_radius {
|
||||
width: 75%;
|
||||
display: flex;
|
||||
height: 220px
|
||||
}
|
||||
}
|
||||
|
||||
#recent-posts > .recent-post-item .post_cover img.post_bg:hover {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
|
@ -2245,8 +2246,9 @@ blockquote footer cite::before {
|
|||
/*}*/
|
||||
|
||||
#aside-content #card-toc .toc-content {
|
||||
position: relative;
|
||||
overflow-y: auto;
|
||||
max-height: calc(100vh - 120px);
|
||||
max-height: calc(100vh - 300px);
|
||||
}
|
||||
|
||||
@media screen and (max-width: 900px) {
|
||||
|
@ -2301,10 +2303,10 @@ blockquote footer cite::before {
|
|||
position: absolute;
|
||||
top: 0.6rem;
|
||||
right: 1.2rem;
|
||||
color: rgb(169, 169, 169);
|
||||
color: #a9a9a9;
|
||||
content: attr(progress-percentage);
|
||||
font-style: italic;
|
||||
font-size: 1.2rem;
|
||||
font-size: 1.2rem
|
||||
}
|
||||
|
||||
#aside-content :only-child > .card-widget {
|
||||
|
@ -2763,9 +2765,13 @@ blockquote footer cite::before {
|
|||
#page-header.nav-fixed #nav #site-name,
|
||||
#page-header.nav-fixed #nav #toggle-menu,
|
||||
#page-header.nav-fixed #nav a {
|
||||
color: var(--heo-fontcolor);
|
||||
text-shadow: none;
|
||||
}
|
||||
@media screen and (min-width: 900px) {
|
||||
#page-header.nav-fixed #nav #site-name:hover {
|
||||
color: var(--heo-white);
|
||||
}
|
||||
}
|
||||
|
||||
#page-header.nav-visible #nav {
|
||||
transition: all 0.5s ease 0s;
|
||||
|
@ -3107,7 +3113,7 @@ ul {
|
|||
|
||||
#pagination .page-number.current {
|
||||
background: rgb(0, 121, 255);
|
||||
color: var(--white);
|
||||
color: var(--heo-card-bg);
|
||||
cursor: default;
|
||||
border-radius: 5px;
|
||||
}
|
||||
|
@ -4856,7 +4862,7 @@ html {
|
|||
color: var(--heo-white);
|
||||
}
|
||||
|
||||
.nav-fixed #nav a {
|
||||
.nav-fixed #nav a{
|
||||
color: var(--heo-fontcolor);
|
||||
transition: 0.3s;
|
||||
}
|
||||
|
@ -4943,7 +4949,7 @@ html {
|
|||
transition: 0.3s;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
z-index: 1000 !important;
|
||||
z-index: 999 !important;
|
||||
-webkit-user-select: none;
|
||||
}
|
||||
|
||||
|
@ -6125,6 +6131,7 @@ i.fab {
|
|||
|
||||
.nav-fixed #nav a:hover {
|
||||
background: var(--heo-main);
|
||||
color: var(--heo-white);
|
||||
transition: 0.3s;
|
||||
}
|
||||
|
||||
|
@ -6298,22 +6305,13 @@ img.footer_mini_logo {
|
|||
height: 50px;
|
||||
margin: 0 1rem;
|
||||
cursor: pointer;
|
||||
transition: cubic-bezier(0, 0, 0, 1.29) 0.5s;
|
||||
transition: cubic-bezier(0,0,0,1.29) .5s;
|
||||
}
|
||||
|
||||
img.footer_mini_logo:hover {
|
||||
-webkit-backface-visibility: hidden;
|
||||
-webkit-transform-style: preserve-3d;
|
||||
}
|
||||
|
||||
@media screen and (min-width: 1300px) {
|
||||
img.footer_mini_logo:hover {
|
||||
transform: scale(1.03);
|
||||
}
|
||||
|
||||
img.footer_mini_logo:active {
|
||||
transform: scale(0.97);
|
||||
}
|
||||
transform: scale(1.2)
|
||||
}
|
||||
|
||||
/* logo居中 */
|
||||
|
@ -6559,6 +6557,10 @@ a.console_switchbutton {
|
|||
transition: 0s;
|
||||
}
|
||||
|
||||
.nav-fixed #nav #site-name{
|
||||
color: var(--heo-fontcolor);
|
||||
}
|
||||
|
||||
/* 导航栏名称样式 */
|
||||
#nav #site-name {
|
||||
color: var(--heo-fontcolor);
|
||||
|
@ -6581,8 +6583,13 @@ a.console_switchbutton {
|
|||
color: var(--heo-fontcolor)
|
||||
}
|
||||
|
||||
.page #nav #site-name:hover {
|
||||
color: var(--heo-card-bg)
|
||||
body[data-type=music] .page #nav #site-name span{
|
||||
color: var(--heo-white);
|
||||
}
|
||||
@media screen and (max-width: 768px) {
|
||||
.page #nav #site-name span:hover {
|
||||
color: var(--heo-card-bg);
|
||||
}
|
||||
}
|
||||
|
||||
/* 搜索 */
|
||||
|
@ -7905,24 +7912,24 @@ div#banners {
|
|||
|
||||
@media screen and (min-width: 1300px) {
|
||||
.topGroup {
|
||||
display: flex;
|
||||
display:flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
justify-content: flex-end;
|
||||
height: calc(328px + 0.5rem);
|
||||
justify-content: space-between;
|
||||
height: calc(328px + .5rem);
|
||||
align-content: space-between;
|
||||
width: calc(600px + 1.5rem);
|
||||
width: calc(50% - .25rem);
|
||||
position: relative;
|
||||
animation: slide-in .6s .1s backwards
|
||||
}
|
||||
|
||||
div#bannerGroup {
|
||||
width: calc(100% - 600px - 2rem);
|
||||
margin-right: 0.5rem;
|
||||
height: calc(328px + 0.5rem);
|
||||
width: calc(50% - .25rem);
|
||||
margin-right: .5rem;
|
||||
height: calc(328px + .5rem);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
justify-content: space-between
|
||||
}
|
||||
|
||||
div#banners {
|
||||
|
@ -7939,7 +7946,7 @@ div#banners {
|
|||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
transition: 0.3s;
|
||||
clip-path: inset(0 0 0 0 round 12px);
|
||||
will-change: transform;
|
||||
animation: slide-in .6s .1s backwards;
|
||||
}
|
||||
|
||||
|
@ -8023,8 +8030,8 @@ div#banners {
|
|||
height: 100%;
|
||||
top: 0;
|
||||
left: 0;
|
||||
background: var(--heo-theme);
|
||||
color: var(--heo-white);
|
||||
background: var(--heo-lighttext);
|
||||
color: var(--heo-card-bg);
|
||||
padding-left: 0.5rem;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
@ -8047,7 +8054,7 @@ div#banners {
|
|||
#banners:hover #banner-hover {
|
||||
opacity: 1;
|
||||
padding-left: 2rem;
|
||||
background: #4259efc9;
|
||||
background: var(--heo-theme-op-deep);
|
||||
backdrop-filter: blur(15px);
|
||||
-webkit-backdrop-filter: blur(15px);
|
||||
-webkit-backface-visibility: hidden;
|
||||
|
@ -8064,19 +8071,19 @@ div#banners {
|
|||
|
||||
.topGroup .todayCard {
|
||||
position: absolute;
|
||||
width: calc(600px + 1rem);
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 1;
|
||||
top: 0;
|
||||
left: 0;
|
||||
background: var(--card-bg);
|
||||
right: 0;
|
||||
background: var(--heo-card-bg);
|
||||
border-radius: 12px;
|
||||
margin-left: 0.5rem;
|
||||
margin-left: .5rem;
|
||||
overflow: hidden;
|
||||
transition: 0.3s;
|
||||
transition: .3s;
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
pointer-events: all;
|
||||
pointer-events: all
|
||||
}
|
||||
|
||||
.topGroup .todayCard::after {
|
||||
|
@ -8148,8 +8155,8 @@ div#banners {
|
|||
}
|
||||
|
||||
.topGroup .banner-button:hover {
|
||||
background: var(--heo-theme);
|
||||
color: var(--heo-white);
|
||||
background: var(--heo-lighttext);
|
||||
color: var(--heo-card-bg);
|
||||
}
|
||||
|
||||
.topGroup .banner-button i {
|
||||
|
@ -8361,7 +8368,7 @@ a.categoryButton:hover {
|
|||
|
||||
/* 首页分类条展示 */
|
||||
#category-bar {
|
||||
padding: 0.4rem 1rem 0.4rem 0.5rem;
|
||||
padding: 0.4rem 1rem 0.4rem 0.7rem;
|
||||
background: var(--heo-card-bg);
|
||||
border-radius: 12px;
|
||||
display: flex;
|
||||
|
@ -8372,6 +8379,9 @@ a.categoryButton:hover {
|
|||
transition: 0.3s;
|
||||
width: 100%;
|
||||
justify-content: space-between;
|
||||
-webkit-user-select: none;
|
||||
display: flex;
|
||||
align-items: center
|
||||
}
|
||||
|
||||
@media screen and (min-width: 1300px) {
|
||||
|
@ -9249,14 +9259,19 @@ ins.adsbygoogle {
|
|||
|
||||
@media screen and (min-width: 1300px) {
|
||||
.recent-post-top .recent-post-item {
|
||||
margin-right: 0px;
|
||||
margin-bottom: 0.5rem;
|
||||
width:calc(100% / 3 - .25rem);
|
||||
margin-left: 0
|
||||
}
|
||||
|
||||
.recent-post-top .recent-post-item:active {
|
||||
transform: scale(0.97);
|
||||
}
|
||||
|
||||
.recent-post-top .recent-post-item {
|
||||
margin-right: 0;
|
||||
margin-bottom: .5rem
|
||||
}
|
||||
|
||||
.recent-post-top {
|
||||
overflow-x: visible;
|
||||
}
|
||||
|
@ -9587,10 +9602,6 @@ span.recent-post-top-text {
|
|||
right: 0;
|
||||
}
|
||||
|
||||
#rightside {
|
||||
display: none
|
||||
}
|
||||
|
||||
/* 背景 */
|
||||
#web_bg {
|
||||
background: none !important;
|
||||
|
@ -9685,16 +9696,17 @@ span.recent-post-top-text {
|
|||
|
||||
/* 文章目录 */
|
||||
#aside-content #card-toc .toc-content .toc-link.active {
|
||||
line-height: 1.2;
|
||||
line-height: 24px;
|
||||
border-radius: 12px;
|
||||
border-left-color: var(--heo-hovertext);
|
||||
background-color: var(--heo-card-bg);
|
||||
color: var(--heo-lighttext);
|
||||
font-weight: bold;
|
||||
font-weight: 700;
|
||||
font-size: 20px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
[data-theme=dark].toc .toc-item.active .toc-link .toc-text {
|
||||
[data-theme=dark].toc-list .toc-item.active .toc-link{
|
||||
color: var(--heo-white);
|
||||
}
|
||||
|
||||
|
@ -9704,27 +9716,31 @@ span.recent-post-top-text {
|
|||
}
|
||||
|
||||
#aside-content #card-toc .toc-content .toc-link {
|
||||
line-height: 1.2;
|
||||
line-height: 24px;
|
||||
padding: 8px;
|
||||
border-left: 0px solid transparent;
|
||||
border-left: 0 solid transparent;
|
||||
border-radius: 12px;
|
||||
color: var(--heo-secondtext);
|
||||
cursor: default;
|
||||
min-height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
|
||||
#aside-content #card-toc .toc-content .toc-link:not(.active) span {
|
||||
#aside-content #card-toc .toc-content a.toc-link:not(.active) {
|
||||
opacity: 0.6;
|
||||
cursor: pointer;
|
||||
filter: blur(1px);
|
||||
transition: 0.3s;
|
||||
}
|
||||
|
||||
#aside-content #card-toc:hover .toc-content .toc-link:not(.active) span {
|
||||
#aside-content #card-toc:hover .toc-content a.toc-link:not(.active) {
|
||||
filter: blur(0px);
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
#aside-content #card-toc .toc-content .toc-link:not(.active) span:hover {
|
||||
#aside-content #card-toc .toc-content a:hover.toc-link:not(.active) {
|
||||
color: var(--heo-lighttext);
|
||||
}
|
||||
|
||||
|
@ -10165,6 +10181,7 @@ div#author-info__sayhi:hover {
|
|||
#aside-content .item-headline + div,
|
||||
#aside-content .item-headline + ul {
|
||||
padding: 0;
|
||||
-webkit-user-select: none;
|
||||
}
|
||||
|
||||
@media screen and (min-width: 1300px) {
|
||||
|
@ -11773,7 +11790,7 @@ blockquote p {
|
|||
|
||||
.post-reward .reward-main .reward-all {
|
||||
border-radius: 12px;
|
||||
background: var(--heo-background);
|
||||
background: var(--heo-card-bg);
|
||||
border: var(--style-border-always);
|
||||
padding: 0.8rem;
|
||||
display: flex;
|
||||
|
@ -11819,20 +11836,18 @@ a.reward-main-btn:hover {
|
|||
color: var(--heo-red);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* 赞赏背景 */
|
||||
|
||||
#quit-box {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
background: rgba(0, 0, 0, .4);
|
||||
height: calc(100vh);
|
||||
background: rgba(0,0,0,.2);
|
||||
opacity: 0.01;
|
||||
top: 0;
|
||||
left: 0;
|
||||
display: none;
|
||||
z-index: 101;
|
||||
margin: 0 !important;
|
||||
z-index: 109;
|
||||
margin: 0!important
|
||||
}
|
||||
|
||||
.post-tools-left #quit-box {
|
||||
|
@ -11841,6 +11856,7 @@ a.reward-main-btn:hover {
|
|||
|
||||
@media screen and (max-width: 768px) {
|
||||
#quit-box {
|
||||
z-index:109;
|
||||
display: none!important;
|
||||
}
|
||||
}
|
||||
|
@ -11980,7 +11996,7 @@ a.reward-main-btn:hover {
|
|||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
opacity: 0;
|
||||
z-index: 1002
|
||||
z-index: 999
|
||||
}
|
||||
|
||||
|
||||
|
@ -12110,12 +12126,12 @@ a.reward-main-btn:hover {
|
|||
#pagination .pagination .extend {
|
||||
width: 100%;
|
||||
height: 2.5rem;
|
||||
margin: 0.2rem 1rem 1rem 1rem;
|
||||
margin: .2rem 0 1rem 0;
|
||||
border-radius: 12px;
|
||||
line-height: 2.5rem;
|
||||
background: var(--heo-card-bg);
|
||||
border: var(--style-border-always);
|
||||
box-shadow: var(--heo-shadow-border);
|
||||
box-shadow: var(--heo-shadow-border)
|
||||
}
|
||||
|
||||
#pagination .pagination .extend i {
|
||||
|
@ -12354,6 +12370,11 @@ div#post-comment {
|
|||
width: 100%;
|
||||
}
|
||||
|
||||
.tk-content img {
|
||||
max-height: 1100px!important;
|
||||
max-width: 100%!important;
|
||||
border-radius: 12px
|
||||
}
|
||||
|
||||
#post-comment .comment-tips.show {
|
||||
display: flex;
|
||||
|
@ -12370,6 +12391,7 @@ div#post-comment {
|
|||
width: 32px !important;
|
||||
height: 32px !important;
|
||||
box-shadow: var(--heo-shadow-border);
|
||||
margin-right: 16px!important
|
||||
}
|
||||
|
||||
.tk-avatar.tk-has-avatar {
|
||||
|
@ -12378,6 +12400,10 @@ div#post-comment {
|
|||
border-radius: 32px !important;
|
||||
}
|
||||
|
||||
.tk-avatar.tk-has-avatar img {
|
||||
border-radius: 32px!important;
|
||||
}
|
||||
|
||||
.tk-row .tk-avatar {
|
||||
display: none;
|
||||
}
|
||||
|
@ -12803,6 +12829,11 @@ button.el-button.tk-cancel.el-button--default.el-button--small {
|
|||
pointer-events: none;
|
||||
}
|
||||
|
||||
.OwO.OwO-open .OwO-body {
|
||||
animation: .3s ease .1s 1 normal both running donate_effcet
|
||||
}
|
||||
|
||||
|
||||
@keyframes owoIn {
|
||||
0% {
|
||||
transform: translate(0, -95%);
|
||||
|
@ -12998,7 +13029,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small {
|
|||
}
|
||||
|
||||
.post-reward .reward-main {
|
||||
z-index: 1003;
|
||||
z-index: 999;
|
||||
}
|
||||
|
||||
.tk-meta-input .el-input .el-input-group__prepend {
|
||||
|
@ -15104,7 +15135,7 @@ span.hexo-douban-pagenum {
|
|||
background: var(--heo-secondbg);
|
||||
display: flex;
|
||||
overflow: hidden;
|
||||
z-index: 1002;
|
||||
z-index: 999;
|
||||
transition: 0.3s;
|
||||
}
|
||||
|
||||
|
@ -15245,8 +15276,6 @@ span.hexo-douban-pagenum {
|
|||
animation-delay: 1.8s;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#about-page .author-img {
|
||||
margin: 0 30px;
|
||||
border-radius: 50%;
|
||||
|
@ -15255,10 +15284,18 @@ span.hexo-douban-pagenum {
|
|||
position: relative;
|
||||
background: var(--heo-secondbg);
|
||||
user-select: none;
|
||||
transition: .3s
|
||||
}
|
||||
|
||||
#about-page .author-img img {
|
||||
border-radius: 200px;
|
||||
overflow: hidden;
|
||||
width: 180px;
|
||||
height: 180px
|
||||
}
|
||||
|
||||
#about-page .author-img:hover {
|
||||
transform: scale(1.1)
|
||||
}
|
||||
|
||||
#about-page .author-img::before {
|
||||
|
@ -15291,8 +15328,6 @@ span.hexo-douban-pagenum {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
#about-page .author-title {
|
||||
font-size: 2rem;
|
||||
font-weight: bold;
|
||||
|
@ -17430,18 +17465,6 @@ a#toPageButton.haveValue:hover {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
/* 文章目录样式 */
|
||||
a.toc-link {
|
||||
color: currentColor;
|
||||
height:0%;
|
||||
}
|
||||
/* 文章目录样式 */
|
||||
#aside-content #card-toc .toc-content .is-active-link {
|
||||
font-weight: 700;
|
||||
font-size: 20px;
|
||||
color: var(--heo-lighttext);
|
||||
}
|
||||
/* code样式 */
|
||||
code:not([class]) {
|
||||
color: var(--heo-white);
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<div id="rightside-config-show">
|
||||
<button id="rightside-config" type="button" title="设置"><i class="haofont hao-icon-gear"></i></button>
|
||||
<button th:if="${htmlType == 'post'}" class="close" id="mobile-toc-button" type="button" title="目录"><i class="haofont hao-icon-list-ul"></i></button>
|
||||
<a id="to_comment" href="javascript:heo.scrollTo('post-comment')" title="直达评论" ><i class="haofont hao-icon-comments"></i></a>
|
||||
<a id="to_comment" href="#post-comment" title="直达评论" ><i class="haofont hao-icon-comments"></i></a>
|
||||
<a th:if="${theme.config.comments.commentBarrageConfig.commentBarrageEnable}" id="switch-commentBarrage" href="javascript:heo.switchCommentBarrage();" rel="external nofollow noreferrer" title="开关弹幕" draggable="false" data-pjax-state="external"><i class="haofont hao-icon-danmu"></i></a>
|
||||
<button id="go-up" type="button" title="回到顶部"><i class="haofont hao-icon-arrow-up"></i></button>
|
||||
<a th:if="${htmlType == 'post' || htmlType == 'page'}"
|
||||
|
@ -30,9 +30,11 @@
|
|||
.comment-barrage {
|
||||
right: 20px;
|
||||
}
|
||||
@media screen and (min-width: 1300px) {
|
||||
#post #pagination {
|
||||
right: 20px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
<link th:if="${theme.config.tool.rightside.readmode && theme.config.tool.rightside.rightsideEnable}"
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
<footer id="footer" th:fragment="footer">
|
||||
|
||||
<div id="heo-footer-bar" th:if="${theme.config.footer.footer_bar.footer_bar_enable}">
|
||||
<div class="footer-logo">[[${theme.config.footer.footer_bar.logo}]]</div>
|
||||
<div class="footer-logo"><th:block th:utext="${theme.config.footer.footer_bar.logo}"></th:block></div>
|
||||
<div class="footer-bar-description">[[${theme.config.footer.footer_bar.description}]]</div>
|
||||
<a class="footer-bar-link" href="/" data-pjax-state="">了解更多</a>
|
||||
</div>
|
||||
|
|
|
@ -108,10 +108,12 @@
|
|||
|
||||
win.activateDarkMode = function () {
|
||||
document.documentElement.setAttribute('data-theme', 'dark')
|
||||
document.documentElement.classList.add('color-scheme-dark')
|
||||
heo.initThemeColor()
|
||||
}
|
||||
win.activateLightMode = function () {
|
||||
document.documentElement.setAttribute('data-theme', 'light')
|
||||
document.documentElement.classList.remove('color-scheme-dark')
|
||||
heo.initThemeColor()
|
||||
}
|
||||
const t = saveToLocal.get('theme')
|
||||
|
@ -176,7 +178,7 @@
|
|||
</th:block>
|
||||
|
||||
<!-- icon图标 -->
|
||||
<link rel="stylesheet" th:href="'https://cdn.cbd.int/hao-theme-static@'+${theme.spec.version}+'/icon/iconfont.css'">
|
||||
<link rel="stylesheet" th:href="${assets_link + '/icon/iconfont.css' + theme_version}">
|
||||
|
||||
<th:block th:replace="~{modules/variables/site-config :: site-config}" />
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
rel="stylesheet" th:href="${not #strings.isEmpty(theme.config.comments.walines.walinesCss) ? theme.config.comments.walines.walinesCss : 'https://cdn.cbd.int/@waline/client@2.15.7/dist/waline.css' }">
|
||||
<!-- 解决 katex pjax问题 -->
|
||||
<script th:if="${pluginFinder.available('plugin-katex')}" defer="" src="/plugins/plugin-katex/assets/static/katex.min.js"></script>
|
||||
|
||||
<script th:src="${assets_link + '/js/custom.js' + theme_version}"></script>
|
||||
<th:block th:if="${head != null}">
|
||||
<th:block th:replace="${head}" />
|
||||
</th:block>
|
||||
|
|
|
@ -11,6 +11,25 @@
|
|||
--heo-theme-op: [(${theme.config.style.themeDarkSkin})]23 !important;
|
||||
--heo-theme-op-deep: [(${theme.config.style.themeDarkSkin})]dd !important;
|
||||
--heo-theme-none: [(${theme.config.style.themeDarkSkin})]00 !important;
|
||||
}
|
||||
|
||||
.color-scheme-dark,.dark,[data-color-scheme=dark] {
|
||||
--halo-search-widget-color-modal-layer: var(--heo-maskbgdeep);
|
||||
--halo-search-widget-color-modal-content-bg: var(--heo-card-bg);
|
||||
--halo-search-widget-color-form-input: rgb(255 255 255 / 79.9%);
|
||||
--halo-search-widget-color-form-input-placeholder: #6b7280d9;
|
||||
--halo-search-widget-color-form-input-bg: var(--heo-card-bg);
|
||||
--halo-search-widget-color-form-divider: #bbbbbb0f;
|
||||
--halo-search-widget-color-result-item-bg: var(--heo-card-bg);
|
||||
--halo-search-widget-color-result-item-hover-bg: #90939914;
|
||||
--halo-search-widget-color-result-item-title: rgb(255 255 255 / 79.9%);
|
||||
--halo-search-widget-color-result-item-content: #ffffff82;
|
||||
--halo-search-widget-color-command-kbd-item: #c0c4ccb3;
|
||||
--halo-search-widget-color-command-kbd-border: #bbbbbb0f;
|
||||
--halo-search-widget-color-result-empty: #6b7280d9
|
||||
}
|
||||
|
||||
[data-theme=light] {
|
||||
--halo-search-widget-color-result-item-title : #4B5563
|
||||
}
|
||||
</style>
|
Loading…
Reference in New Issue