mirror of
https://ghfast.top/https://github.com/zsjy/halo-theme-dream2.0-plus.git
synced 2025-03-15 17:49:40 +08:00
新增:侧边栏组件-微信公众号
This commit is contained in:
parent
219b948789
commit
c248179e6e
@ -665,6 +665,8 @@ spec:
|
||||
label: 文章标签云模块
|
||||
- value: 'timelife'
|
||||
label: 人生倒计时
|
||||
- value: 'wechat'
|
||||
label: 微信公众号
|
||||
- $formkit: select
|
||||
name: position
|
||||
label: 模块位置
|
||||
@ -782,6 +784,27 @@ spec:
|
||||
label: 目录模块不显示时
|
||||
- value: index
|
||||
label: 仅首页
|
||||
- $formkit: group
|
||||
name: wechat
|
||||
label: 微信公众号
|
||||
help: 图片可以从公众号后台下载物料或者自制。
|
||||
value:
|
||||
wechat_url:
|
||||
wechat_img_face:
|
||||
wechat_img_back:
|
||||
children:
|
||||
- $formkit: attachment
|
||||
name: wechat_url
|
||||
label: 跳转链接
|
||||
placeholder: '请输入网址/选择附件作为点击时的链接'
|
||||
- $formkit: attachment
|
||||
name: wechat_img_face
|
||||
label: 公众号正面图
|
||||
placeholder: '请输入/选择公众号正面图路径'
|
||||
- $formkit: attachment
|
||||
name: wechat_img_back
|
||||
label: 公众号背面图
|
||||
placeholder: '请输入/选择公众号背面图路径'
|
||||
- $formkit: attachment
|
||||
name: love_oneself_avatar
|
||||
label: 侧边栏恋爱墙-自己的头像
|
||||
@ -1324,24 +1347,6 @@ spec:
|
||||
label: busuanzi统计
|
||||
- value: false
|
||||
label: 不显示
|
||||
# - $formkit: radio
|
||||
# name: enable_baidu_push
|
||||
# label: 启用百度 URL 自动推送
|
||||
# value: false
|
||||
# options:
|
||||
# - value: true
|
||||
# label: 开启
|
||||
# - value: false
|
||||
# label: 关闭
|
||||
# - $formkit: radio
|
||||
# name: enable_toutiao_push
|
||||
# label: 启用头条搜索自动推送
|
||||
# value: false
|
||||
# options:
|
||||
# - value: true
|
||||
# label: 开启
|
||||
# - value: false
|
||||
# label: 关闭
|
||||
- $formkit: radio
|
||||
name: enable_debug
|
||||
label: 开启 DEBUG 日志
|
||||
|
@ -3323,6 +3323,74 @@ button.swiper-pagination-bullet {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*微信公众号*/
|
||||
&.wechat {
|
||||
/* 微信公众号翻转 */
|
||||
.flip-wrapper {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
z-index: 1;
|
||||
cursor: var(--cursor-default);
|
||||
|
||||
&.pointer{
|
||||
cursor: var(--cursor-pointer);
|
||||
}
|
||||
|
||||
&:hover .animation {
|
||||
-webkit-transform: rotateY(180deg);
|
||||
transform: rotateY(180deg);
|
||||
|
||||
.wechatBack {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.wechatFace {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.flip-content {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
|
||||
&.animation {
|
||||
-webkit-transform-style: preserve-3d;
|
||||
transform-style: preserve-3d;
|
||||
transition: cubic-bezier(0, 0, 0, 1.29) 0.3s;
|
||||
}
|
||||
}
|
||||
|
||||
.wechatFace {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
-webkit-backface-visibility: hidden;
|
||||
backface-visibility: hidden;
|
||||
background-size: 100%;
|
||||
}
|
||||
|
||||
.wechatBack {
|
||||
display: none;
|
||||
box-sizing: border-box;
|
||||
background-size: 100%;
|
||||
|
||||
&.animation {
|
||||
-webkit-transform: rotateY(180deg);
|
||||
transform: rotateY(180deg);
|
||||
}
|
||||
|
||||
&.show {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.main-content {
|
||||
|
@ -40,6 +40,9 @@ html {
|
||||
--radius-img: 5px;
|
||||
--box-shadow: 0 0px 10px -5px #949494;
|
||||
|
||||
--cursor-pointer: pointer;
|
||||
--cursor-default: default;
|
||||
|
||||
&.night {
|
||||
--theme: #5d93db;
|
||||
--main: #b0b0b0;
|
||||
|
2
templates/assets/css/style.min.css
vendored
2
templates/assets/css/style.min.css
vendored
File diff suppressed because one or more lines are too long
2
templates/assets/css/theme.min.css
vendored
2
templates/assets/css/theme.min.css
vendored
@ -1 +1 @@
|
||||
@charset "utf-8";html{--theme:#50bfff;--main:#505050;--title:#444;--background:rgba(255, 255, 255, 0.94);--background-hover:#fff;--style-a:#fff;--light-a:#ffffff;--light-b:#ebeef5;--light-c:#dcdcdc;--light-d:#c0c4cc;--light-x:#d6d6d6;--light-y:#1f1f1f;--light-z:#ffffff;--dark-a:#4a4a4a;--dark-b:#909399;--dark-c:#333;--dark-d:#9a9a9a;--dark-e:#7a7a7a;--color-a:#409eff;--bg-a:rgba(242, 246, 252, 0.8);--bg-b:#f2f6fc;--bg-c:#f5f5f5;--bg-d:rgba(255, 255, 255, 0.8);--bg-e:var(--theme);--bg-f:#f7f7f7;--bg-g:#e8f3ff;--bg-h:rgba(237, 244, 253, 0.75);--bg-i:#50bfff;--bg-j:rgba(243, 244, 245, 0.25);--bg-k:rgba(250, 250, 250, 0.8);--bg-l:rgba(243, 243, 243, 0.8);--bg-z:rgba(230, 240, 250, 0.75);--radius-wrap:8px;--radius-inner:4px;--radius-img:5px;--box-shadow:0 0px 10px -5px #949494;--halo-search-widget-base-font-size:1rem!important;--halo-search-widget-base-font-family:"Dream Font"!important;--halo-comment-widget-base-color:var(--light-y)!important;--halo-comment-widget-base-font-size:1rem!important;--halo-comment-widget-base-font-family:"Dream Font"!important;--halo-comment-widget-component-form-input-border-color-focus:var(--theme)!important;--halo-comment-widget-component-form-button-login-border-color:var(--light-c)!important;--halo-comment-widget-component-form-button-submit-bg-color:var(--theme)!important;--halo-comment-widget-component-form-button-submit-border-color:var(--theme)!important;--halo-comment-widget-component-form-button-submit-border-color-hover:var(--theme)!important;--halo-contact-form-font-family:"Dream Font"!important;--halo-contact-form-font-size:1rem!important;--halo-contact-form-width-submit:100%!important;--halo-contact-form-color-primary:var(--theme)!important;--halo-contact-form-color-label:var(--light-y)!important;--halo-contact-form-color-input:var(--light-y)!important;--halo-contact-form-color-danger:#ff5656!important}html.night{--theme:#5d93db;--main:#b0b0b0;--title:#c4c4c4;--background:rgba(40, 44, 52, 0.6);--background-hover:rgba(40, 44, 52, 0.8);--style-a:#080c28;--light-a:#232323;--light-b:#414243;--light-c:#303030;--light-d:#666;--light-x:#6e6e6e;--light-y:#fafafa;--light-z:#c2c2c2;--dark-a:#888;--dark-b:#777;--dark-c:silver;--dark-d:#aaa;--dark-e:#c0c0c0;--color-a:#cbba7d;--bg-a:rgba(65, 66, 67, 0.8);--bg-b:#303030;--bg-c:#373d48;--bg-d:rgba(40, 44, 52, 0.8);--bg-e:#434a56;--bg-f:#080c28;--bg-g:rgba(210, 210, 210, 0.2);--bg-h:rgba(65, 68, 74, 0.6);--bg-i:#276b92;--bg-j:rgba(36, 36, 36, 0.15);--bg-k:rgba(30, 33, 41, 0.8);--bg-l:rgba(63, 65, 75, 0.8);--bg-z:rgba(65, 68, 74, 0.6);--box-shadow:1px 1px 3px 1px #1b1b1b}html.night body::before{-webkit-filter:brightness(.3);filter:brightness(.3)}html.night .logo-img{display:none}html.night .logo-img-dark{display:inline-block}html.night .aplayer-pic,html.night .brightness,html.night .cover-image,html.night .small-image,html.night .thumbnail-image,html.night .waifu,html.night comment-widget,html.night iframe,html.night img,html.night svg,html.night video{-webkit-filter:brightness(.8);filter:brightness(.8)}html.night .canvas_effects.night{display:block}html.night .canvas_effects.day{display:none}html.night .main-content figure{color:var(--main);background:var(--bg-k)}html.night .main-content figure pre code{color:var(--color-a);background:0 0}
|
||||
@charset "utf-8";html{--theme:#50bfff;--main:#505050;--title:#444;--background:rgba(255, 255, 255, 0.94);--background-hover:#fff;--style-a:#fff;--light-a:#ffffff;--light-b:#ebeef5;--light-c:#dcdcdc;--light-d:#c0c4cc;--light-x:#d6d6d6;--light-y:#1f1f1f;--light-z:#ffffff;--dark-a:#4a4a4a;--dark-b:#909399;--dark-c:#333;--dark-d:#9a9a9a;--dark-e:#7a7a7a;--color-a:#409eff;--bg-a:rgba(242, 246, 252, 0.8);--bg-b:#f2f6fc;--bg-c:#f5f5f5;--bg-d:rgba(255, 255, 255, 0.8);--bg-e:var(--theme);--bg-f:#f7f7f7;--bg-g:#e8f3ff;--bg-h:rgba(237, 244, 253, 0.75);--bg-i:#50bfff;--bg-j:rgba(243, 244, 245, 0.25);--bg-k:rgba(250, 250, 250, 0.8);--bg-l:rgba(243, 243, 243, 0.8);--bg-z:rgba(230, 240, 250, 0.75);--radius-wrap:8px;--radius-inner:4px;--radius-img:5px;--box-shadow:0 0px 10px -5px #949494;--cursor-pointer:pointer;--cursor-default:default;--halo-search-widget-base-font-size:1rem!important;--halo-search-widget-base-font-family:"Dream Font"!important;--halo-comment-widget-base-color:var(--light-y)!important;--halo-comment-widget-base-font-size:1rem!important;--halo-comment-widget-base-font-family:"Dream Font"!important;--halo-comment-widget-component-form-input-border-color-focus:var(--theme)!important;--halo-comment-widget-component-form-button-login-border-color:var(--light-c)!important;--halo-comment-widget-component-form-button-submit-bg-color:var(--theme)!important;--halo-comment-widget-component-form-button-submit-border-color:var(--theme)!important;--halo-comment-widget-component-form-button-submit-border-color-hover:var(--theme)!important;--halo-contact-form-font-family:"Dream Font"!important;--halo-contact-form-font-size:1rem!important;--halo-contact-form-width-submit:100%!important;--halo-contact-form-color-primary:var(--theme)!important;--halo-contact-form-color-label:var(--light-y)!important;--halo-contact-form-color-input:var(--light-y)!important;--halo-contact-form-color-danger:#ff5656!important}html.night{--theme:#5d93db;--main:#b0b0b0;--title:#c4c4c4;--background:rgba(40, 44, 52, 0.6);--background-hover:rgba(40, 44, 52, 0.8);--style-a:#080c28;--light-a:#232323;--light-b:#414243;--light-c:#303030;--light-d:#666;--light-x:#6e6e6e;--light-y:#fafafa;--light-z:#c2c2c2;--dark-a:#888;--dark-b:#777;--dark-c:silver;--dark-d:#aaa;--dark-e:#c0c0c0;--color-a:#cbba7d;--bg-a:rgba(65, 66, 67, 0.8);--bg-b:#303030;--bg-c:#373d48;--bg-d:rgba(40, 44, 52, 0.8);--bg-e:#434a56;--bg-f:#080c28;--bg-g:rgba(210, 210, 210, 0.2);--bg-h:rgba(65, 68, 74, 0.6);--bg-i:#276b92;--bg-j:rgba(36, 36, 36, 0.15);--bg-k:rgba(30, 33, 41, 0.8);--bg-l:rgba(63, 65, 75, 0.8);--bg-z:rgba(65, 68, 74, 0.6);--box-shadow:1px 1px 3px 1px #1b1b1b}html.night body::before{-webkit-filter:brightness(.3);filter:brightness(.3)}html.night .logo-img{display:none}html.night .logo-img-dark{display:inline-block}html.night .aplayer-pic,html.night .brightness,html.night .cover-image,html.night .small-image,html.night .thumbnail-image,html.night .waifu,html.night comment-widget,html.night iframe,html.night img,html.night svg,html.night video{-webkit-filter:brightness(.8);filter:brightness(.8)}html.night .canvas_effects.night{display:block}html.night .canvas_effects.day{display:none}html.night .main-content figure{color:var(--main);background:var(--bg-k)}html.night .main-content figure pre code{color:var(--color-a);background:0 0}
|
19
templates/widget/wechat.html
Normal file
19
templates/widget/wechat.html
Normal file
@ -0,0 +1,19 @@
|
||||
<div xmlns:th="https://www.thymeleaf.org"
|
||||
th:fragment="widget (hide)"
|
||||
th:class="'card widget wechat ' + ${hide}"
|
||||
th:with="faceImg = ${theme.config.sidebar.wechat.wechat_img_face},
|
||||
backImg = ${theme.config.sidebar.wechat.wechat_img_back},
|
||||
wechatUrl = ${theme.config.sidebar.wechat.wechat_url}">
|
||||
<a class="flip-wrapper" th:classappend="${!#strings.isEmpty(wechatUrl)}? 'pointer'"
|
||||
th:href="${!#strings.isEmpty(wechatUrl) ? wechatUrl : (!#strings.isEmpty(faceImg) ? faceImg : (!#strings.isEmpty(backImg) ? backImg : '#'))}"
|
||||
th:onclick="${#strings.isEmpty(wechatUrl)} ? 'event.preventDefault();'" target="_blank">
|
||||
<div th:class="${!#strings.isEmpty(faceImg) && !#strings.isEmpty(backImg) ? 'flip-content animation' : 'flip-content'}">
|
||||
<div class="wechatFace">
|
||||
<img th:if="${!#strings.isEmpty(faceImg)}" th:src="${faceImg}" alt="微信公众号"/>
|
||||
</div>
|
||||
<div th:class="${!#strings.isEmpty(faceImg) && !#strings.isEmpty(backImg) ? 'wechatBack animation' : 'wechatBack'}" th:classappend="${#strings.isEmpty(faceImg)}? 'show'">
|
||||
<img th:if="${!#strings.isEmpty(backImg)}" th:src="${backImg}" alt="微信公众号"/>
|
||||
</div>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
@ -22,6 +22,6 @@ spec:
|
||||
settingName: theme-dream-setting
|
||||
configMapName: theme-dream-configMap
|
||||
# 版本号
|
||||
version: 1.0.1.16
|
||||
version: 1.0.1.58
|
||||
# 最低支持的 Halo 版本
|
||||
require: ">=2.6.0"
|
Loading…
x
Reference in New Issue
Block a user