1.2.5原版

This commit is contained in:
anian
2026-03-10 17:17:32 +08:00
commit af82232813
163 changed files with 35269 additions and 0 deletions
+70
View File
@@ -0,0 +1,70 @@
apiVersion: v1alpha1
kind: AnnotationSetting
metadata:
generateName: annotation-setting-
spec:
targetRef:
group: content.halo.run
kind: Post
formSchema:
- $formkit: "radio"
name: "mu_on"
key: "mu_on"
id: "mu_on"
label: "文章音乐"
value: "false"
options:
- label: "启用"
value: "true"
- label: "禁用"
value: "false"
- $formkit: "select"
if: "$get(mu_on).value != 'false'"
name: "mus_type"
label: "歌曲列表类型"
value: "playlist"
options:
- label: "歌曲列表"
value: "playlist"
- label: "专辑列表"
value: "album"
- $formkit: "select"
if: "$get(mu_on).value != 'false'"
name: "mus_source"
label: "歌曲源"
value: "netease"
options:
- label: "网易云"
value: "netease"
- label: "QQ音乐"
value: "tencent"
- label: "酷狗音乐"
value: "kugou"
- label: "酷我音乐"
value: "kuwo"
- $formkit: "text"
if: "$get(mu_on).value != 'false'"
name: "plays_id"
label: "列表ID"
- $formkit: "textarea"
if: "$get(mu_on).value != 'false'"
name: "mu_des"
label: "专辑描述"
---
apiVersion: v1alpha1
kind: AnnotationSetting
metadata:
generateName: annotation-setting-
spec:
targetRef:
group: ""
kind: MenuItem
formSchema:
- $formkit: "text"
name: "icon"
label: "图标"
+968
View File
@@ -0,0 +1,968 @@
apiVersion: v1alpha1
kind: Setting
metadata:
name: theme-pix-setting
spec:
forms:
- group: base_set
label: 常规设置
formSchema:
- $formkit: attachment
name: favicon
label: favicon
value: /themes/theme-pix/assets/img/favicon.ico
help: 建议制作一张400x400的png图像, 然后等比缩小到你想转换的ico尺寸,最后通过网上的工具转换成ico图标格式.
- $formkit: menuRadio
name: left_nav
label: 左侧菜单/移动端菜单
help: 默认只有主菜单,可前往【外观】—>【菜单】新建菜单组
value: ""
- $formkit: radio
name: site_pjax
label: 全站PJAX
value: false
options:
- label: 开启
value: true
- label: 关闭
value: false
- $formkit: checkbox
name: login_button
label: 显示登录按钮
value: true
- $formkit: text
name: site_page
label: 全站分页名称
value: LOAD MORE
- $formkit: text
name: custom_fonts
label: 自定义字体链接
- $formkit: text
name: nice_name
label: 博主自定义昵称
value: 倒霉蛋
- $formkit: text
name: admin_des
label: 博主简介
value: Born for design
- $formkit: attachment
name: default_avatar
label: 博主头像
value: /themes/theme-pix/assets/img/avatar.png
- group: base_top_set
label: 顶部设置
formSchema:
- $formkit: attachment
name: site_logo
label: 常规LOGO
value: /themes/theme-pix/assets/img/avatar.png
- $formkit: number
name: logo_height
label: 常规LOGO高度尺寸
value: 38
help: 只填写数值即可
- $formkit: attachment
name: m_site_logo
label: 方形LOGO
help: 建议制作一张48*48的方形LOGO
value: /themes/theme-pix/assets/img/avatar.png
- $formkit: attachment
name: mobile_logo
label: 移动端LOGO
value: /themes/theme-pix/assets/img/avatar.png
- $formkit: checkbox
name: top_nav_on_web
id: top_nav_on_web
key : top_nav_on_web
label: WEB 端顶部菜单开关
- $formkit: menuRadio
name: top_nav
if: $get(top_nav_on_web).value == true
label: WEB 端顶部菜单
help: 默认只有主菜单,可前往【外观】—>【菜单】新建菜单组
value: ""
- group: base_footer_set
label: 底部设置
formSchema:
- $formkit: repeater
name: sfooter_info
label: 底部信息
value: [ ]
children:
- $formkit: text
name: sf_title
label: 信息文本
- $formkit: text
name: sf_link
label: 信息链接
- $formkit: attachment
name: sf_img
label: 图标
- $formkit: radio
name: sf_open_new
label: 打开方式
value: _blank
options:
- label: 新窗口
value: _blank
- label: 当前窗口
value: _self
- $formkit: group
label: 移动端底部导航设置
name: footer_fpush
value:
fpush_open: true
footmenu_left:
children:
- $formkit: radio
label: 移动端底部导航
name: fpush_open
key: fpush_open
id: fpush_open
options:
- label: 显示
value: true
- label: 隐藏
value: false
- $formkit: repeater
name: footmenu_left
if: $get(fpush_open).value
label: 底部导航左侧区域
value: [ ]
children:
- $formkit: text
name: title
label: 菜单文本
- $formkit: text
name: icon
label: 图标
help: 图标为空则使用默认图标
- $formkit: radio
name: fmenu_type
id: fmenu_type
key: fmenu_type
label: 菜单类型
value: normal
options:
- label: 自定义链接
value: normal
- label: 返回顶部
value: top
- label: 搜索
value: search
- label: 黑夜切换
value: dark
- $formkit: text
if: $get(fmenu_type).value == 'normal'
name: link
label: 信息链接
- $formkit: radio
if: $get(fmenu_type).value == 'normal'
name: open_new
label: 打开方式
value: _blank
options:
- label: 新窗口
value: _blank
- label: 当前窗口
value: _self
- $formkit: repeater
name: footmenu_right
if: $get(fpush_open).value
label: 底部导航右侧区域
max: 3
children:
- $formkit: text
name: title
label: 菜单文本
- $formkit: text
name: icon
label: 图标
- $formkit: radio
name: fmenu_type
id: fmenu_type
key: fmenu_type
label: 菜单类型
value: normal
options:
- label: 自定义链接
value: normal
- label: 返回顶部
value: top
- label: 搜索
value: search
- label: 黑夜切换
value: dark
- $formkit: text
if: $get(fmenu_type).value == 'normal'
name: link
label: 信息链接
- $formkit: radio
if: $get(fmenu_type).value == 'normal'
name: open_new
label: 打开方式
value: _blank
options:
- label: 新窗口
value: _blank
- label: 当前窗口
value: _self
- group: style
label: 外观设置
formSchema:
- $formkit: select
name: theme_set
id: theme_set
label: 主题风格
value: green-normal
options:
- label: 绿色
value: green-normal
- label: 紫色
value: purple-gay
- label: 黑暗
value: dark-theme
- $el: div
if: $get(theme_set).value === 'green-normal'
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 100%;
display: block;
background-image: url('/themes/theme-pix/assets/img/theme/green.png') 100% / contain
- $el: div
if: $get(theme_set).value === 'purple-gay'
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/blue.png')
- $el: div
if: $get(theme_set).value === 'dark-theme'
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/dark.png')
- $formkit: select
name: layout_set
id: layout_set
label: 主题布局
value: mod_single
options:
- label: single
value: mod_single
- label: lbc
value: lbc
- label: double
value: mod_double
- label: third-s
value: mod_third_s
- label: third
value: mod_third
- $el: div
if: $get(layout_set).value === mod_single
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/single.png')
- $el: div
if: $get(layout_set).value === lbc
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/lbc.png')
- $el: div
if: $get(layout_set).value === mod_double
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/double.png')
- $el: div
if: $get(layout_set).value === mod_third_s
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/third-s.png')
- $el: div
if: $get(layout_set).value === mod_third
attrs:
fill: none
viewBox: "0 0 120 87"
style: |
width: 120px;
height: 87px;
background-image: url('/themes/theme-pix/assets/img/theme/third.png')
- $formkit: attachment
name: topbg_banner
label: 顶部封面图
value: /themes/theme-pix/assets/img/banner.jpg
- $formkit: radio
name: home_post_type
label: 首页类型模式
value: moment
help: 瞬间模式需要启用瞬间插件
options:
- label: 瞬间模式
value: moment
- label: 博客模型
value: post
- group: post
label: 文章设置
formSchema:
- $formkit: radio
name: post_list_type
label: 首页文章展示类型
value: card
options:
- label: 常规
value: normal
- label: 网格
value: grid
- label: 卡片
value: card
- label: 无图
value: notimg
- $formkit: select
name: post_nav
id: post_nav
key: post_nav
value: category
label: 首页文章导航条显示内容
options:
- label: 分类
value: category
- label: 自定义分类
value: custom_category
- $formkit: categorySelect
if: $get(post_nav).value === 'custom_category'
name: nav_category
key: nav_category
label: 自定义分类
multiple: true
clearable: true
searchable: true
sortable: true
- $formkit: color
name: tocColor
label: 颜色
value: "#58a5c3"
- $formkit: attachment
name: post_banner
label: 文章默认封面图
value: https://www.dmoe.cc/random.php
help: 支持随机图api(例如:https://www.dmoe.cc/random.php)
- $formkit: attachment
name: category_banner
label: 分类默认封面图
value: https://www.dmoe.cc/random.php
help: 支持随机图api(例如:https://www.dmoe.cc/random.php)
- $formkit: attachment
name: tag_banner
label: 标签默认封面图
value: https://www.dmoe.cc/random.php
help: 支持随机图api(例如:https://www.dmoe.cc/random.php)
- $formkit: number
name: post_word_max
label: 文章列表摘要字数
value: 100
- $formkit: group
label: 目录设置
name: toc
value:
all_open: true
mobile_open: true
children:
- $formkit: checkbox
name: all_open
id: all_open
key: all_open
label: 显示目录
value: true
- $formkit: checkbox
if: $get(all_open).value
name: mobile_open
label: 显示移动端目录
value: true
- $formkit: radio
name: donate_on
key: donate_on
id: donate_on
label: 文章打赏
value: false
options:
- label: 显示
value: true
- label: 隐藏
value: false
- $formkit: textarea
if: $get(donate_on).value
name: donate_des
label: 打赏文案
value: 求求你赏口饭吃吧!
- $formkit: attachment
if: $get(donate_on).value
name: donate_pic
label: 打赏二维码
value: /themes/theme-pix/assets/img/avatar.png
- group: moments
label: 瞬间设置
formSchema:
- $formkit: radio
name: img_style
label: 图片样式
value: one
options:
- label: 样式一
value: one
- label: 样式二
value: two
- $formkit: text
name: topics_de_cat
label: 默认瞬间发布标签
value: 日常
- $formkit: number
name: min_push_num
label: 瞬间发布最少字数限制
value: 6
help: 如果不限制,请输入-1
- $formkit: attachment
name: banner
label: 瞬间分享背景
value: /themes/theme-pix/assets/img/banner.jpg
- $formkit: attachmentPolicySelect
name: attachmentPolicy
label: 附件存储策略
help: 瞬间图片上传功能必填项
value: ""
validation: required
- $formkit: attachmentGroupSelect
name: attachmentGroup
label: 附件分组
value: ""
validation: required
- $formkit: text
name: gaode_key
label: 高德开放平台应用KEY
value:
help: "https://console.amap.com/"
- group: sidebar
label: 侧边栏
formSchema:
- $formkit: repeater
name: sidebar_left
id: sidebar_left
label: 左侧小工具栏
children:
- $formkit: select
name: widget
id: widget
key: widget
label: "小工具"
options:
- value: "user_widget"
label: 博主社交信息
- value: "adinfo_widget"
label: 博主基础信息
- value: "posts_show_widget"
label: 文章展示
- value: "hot_cat"
label: 专题推荐
- value: "tag_cloud"
label: 标签
- value: "cst_widget_comment"
label: 最新评论
- value: "pix_widget_tongji"
label: 站点统计
- value: "pix_widget_yiyan"
label: 一言
- value: "custom_html"
label: 自定义
- $formkit: group
name: custom_html
if: $value.widget == 'custom_html'
key: custom_html
label: 自定义内容
children:
- $formkit: text
name: title
label: 标题
- $formkit: code
name: html
label: 内容
height: 200px
help: 支持html语法
language: html
- $formkit: repeater
name: sidebar_right
id: sidebar_right
label: 右侧小工具栏
children:
- $formkit: select
name: widget
id: widget
key: widget
label: "小工具"
options:
- value: "user_widget"
label: 博主社交信息
- value: "adinfo_widget"
label: 博主基础信息
- value: "posts_show_widget"
label: 文章展示
- value: "hot_cat"
label: 专题推荐
- value: "tag_cloud"
label: 标签
- value: "cst_widget_comment"
label: 最新评论
- value: "pix_widget_tongji"
label: 站点统计
- value: "pix_widget_yiyan"
label: 一言
- value: "custom_html"
label: 自定义
- $formkit: group
name: custom_html
if: $value.widget == 'custom_html'
key: custom_html
label: 自定义内容
children:
- $formkit: text
name: title
label: 标题
- $formkit: code
name: html
label: 内容
height: 200px
help: 支持html语法
language: html
- $formkit: group
name: user_widget
label: 博主社交信息
help: 展示博主社交资料
children:
- $formkit: text
name: title
label: 菜单名称
- $formkit: repeater
name: admin_info
id: admin_info
label: 博主社交资料
children:
- $formkit: text
name: ad_title
label: 名称
- $formkit: color
name: s_btn_bg
label: 按钮背景颜色
value: "#2f2f2f"
- $formkit: text
name: ad_icon
label: 图标
help: 图标和图片二选一
- $formkit: attachment
name: ad_img
label: 图标图片
help: 建议18x18(px)方形的PNG图像
- $formkit: radio
name: ad_show_type
key: ad_show_type
id: ad_show_type
label: 信息展示方式
value: link
options:
- label: 跳转链接
value: link
- label: 二维码
value: qrcode
- $formkit: text
name: ad_link
key: ad_link
if: $value.ad_show_type == 'link'
label: 自定义链接
- $formkit: radio
if: $value.ad_show_type == 'link'
name: ad_open_new
key: ad_open_new
label: 打开方式
value: _blank
options:
- label: 新窗口
value: _blank
- label: 当前窗口
value: _self
- $formkit: attachment
if: $value.ad_show_type == 'qrcode'
name: ad_qrcode
key: ad_qrcode
label: 二维码
help: 建议尺寸不要太大
- $formkit: group
name: adinfo_widget
label: 博主基础信息
help: 展示博主个人资料
value:
title: About Me
children:
- $formkit: text
name: title
label: 菜单名称
- $formkit: repeater
name: base_info
id: base_info
label: 博主个人资料
children:
- $formkit: text
name: ba_title
label: 名称
- $formkit: text
name: ba_icon
label: 图标
help: 图标和图片二选一
- $formkit: attachment
name: ba_img
label: 图标图片
help: 建议18x18(px)方形的PNG图像
- $formkit: text
name: ba_des
label: 描述
- $formkit: text
name: ba_link
label: 自定义链接
help: 可不填
- $formkit: radio
name: ba_open_new
label: 打开方式
value: _blank
options:
- label: 新窗口
value: _blank
- label: 当前窗口
value: _self
- $formkit: group
name: posts_show_widget
label: 文章展示
help: 展示站点文章
value:
title: 热门文章
posts_number: 6
show_style: small_img
children:
- $formkit: text
name: title
label: 标题
- $formkit: number
name: posts_number
label: 文章数量
- $formkit: select
name: show_style
label: 展示形式
options:
- label: 无图列表
value: no_img
- label: 小图列表
value: small_img
- $formkit: group
name: hot_cat
label: 专题推荐
help: 展示推荐的分类专题
value:
title: 专题推荐
children:
- $formkit: text
name: title
label: 标题
- $formkit: categorySelect
name: widget_cat_select
label: 自定义分类
multiple: true
clearable: true
searchable: true
sortable: true
- $formkit: group
name: cst_widget_comment
label: 最新评论
help: 展示站最新评论
value:
title: 最新评论
number: 5
children:
- $formkit: text
name: title
label: 标题
- $formkit: number
name: number
label: 评论数量
- $formkit: group
name: pix_widget_tongji
label: 站点统计
value:
title: 站点统计
posts_count: true
moments_count: true
tags_count: true
comments_count: true
cat_count: true
site_day: true
build_date: "2023-11-02"
children:
- $formkit: text
name: title
label: 标题
- $formkit: checkbox
name: posts_count
label: 文章数
- $formkit: checkbox
name: moments_count
label: 片刻数
- $formkit: checkbox
name: tags_count
label: 标签数
- $formkit: checkbox
name: comments_count
label: 评论数
- $formkit: checkbox
name: cat_count
label: 分类数
- $formkit: checkbox
name: site_day
label: 运行时间
- $formkit: date
name: build_date
label: 建站日期
validation: required
- $formkit: group
name: pix_widget_yiyan
label: 一言
value:
title: 一言
yiyan_bg: /themes/theme-pix/assets/img/banner.jpg
children:
- $formkit: text
name: title
label: 标题
- $formkit: attachment
name: yiyan_bg
label: 背景图
- $formkit: text
name: api
label: api地址
help: 不填默认为内置api
- group: music
label: 音乐设置
formSchema:
- $formkit: text
name: pix_mu_api
label: 音乐API地址
help: 填写音乐api地址所在域名,例如 https://api.i-meto.com/meting/api 即可,不填则使用默认api
- $formkit: checkbox
name: bgm_open
id: bgm_open
key: bgm_open
label: 开启音乐播放器
value: false
- $formkit: checkbox
if: $get(bgm_open).value
name: lrc_open
label: 开启右侧音乐歌词
value: false
- $formkit: select
if: $get(bgm_open).value
name: m_loop
label: 歌单播放类型
value: all
options:
- label: 循环
value: all
- label: 单曲循环播放
value: one
- label: 随机播放
value: none
- $formkit: select
if: $get(bgm_open).value
name: mu_type
label: 歌曲列表类型
value: playlist
options:
- label: 歌曲列表
value: playlist
- label: 专辑列表
value: album
- $formkit: select
if: $get(bgm_open).value
name: mu_source
label: 歌曲源
value: netease
options:
- label: 网易云
value: netease
- label: QQ音乐
value: tencent
- label: 酷狗音乐
value: kugou
- label: 酷我音乐
value: kuwo
- $formkit: text
name: play_id
if: $get(bgm_open).value
label: 列表ID
- group: com
label: 评论设置
formSchema:
- $formkit: checkbox
name: com_close
label: 关闭所有评论
value: false
help: 备案期间可开启
- $formkit: text
label: 头像服务镜像地址
name: providerMirror
value: "https://cravatar.cn"
- group: landing_set
label: 落地页设置
formSchema:
- $formkit: select
name: land_type
id: land_type
key: land_type
label: 落地页风格
value: card
options:
- label: landcard
value: card
- label: landsimple
value: simple
- $formkit: checkbox
name: land_dark
label: 暗黑模式
value: false
- $formkit: attachment
name: land_logo
label: LOGO或头像
value: /themes/theme-pix/assets/img/avatar.png
- $formkit: attachment
name: land_feature
label: 封面头图
value: /themes/theme-pix/assets/img/landimg.jpg
- $formkit: text
name: land_title
label: 标题或名称
value: 我的博客
- $formkit: code
name: land_des
label: 描述
height: 100px
language: html
value: WELCOME TO MY BLOG 欢迎访问PIXIT , 接下来请享受丝滑的体验.
- $formkit: text
name: land_diy
label: 底部自定义文案
value: "- Born for design"
- $formkit: code
name: land_html
if: $get(land_type).value == 'simple'
label: 自定义HTML
height: 200px
language: html
value: css javascript
- $formkit: repeater
name: land_btn
label: 按钮组
children:
- $formkit: text
name: icon
label: 图标
- $formkit: text
name: name
label: 名称
- $formkit: text
name: link
label: 按钮链接
- $formkit: radio
name: open_new
label: 打开方式
value: _self
options:
- label: 新窗口
value: _blank
- label: 当前窗口
value: _self
- group: login_page
label: 登录页相关
formSchema:
- $formkit: attachment
name: custom_login_logo
label: 登录页 Logo
help: 推荐的像素为:宽度 288px,高度任意。如果不填写,将使用默认的 Halo 标志
value: /images/wordmark.svg
validation: required
- $formkit: "range"
name: custom_login_logo_size
id: custom_login_logo_size
label: 登录页 Logo 大小
help: "$get(custom_login_logo_size).value + '%'"
value: 50
validation: required
- $formkit: attachment
name: custom_login_background
label: 背景图
value: /themes/theme-pix/assets/img/default-header.png
accepts:
- "image/*"
- group: custom
label: 扩展设置
formSchema:
- $formkit: code
name: head_html
label: 头部HTML代码
height: 200px
language: html
- $formkit: code
name: footer_html
label: 底部HTML代码
height: 200px
language: html
- $formkit: code
name: code_css
label: 自定义CSS
height: 200px
language: css
- $formkit: code
name: code_js
label: 自定义Javascript
height: 200px
language: javascript
+22
View File
@@ -0,0 +1,22 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title= ${'博客' + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container" th:with="page = ${#strings.isEmpty(param.page) ? 1 : param.page}">
<th:block th:replace="~{macro/home-blog :: home-blog(${postFinder.list(page,site.post.postPageSize)},'/archives')}"></th:block>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+111
View File
@@ -0,0 +1,111 @@
.gallery-photos span img {
margin: 0 !important;
border-radius: 0;
bottom: 0px;
}
.gallery-photos {
width: 100%;
margin-top: 10px;
}
.gallery-photo {
min-height: 5rem;
width: 33.3%;
padding: 4px;
position: relative;
}
.gallery-photo span {
border-radius: 8px;
display: block;
overflow: hidden;
}
.gallery-photo img {
display: block;
width: 100%;
animation: fadeIn 1s;
cursor: pointer;
transition: all .4s ease-in-out !important;
}
.gallery-photo span.photo-title,
.gallery-photo span.photo-time {
max-width: calc(100% - 7px);
line-height: 1.8;
position: absolute;
left: 4px;
font-size: 14px;
background: rgba(0, 0, 0, 0.3);
padding: 0px 8px;
color: #fff;
animation: fadeIn 1s;
}
.gallery-photo span.photo-title {
bottom: 4px;
border-radius: 0 8px 0 8px;
}
.gallery-photo span.photo-time {
top: 4px;
border-radius: 8px 0 8px 0;
}
.gallery-photo:hover img {
transform: scale(1.1);
}
@media screen and (max-width: 1100px) {
.gallery-photo {
width: 33.3%;
}
}
@media screen and (max-width: 768px) {
.gallery-photo {
width: 49.9%;
padding: 3px
}
.gallery-photo span.photo-time {
display: none
}
.gallery-photo span.photo-title {
font-size: 12px
}
.gallery-photo span.photo-title {
left: 3px;
bottom: 3px;
}
}
@keyframes fadeIn {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
.uploadmore {
width: 40%;
max-width: 810px;
height: 30px;
margin: auto;
border-radius: 12px;
font-weight: 700;
text-align: center;
display: flex;
align-items: center;
justify-content: center;
cursor: pointer;
border: 1px solid #000;
box-shadow: 0 8px 16px -4px #2c2d300c;
background: #f4f4f4
}
+343
View File
@@ -0,0 +1,343 @@
:root {
--pix-style-border-always: 1px solid var(--card-border);
--pix-secondbg: #f7f7f9;
--dark-body-bg: #d0dada;
--card-border: #e3e8f7;
}
/*黑夜模式*/
.dark {
--pix-secondbg: #21232a;
--dark-bg: #111324;
--dark-medium-bg: #161829;
--dark-light-bg: #2e325c;
--light-color: #dedede;
--text-color: #a5a9c3;
--dark-border: #1e2036;
--dark-ac-btn: #2b48ff;
--dark-icon: #8c92b3;
--text-light: #5b5f80;
--normal-btn: #292c45;
--btn-normal: #1e2139;
--dark-body-bg: #0a0c19;
--dark-body-gay-bg: #0a0c19;
--card-border: #42444a;
--code-color: var(--normal-btn);
--halo-comment-widget-ava-content-background: #292c45;
--halo-comment-widget-component-comment-author-info-input: var(--dark-medium-bg);
--halo-comment-widget-a-color: #dedede;
--halo-comment-widget-time-color: #5b5f80;
--halo-comment-widget-parents_at-color: #7786e7;
--halo-comment-widget-text-color: var(--text-color);
--halo-comment-widget-textarea-comment-color: #dedede;
--halo-comment-widget-component-form-button-submit-pix-bg-color: #2b48ff;
--halo-comment-widget-component-form-button-submit-pix-color: #fff;
--halo-comment-widget-component-pagination-button-pix-bg-color-hover: #3b3eff;
--halo-comment-widget-component-pagination-button-pix-bg-color-active: #1e2139;
--halo-comment-widget-component-pagination-button-pix-border-color-active: #8c92b3;
--halo-comment-widget-component-form-input-pix-bg-color: var(--dark-medium-bg);
--halo-comment-widget-component-form-input-color: #dedede;
--halo-comment-widget-component-form-input-border-color: #1e2036;
--halo-comment-widget-component-webkit-box-shadow: #d0dada00;
--halo-comment-widget-component-box-shadow: #d0dada00;
--halo-comment-widget-component-border-bottom-color: var(--dark-border);
--halo-comment-widget-component-btn-active-color: #3b3eff;
--halo-comment-widget-parents_at-color: #3b3eff;
}
.dark .left_nav_inner , .dark .entry-footer , .dark .topic_comments_wrap , .dark #create_post_box .modal_inner , .dark #topic-title ,.dark input#set_local
, .dark .t_cat_box li , .dark .single_content .comments-area , .dark #commentform textarea#comment , .dark .single_wrap .comments-area, .dark .page_content .comments-area
, .dark .column_inner , .dark #login_form_box .modal_inner , .dark #link_modal .uk-modal-dialog , .dark #msg_modal .uk-modal-dialog , .dark .moment_card_item a
, .dark .post_control_list , .dark .sidebar_right , .dark .right_admin_tool , .dark .top_set_box a.active , .dark .single-content blockquote, .dark .entry-content blockquote
, .dark .footer_main .inner ,.dark .m_offcanvas .inner {
background: var(--dark-bg);
}
.dark #ava-content {
background-color: #292c45;
}
.dark .unread_box .vi_reply_item {
background: #2f325545;
}
.dark .blog_list_inner, .dark .normal_list_inner, .dark .single_wrap , .dark .top_bar , .dark .left_menu_box ul li a:hover, .dark .link_group .item:hover
, .dark #t_commentform , .dark textarea#comment , .dark .field textarea , .dark .single_content, .dark .page_content, .dark .page_wrap , .dark #topic_content , .dark .t_cat_box
, .dark .local_box , .dark input#add_cat , .dark .show_media_box, .dark .show_cdn_media , .dark input#img_link_up , .dark .com_smile_show .inner
, .dark #commentform , .dark #login_form_box input#username, .dark #login_form_box input#password , .dark #comment-author-info input , .dark .field input , .dark .archive_main
, .dark .page_main , .dark .loacl_audio .audio_right input,.dark .loacl_audio input, .dark .netease_audio input, .dark .tencent_audio input, .dark .kugou_audio input, .dark .kuwo_audio input , .dark .loacl_audio .audio_left , .dark .edit_card_box .edit_content input
, .dark input#moment_video_url, .dark input#moment_video_bili , .dark .m_media_left , .dark .widget_tag_cloud a , .dark .cst_widget_comment ul li .right .body
,.dark .nodata_main , .dark .s_main , .dark .musci_list_box , .dark .volume_box , .dark .top_set_box , .dark .sw_qrcode {
background: var(--dark-medium-bg);
}
.dark .main_wrap, .dark .top_ava img , .dark .left_menu_box ul li a:hover, .dark .link_group .item:hover , .dark .t_cat_box
, .dark .local_box , .dark .com_smile_show , .dark #ava-content , .dark .moment_card_item.loop_card_item a:hover , .dark .post_control_list
, .dark .widget_tag_cloud a , .dark .single_music_header .mu_img img , .dark .sw_qrcode{
box-shadow: none;
}
.dark .left_menu_box ul li a , .dark .normal_card_content .entry-title a , .dark .list_user_meta .name , .dark .post_footer_meta span.comnum , .dark .p_title a , .dark .avatar_title a
, .dark textarea#comment , .dark .field textarea , .dark .p_title ,.dark .avatar_title , .dark #topic_content , .dark #topic-title , .dark input#add_cat , .dark input#set_local
, .dark input#img_link_up , .dark .comment-list li .com_right .left h4 a , .dark .post-single .entry-title , .dark .page_content .entry-title
, .dark .page_content .entry-header i , .dark p.log_title , .dark #login_form_box input#username, .dark #login_form_box input#password , .dark #comment-author-info input
, .dark .links_count , .dark .link_cat_name , .dark .link_group .item .info .name a , .dark .msg_title , .dark .archive_main .cat_title h1
, .dark .normal_content .entry-title a, .dark .normal_grid_content .entry-title a , .dark .player_meta .title , .dark .moment_card_item .right h4
, .dark .loacl_audio .audio_right input, .dark .netease_audio input , .dark .edit_card_box .edit_content input , .dark input#moment_video_url, .dark input#moment_video_bili
, .dark .post_control_list a , .dark .t_dark a i , .dark .player_mod .m_info h2 , .dark .posts_mu_list li , .dark .posts_mu_list .s_play_btn, .dark .signup span,.dark #login_form_box [for="loginRemember"] {
color: var(--light-color);
}
.dark .normal_content .entry-content p, .dark .normal_card_content .entry-content p , .dark .normal_content .post_footer_meta span.comnum
, .dark .normal_card_content .post_footer_meta span.comnum, .dark .normal_grid_content .post_footer_meta span.comnum , .dark .post_footer_meta span
, .dark .t_content p , .dark .t_content ,.dark .up_img_btn i , .dark .t_cat_box li , .dark .show_cdn_media span , .dark .form_footer .admin_tool a
, .dark .comment-list li .com_right .body p , .dark .comment-list p.nodata , .dark .single-content p , .dark ul.column_lists li a
, .dark .page_content .entry-content , .dark blockquote , .dark .link_group .item .info .description , .dark .vi_reply_item .content
, .dark .vi_reply_item .target_comment , .dark .msg_log , .dark .post_footer_meta span i , .dark .edit_audio_box .tips, .dark .edit_video_box .tips
, .dark span.ip_loca , .dark .posts_show_widget ul li .title a , .dark .cst_widget_comment ul li .right a , .dark .pix_widget_tongji ul li small
, .dark .top_s_box input.s_input , .dark .top_menu_box ul li a , .dark .top_menu_box ul li a i , .dark .pl_btn a i {
color: var(--text-color);
}
.dark .posts_show_widget ul li .title a:hover,.dark .cst_widget_comment ul li .right a:hover,.dark .normal_card_content .entry-title a:hover, .dark .post-categories a:hover,.dark .sf_item a:hover{
color: var(--dark-ac-btn);
}
.dark .moment_cat_nav, .dark .posts_cat_nav ,.dark .photos_cat_nav, .dark .left_menu_box ul, .dark textarea#comment , .dark .field textarea , .dark .tool_box, .dark .smile_show, .dark .form_footer, .dark .set_cat, .dark #commentform textarea#comment
, .dark .p_item , .dark .footer_nav_box , .dark #t_pagination, .dark #pagination , .dark #p_pagination,.dark input#set_local , .dark input#img_link_up , .dark .comments-area ul.comment-list li
, .dark .commentnav , .dark #t_commentform , .dark #commentform , .dark .single-inner , .dark .page_content .entry-header , .dark #login_form_box input#username, .dark #login_form_box input#password
, .dark #comment-author-info input , .dark .field input , .dark .vi_reply_item , .dark #topic_content , .dark .archive_main .page-header , .dark .widget_inner .widget , .dark .moment_card_item.loop_card_item a
, .dark .edit_card_box .edit_content input , .dark .post_control_list , .dark .link_group_content , .dark .set_text , .dark .s_tips , .dark .single-content blockquote, .dark .entry-content blockquote,.dark .entry-content ol li{
border-color: var(--dark-border);
}
.dark .left_menu_box li[class*=current-] a , .dark .moment_cat_nav ul li a.active, .dark .posts_cat_nav ul li a.active ,.dark .photos_cat_nav ul li a.active , .dark .normal_cat , .dark #t_pagination a, .dark #pagination a, .dark .arc_pagenav a , .dark #p_pagination a
, .dark a.go_top , .dark input#push_comment , .dark .up_cat_btn , .dark a.set_local_btn , .dark a.img_link_btn
, .dark .push_item , .dark .de_cat , .dark .commentnav span.page-numbers.current , .dark input.submit_button , .dark #post_pager a
, .dark .edit_card_box .edit_content a.push_card , .dark span.de_card i , .dark .post_control_list a:hover , .dark .t_dark a , .dark .left_menu_box li[class*=current-] a:hover
,.dark a.bg_music , .dark a.bg_lrc, .dark .vo_size ,.dark .footer_menu .inner .center .mobile_edit {
background: var(--dark-ac-btn);
color: #fff;
}
.dark ::-webkit-scrollbar-thumb{
background-color: var(--dark-ac-btn);
}
.dark .uk-dropdown{
background: var(--dark-border);
color: #666;
}
.dark .user_pannel .inner a {
background: var(--normal-btn);
color: var(--text-light);
}
.dark .user_pannel .inner a:hover {
background: var(--dark-ac-btn);
color: #fff;
}
.dark .t_dark a i , .dark .top_tool i , .dark .normal_content .post_footer_meta span.comnum i
, .dark .normal_card_content .post_footer_meta span.comnum i, .dark .normal_grid_content .post_footer_meta span.comnum i , .dark a.up_like i
, .dark .footer_nav_box ul li a , .dark .comment_smile_box a i , .dark #login_form_box label i , .dark .ad_info .name , .dark .top_s_box form i {
color: var(--dark-icon);
}
.dark a.up_like.done i {
color: #ff5d49;
}
.dark .normal_content .entry_meta, .dark .normal_card_content .entry_meta, .dark .normal_grid_content .entry_meta , .dark #post_pager .c_paged , .dark .comment-list li .com_right .left time
, .dark a.comment-reply-link , .dark span.single_time , .dark ul.column_lists li span , .dark .page_content .entry-header .right time
, .dark a.beian , .dark footer#colophon , .dark .ad_info p , .dark .ad_info a , .dark .widget_tag_cloud a , .dark .cst_widget_comment ul li .right .body
, .dark .cst_widget_comment ul li .right .meta , .dark .posts_show_widget ul li .meta , .dark .pix_widget_tongji ul li span ,.dark .set_text
, .dark .top_s_box input::-webkit-input-placeholder , .dark .mu_des , .dark .s_tips , .dark .top_set_box a {
color: var(--text-light);
}
.dark .moment_cat_nav ul li a, .dark .posts_cat_nav ul li a , .dark .photos_cat_nav ul li a , .dark .link_group .item:hover {
background: var(--normal-btn);
color: var(--text-light);
}
.dark .moment_cat_nav ul li a:hover,.dark .posts_cat_nav ul li a:hover,.dark .photos_cat_nav ul li a:hover {
background-color: var(--dark-ac-btn);
color: #fff;
}
.dark .top_bar.uk-sticky-fixed.uk-active , .dark .footer_nav_box , .dark .top_menu_box {
background: rgb(27 29 48 / 80%);
}
.dark .footer_nav_box , .dark .top_menu_box {
border: none;
color: var(--light-color);
}
.dark .footer_nav_box ul li a:hover , .dark .ad_info a:hover , .dark .audio_choose li.uk-active a , .dark .video_choose li.uk-active a, .dark .s_tips span
, .dark .posts_mu_list li:hover div, .dark .posts_mu_list li:hover a, .dark .posts_mu_list li.active, .dark .posts_mu_list li.active .s_play_btn , .dark .s_set_box a.active
, .dark .search_box .s_set_box a:hover , .dark .posts_show_widget .no_img li a:before {
color: var(--dark-ac-btn);
}
.dark .loca i , .dark a.up_img_btn , .dark .up_from_media a, .dark .up_from_cdn a , .dark .attch_nav a i
, .dark a.img_link_cancel , .dark .push_close , .dark .commentnav a , .dark .post-categories a , .dark .link_group .item{
background: var(--btn-normal);
color: var(--dark-icon);
}
.dark .up_img_type {
border: none;
}
.dark .t_cat_box li span i {
background: transparent;
}
.dark .t_cat_box li span {
color: var(--text-color) !important;
}
.dark #topic_content:focus {
box-shadow: 0 0 0 0.12rem rgb(84 96 155);
}
.dark input#img_link_up:focus , .dark input#set_local:focus , .dark #t_commentform:focus-within , .dark #commentform:focus-within , .dark #login_form_box input#username:focus
, .dark #login_form_box input#password:focus , .dark #comment-author-info input:focus , .dark .field input:focus , .dark .audio_choose li.uk-active a , .dark .video_choose li.uk-active a , .dark .player_dot{
border-color: var(--dark-ac-btn);
}
.dark a.parents_at , .dark ul.column_lists li a:hover , .dark .single-content a, .dark .page_content .entry-content a , .dark a.mo_link , .dark .t_content a , .dark .show-more-btn , .dark .vi_reply_item .name span
, .dark .vi_reply_item .meta a , .dark .copyright a {
color: #7786e7;
}
.dark .single-content ul li ,.dark .entry-content ul li, .dark .single-content ol li {
border-bottom: 1px solid #282a40;
color: #bdbfff;
}
.dark .single-content h1 , .dark .single-content h2 , .dark .single-content h3 , .dark .single-content h4 {
color: #e5e8ff;
}
.dark .page_content pre {
border: 1px solid #111324;
background: #111324;
color: #fff8f8;;
}
.dark .post_footer_meta span.sticky_icon {
background: #ff4731;
color: #fff;
}
.dark .post_footer_meta span.sticky_icon i , .dark .post_footer_meta span.comnum i{
color: #fff;
}
.dark .moment_type_btn i , .dark .smile_box i, .dark .simi i, .dark .t_cat i , .dark span.moment_btn_line , .dark .simi i.ri-lock-unlock-line {
color: #6674c1 !important;
background: transparent !important;
}
.dark .pix_player.loacl_audio {
background: rgb(59 59 59);
}
.dark .pix_player {
background: rgb(43 43 43 / 75%);
}
.dark .player_bar {
background: #585858;
}
.dark .local_video {
background: #2b2d40;
}
.dark .show_card {
background: #1f2136;
border: 1px dashed #4c5985;
}
.dark .pix_widget_tongji ul li {
box-shadow: 0px 8px 4px 0px rgb(15 17 33);
background: linear-gradient(90deg,#161829,#816bff00);
}
.dark .top_s_box input.s_input{
background: rgb(13 15 35 / 65%);
}
.dark .single_music_header .mu_img img {
border: 1px solid #0a0c19;
}
.dark .posts_mu_list {
background: #111324;
border: 1px solid #0a0c19;
}
.dark .posts_mu_list li:nth-of-type(odd) {
background: #161829;
}
.dark .left_menu_box li[class*=current-] ul a {
background: inherit;
color: var(--light-color);
}
.dark .single_footer_box {
background: linear-gradient(90deg,#262841,#816bff00);
}
.dark .footer_menu .inner {
background: #0d0f1e;
border-top: 1px solid #0d0f1e;
}
.dark .bgm_box {
border-bottom: 1px solid #0d0f1e;
}
.dark .footer_menu li a , .dark .footer_menu li a i , .dark .m_offcanvas ul li a , .dark .m_offcanvas ul li a i {
color: #c7caff;
}
.dark .current-line {
color: #9098a7;
}
.dark .current-line .active {
color: var(--light-color);
}
/**豆瓣插件*/
.dark .doulist-item .doulist-subject .db--viewTime {
color: var(--light-color);
background :#2f2f2f
}
.dark .doulist-item {
border-color: var(--dark-border);
}
.dark .doulist-item .doulist-subject .abstract,.dark .doulist-item .doulist-subject .rating_nums {
color: #909090;
}
.dark .msg_modal_inner .body p{
color: var(--light-color);
}
.dark .msg_modal_inner .body pre{
background: var(--dark-medium-bg);
border: var(--dark-medium-bg);
color: var(--light-color);
}
File diff suppressed because it is too large Load Diff
+712
View File
@@ -0,0 +1,712 @@
/**
* 1440px
*/
@media only screen and (max-width:1440px) {
.footer_top , .footer_text {
font-size: 12px;
}
.land_content {
max-width: 960px;
height: 550px;
}
.land_right {
padding: 60px;
padding-top: 150px;
}
.land_logo {
margin-bottom: 40px;
}
.land_right {
padding-top: 40px;
}
.land_right .title {
font-size: 28px;
}
.land_right .land_des {
font-size: 15px;
}
.land_right .footer {
padding: 0 60px;
}
}
@media only screen and (max-width:1920px) {
.main_wrap , .footer_nav , .go_top_box {
max-width: 860px;
}
.land_content {
max-width: 1080px;
height: 607px;
}
.land_right {
padding: 40px;
padding-top: 60px;
}
.land_logo {
margin-bottom: 30px;
}
.land_right .title {
font-size: 32px;
}
.land_right .land_des {
font-size: 14px;
}
.land_right .footer {
padding: 0 40px;
}
body.mod_third .main_wrap , body.mod_third .go_top_box {
max-width: 1180px;
}
body.mod_third .footer_nav {
max-width: 885px;
}
}
@media only screen and (max-width:1366px) {
.land_content {
max-width: 860px;
height: 500px;
}
.land_right {
padding: 30px;
padding-top: 30px;
}
.land_logo {
margin-bottom: 15px;
}
.land_right .title {
font-size: 22px;
}
.land_right .land_des {
font-size: 14px;
}
.land_right .footer {
padding: 0 40px;
}
.land_nav a span , .land_nav a i {
font-size: 14px;
}
body.mod_third .main_wrap , body.mod_third .go_top_box , body.mod_third .footer_nav {
max-width: 860px;
}
body.mod_third .main_sidebar {
display: none;
}
body.mod_third #top_third{
display: flex;
}
body.mod_third .left_nav {
width: calc(100% * 1 / 3.001);
}
body.mod_third .page_main {
width: calc(100% * 2 / 3.001);
}
body.mod_third .top_bar {
border-top-right-radius: 12px;
}
}
@media only screen and (max-width:1200px) {
.land_page {
align-items: flex-start;
}
.land_content {
display: flex;
flex-direction: column;
margin: 0;
height: max-content;
border-radius: 0;
position: relative;
align-items: center;
max-width: 100%;
}
.land_left {
min-height: calc(100vh);
width: 100%;
}
.land_right {
width: 94%;
position: absolute;
background: rgb(243 245 255 / 78%);
border-radius: 18px;
top: 5%;
backdrop-filter: blur(0.5rem);
-webkit-backdrop-filter: blur(0.5rem);
padding: 30px 30px 50px;
border: 1px solid #fff;
}
.land_logo {
margin-bottom: 30px;
}
.land_logo img {
height: 42px;
object-fit: cover;
border-radius: 8px;
}
.land_right .title {
font-size: 32px;
}
.land_right .footer {
position: relative;
bottom: auto;
margin-top: 40px;
padding: 0;
}
.land_nav {
display: flex;
justify-content: space-between;
flex-direction: row;
flex-wrap: wrap;
}
.land_nav a {
display: flex;
flex-direction: column;
align-items: center;
margin: 0;
padding: 8px;
border-radius: 12px;
background: #1d1d1d;
margin-bottom: 8px;
width: 22%;
}
.land_nav a i {
margin: 0;
}
.land_right .beian , .land_right .copyright {
color: #293563;
}
}
@media only screen and (max-width:960px) {
.main_wrap , .top_bar , .footer_nav {
max-width: 720px;
}
.main_wrap {
margin-top: 0;
}
.lbc .page_main , .lbc .footer_nav_box .right {
width: 100%;
}
.top_logo {
margin-left: 20px;
}
.land_nav a {
display: flex;
flex-direction: column;
align-items: center;
}
footer#colophon {
display: none;
}
body.mod_third .main_wrap, body.mod_third .go_top_box, body.mod_third .footer_nav {
max-width: 720px;
}
body.mod_third .page_main {
width: 100%;
}
body.mod_third_s .sidebar_right {
display: none;
}
body.mod_third_s #top_third{
display: block;
}
body.mod_third_s .page_main {
width: 100%;
}
.top_menu_box {
border-radius: 8px;
}
}
@media only screen and (max-width:540px) {
body.mod_third_s #top_third,body.mod_third #top_third{
display: flex;
}
.top_right {
margin-right: 15px;
justify-content: flex-end;
width: 100%;
}
.user_info .avatar {
width: 54px;
height: 54px;
}
.moment_cat_nav, .posts_cat_nav, .photos_cat_nav {
padding: 15px;
}
#post_item,#photos_item {
padding: 0 15px;
}
.p_item {
padding: 20px 0;
}
.t_content p {
margin-bottom: 8px;
}
.normal_card_content .feature {
width: 100px;
min-width: 100px;
height: 120px;
margin-right: 12px;
}
.normal_content .entry-content p, .normal_card_content .entry-content p {
display: none;
}
.normal_card_content .entry-title {
font-size: 16px;
word-break: break-all;
}
.normal_card_content .card_right {
width: 100%;
}
.entry-footer {
padding: 5px 8px;
margin-top: 10px;
}
.normal_content .entry-content .feature {
margin-top: 8px;
height: 140px;
}
.normal_cat {
font-size: 12px;
}
.single_wrap {
padding: 15px;
padding-bottom: 100px;
}
.single_wrap .comments-area, .page_content .comments-area , .single_content .comments-area {
padding: 15px;
}
.list_user_meta .avatar {
width: 40px;
height: 40px;
min-width: 40px;
}
.blog_content {
padding-left: 50px;
}
.comments-area ul.comment-list li .profile , .comments-area ul.comment-list li .profile a {
width: 35px;
height: 35px;
}
.img_show {
width: calc(83px*3);
}
/*.img_list a {*/
/* width: 30%;*/
/* margin: 2px;*/
/*}*/
.t_media_item , a.up_img_btn{
width: 80px;
height: 80px;
}
.single_content, .page_content, .page_wrap {
padding: 0 15px;
padding-bottom: 100px;
}
.page_wrap {
padding-top: 20px;
}
.user_info {
bottom: 18%;
}
.blog_list_inner , .single_content, .page_content, .page_wrap , .normal_list_inner , .single_wrap {
border-radius: 12px;
position: relative;
z-index: 199;
top: -18px;
}
.top_left {
margin-left: 8px;
}
.top_left .top_logo {
display: block;
margin-left: 0;
}
.top_bar , .dark .top_bar {
height: 64px;
width: 100% !important;
border-radius: 0;
background: transparent;
}
.top_logo img {
height: 40px !important;
}
.footer_nav_box ul li a i {
font-size: 18px;
}
.footer_nav_box .inner {
min-height: 60px;
}
.footer_nav_box ul li a {
padding: 0 15px;
}
.t_login {
display: none;
}
a.go_top {
display: none;
}
a.mobile_edit {
display: flex;
}
.index_banner {
margin-top: -64px;
height: 260px;
}
.top_bar.uk-sticky-fixed.uk-active , .dark .top_bar.uk-sticky-fixed.uk-active {
background: transparent;
backdrop-filter: none;
-webkit-backdrop-filter: none;
}
.top_bar.uk-sticky-fixed.uk-active.mobile_active {
backdrop-filter: blur(0.5rem);
-webkit-backdrop-filter: blur(0.5rem);
background: rgb(255 255 255 / 80%);
}
.dark .top_bar.uk-sticky-fixed.uk-active.mobile_active {
background: rgb(27 29 48 / 80%);
}
.top_tool i , .dark .top_tool i , .dark .mobile_active .top_tool i , .t_dark a i , .dark .t_dark a i {
color: #fff;
}
.mobile_active .top_tool i {
color: #000000;
}
.top_tool input.s_input:focus ~ [class*=ri-] {
color: #4f4f4f;
}
.land_page {
align-items: flex-start;
}
.land_content {
display: flex;
flex-direction: column;
margin: 0;
height: max-content;
border-radius: 0;
position: relative;
align-items: center;
}
.land_left {
min-height: calc(100vh);
width: 100%;
}
.land_right {
width: 94%;
position: absolute;
background: rgb(243 245 255 / 78%);
border-radius: 18px;
top: 5%;
backdrop-filter: blur(0.5rem);
-webkit-backdrop-filter: blur(0.5rem);
padding: 30px 30px 50px;
border: 1px solid #fff;
}
.land_logo {
margin-bottom: 30px;
}
.land_logo img {
height: 42px;
object-fit: cover;
border-radius: 8px;
}
.land_right .title {
font-size: 32px;
}
.land_right .footer {
position: relative;
bottom: auto;
margin-top: 40px;
padding: 0;
}
.land_nav {
display: flex;
justify-content: space-between;
flex-direction: row;
flex-wrap: wrap;
}
.land_nav a {
display: flex;
flex-direction: column;
align-items: center;
margin: 0;
padding: 8px;
border-radius: 12px;
background: #1d1d1d;
margin-bottom: 8px;
width: 22%;
}
.land_nav a i {
margin: 0;
}
.land_right .beian , .land_right .copyright {
color: #293563;
}
.sim .land_content {
padding: 0 15px;
}
.sim .land_nav a {
width: 22%;
margin-bottom: 8px;
}
.sim .land_meta {
left: 40px;
}
.darkl .land_right .title p {
color: #323232;
}
.darkl .land_right .land_des {
color: #222433;
}
.darkl .land_right .land_des a {
color: #00935a;
}
.land_nav a span {
font-size: 13px;
}
.archive_main .page-header {
padding: 20px 15px;
}
.post_footer_meta span.sticky_icon {
display: none;
}
.t_form {
padding: 0 15px;
padding-top: 20px;
}
.topic_tool {
padding: 0px 15px 40px;
}
.uk-modal {
padding: 5px;
}
.t_search.top_tool.icon_color {
display: block;
}
.top_s_box {
display: none;
}
a.bg_music , .dark a.bg_music {
background: transparent;
width: auto;
height: auto;
margin-left: 10px;
}
a.bg_music i {
color: #fff;
}
.player_mod .tool , a.m_prev , a.m_next , .timer , a.m_volume , .player_hand {
display: none;
}
.player_mod .m_cover {
width: 32px;
height: 32px;
min-width: 32px;
}
.player_mod .m_cover img {
border-radius: 50%;
}
a.m_play {
line-height: 1;
}
.bgm_box {
padding: 6px 10px;
border-bottom: 1px solid #f4f4f4;
}
.footer_nav_box .footer_player {
min-height: auto;
}
.player_mod .pl_btn {
margin-right: 0;
}
.footer_nav_box {
top: 56px;
z-index: -1;
}
.footer_menu {
display: block;
}
.player_mod .m_info small {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
max-width: 100px;
}
.single_music_header .mu_img {
width: 120px;
height: 120px;
min-width: 120px;
}
.footer_main {
position: relative;
padding-bottom: 110px;
}
.mobile_logo {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
}
/*.img_list a:nth-child(1):nth-last-child(4), .img_list a:nth-child(3):nth-last-child(2), .img_list a:nth-child(4):nth-last-child(1) {*/
/* width: 30%;*/
/*}*/
.admin_ava a.mobile_edit {
display: none;
}
body.mod_third_s .nav_title {
display: flex;
opacity: 1;
}
body.mod_third_s .footer_nav_box .right {
width:100%;
}
}
+275
View File
@@ -0,0 +1,275 @@
/*基佬紫主题*/
:root {
--pix-theme: #3b3eff;
--body-bg-color: #e8e8f1;
--withe-bg-color: #fff;
--light-bg-color: #f6f7ff;
--linear-color:linear-gradient(90deg,#4832ff,#816bff);
--shadow-bg: 0px 7px 20px 1px #d7ceff30;
--btn-active-color: var(--pix-theme);
--btn-light-color:#e9ecfe;
--big-shadow: 0 28px 50px rgb(212 221 255);
--hilight-color: var(--pix-theme);
--light-text-color: #9498cd;
--heave-text-color: #44507b;
--border-color: #f7f7ff;
--icon-color : #44507b;
--box-bg: #eff1ff;
--box-light: #b1b3d2;
--dark-color : #2f2f2f;
--dark-body-gay-bg: linear-gradient(117deg,#f3efff,#e7f1ff);
--halo-comment-widget-component-form-button-submit-pix-bg-color:linear-gradient(90deg,#4832ff,#816bff);
--halo-comment-widget-component-form-input-pix-bg-color: #fff;
--halo-comment-widget-component-comment-author-info-input: #f6f7ff;
--halo-comment-widget-component-pagination-button-pix-bg-color-hover: #3b3eff;
--halo-comment-widget-component-pagination-button-pix-bg-color-active: #e9ecfe;
--halo-comment-widget-component-pagination-button-pix-border-color-active: #9498cd;
--halo-comment-widget-component-btn-active-color: #3b3eff;
--halo-comment-widget-parents_at-color: #3b3eff;
}
.uk-link-toggle:hover .uk-link, .uk-link:hover, a:hover , .footer_nav_box ul li a:hover , .copyright a , a.mo_link , .show-more-btn , .page_content .entry-header i
, .link_group .item:hover .name a , a.comment-reply-link:hover , .s_set_box a.active , .search_box .s_set_box a:hover , .ad_info a:hover , .audio_choose li.uk-active a, .video_choose li.uk-active a
, .posts_show_widget .no_img li a:before , .posts_mu_list li:hover div, .posts_mu_list li:hover a, .posts_mu_list li.active, .posts_mu_list li.active .s_play_btn
, .pl_btn a i:hover{
color: var(--hilight-color);
}
input#img_link_up:focus , .top_tool input.s_input:focus , #t_commentform:focus-within , #commentform:focus-within , .vi_reply_item .target_comment , #comment-author-info input:focus , .field input:focus
, #login_form_box input#username:focus , #login_form_box input#password:focus , .s_set_box a.active , .search_box input.s_input:focus , .edit_card_box .edit_content input:focus
, .audio_choose li.uk-active a , .video_choose li.uk-active a {
border-color: var(--hilight-color);
}
body {
background: var(--dark-body-gay-bg);
}
.up_from_media a, .up_from_cdn a {
background: var(--body-bg-color);
}
.push_close , .attch_nav a i , a.img_link_cancel {
background: var(--box-light);
}
.unread_box .vi_reply_item {
background: #ebeeff;
}
a.img_link_btn , a.img_link_cancel , #post_pager a:hover , a.go_top{
color: #fff;
}
.blog_list_inner, .normal_list_inner, .single_wrap , #t_commentform , textarea#comment , .field textarea , .single_content, .page_content, .page_wrap , #commentform , .top_bar
, .archive_main , .page_main , .posts_mu_list {
background: var(--withe-bg-color);
}
.left_nav_inner , #commentform textarea#comment , .top_tool input.s_input:focus , .post_control_list , .right_admin_tool , .sidebar_right , .posts_mu_list li:nth-of-type(odd) {
background: var(--light-bg-color);
}
.single_wrap .comments-area, .page_content .comments-area , .topic_comments_wrap , .column_inner {
background: #fafbff;
}
.left_menu_box li[class*=current-] a , .left_menu_box li[class*=current-] a:hover , input#push_comment , input.submit_button {
background: var(--linear-color);
color: var(--light-bg-color);
}
.main_wrap , .top_ava img , .widget_tag_cloud a {
box-shadow: var(--shadow-bg);
}
.moment_cat_nav ul li a.active, .posts_cat_nav ul li a.active , .photos_cat_nav ul li a.active , #t_pagination a, #pagination a , #p_pagination a , .up_cat_btn , a.set_local_btn , .push_item , a.img_link_btn , .commentnav span.page-numbers.current
, ::-webkit-scrollbar-thumb , #post_pager a:hover , a.go_top , .edit_card_box .edit_content a.push_card , a.play_btn , .post_control_list a:hover , .top_set_box a.active , .vo_size {
background-color: var(--btn-active-color);
}
.moment_cat_nav ul li a:hover, .posts_cat_nav ul li a:hover, .photos_cat_nav ul li a:hover {
background-color: var(--btn-active-color);
color: #fff;
}
a.set_local_btn , .top_set_box a.active , .top_set_box a.active:hover {
color: #fff;
}
.left_menu_box ul li a:hover, .link_group .item:hover {
box-shadow: var(--big-shadow);
background: var(--btn-light-color);
color: var(--hilight-color);
}
.moment_cat_nav ul li a, .posts_cat_nav ul li a ,.photos_cat_nav ul li a, .cancel-comment-reply a , .commentnav a , #post_pager a {
background: var(--btn-light-color);
color: var(--light-text-color);
}
textarea#comment , .field textarea , .tool_box , .smile_show , .form_footer , .set_cat , #commentform textarea#comment , .p_item
, .moment_cat_nav, .posts_cat_nav, .photos_cat_nav {
border-color: var(--border-color);
}
.left_menu_box ul , .widget_inner .widget {
border-color: #eeefff
}
.list_user_meta .name , .comment-list p.nodata , .t_cat_box li , .show_cdn_media span , .vi_reply_item .name span , .vi_reply_item .meta a , .msg_log , .links_count , .link_cat_name , #post_pager .c_paged
, .p_title a ,.avatar_title a , .ad_info p , .ad_info a , .top_set_box a {
color: var(--heave-text-color);
}
.user_pannel .inner a {
background: var(--btn-light-color);
color: var(--light-text-color);
}
.user_pannel .inner a:hover {
background: var(--btn-active-color);
}
.t_dark a i , .top_tool i , .normal_content .post_footer_meta span.comnum i, .normal_card_content .post_footer_meta span.comnum i, .normal_grid_content .post_footer_meta span.comnum i
, a.up_like i , .footer_nav_box ul li a , a.music_btn , .post_footer_meta span i , .comment_smile_box a i , a.bg_music i , a.bg_lrc i, .top_s_box form i , .pix_widget_tongji ul li small , .posts_mu_list .s_play_btn {
color: var(--icon-color);
}
.entry-footer , .t_cat_box li , input#set_local , .show_media_box, .show_cdn_media , .single_content .comments-area {
background: var(--light-bg-color);
}
.bottom_tool .inner , .links_page .link_group .item , .link_group .item {
background: var(--box-bg);
}
#topic_content {
background: #f6f7ff;
border: 1px solid #cccdf0;
}
.normal_cat , .de_cat {
background: var(--dark-color);
}
.normal_content .entry_meta, .normal_card_content .entry_meta, .normal_grid_content .entry_meta , a.beian , footer#colophon , .page_content .entry-header .right time , a.comment-reply-link
, .ad_info .name , .set_text , .widget_tag_cloud a , .cst_widget_comment ul li .right .meta , .posts_show_widget ul li .meta , .pix_widget_tongji ul li span
, .pl_btn a i {
color: var(--light-text-color);
}
.normal_content .entry-title a, .normal_grid_content .entry-title a {
color: var(--dark-color);
}
a.up_like.done i {
color: #ff4040;
}
.show-more-btn:hover {
color: #5457ff;
}
.smile_box i, .simi i, .t_cat i, .loca i , .post-categories a {
background: var(--box-bg);
color: var(--box-light);
}
#topic_content:focus {
box-shadow: 0 0 0 0.12rem rgb(182 190 255);
}
.up_img_btn i {
color: var(--box-light);
}
.t_cat_box li span {
color: var(--heave-text-color) !important;
}
.form_footer .admin_tool a {
display: none;
}
.top_bar.uk-sticky-fixed.uk-active {
background: rgb(245 246 255 / 80%);
}
#comment-author-info input , .field textarea ,.field input , #login_form_box input#username, #login_form_box input#password {
border-color: #d9dfee;
background: var(--light-bg-color);
}
.post_footer_meta span.sticky_icon {
background: #ff5252;
}
.pix_player {
background: rgb(234 234 255 / 81%);
}
.moment_type_btn i , .smile_box i, .simi i, .t_cat i, .loca i{
color: #746de2;
background: transparent;
}
.loacl_audio input, .netease_audio input , .tencent_audio input , .kugou_audio input , .kuwo_audio input , .edit_card_box .edit_content input , .local_video , input#moment_video_bili {
background: #f1f3ff;
}
.loacl_audio .audio_right input , input#moment_video_url {
background: #dfe3f6;
}
.moment_card_item a {
background: #ebeeff;
}
.moment_card_item.loop_card_item a:hover {
box-shadow: 0px 8px 13px 0px rgb(229 226 255);
}
.top_s_box input.s_input {
background: rgb(237 239 254 / 59%);
}
.widget_tag_cloud a , .cst_widget_comment ul li .right .body {
background: #e9ecfe;
}
.pix_widget_tongji ul li {
background: linear-gradient(90deg,#e9ecfe,#816bff00);
box-shadow: 0px 8px 9px 0px rgb(234 235 255 / 47%);
}
.t_dark a , a.bg_music, a.bg_lrc{
background: #c4d0e6;
}
.single_footer_box {
background: linear-gradient(90deg,#f0f2ff,#816bff00);
}
.footer_main .inner {
background: #f6f7ff;
}
.sf_item a {
color: #7e85ad;
}
a.m_play i , a.m_play i:hover {
color: var(--hilight-color);
}
.player_dot {
border-color: var(--hilight-color);;
}
.player_bar .progress {
background: linear-gradient(90deg,var(--pix-theme),#5c7fff);
}
+933
View File
@@ -0,0 +1,933 @@
:root {
--font-family: eafont,HarmonyOS_M,PingFang SC,Hiragino Sans GB,Microsoft YaHei,STHeiti,WenQuanYi Micro Hei,Helvetica,Arial,sans-serif;
--halo-comment-widget-base-font-family: var(--font-family);
/* 搜索 */
--halo-search-widget-base-font-size: 1.04rem;
--halo-search-widget-base-font-family: var(--font-family);
--halo-search-widget-primary-color: #3451b2;
}
html {
line-height: 1.15;
-webkit-text-size-adjust: 100%;
overflow-y:scroll;
overflow-x: hidden;
image-rendering: -webkit-optimize-contrast;
}
/* Sections
========================================================================== */
/**
* Remove the margin in all browsers.
*/
body {
margin: 0;
}
/**
* Render the `main` element consistently in IE.
*/
main {
display: block;
}
/**
* Correct the font size and margin on `h1` elements within `section` and
* `article` contexts in Chrome, Firefox, and Safari.
*/
h1 {
font-size: 2em;
margin: 0.67em 0;
}
/* Grouping content
========================================================================== */
/**
* 1. Add the correct box sizing in Firefox.
* 2. Show the overflow in Edge and IE.
*/
hr {
box-sizing: content-box;
height: 0;
overflow: visible;
}
/**
* 1. Correct the inheritance and scaling of font size in all browsers.
* 2. Correct the odd `em` font sizing in all browsers.
*/
pre {
font-family: monospace, monospace;
font-size: 1em;
}
/* Text-level semantics
========================================================================== */
/**
* Remove the gray background on active links in IE 10.
*/
a {
background-color: transparent;
}
/**
* 1. Remove the bottom border in Chrome 57-
* 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
*/
abbr[title] {
border-bottom: none;
text-decoration: underline;
text-decoration: underline dotted;
}
/**
* Add the correct font weight in Chrome, Edge, and Safari.
*/
b,
strong {
font-weight: bolder;
}
/**
* 1. Correct the inheritance and scaling of font size in all browsers.
* 2. Correct the odd `em` font sizing in all browsers.
*/
code,
kbd,
samp {
font-family: monospace, monospace;
font-size: 1em;
}
/**
* Add the correct font size in all browsers.
*/
small {
font-size: 80%;
}
/**
* Prevent `sub` and `sup` elements from affecting the line height in
* all browsers.
*/
sub,
sup {
font-size: 75%;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
/* Embedded content
========================================================================== */
/**
* Remove the border on images inside links in IE 10.
*/
img {
border-style: none;
}
/* Forms
========================================================================== */
/**
* 1. Change the font styles in all browsers.
* 2. Remove the margin in Firefox and Safari.
*/
button,
input,
optgroup,
select,
textarea {
font-family: var(--font-family);
font-size: 100%;
line-height: 1.15;
margin: 0;
}
/**
* Show the overflow in IE.
* 1. Show the overflow in Edge.
*/
button,
input {
overflow: visible;
}
/**
* Remove the inheritance of text transform in Edge, Firefox, and IE.
* 1. Remove the inheritance of text transform in Firefox.
*/
button,
select {
text-transform: none;
}
/**
* Correct the inability to style clickable types in iOS and Safari.
*/
button,
[type="button"],
[type="reset"],
[type="submit"] {
-webkit-appearance: button;
}
/**
* Remove the inner border and padding in Firefox.
*/
button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
border-style: none;
padding: 0;
}
/**
* Restore the focus styles unset by the previous rule.
*/
button:-moz-focusring,
[type="button"]:-moz-focusring,
[type="reset"]:-moz-focusring,
[type="submit"]:-moz-focusring {
outline: 1px dotted ButtonText;
}
button.null {
background: 0 0;
border: none;
margin: 0;
padding: 0;
line-height: 1.5;
}
/**
* Correct the padding in Firefox.
*/
fieldset {
padding: 0.35em 0.75em 0.625em;
}
/**
* 1. Correct the text wrapping in Edge and IE.
* 2. Correct the color inheritance from `fieldset` elements in IE.
* 3. Remove the padding so developers are not caught out when they zero out
* `fieldset` elements in all browsers.
*/
legend {
box-sizing: border-box;
color: inherit;
display: table;
max-width: 100%;
padding: 0;
white-space: normal;
}
/**
* Add the correct vertical alignment in Chrome, Firefox, and Opera.
*/
progress {
vertical-align: baseline;
}
/**
* Remove the default vertical scrollbar in IE 10+.
*/
textarea {
overflow: auto;
}
/**
* 1. Add the correct box sizing in IE 10.
* 2. Remove the padding in IE 10.
*/
[type="checkbox"],
[type="radio"] {
box-sizing: border-box;
padding: 0;
}
.vditor-task input {
margin: 0 0.2em 0.25em -1.6em;
font-size: 12px;
vertical-align: middle;
}
/**
* Correct the cursor style of increment and decrement buttons in Chrome.
*/
[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
height: auto;
}
/**
* 1. Correct the odd appearance in Chrome and Safari.
* 2. Correct the outline style in Safari.
*/
[type="search"] {
-webkit-appearance: textfield;
outline-offset: -2px;
}
/**
* Remove the inner padding in Chrome and Safari on macOS.
*/
[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
/**
* 1. Correct the inability to style clickable types in iOS and Safari.
* 2. Change font properties to `inherit` in Safari.
*/
::-webkit-file-upload-button {
-webkit-appearance: button;
font: inherit;
}
/* Interactive
========================================================================== */
/*
* Add the correct display in Edge, IE 10+, and Firefox.
*/
details {
display: block;
}
/*
* Add the correct display in all browsers.
*/
summary {
display: list-item;
}
/* Misc
========================================================================== */
/**
* Add the correct display in IE 10+.
*/
template {
display: none;
}
/**
* Add the correct display in IE 10.
*/
[hidden] {
display: none;
}
/* Box sizing
--------------------------------------------- */
/* Inherit box-sizing to more easily change it's value on a component level.
@link http://css-tricks.com/inheriting-box-sizing-probably-slightly-better-best-practice/ */
*,
*::before,
*::after {
box-sizing: inherit;
}
html {
box-sizing: border-box;
}
/*--------------------------------------------------------------
# Base
--------------------------------------------------------------*/
/* Typography
--------------------------------------------- */
body,
button,
input,
select,
optgroup,
textarea {
color: #404040;
font-family: var(--font-family);
font-size: 1rem;
line-height: 1.5;
}
.dark body{
color: #FFFFFF;
}
h1,
h2,
h3,
h4,
h5,
h6 {
clear: both;
}
p {
margin-bottom: 1.5em;
}
dfn,
cite,
em,
i {
font-style: italic;
}
blockquote {
margin: 0 1.5em;
}
address {
margin: 0 0 1.5em;
}
pre {
background: #eee;
font-family: "Courier 10 Pitch", courier, monospace;
line-height: 1.6;
margin-bottom: 1.6em;
max-width: 100%;
overflow: auto;
padding: 1.6em;
}
code,
kbd,
tt,
var {
font-family: monaco, consolas, "Andale Mono", "DejaVu Sans Mono", monospace;
}
abbr,
acronym {
border-bottom: 1px dotted #666;
cursor: help;
}
mark,
ins {
background: #fff9c0;
text-decoration: none;
}
big {
font-size: 125%;
}
/* Elements
--------------------------------------------- */
body {
background: #fff;
}
hr {
background-color: #ccc;
border: 0;
height: 1px;
margin-bottom: 1.5em;
}
ul,
ol {
margin: 0 0 1.5em 3em;
}
ul {
list-style: disc;
}
ol {
list-style: decimal;
}
li > ul,
li > ol {
margin-bottom: 0;
margin-left: 1.5em;
}
dt {
font-weight: 700;
}
dd {
margin: 0 1.5em 1.5em;
}
/* Make sure embeds and iframes fit their containers. */
embed,
iframe,
object {
max-width: 100%;
}
img {
height: auto;
max-width: 100%;
}
figure {
margin: 1em 0;
}
table {
margin: 0 0 1.5em;
width: 100%;
}
/* Links
--------------------------------------------- */
a {
color: #4169e1;
}
a:visited {
color: #252525;
}
a:hover,
a:focus,
a:active {
color: #191970;
}
a:focus {
outline: thin dotted;
}
a:hover,
a:active {
outline: 0;
}
/* Forms
--------------------------------------------- */
button,
input[type="button"],
input[type="reset"],
input[type="submit"] {
border: 1px solid;
border-color: #ccc #ccc #bbb;
border-radius: 3px;
background: #e6e6e6;
color: rgba(0, 0, 0, 0.8);
line-height: 1;
padding: 0.6em 1em 0.4em;
}
button:hover,
input[type="button"]:hover,
input[type="reset"]:hover,
input[type="submit"]:hover {
border-color: #ccc #bbb #aaa;
}
button:active,
button:focus,
input[type="button"]:active,
input[type="button"]:focus,
input[type="reset"]:active,
input[type="reset"]:focus,
input[type="submit"]:active,
input[type="submit"]:focus {
border-color: #aaa #bbb #bbb;
}
input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
input[type="range"],
input[type="date"],
input[type="month"],
input[type="week"],
input[type="time"],
input[type="datetime"],
input[type="datetime-local"],
input[type="color"],
textarea {
color: #666;
border: 1px solid #ccc;
border-radius: 3px;
padding: 3px;
}
input[type="text"]:focus,
input[type="email"]:focus,
input[type="url"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
input[type="range"]:focus,
input[type="date"]:focus,
input[type="month"]:focus,
input[type="week"]:focus,
input[type="time"]:focus,
input[type="datetime"]:focus,
input[type="datetime-local"]:focus,
input[type="color"]:focus,
textarea:focus {
color: #111;
}
select {
border: 1px solid #ccc;
}
textarea {
width: 100%;
}
/*--------------------------------------------------------------
# Layouts
--------------------------------------------------------------*/
/*--------------------------------------------------------------
# Components
--------------------------------------------------------------*/
/* Navigation
--------------------------------------------- */
.main-navigation {
display: block;
width: 100%;
}
.main-navigation ul {
display: none;
list-style: none;
margin: 0;
padding-left: 0;
}
.main-navigation ul ul {
box-shadow: 0 3px 3px rgba(0, 0, 0, 0.2);
float: left;
position: absolute;
top: 100%;
left: -999em;
z-index: 99999;
}
.main-navigation ul ul ul {
left: -999em;
top: 0;
}
.main-navigation ul ul li:hover > ul,
.main-navigation ul ul li.focus > ul {
display: block;
left: auto;
}
.main-navigation ul ul a {
width: 200px;
}
.main-navigation ul li:hover > ul,
.main-navigation ul li.focus > ul {
left: auto;
}
.main-navigation li {
position: relative;
}
.main-navigation a {
display: block;
text-decoration: none;
}
/* Small menu. */
.menu-toggle,
.main-navigation.toggled ul {
display: block;
}
@media screen and (min-width: 37.5em) {
.menu-toggle {
display: none;
}
.main-navigation ul {
display: flex;
}
}
.site-main .comment-navigation,
.site-main
.posts-navigation,
.site-main
.post-navigation {
margin: 0 0 1.5em;
}
.comment-navigation .nav-links,
.posts-navigation .nav-links,
.post-navigation .nav-links {
display: flex;
}
.comment-navigation .nav-previous,
.posts-navigation .nav-previous,
.post-navigation .nav-previous {
flex: 1 0 50%;
}
.comment-navigation .nav-next,
.posts-navigation .nav-next,
.post-navigation .nav-next {
text-align: end;
flex: 1 0 50%;
}
/* Posts and pages
--------------------------------------------- */
.sticky {
display: block;
}
.post,
.page {
margin: 0;
}
.updated:not(.published) {
display: none;
}
.page-content,
.entry-content,
.entry-summary {
margin: 1.5em 0 0;
}
.page-links {
clear: both;
margin: 0 0 1.5em;
}
/* Comments
--------------------------------------------- */
.comment-content a {
word-wrap: break-word;
}
.bypostauthor {
display: block;
}
/* Widgets
--------------------------------------------- */
.widget {
margin: 0 0 1.5em;
}
.widget select {
max-width: 100%;
}
/* Media
--------------------------------------------- */
.page-content .wp-smiley,
.entry-content .wp-smiley,
.comment-content .wp-smiley {
border: none;
margin-bottom: 0;
margin-top: 0;
padding: 0;
}
/* Make sure logo link wraps around logo image. */
.custom-logo-link {
display: inline-block;
}
/* Captions
--------------------------------------------- */
.wp-caption {
margin-bottom: 1.5em;
max-width: 100%;
}
.wp-caption img[class*="wp-image-"] {
display: block;
margin-left: auto;
margin-right: auto;
}
.wp-caption .wp-caption-text {
margin: 0.8075em 0;
}
.wp-caption-text {
text-align: center;
}
/* Galleries
--------------------------------------------- */
.gallery {
margin-bottom: 1.5em;
display: grid;
grid-gap: 1.5em;
}
.gallery-item {
display: inline-block;
text-align: center;
width: 100%;
}
.gallery-columns-2 {
grid-template-columns: repeat(2, 1fr);
}
.gallery-columns-3 {
grid-template-columns: repeat(3, 1fr);
}
.gallery-columns-4 {
grid-template-columns: repeat(4, 1fr);
}
.gallery-columns-5 {
grid-template-columns: repeat(5, 1fr);
}
.gallery-columns-6 {
grid-template-columns: repeat(6, 1fr);
}
.gallery-columns-7 {
grid-template-columns: repeat(7, 1fr);
}
.gallery-columns-8 {
grid-template-columns: repeat(8, 1fr);
}
.gallery-columns-9 {
grid-template-columns: repeat(9, 1fr);
}
.gallery-caption {
display: block;
}
/*--------------------------------------------------------------
# Plugins
--------------------------------------------------------------*/
/* Jetpack infinite scroll
--------------------------------------------- */
/* Hide the Posts Navigation and the Footer when Infinite Scroll is in use. */
.infinite-scroll .posts-navigation,
.infinite-scroll.neverending .site-footer {
display: none;
}
/* Re-display the Theme Footer when Infinite Scroll has reached its end. */
.infinity-end.neverending .site-footer {
display: block;
}
/*--------------------------------------------------------------
# Utilities
--------------------------------------------------------------*/
/* Accessibility
--------------------------------------------- */
/* Text meant only for screen readers. */
.screen-reader-text {
border: 0;
clip: rect(1px, 1px, 1px, 1px);
clip-path: inset(50%);
height: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute !important;
width: 1px;
word-wrap: normal !important;
}
.screen-reader-text:focus {
background-color: #f1f1f1;
border-radius: 3px;
box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
clip: auto !important;
clip-path: none;
color: #21759b;
display: block;
font-size: 0.875rem;
font-weight: 700;
height: auto;
left: 5px;
line-height: normal;
padding: 15px 23px 14px;
text-decoration: none;
top: 5px;
width: auto;
z-index: 100000;
}
/* Do not show the outline on the skip link target. */
#primary[tabindex="-1"]:focus {
outline: 0;
}
/* Alignments
--------------------------------------------- */
.alignleft {
/*rtl:ignore*/
float: left;
/*rtl:ignore*/
margin-right: 1.5em;
margin-bottom: 1.5em;
}
.alignright {
/*rtl:ignore*/
float: right;
/*rtl:ignore*/
margin-left: 1.5em;
margin-bottom: 1.5em;
}
.aligncenter {
clear: both;
display: block;
margin-left: auto;
margin-right: auto;
margin-bottom: 1.5em;
}
+4051
View File
File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 303 B

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="18" height="18"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 1l8.217 1.826a1 1 0 0 1 .783.976v9.987a6 6 0 0 1-2.672 4.992L12 23l-6.328-4.219A6 6 0 0 1 3 13.79V3.802a1 1 0 0 1 .783-.976L12 1zm0 2.049L5 4.604v9.185a4 4 0 0 0 1.781 3.328L12 20.597l5.219-3.48A4 4 0 0 0 19 13.79V4.604L12 3.05zM12 7a2 2 0 0 1 1.001 3.732L13 15h-2v-4.268A2 2 0 0 1 12 7z" fill="rgba(255,255,255,1)"/></svg>

After

Width:  |  Height:  |  Size: 456 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 383 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 22C6.477 22 2 17.523 2 12S6.477 2 12 2s10 4.477 10 10-4.477 10-10 10zM9 9v6h2V9H9zm4 0v6h2V9h-2z"/></svg>

After

Width:  |  Height:  |  Size: 238 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path fill="none" d="M0 0h24v24H0z"/><path d="M12 22C6.477 22 2 17.523 2 12S6.477 2 12 2s10 4.477 10 10-4.477 10-10 10zM10.622 8.415a.4.4 0 0 0-.622.332v6.506a.4.4 0 0 0 .622.332l4.879-3.252a.4.4 0 0 0 0-.666l-4.88-3.252z"/></svg>

After

Width:  |  Height:  |  Size: 313 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path fill="none" d="M0 0h24v24H0z"/><path d="M8 11.333l10.223-6.815a.5.5 0 0 1 .777.416v14.132a.5.5 0 0 1-.777.416L8 12.667V19a1 1 0 0 1-2 0V5a1 1 0 1 1 2 0v6.333z"/></svg>

After

Width:  |  Height:  |  Size: 256 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path fill="none" d="M0 0h24v24H0z"/><path d="M16 12.667L5.777 19.482A.5.5 0 0 1 5 19.066V4.934a.5.5 0 0 1 .777-.416L16 11.333V5a1 1 0 0 1 2 0v14a1 1 0 0 1-2 0v-6.333z"/></svg>

After

Width:  |  Height:  |  Size: 259 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 330 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 331 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 331 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 320 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 388 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 340 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

+1
View File
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="18" height="18"><path fill="none" d="M0 0h24v24H0z"/><path d="M2 19h20v2H2v-2zM2 5l5 3.5L12 2l5 6.5L22 5v12H2V5zm2 3.841V15h16V8.841l-3.42 2.394L12 5.28l-4.58 5.955L4 8.84z" fill="rgba(255,193,116,1)"/></svg>

After

Width:  |  Height:  |  Size: 275 B

File diff suppressed because it is too large Load Diff
+561
View File
@@ -0,0 +1,561 @@
main_content = $('.moment_type_main');
function remove_image_temp(){
if(!$('.image_edit_temp .add_img_box').length > 0){
var temp = $('.add_img_box');
$('.image_edit_temp').html(temp);
}
main_content.empty();
}
function back_image_temp(){
var temp = $('.add_img_box');
main_content.html(temp);
$('.image_edit_temp').empty();
}
//发布卡片
$('body').on('click', '.moment_card_type a', function () {
$('.push_item').attr('type', 'card');
main_content = $('.moment_type_main');
if ($('.add_card_box').length > 0) {
return false;
}
remove_image_temp();
main_content.html('<div class="loading_box"><div uk-spinner></div></div>');
$('.moment_type_main .loading_box').remove();
main_content.append(
`<div class="add_card_box">
<div class="edit_card_box">
<div class="card_choose" uk-switcher="animation: uk-animation-fade">
<li><a class="card_c_btn post" c_type="post">文章</a></li>
<li><a class="card_c_btn page" c_type="page">页面</a></li>
</div>
<div class="tips"># 输入别名或者标题,自动生成链接卡片 <span>支持文章, 页面等网址</span></div>
<div class="edit_content">
<input type="text" placeholder="别名或者标题" name="moment_card_link" id="moment_card_link" required="required">
<a class="push_card">生成</a>
</div>
</div>
<div class="show_card"><div class="card_sortble" uk-sortable="handle: .moment_card_item"></div></div>
</div>`);
});
$('body').on('click', '.edit_content .push_card', function () {
var card_url = $('.edit_card_box .edit_content input').val();
var num = $('.card_sortble .moment_card_item').length;
if (num > 2) {
cocoMessage.error('最多插入3个卡片');
$('.edit_card_box .edit_content input').val('');
return false;
}
var c_type = $('.card_choose .uk-active a').attr('c_type');
switch (c_type) {
case "post":
card_post(card_url);
break;
case "page":
edit_page(card_url);
break;
}
});
function card_post(card_url){
$.ajax({
type: 'GET',
url: `/apis/api.console.halo.run/v1alpha1/posts?keyword=${card_url}&labelSelector=content.halo.run%2Fdeleted%3Dfalse&page=1&size=20`,
beforeSend: function () {
cocoMessage.info('生成中...');
},
success: function (data) {
$('.edit_card_box .edit_content input').val('');
if (data.total > 0) {
if(data.total>1){
cocoMessage.error('当前搜索的文章有多个无法选择');
}else{
var item = data.items[0]
$('.show_card').show();
$('.card_sortble').append(getcard(item.post.metadata.name,item.post.spec.cover,item.post.spec.title,'post'));
cocoMessage.success('已生成卡片');
}
} else {
cocoMessage.error('文章不存在');
}
}
});
}
function edit_page(card_url){
$.ajax({
type: 'GET',
url: `/apis/api.console.halo.run/v1alpha1/singlepages?keyword=${card_url}&labelSelector=content.halo.run%2Fdeleted%3Dfalse&page=1&size=20`,
beforeSend: function () {
cocoMessage.info('生成中...');
},
success: function (data) {
$('.edit_card_box .edit_content input').val('');
if (data.total > 0) {
if(data.total>1){
cocoMessage.error('当前搜索的页面有多个无法选择');
}else{
var item = data.items[0]
$('.show_card').show();
$('.card_sortble').append(getcard(item.page.metadata.name,item.page.spec.cover,item.page.spec.title,'page'));
cocoMessage.success('已生成卡片');
}
} else {
cocoMessage.error('页面不存在');
}
}
});
}
function getcard(name,cover,title,type){
return `<div class="moment_card_item" pid="${name}" type="${type}">
<a>
<div class="left"><img src="${cover}"></div>
<div class="right">
<h4>${title}</h4>
<div class="content"></div>
</div>
<span class="de_card"><i class="ri-close-line"></i></span>
</a>
</div>`
}
$(document).on('click', '.de_card', function() {
var msg = "确认删除此卡片?";
var num = $('.moment_card_item').length;
if (confirm(msg)==true){
$(this).parents('.moment_card_item').remove();
} else {
return false;
}
if(num == 1){
$(".show_card").hide();
}
});
//图文编辑 返回图文编辑区域
$('body').on('click', '.moment_image_type a', function() {
back_image_temp();
$('.push_item').attr('type','image');
});
//发布音乐--------------------------------------------------------------
$('body').on('click', '.moment_audio_type a', function() {
$('.push_item').attr('type','audio');
main_content = $('.moment_type_main');
if($('.add_audio_box').length > 0){
return false;
}
remove_image_temp();
main_content.append(
`<div class="add_audio_box">
<div class="edit_audio_box">
<div class="audio_choose" uk-switcher="animation: uk-animation-fade">
<li class="local"><a href="#" class="audio_c_btn" au_type="local">本地</a></li>
<li class="netease"><a href="#" class="audio_c_btn" au_type="netease">网易云</a></li>
<li class="tencent"><a href="#" class="audio_c_btn" au_type="tencent">QQ音乐</a></li>
<li class="kugou"><a href="#" class="audio_c_btn" au_type="kugou">酷狗</a></li>
<li class="kuwo"><a href="#" class="audio_c_btn" au_type="kuwo">酷我</a></li>
</div>
<div class="tips"># 请插入歌曲外链 <span></span></div>
<div class="edit_content audio_type uk-switcher">
<div class="loacl_audio">
<input type="text" placeholder="歌曲外链" name="moment_audio_url" id="moment_audio_url" class="required" required="required">
</div>
<div class="netease_audio type_audio_text"></div>
<div class="tencent_audio type_audio_text"></div>
<div class="kugou_audio type_audio_text"></div>
<div class="kuwo_audio type_audio_text"></div>
</div>
</div>
</div>`);
});
//音乐和视频上传
$(document).on('change','#moment_img_up',function(){
if($('#moment_img_up').val() == '')
return;
var f = this.files[0];
var formData = new FormData();
formData.append('file',f);
const policyName = Theme.moments.policy_name;
const groupName = Theme.moments.group_name;
policyName && formData.append('policyName',policyName)
groupName && formData.append('groupName',groupName)
$.ajax({
type: "POST",
url: `${Theme.moments.attachments_upload_api}`,
dataType: 'json',
data: formData,
processData : false,
contentType : false,
beforeSend: function () {
cocoMessage.info('上传中...');
$('.m_media_left i').remove();
$('.m_media_left').append("<div class='up_loading' uk-spinner='ratio: .6'></div>");
var imged = $('.m_media_left img');
if(imged.length > 0){
imged.remove();
}
},
success: function(data){
var thum = data.metadata.annotations["storage.halo.run/uri"] || data.metadata.annotations["storage.halo.run/external-link"]
$('.m_media_left .up_loading').remove();
$('.m_media_left').append('<img src="/themes/theme-pix/assets/img/video.png" data="'+thum+'">');
cocoMessage.success('上传成功');
$('input#moment_video_url').val(thum)
}
});
});
$('body').on('click', '.audio_choose a', function() {
var text = '# 请插入封面,歌名以及歌曲外链';
var type = $(this).attr('au_type');
if(type != 'local'){
var text = '# 请输入歌曲ID';
}
$('.edit_audio_box .tips').text(text);
});
//发布视频--------------------------------------------------------------
$('body').on('click', '.moment_video_type a', function() {
$('.push_item').attr('type','video');
main_content = $('.moment_type_main');
if($('.add_video_box').length > 0){
return false;
}
remove_image_temp();
main_content.html('<div class="loading_box"><div uk-spinner></div></div>');
$('.moment_type_main .loading_box').remove();
main_content.append(
`<div class="add_video_box">
<div class="edit_video_box">
<div class="video_choose" uk-switcher="animation: uk-animation-fade">
<li><a href="#" class="video_c_btn local" vi_type="local">本地</a></li>
<li><a href="#" class="video_c_btn bili" vi_type="bili">B站</a></li>
</div>
<div class="tips"># 请上传视频或填写视频外链 <span></span></div>
<div class="edit_content video_type uk-switcher">
<div class="local_video">
<div class="video_left m_media_left">
<i class="ri-add-line"></i>
<input type="file" name="moment_img_up" id="moment_img_up" accept="video/mp4,video/ogg,video/webm,video/3gpp,video/flv,video/avi,video/mov,video/wmv,video/rm,video/rmvb,video/3gp,video/3g2,video/asf,video/mkv,video/mpg,video/mpeg,video/ts" multiple="multiple" title="上传视频">
</div>
<div class="video_right">
<div class="video_meta">
<input type="text" placeholder="视频外链" name="moment_video_url" id="moment_video_url" class="required" required="required">
</div>
</div>
</div>
<div class="bili_video">
<input type="text" placeholder="B站视频bvid" name="moment_video_bili" id="moment_video_bili" class="required" required="required">
</div>
</div>
</div>
</div>`);
});
$('body').on('click', '.video_choose a', function() {
var text = '# 请上传视频或填写视频外链';
var type = $(this).attr('vi_type');
if(type == 'bili'){
var text = '# 请输入B站视频bvid';
}
$('.edit_video_box .tips').text(text);
});
//图文类型
//$('body').on('click', '.moment_video_type a', function() {
//});
//删除片刻文章
$('body').on('click', '.control_delete_post', function() {
var pid = $(this).parent().attr('pid');
var msg = "确定删除瞬间?";
if (confirm(msg)==true){
$.ajax({
type: 'DELETE',
dataType: 'json',
url: `/apis/${Theme.moments.api}/v1alpha1/moments/`+pid,
contentType: "application/json",
beforeSend: function () {
cocoMessage.info('处理中..');
},
success: function (data) {
cocoMessage.success('删除成功');
setTimeout(()=>{
$(`#post-${pid}`)[0].remove()
},1000)
},
error: function (request) {
if(request.status){
cocoMessage.error('瞬间不存在或已删除');
}else{
cocoMessage.error('删除失败');
}
console.log(request)
},
});
} else {
return false;
}
});
//置顶片刻
$('body').on('click', '.sticky_btn', function() {
var pid = $(this).parent().attr('pid');
var stick = $(this).hasClass('stick');
if(stick){
var state = 'stick';
} else {
var state = 'unstick';
}
var msg = "确定执行此操作?";
if (confirm(msg)==true){
$.ajax({
type: 'POST',
dataType: 'json',
url: Theme.ajaxurl,
data: {
'action':'stick_moment',
pid:pid,
state:state
},
beforeSend: function () {
cocoMessage.info('处理中..');
},
success: function (data) {
if(data.state == '1'){
cocoMessage.success(data.msg);
if(data.type == 'stick'){
var post_item = $('#post-'+pid+'.moment_item');
post_item.remove();
$('.moment_list').prepend(post_item.prop('outerHTML'));
$('#post-'+pid+'.moment_item').find('.post_footer_meta .right').prepend('<span class="sticky_icon"><i class="ri-fire-line"></i> TOP</span>');
$('#post-'+pid+'.moment_item').find('.post_control').remove();
} else {
$('#post-'+pid+'.moment_item').find('.sticky_icon').remove();
}
} else {
cocoMessage.error('操作失败');
}
}
});
} else {
return false;
}
});
//编辑片刻
$('body').on('click', '.control_edit_post', function() {
$('.t_media_item').remove();
$('#moment_audio_api').remove();
var pid = $(this).parent().attr('pid');
$('.push_item').html('<i class="ri-edit-box-line"></i>更新');
$('.push_item').attr('pid',pid).attr('action','update')
$.ajax({
type: 'GET',
url: `/apis/${Theme.moments.api}/v1alpha1/moments/`+pid,
beforeSend: function () {
cocoMessage.info('数据拉取中');
//$('.t_form').before('<div class="edit_overlay"></div>');
},
success: function (data) {
$('.push_item').attr('version',data.metadata.version)
$('.push_item').attr('owner',data.spec.owner)
$('.push_item').attr('releaseTime',data.spec.releaseTime)
//发布状态
if(data.spec.visible == 'PRIVATE'){
$(".simi a").html('<i class="ri-lock-line"></i>').attr('visible','PRIVATE');
$(".simi a").children().css({"background":"#ddd","color":"#c6c6c6"});
} else {
$(".simi a").html('<i class="ri-lock-unlock-line"></i>').attr('visible','PUBLIC');
$(".simi a").children().css({"background":"#e3efe7","color":"#66c187"});
}
var medium = data.spec.content.medium;
var tags = data.spec.tags
if(medium.length > 0){
var type = medium[0].type;
}
let content = data.spec.content.html;
if(content == null){
content = '';
}else{
// 创建一个新的HTML解析器对象
var parser = new DOMParser();
// 解析HTML字符串并获取根元素
var doc = parser.parseFromString(content, 'text/html');
// 获取根元素下的所有子元素
var elements = doc.body.childNodes;
// 需要删除的链接元素的条件
var conditions = doc.querySelectorAll('p > a.tag');
// 遍历子元素并删除特定段落元素和链接元素
for (var i = 0; i < conditions.length; i++) {
for (var j = 0; j < elements.length; j++) {
if (elements[j].nodeName === 'P' && elements[j].querySelector('a.tag')) {
elements[j].parentNode.removeChild(elements[j]);
}
}
content = doc.body.innerHTML;
}
}
$('#topic_content').val(content);
if(tags.length > 0){
$('.t_cat_toogle span').text(tags[0]);
}
if(data.metadata.annotations?.mylocal!=null && data.metadata.annotations?.mylocal!='') {
$('.loca_text').text(data.metadata.annotations?.mylocal);
}
switch(type)
{
case "PHOTO":
//if(data.moment_data.length > 0){ 文字片刻没有数据
edit_image(data);
//}
break;
case "POST":
edit_card(data);
break;
case "AUDIO":
edit_audio(data);
break;
case "VIDEO":
edit_video(data);
break;
}
cocoMessage.success('拉取完成');
}
});
});
//发布片刻重置
$('body').on('click', '.normal_edit,.center .mobile_edit', function() {
$('.push_item').attr('action','push').html('<i class="ri-send-plane-2-line"></i>发布');
$('.moment_image_type a').click();
$(".simi a").html('<i class="ri-lock-unlock-line"></i>').attr('visible','PUBLIC');
$(".simi a").children().css({"background":"#e3efe7","color":"#66c187"});
$('#topic_content').val('');
const mylocalValue = getCookie('mylocal');
$(".loca_text").html(mylocalValue).attr("state",'1');
$('.t_media_item').remove();
});
//编辑片刻类型------------------------------------------------------------------------------
function edit_image(data){
var m_data = data.spec.content.medium;
$('.t_media_item').remove();
$('.moment_image_type a').click();
if(m_data.length > 0){
var new_data = m_data.reverse();
$.each(new_data, function(index, value) {
var thum = value.url;
var src = value.url;
var type = value.originType;
var media = `<div class="t_media_item" data-type="${type}" data-src="${src}" data-thum="${thum}">`;
media += '<a class="topic-img-de"><i class="ri-subtract-line"></i></a>';
media += '<img src="'+thum+'">';//图片预览
media += '</div>';
$(".img_show").prepend(media);
});
}
}
function edit_video(data){
var m_data = data.spec.content.medium[0];
var type = m_data.originType;
//var url = m_data.url;
$('.moment_video_type a').click();
var add = setInterval(function() {
if(type != 'video/bili'){
var url = m_data.url;
$('input#moment_video_url').val(url);
if(url !== ''){
$('.m_media_left i').remove();
$('.m_media_left').append('<img src="/themes/theme-pix/assets/img/video.png" data="'+url+'">');
}
} else if(type == 'video/bili') {
if($('.video_choose').length > 0){
var bvid = m_data.url;
UIkit.switcher('.video_choose').show(1);
$('input#moment_video_bili').val(bvid);
}
}
if($('.edit_video_box').length == 1){
clearInterval(add);
}
}, 100);
}
function edit_audio(data){
var m_data = data.spec.content.medium[0];
var type = m_data.originType;
$('.moment_audio_type a').click();
var add = setInterval(function() {
if(type == 'audio/netease' || type == 'audio/tencent' || type == 'audio/kugou' || type == 'audio/kuwo'){
var result = type.substring(type.indexOf("audio/") + 6);
if($('.audio_choose').length > 0){
var n_id = m_data.url;
var index = $('.audio_choose li.'+result+'').index();
UIkit.switcher('.audio_choose').show(index);
$('.edit_audio_box .tips').text('# 请输入歌曲ID');
$('.'+result+'_audio').append('<input type="text" placeholder="歌曲ID" name="moment_audio_api" id="moment_audio_api" class="required" required="required">');
$('input#moment_audio_api').val(n_id);
}
} else {
var index = $('.audio_choose li.local').index();
UIkit.switcher('.audio_choose').show(index);
var url = m_data.url;
$('.edit_audio_box .tips').text('# 请插入歌曲外链');
$('input#moment_audio_url').val(url);
}
if($('.edit_audio_box').length == 1){
clearInterval(add);
}
}, 100);
}
function edit_card(data) {
var m_data = data.spec.content.medium;
$('.card_sortble .moment_card_item').remove();
$('.moment_card_type a').click();
var pid = data.metadata.name;
var card_list = $("#post-"+pid+"").find('.moment_card_item');
var add = setInterval(function() {
$('.show_card').show();
$.each(m_data, function(index, value) {
var srcValue = card_list.eq(index).find('img').attr('src');
var h4Text = card_list.eq(index).find('h4').text();
$('.card_sortble').append(getcard(value.url,srcValue,h4Text,value.originType));
});
if($('.edit_card_box').length == 1){
clearInterval(add);
}
}, 100);
}
+217
View File
@@ -0,0 +1,217 @@
var pix = {
/**
* 页面運行時間
*/
addRuntime: function () {
const $runtimeCount = document.getElementById('runtimeshow');
if ($runtimeCount) {
var s1 = $runtimeCount.innerText;//建站时间
if (s1) {
s1 = new Date(s1.replace(/-/g, "/"));
s2 = new Date();
var days = s2.getTime() - s1.getTime();
var number_of_days = parseInt(days / (1000 * 60 * 60 * 24));
$runtimeCount.innerText = number_of_days + '天';
}
}
},
loadLightbox: function () {
/**
* fancybox
*/
const addFancybox = function (ele) {
const runFancybox = (ele) => {
ele.each(function (i, o) {
const $this = $(o)
const lazyloadSrc = $this.attr('data-src') || $this.attr('src')
const dataCaption = $this.attr('alt') || ''
$this.wrap(`<a href="${lazyloadSrc}" data-fancybox="images" class="fancybox" data-srcset="${lazyloadSrc}"></a>`)
})
}
runFancybox($(ele))
}
const $fancyboxEle = document.querySelectorAll('.single-content :not(a) > img,.single-content > img')
if ($fancyboxEle.length > 0) {
addFancybox($fancyboxEle)
}
},
initTopBar: function () {
let topBar = $('#masthead .top_bar');
var placeholder = document.querySelector('#masthead .uk-sticky-placeholder');
var width = $('#masthead').width();
var height = '71.9979px;'
if (window.innerWidth < 960) {
if (window.innerWidth <= 540) {
height = '63.9957px'
}
topBar.addClass('uk-sticky-fixed').css({ "width": width, "top": '0px', "position": "fixed" });
$('#masthead .uk-sticky-placeholder').css({ "width": width, "height": height, "margin": "0px" });
placeholder.hidden = false;
} else {
topBar.removeAttr("style");
$('#masthead .uk-sticky-placeholder').css({ "width": width, "height": '71.9979px;', "margin": "0px" });
placeholder.hidden = true;
}
},
getMsg: function () {
var com_msg_btn = $('.com_msg_btn')
var msg_modal_inner = $('.msg_modal_inner')
let username = Theme.username
var f_unread_num = 0;
if (com_msg_btn.length > 0) {
$.ajax({
type: "get",
url: `/apis/api.notification.halo.run/v1alpha1/userspaces/${username}/notifications?fieldSelector=spec.unread=true`,
success: function (res) {
if (res.total == 0) {
$('.f_unread_num').remove();
}else {
f_unread_num = res.total
com_msg_btn.append(`<small class="f_unread_num">${res.total}</small>`);
}
if (msg_modal_inner.length > 0) {
$.ajax({
type: "get",
url: `/apis/api.notification.halo.run/v1alpha1/userspaces/${username}/notifications?page=1&size=10`,
success: function (res) {
var data = res.items
if (data.length > 0) {
var unread_box = `
<div class="unread_box">
<div class="unread_tip"># 您有${f_unread_num}条未读消息 #
<a href="/uc/notifications" target="_blank">查看全部</a>
</div>
`
var read_box = `
<div class="read_box">
`
var unreadSum = 0
data.forEach((e => {
if (e.spec.unread) {
unreadSum = unreadSum + 1;
unread_box += `
<div class="vi_reply_item">
<div class="box" msg-name="${e.metadata.name}">
<span class="mark_read">标记为已读</span>
<div class="avatar_top"><img alt=""
src="https://cravatar.cn/avatar/?d=mp"
class="avatar avatar-50 photo" height="50" width="50" decoding="async"></div>
${e.spec.htmlContent}
</div>
</div>
`
} else {
read_box += `
<div class="vi_reply_item">
<div class="box">
<div class="avatar_top"><img alt=""
src="https://cravatar.cn/avatar/?d=mp"
class="avatar avatar-50 photo" height="50" width="50" decoding="async"></div>
${e.spec.htmlContent}
</div>
</div>
`
}
}
))
unread_box += `</div>`
read_box += `</div><p class="msg_limit">只显示最新10条未读和已读信息</p> `
msg_modal_inner.html(unread_box + read_box)
} else {
msg_modal_inner.html(`
<p class="no_posts"><small># 暂无消息 #</small><img class="s_nodata"
src="/themes/theme-pix/assets/img/nodata.png"></p>
<p class="msg_limit">只显示最新10条未读和已读信息</p>
`)
}
},
error: function () {
msg_modal_inner.html(`
<p class="no_posts"><small># 暂无消息 #</small><img class="s_nodata"
src="/themes/theme-pix/assets/img/nodata.png"></p>
<p class="msg_limit">只显示最新10条未读和已读信息</p>
`)
},
});
}
}
});
}
},
initGalleryPhotos: function () {
var galleryPhotos = document.querySelectorAll('.gallery-photos .gallery-photo');
if (galleryPhotos.length > 0) {
// 瀑布流排版
imgStatus.watch('.photo-img', () => {
waterfall('.gallery-photos');
});
}
},
topCategoriesBarScroll: function () {
if (document.getElementById("cat_nav_items")) {
let xscroll = document.getElementById("cat_nav_items");
xscroll.addEventListener("mousewheel", function (e) {
//计算鼠标滚轮滚动的距离
let v = -e.wheelDelta / 2;
xscroll.scrollLeft += v;
//阻止浏览器默认方法
e.preventDefault();
}, false);
}
},
topTableBarScroll: function () {
var tables = document.querySelectorAll('.single-content table')
if (tables.length>0) {
tables.forEach(function (xscroll) {
xscroll.addEventListener("mousewheel", function (e) {
//计算鼠标滚轮滚动的距离
let v = -e.wheelDelta / 2;
xscroll.scrollLeft += v;
//阻止浏览器默认方法
e.preventDefault();
}, false);
})
}
},
//处理瞬间权限
roleMoments: async function () {
const response = await fetch(`/apis/api.console.halo.run/v1alpha1/users/-`);
const data = await response.json();
var roles = data.roles;
if(roles.length>0) {
var name = roles[0].metadata.name
if(name != 'super-role') {
let dependencies = roles[0].metadata.annotations["rbac.authorization.halo.run/dependencies"]
if(dependencies != undefined) {
var targetRoles = ["role-template-uc-moments-approved","role-template-uc-moments-publish"]
const result = targetRoles.some(r => dependencies.includes(r));
if(!result) {
$('.normal_edit').remove();
}
}else {
$('.normal_edit').remove();
}
}
}
},
}
+662
View File
@@ -0,0 +1,662 @@
/*
* pix主题音乐播放器
*/
var rem=[];
rem.audio = $('<audio id="pix_player"></audio>');
var audiobox = $('<audio id="pix_player"></audio>');
var au = $('#pix_player');
var volume = 1;
var loop = Theme.play.m_loop;
var playlist = [];
var post_playlist = [];
var Paused = true;
var playLrc = '';
var m_cover = $('.player_mod .m_cover img');
var m_title = $('.player_mod .m_info h2');
var m_artist = $('.player_mod .m_info small');
$(document).on('click','.play_btn',function(){
$('.player_box').append(audiobox);
$('.pix_player').removeClass('playing');
$(this).parents('.pix_player').addClass('playing');
var url = $(this).attr('data');
var lrc = $(this).attr('lrc');
var audio_s = $('#pix_player').attr('src');
//var play = new Audio(url);
var meta = $(this).siblings('.player_meta').find('.title');
playLrc = lrc;
m_title.text(meta.find('.name').text());
m_artist.text(meta.find('.author').text());
m_cover.attr('src',$('.pix_player.playing .player_thum img').attr('src'));
if(audio_s == '' || audio_s !== url){
$('#pix_player').attr('src',url);
audiobox[0].play();
} else {
pasued();
}
$(".play_btn").html("<i class='ri-play-line'></i>");
initAudio();
});
// 初始化函数
function initAudio(){
// 给音乐标签绑定事件之后所触发的函数
audiobox[0].addEventListener("play",audioplay);
audiobox[0].addEventListener("pause",audiopause);
// timeupdate,代表音乐播放过程中只要发生变化就触发updateProcess
audiobox[0].addEventListener("timeupdate",updateProcess);
if(Theme.bgm_open == true){
audiobox[0].addEventListener("ended",endplay);
}
}
//音乐结束触发
function endplay(){
var index = $('.musci_list_box li.active').index() + 1;
var max = $('.musci_list_box li').length;
var new_mid = 0;
if(loop=="one"){
new_mid = index-1;
}else if(loop=="none") {
new_mid = (Math.floor(Math.random() * max) + 1)-1;
}else if(loop=="all") {
new_mid = index > (max - 1) ? 0 : index;
}
mulist_play(new_mid);
}
// 当音乐标签加载完成之后所触发的函数
audiobox[0].oncanplay=function(){
// 音乐的总时间
var duration=handleTime(this.duration);
// 音乐播放的当前时间
var currenttime=handleTime(this.currentTime);
$(".timer .total_time").text(duration);
$(".timer .current_time").text(currenttime);
initAudio();
}
// 音乐播放暂停的函数
function pasued(){
// paused,保存音乐播放和暂停的状态
if(Paused === false){//音乐是一个播放状态
audiobox[0].pause();
}else{
audiobox[0].play();
}
}
// 音乐播放之后触发的函数
function audioplay(){
//var height = $('.footer_menu').height();
var mheight = $('.footer_nav_box').height();
$('.footer_nav_box').animate({top:-mheight},200,'linear');
//music_bar.lock(false);//取消进度条的锁定
Paused=false;//更新音乐的播放状态(暂停)
$(".pix_player.playing .play_btn").html("<i class='ri-pause-line'></i>");//暂停按钮
$('.m_play').html('<i class="ri-pause-circle-fill"></i>');
}
// 音乐暂停之后触发的函数
function audiopause(){
//music_bar.lock(true);//添加进度条的锁定
Paused=true; //播放的状态
$(".pix_player.playing .play_btn").html("<i class='ri-play-line'></i>");
$('.m_play').html('<i class="ri-play-circle-fill"></i>');
}
// 更新进度条
function updateProcess(){
// 如果音乐不是暂停状态,则继续执行函数的代码块
if(Paused!==false) return true;
// 音乐的总时间
var duration = handleTime(this.duration);
// 音乐播放的当前时间
var currenttime = handleTime(this.currentTime);
var percent = audiobox[0].currentTime/audiobox[0].duration;
$(".player_mod .player_bar .progress").css('width',(percent)*100+"%");
$(".timer .total_time").text(duration);
$(".timer .current_time").text(currenttime);
}
//循环歌曲 m_loop
$(document).on('click','.m_loop',function(){
if($(this).hasClass('all')){ // 如果当前是循环
$(this).removeClass('all');
$(this).addClass('one');
$(this).html('<i class="ri-repeat-one-line"></i>');
loop = 'one';
}else if(($(this).hasClass('one'))){ // 如果当前是单曲循环
$(this).removeClass('one');
$(this).addClass('none');
$(this).html('<i class="ri-shuffle-line"></i>');
loop = 'none';
}else {
$(this).removeClass('none');
$(this).addClass('all');
$(this).html('<i class="ri-repeat-line"></i>');
loop = 'all';
}
});
// 时间处理的函数
function handleTime(seconedTime){
// 定义一个变量保存分钟
var minute=parseInt(seconedTime/60,10);
if(minute<10){minute="0"+minute};
//console.log(minute);
// 定义变量存放秒数
var second=(seconedTime-minute*60).toFixed(2).split(".")[0];
//console.log(second);
if(second<10){second="0"+second};
var Time=minute+":"+second;
// 返回最终的时间数值
return Time;
}
//视频播放
var video = $('#pix_video_player');
$(document).on('click','.video_play_btn',function(){
var video = $(this).siblings('#pix_video_player');
video.attr('controls','controls'); //显示控制条
$(this).remove(); //去除覆盖层
video[0].play();
});
function stopOtherMedia(element) {
$("video").not(element).each(function(index, video) {
video.pause();
});
}
//背景音乐
function autoload_music() {
var state = Theme.bgm_open;
var api = `${Theme.play.pix_mu_api || 'https://api.i-meto.com/meting/api'}?server=:server&type=:type&id=:id&r=:r`
var meta = {
server : Theme.play.mu_source,
type : Theme.play.mu_type,
id : Theme.play.play_id,
auth : ''
}
if(state == true){
let url = api.replace(":server", meta.server).replace(":type", meta.type).replace(":id", meta.id).replace(":auth", meta.auth).replace(":r", Math.random());
$.ajax({
type: "get",
url:url,
success: function (res) {
if(res.length > 0){
var new_mid = 0;
if(loop=="none") {
new_mid = (Math.floor(Math.random() * res.length) + 1)-1;
}
var f = res[new_mid];
var playnum = 1;
//$(".m_play").html('<i class="ri-pause-circle-line"></i>');
//默认播放第一首
audiobox.attr('src',f.url);
playLrc = f.lrc;
$('.player_mod .m_cover img').attr('src',f.pic);
$('.player_mod .m_info h2').text(f.title || f.name);
$('.player_mod .m_info small').text(f.author || f.artist);
$('.player_box').append(audiobox);
//存储一个播放列表
playlist.push(res);
//插入播放列表
$.each(res, function(key, data) {
$(".musci_list_box").append('<li class="item" id='+ key +'>' + playnum++ + '. ' + (data.title || data.name) + ' - ' + (data.author || data.artist) + '</li>');
});
$(".musci_list_box li").removeClass('active').eq(new_mid).addClass('active');
//console.log(playlist);
} else {
$(".musci_list_box").append('<div class="nodata">背景音乐未设置</div>');
}
}
});
}
}
//播放选中音乐
function mulist_play(index){
audiobox[0].removeEventListener("play",audioplay);
audiobox[0].removeEventListener("pause",audiopause);
$(".pix_player.playing .play_btn").html("<i class='ri-play-line'></i>");
$(".m_play").html('<i class="ri-pause-circle-fill"></i>');
$('.musci_list_box li').eq(index).addClass('active').siblings().removeClass('active');
scrollToPosition(index);
var data = playlist[0][index];
playLrc = data.lrc;
audiobox.attr('src',data.url);
m_cover.attr('src',data.pic);
m_title.text(data.title || data.name);
m_artist.text(data.author || data.artist);
audiobox[0].play();
Paused = false;
}
//点击展开播放列表
$(document).on('click', '.ri-bar-chart-horizontal-line', function () {
var position = $('.musci_list_box li.active').index()
// 延迟一段时间后进行滚动
setTimeout(function () {
if($('.m_list').attr('aria-expanded')){
scrollToPosition(position)
}
}, 200); // 延迟100毫秒后执行滚动操作
});
//点击列表播放
$(document).on('click','.musci_list_box li',function(){
$('.musci_list_box li').removeClass('active');
$(this).addClass('active');
var id = $(this).attr('id');
mulist_play(id)
});
//上一首
$(document).on('click','.m_prev',function(){
var index = $('.musci_list_box li.active').index() - 1;
var max = $('.musci_list_box li').length;
var new_mid = 0;
if(loop=="none") {
new_mid = (Math.floor(Math.random() * max) + 1)-1;
}else {
new_mid = index < 0 ? max - 1 : index;
}
mulist_play(new_mid);
});
//下一首
$(document).on('click','.m_next',function(){
var index = $('.musci_list_box li.active').index() + 1;
var max = $('.musci_list_box li').length;
var new_mid = 0;
if(loop=="none") {
new_mid = (Math.floor(Math.random() * max) + 1)-1;
}else{
new_mid = index > (max - 1) ? 0 : index;
}
mulist_play(new_mid);
});
//播放和暂停
function m_play() {
if(Paused === false){//音乐是一个播放状态
audiobox[0].pause();
$('.m_play').html('<i class="ri-play-circle-fill"></i>');
Paused = true;
}else{
audiobox[0].play();
$('.m_play').html('<i class="ri-pause-circle-fill"></i>');
Paused = false;
}
}
//播放按钮
$(document).on('click','.m_play',function(){
if(!$("#pix_player").length > 0){
cocoMessage.error('没有音乐可播放');
return false;
} else {
m_play();
}
});
/*
document.addEventListener('click', musicPlay);
function musicPlay() {
audiobox[0].play();
document.removeEventListener('click', musicPlay);
}
*/
//触发显示播放器
var trigger;
function mu_box_show(){
clearTimeout(trigger);
var mheight = $('.footer_nav_box').height();
$('.footer_nav_box').animate({top:-mheight},200,'linear');
}
function mu_box_hide(){
$('.footer_nav_box').animate({top:"0px"},200,'linear');
}
$(document).on('mouseenter', '.player_hand , .footer_nav_box', function(event) {
mu_box_show();
});
$(document).on('mouseleave', '.footer_nav_box .right_inner', function(event) {
trigger = setTimeout(function(){
mu_box_hide();
},2000);
});
//音乐进度条跳转
function getMousePosition(e){
var e = e || window.event;
var x = e.pageX;
var y = e.pageY;
return {'left':x,'top':y}
}
$(document).on('click','.player_bar',function(){
// 获取当前鼠标点击的位置
// console.log(getMousePosition().left)
// console.log($('.progress').offset())
var long = (getMousePosition().left) - ($('.progress').offset().left);
// console.log(long)
// 将当前点击的长度重新给p标签
$('.progress').width(long);
// 获得当前点击长度的时间
allTime = parseInt(audiobox[0].duration);
var nowtime = (long/$('.player_bar').width()) * allTime;
audiobox[0].currentTime = nowtime;
});
//音量调节 m_volume
$(document).on('click','.m_volume',function(){
if($(this).hasClass('mute')){ // 如果当前是静音
$(this).removeClass('mute');
$(this).html('<i class="ri-volume-down-line"></i>');
audiobox[0].muted = false;
}else{ // 如果当前不是静音
$(this).addClass('mute');
audiobox[0].muted = true;
$(this).html('<i class="ri-volume-mute-line"></i>');
}
});
$(document).on('click','.vo_bar',function(){
var long = (getMousePosition().top) - ($(this).offset().top)
var meter = long / $(this).height();
var finalLong = 1 - meter;
$('.vo_size').height(finalLong * $(this).height());
// 将audio音量调整为对应的音量
//var finalLong = volume;
audiobox[0].volume = finalLong;
// 改变数字
//$('.vol b').html(parseInt(finalLong * 100) + '%')
// 点击后音量调整键隐藏
//$('.vol a').css('display','none')
});
//文章歌曲
function autoload_posts_music() {
post_playlist.splice(0,post_playlist.length);
var pid = $('.posts_mu_list').attr('pid');
var api = `${Theme.play.pix_mu_api || 'https://api.i-meto.com/meting/api'}?server=:server&type=:type&id=:id&r=:r`
var meta = {
server : $('.posts_mu_list').attr('mus_source'),
type : $('.posts_mu_list').attr('mus_type'),
id : $('.posts_mu_list').attr('plays_id'),
mu_on: $('.posts_mu_list').attr('mu_on'),
auth : ''
}
if(pid && meta.mu_on=='true'){
let url = api.replace(":server", meta.server).replace(":type", meta.type).replace(":id", meta.id).replace(":auth", meta.auth).replace(":r", Math.random());
$.ajax({
type: "get",
url:url,
beforeSend: function () {
$('.posts_mu_list').html('<div class="loading_box"><div uk-spinner></div></div>');
},
success: function (res) {
if(res.length > 0){
$('.posts_mu_list .loading_box').remove();
var playnum = 1;
if(!$('#pix_player').length > 0){
$('.player_box').append(audiobox);
}
//存储一个播放列表
post_playlist.push(res);
//插入播放列表
$.each(res, function(key, data) {
$(".posts_mu_list").append('<li class="item" id='+ key +'><div class="mu_id">' + playnum++ + '</div><a class="s_play_btn"><i class="ri-play-circle-line"></i></a><div class="mus_info">'+ (data.title || data.name) +' <span>- ' + (data.author || data.artist) + '</span></div></li>');
});
//$(".musci_list_box li").removeClass('active').eq(0).addClass('active');
}
}
});
}
}
//文章歌曲播放
$(document).on('click','.s_play_btn',function(){
mu_box_show();
$('.posts_mu_list li').removeClass('active');
audiobox[0].removeEventListener("play",audioplay);
audiobox[0].removeEventListener("pause",audiopause);
$(".m_play").html('<i class="ri-pause-circle-fill"></i>');
$(this).parent().addClass('active');
var id = $(this).parents('li').attr('id');
var data = post_playlist[0][id];
playLrc = data.lrc;
audiobox.attr('src',data.url);
m_cover.attr('src',data.pic);
m_title.text(data.title || data.name);
m_artist.text(data.artist || data.artist);
audiobox[0].play();
Paused = false;
});
//播放器按钮
$(document).on('click','a.bg_music',function(){
mu_box_show();
});
$(function () {
autoload_music();
autoload_posts_music();
});
//播放类型切换
$(document).on('click','.audio_c_btn',function(){
var type = $(this).attr('au_type');
var input = $('<input type="text" placeholder="歌曲ID" name="moment_audio_api" id="moment_audio_api" class="required" required="required">');
$('.type_audio_text').empty();
$('.'+type+'_audio.type_audio_text').append(input);
});
$('.bg_lrc').click(function () {
if (lyricsContainer.css('display') === 'none') {
lyricsContainer.css('display', 'block');
$('a.bg_lrc i').css({
"color": "",
});
$('a.bg_lrc').css({
"background": "",
});
} else {
lyricsContainer.css('display', 'none');
$('a.bg_lrc i').css({
"color": "#aeaeae",
});
$('a.bg_lrc').css({
"background": "rgb(196 208 230 / 38%)",
});
}
});
//创建容器
if(Theme.play.lrc_open){
var lyricsContainer = $('<div class="lyrics-container"></div>');
$('.player_box').append(lyricsContainer);
var css = $(window).width() > 767 ?
{
//桌面歌词css(按照下面格式自行修改)
position: 'fixed',
bottom: '10px',
left: '2%',
width: '350px',
height: '100px',
overflow: 'hidden',
zIndex: '999',
pointerEvents: 'none',
} :
{
//移动端歌词css(按照下面格式自行修改)
position: 'fixed',
bottom: '88px',
left: '0',
width: '100%',
height: '72px',
textAlign: 'center',
overflow: 'hidden',
zIndex: '999',
pointerEvents: 'none',
};
lyricsContainer.css(css);
}
var lyricsMap = {};
// 获取歌词
async function fetchLyrics(url) {
if (!lyricsMap[url]) {
var lrcOriginal = await $.get(url);
lyricsMap[url] = parseLyrics(lrcOriginal);
}
return lyricsMap[url];
}
// 解析歌词
function parseLyrics(lrcOriginal) {
var lyrics = [];
var lines = lrcOriginal.split("\n");
for (var i = 0; i < lines.length; i++) {
var line = lines[i];
if (!line.trim()) {
continue;
}
var timeAndText = line.split("]");
var time = timeAndText[0].substr(1);
var text = timeAndText[1];
// 增加代码:如果歌词为空,跳过此次循环
if (!text.trim()) {
continue;
}
// 增加代码:把时间转换成秒
var timeInSeconds = 0;
var timeParts = time.split(":");
timeInSeconds += parseInt(timeParts[0], 10) * 60 - 0.5;
timeInSeconds += parseFloat(timeParts[1]);
lyrics.push({
time: timeInSeconds,
text: text
});
}
return lyrics;
}
// 更新歌词
function updateLyrics(currentTime, lyrics) {
for (var i = 0; i < lyrics.length; i++) {
if (currentTime >= lyrics[i].time && (i === lyrics.length - 1 || currentTime < lyrics[i + 1].time)) {
// 创建4行歌词
// 防止数组i越界
var currentLine3 = "";
if (i - 1 >= 0 && typeof lyrics[i - 1].text === "string") {
currentLine3 = lyrics[i - 1].text;
}
var currentLine = "";
if (typeof lyrics[i].text === "string") {
currentLine = lyrics[i].text;
}
var currentLine1 = "";
if (i + 1 < lyrics.length && typeof lyrics[i + 1].text === "string") {
currentLine1 = lyrics[i + 1].text;
}
var currentLine2 = "";
if (i + 2 < lyrics.length && typeof lyrics[i + 2].text === "string") {
currentLine2 = lyrics[i + 2].text;
}
//歌词文本css(修改style内的内容即可)
lyricsContainer.html(`
<div class="current-line" style="font-size: 10px;opacity: .4;">${currentLine3}</div>
<div class="current-line active" style="font-size: 14px;">${currentLine}</div>
<div class="current-line" style="font-size: 12px;opacity: .4;">${currentLine1}</div>
<div class="current-line" style="font-size: 10px;opacity: .1;">${currentLine2}</div>
`);
// 增加代码:添加从下往上线性滚动的动画
$('.current-line').animate({
top: '-=30px'
}, 2000, function () {
$(this).css({
top: '30px'
});
});
}
}
}
// 监听音频播放进度更新事件,更新歌词
Theme.play.lrc_open && audiobox[0].addEventListener("timeupdate", async function () {
var lyrics = await fetchLyrics(playLrc)
updateLyrics(this.currentTime, lyrics);
});
// 根据选择的位置定位滚动条
function scrollToPosition(position) {
let container = document.getElementById("musci_list");
let items = container.getElementsByClassName("item");
if (position >= 0 && position < items.length) {
items[position].scrollIntoView();
}
}
+418
View File
@@ -0,0 +1,418 @@
// 部分代码来自ZIBILL主题作者
// canvas生成海报
const poster = (function() {
const DEBUG = false
const WIDTH = 700
const HEIGHT = 1160
function init(config) {
const $container = document.querySelector(config.selector)
$container.style.border = '1px solid #f0f0f0'
const $wrapper = createDom('div', 'id', 'wrapper')
const $canvas = createDom('canvas', 'id', 'canvas', 'block')
const $day = createDom('canvas', 'id', 'day')
const $date = createDom('canvas', 'id', 'date')
const $title = createDom('canvas', 'id', 'title')
const $content = createDom('canvas', 'id', 'content')
const $logo = createDom('canvas', 'id', 'logo')
const $description = createDom('canvas', 'id', 'description')
appendChilds($wrapper, $canvas, $day, $date, $title, $content, $logo, $description)
$container.appendChild($wrapper)
const date = new Date()
// day
const dayStyle = {
font: 'bold 80px Helvetica',
color: 'rgba(255, 255, 255, 1)',
position: 'right'
}
drawOneline($day, dayStyle, date.getDate());
// date
const dateStyle = {
font: '23px Helvetica',
color: 'rgba(255, 255, 255, 1)',
position: 'right'
}
drawOneline($date, dateStyle, date.getFullYear() + '/' + (date.getMonth() + 1))
// title canvas
const titleStyle = {
font: '30px Helvetica',
lineHeight: 1.5,
color: 'rgba(255, 255, 255, 1)',
length: 2,
position: 'left'
}
titleStyle.font = (config.titleStyle && config.titleStyle.font) || titleStyle.font
titleStyle.color = (config.titleStyle && config.titleStyle.color) || titleStyle.color
titleStyle.position = (config.titleStyle && config.titleStyle.position) || titleStyle.position
drawMoreLines($title, titleStyle, config.title)
// content canvas
const contentStyle = {
font: '22px Helvetica',
lineHeight: 1.5,
position: 'left',
color: 'rgba(236, 241, 255, 1)'
}
contentStyle.font = (config.contentStyle && config.contentStyle.font) || contentStyle.font
contentStyle.color = (config.contentStyle && config.contentStyle.color) || contentStyle.color
contentStyle.lineHeight = (config.contentStyle && config.contentStyle.lineHeight) || contentStyle.lineHeight
contentStyle.position = (config.contentStyle && config.contentStyle.position) || contentStyle.position
drawMoreLines($content, contentStyle, config.content);
// description
const descriptionStyle = {
font: '24px Helvetica',
color: 'rgba(180, 180, 180, 1)',
lineHeight: 1.2,
position: 'left'
}
drawMoreLines($description, descriptionStyle, config.description)
// background image
const image = new Image();
image.crossOrigin = "Anonymous";
//logo
const logo = new Image();
logo.crossOrigin = "Anonymous";
logo.src = config.logo;
//qrcode
const qrcode = new Image();
qrcode.src = config.qrcode;
const onload = function() {
$canvas.width = WIDTH;
$canvas.height = HEIGHT;
image.src = config.banner;
image.onload = function() {
const ctx = $canvas.getContext('2d')
ctx.fillStyle = 'rgba(255, 255, 255, 1)';
ctx.fillRect(0, 0, $canvas.width, $canvas.height);
// banner
imgRect = coverImg($canvas.width - 40, $canvas.height / 1.2 - 40, image.width, image.height);
ctx.drawImage(image, imgRect.sx, imgRect.sy, imgRect.sWidth, imgRect.sHeight, 20, 20, $canvas.width - 40, $canvas.height / 1.2 - 40);
//覆盖层
ctx.fillStyle="rgba(0, 0, 0, 0.3)";
ctx.fillRect(20,20,$canvas.width - 40,$canvas.height / 1.2 - 40);
// 时间
ctx.drawImage($day, -20, 50)
ctx.drawImage($date, -21, 125)
//logo
var logowidth = logo.width;
var logoheight = logo.height;
var scale = logowidth / logoheight;
var logoh = 60;
var cwidth = logoh * scale;
ctx.drawImage(logo, 60, $canvas.height / 1.2 + 30, cwidth, logoh);
ctx.drawImage(qrcode, $canvas.width - 160, $canvas.height / 1.2 + 20, 120, 120);
//标题文字
ctx.drawImage($title, 20, $canvas.height / 2 + 20)
ctx.drawImage($content, 20, $canvas.height / 2 + 120)
ctx.drawImage($description, 20, $canvas.height / 1.2 + 110)
ctx.strokeStyle = 'rgba(122, 122, 122, 0.5)';
const img = new Image();
img.crossOrigin = "Anonymous";
img.src = $canvas.toDataURL('image/png')
const radio = config.radio || 0.7
img.width = WIDTH * radio
img.height = HEIGHT * radio
img.className = 'poster_load';
ctx.clearRect(0, 0, $canvas.width, $canvas.height)
$canvas.style.display = 'none'
if ($container.querySelector('.poster_load')) {
$container.querySelector('.poster_load').src = img.src;
} else {
$container.appendChild(img);
}
$container.appendChild(img);
$container.removeChild($wrapper)
if (config.callback) {
config.callback($container)
}
}
}
onload()
}
//裁切
function containImg(sx, sy, box_w, box_h, source_w, source_h) {
var dx = sx,
dy = sy,
dWidth = box_w,
dHeight = box_h;
if (source_w > source_h || (source_w == source_h && box_w < box_h)) {
dHeight = source_h * dWidth / source_w;
dy = sy + (box_h - dHeight) / 2;
} else if (source_w < source_h || (source_w == source_h && box_w > box_h)) {
dWidth = source_w * dHeight / source_h;
dx = sx + (box_w - dWidth) / 2;
}
return {
dx,
dy,
dWidth,
dHeight
}
}
function coverImg(box_w, box_h, source_w, source_h) {
var sx = 0,
sy = 0,
sWidth = source_w,
sHeight = source_h;
if (source_w > source_h || (source_w == source_h && box_w < box_h)) {
sWidth = box_w * sHeight / box_h;
sx = (source_w - sWidth) / 2;
} else if (source_w < source_h || (source_w == source_h && box_w > box_h)) {
sHeight = box_h * sWidth / box_w;
sy = (source_h - sHeight) / 2;
}
return {
sx,
sy,
sWidth,
sHeight
}
}
function createDom(name, key, value, display = 'none') {
const $dom = document.createElement(name)
$dom.setAttribute(key, value)
$dom.style.display = display
$dom.width = WIDTH
return $dom
}
function appendChilds(parent, ...doms) {
doms.forEach(dom => {
parent.appendChild(dom)
})
}
function drawOneline(canvas, style, content) {
const ctx = canvas.getContext('2d')
canvas.height = parseInt(style.font.match(/\d+/), 10) + 20
ctx.font = style.font
ctx.fillStyle = style.color
ctx.textBaseline = 'top'
let lineWidth = 0
let idx = 0
let truncated = false
for (let i = 0; i < content.length; i++) {
lineWidth += ctx.measureText(content[i]).width;
if (lineWidth > canvas.width - 60) {
truncated = true
idx = i
break
}
}
let padding = 30
if (truncated) {
content = content.substring(0, idx)
padding = canvas.width / 2 - lineWidth / 2
}
if (DEBUG) {
ctx.strokeStyle = "#6fda92";
ctx.strokeRect(0, 0, canvas.width, canvas.height);
}
if (style.position === 'center') {
ctx.textAlign = 'center';
ctx.fillText(content, canvas.width / 2, 0)
} else if (style.position === 'left') {
ctx.fillText(content, padding, 0)
} else {
ctx.textAlign = 'right'
ctx.fillText(content, canvas.width - padding, 0)
}
}
function drawMoreLines(canvas, style, content) {
const ctx = canvas.getContext('2d')
const fontHeight = parseInt(style.font.match(/\d+/), 10)
if (DEBUG) {
ctx.strokeStyle = "#6fda92";
ctx.strokeRect(0, 0, canvas.width, canvas.height);
}
ctx.font = style.font
ctx.fillStyle = style.color
ctx.textBaseline = 'top'
ctx.textAlign = 'center'
let alignX = 0
if (style.position === 'center') {
alignX = canvas.width / 2;
} else if (style.position === 'left') {
ctx.textAlign = 'left'
alignX = 40
} else {
ctx.textAlign = 'right'
alignX = canvas.width - 40
}
let lineWidth = 0
let lastSubStrIndex = 0
let offsetY = 0
for (let i = 0; i < content.length; i++) {
lineWidth += ctx.measureText(content[i]).width;
if (lineWidth > canvas.width - 120) {
ctx.fillText(content.substring(lastSubStrIndex, i), alignX, offsetY);
offsetY += fontHeight * style.lineHeight
lineWidth = 0
lastSubStrIndex = i
}
if (i === content.length - 1) {
ctx.fillText(content.substring(lastSubStrIndex, i + 1), alignX, offsetY);
}
}
}
return {
init
}
})()
//ajax生成文章海报
$('body').on('click', '.cr_poster', function () {
var post_id = $(this).attr('poster-data');
var banner = $(this).attr('banner');
var single_content = $('.single-content')
var t_content = $('#post-'+post_id+' .t_content')
var content = single_content.length>0 ? single_content[0].innerText : t_content[0].innerText
var content_length = content.length
var permalink = t_content.length>0 ? window.location.origin + '/moments/'+post_id : window.location.origin + window.location.pathname;
var title = t_content.length>0 ? Theme.site_title+'-瞬间' : document.title;
new QRious({ element: document.getElementById("twoCode"), value: permalink, size: 260, });
$('.poster_box').remove();
$('#share_modal_' + post_id + ' .poster_box_ap').append('<div class="poster_box"></div>');
if (content_length > 120) {
content = content.substring(0, 80) + '...'
}
function Posterdown(e) {
if (e == null) {
return;
}
var modal = '#share_modal_' + post_id;
var url = $('' + modal + ' .poster_box img').attr('src');
$('' + modal + ' .post_share_box').removeClass('hide');
$('' + modal + ' .poster_download').attr('href', url).attr('download', 'poster_' + post_id + '.png');
}
$('#share_modal_' + post_id + ' .poster_box').append('<div class="loading_box"><div uk-spinner></div></div>');
$('.loading_box').remove();
poster.init({
banner: banner,
selector: '.poster_box',
title: title,
content: content,
logo: Theme.site_logo,
qrcode: $('#twoCode').attr('src'),
description: Theme.admin_des,
callback: Posterdown
});
});
function convertImgToBase64(url, callback) {
var canvas = document.createElement('canvas');
var img = new Image();
img.crossOrigin = 'Anonymous';
img.onload = function () {
canvas.width = img.width;
canvas.height = img.height;
var ctx = canvas.getContext('2d');
ctx.drawImage(img, 0, 0);
var ext = img.src.substring(img.src.lastIndexOf('.') + 1).toLowerCase();
var dataURL = canvas.toDataURL('image/' + ext);
callback(dataURL);
canvas = null;
};
img.src = url;
}
function handleShare(e, pic, title,pathname) {
var permalink = window.location.origin + pathname;
switch (e) {
case 'wb':
var url = `https://service.weibo.com/share/share.php?url=${permalink}&type=button&language=zh_cn&pic=${pic}&title=${title}`
window.open(url);
break
case 'qzone':
var url = `https://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?url=${permalink}&title=${title}&pics=${pic}`
window.open(url);
break
case "qq":
var url = `http://connect.qq.com/widget/shareqq/index.html?url=${permalink}&title=${title}&pics=${pic}`
window.open(url);
break;
case "copy":
if (navigator.clipboard) {
navigator.clipboard.writeText(permalink).then(function() {
cocoMessage.success("链接已复制到剪贴板!");
}, function(err) {
cocoMessage.error("复制失败,请手动复制链接");
});
} else {
// 兼容旧浏览器
var tempInput = document.createElement('input');
tempInput.value = permalink;
document.body.appendChild(tempInput);
tempInput.select();
try {
document.execCommand('copy');
cocoMessage.success("链接已复制到剪贴板!");
} catch (err) {
cocoMessage.error("复制失败,请手动复制链接");
}
document.body.removeChild(tempInput);
}
break;
default:
break
}
}
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
+1
View File
@@ -0,0 +1 @@
!function(){this.loaded=0,this.failed=0,this.total=0,this.watch=function(a,b){var c=document.querySelectorAll(a);if(!c.length)return console.log("[imgStatus]: Doesn't exists any images with this class!");this.total=c.length;for(var d=0;d<c.length;d++)is_cached(c[d].src)?this.ready(b):c[d].addEventListener?(c[d].addEventListener("load",this.ready.bind(this,b)),c[d].addEventListener("error",this.fail.bind(this,b))):(c[d].attachEvent("onload",this.ready.bind(this,b)),c[d].attachEvent("onerror",this.fail.bind(this,b)))},this.is_cached=function(a){var b=new Image;return b.src=a,b.complete},this.fail=function(a,b){++this.failed,"function"==typeof a&&a(this)},this.ready=function(a,b){++this.loaded,"function"==typeof a&&a(this)},this.done=function(){return this.loaded+this.failed===this.total?!0:!1},"object"==typeof window&&(window.imgStatus=this)}();
@@ -0,0 +1,8 @@
/*!
* jQuery Cookie Plugin v1.4.1
* https://github.com/carhartl/jquery-cookie
*
* Copyright 2013 Klaus Hartl
* Released under the MIT license
*/
!function(factory){"function"==typeof define&&define.amd?define(["jquery"],factory):"object"==typeof exports?factory(require("jquery")):factory(jQuery)}((function($){var pluses=/\+/g;function encode(s){return config.raw?s:encodeURIComponent(s)}function stringifyCookieValue(value){return encode(config.json?JSON.stringify(value):String(value))}function read(s,converter){var value=config.raw?s:function(s){0===s.indexOf('"')&&(s=s.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return s=decodeURIComponent(s.replace(pluses," ")),config.json?JSON.parse(s):s}catch(e){}}(s);return $.isFunction(converter)?converter(value):value}var config=$.cookie=function(key,value,options){if(void 0!==value&&!$.isFunction(value)){if("number"==typeof(options=$.extend({},config.defaults,options)).expires){var days=options.expires,t=options.expires=new Date;t.setTime(+t+864e5*days)}return document.cookie=[encode(key),"=",stringifyCookieValue(value),options.expires?"; expires="+options.expires.toUTCString():"",options.path?"; path="+options.path:"",options.domain?"; domain="+options.domain:"",options.secure?"; secure":""].join("")}for(var s,result=key?void 0:{},cookies=document.cookie?document.cookie.split("; "):[],i=0,l=cookies.length;i<l;i++){var parts=cookies[i].split("="),name=(s=parts.shift(),config.raw?s:decodeURIComponent(s)),cookie=parts.join("=");if(key&&key===name){result=read(cookie,value);break}key||void 0===(cookie=read(cookie))||(result[name]=cookie)}return result};config.defaults={},$.removeCookie=function(key,options){return void 0!==$.cookie(key)&&($.cookie(key,"",$.extend({},options,{expires:-1})),!$.cookie(key))}}));
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1,306 @@
"use strict";
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
!function (global, factory) {
(typeof exports === "undefined" ? "undefined" : _typeof(exports)) === "object" && typeof module !== "undefined" ? module.exports = factory() : typeof define === "function" && define.amd ? define(factory) : (global = global || self, global.cocoMessage = factory());
}(void 0, function () {
"use strict";
var msgWrapper = c({
className: "coco-msg-stage"
});
function c(args, children) {
var el = document.createElement("div");
for (var key in args) {
var element = args[key];
if (key == "className") {
key = "class";
el.setAttribute(key, element);
} else if (key[0] == "_") {
el.addEventListener(key.slice(1), element);
}
}
if (typeof children == "string") {
el.innerHTML = children;
} else if (_typeof(children) == "object" && children.tagName) {
el.appendChild(children);
} else if (children) {
for (var i = 0; i < children.length; i++) {
var child = children[i];
el.appendChild(child);
}
}
return el;
}
function addAnimationEnd(el, fn) {
["a", "webkitA"].forEach(function (prefix) {
var name = prefix + "nimationEnd";
el.addEventListener(name, function () {
fn();
});
});
}
function css(el, css) {
for (var key in css) {
el.style[key] = css[key];
}
if (el.getAttribute("style") === "") {
el.removeAttribute("style");
}
}
function addClass(el, s) {
var c = el.className || "";
if (!hasClass(c, s)) {
var arr = c.split(/\s+/);
arr.push(s);
el.className = arr.join(" ");
}
}
function hasClass(c, s) {
return c.indexOf(s) > -1 ? !0 : !1;
}
function removeClass(el, s) {
var c = el.className || "";
if (hasClass(c, s)) {
var arr = c.split(/\s+/);
var i = arr.indexOf(s);
arr.splice(i, 1);
el.className = arr.join(" ");
}
if (el.className === "") {
el.removeAttribute("class");
}
}
var initArgs = {
msg: "",
duration: 2000,
showClose: false
};
var cocoMessage = {
info: function info() {
initConfig(arguments, "info");
},
success: function success() {
initConfig(arguments, "success");
},
warning: function warning() {
initConfig(arguments, "warning");
},
error: function error() {
initConfig(arguments, "error");
},
loading: function loading() {
return initConfig(arguments, "loading");
},
destroyAll: function destroyAll() {
_destroyAll();
},
config: function config(obj) {
for (var key in obj) {
if (Object.hasOwnProperty.call(obj, key)) {
if (obj[key] !== undefined) {
initArgs[key] = obj[key];
}
}
}
}
};
function initConfig(obj, type) {
var args = {};
for (var key in initArgs) {
args[key] = initArgs[key];
}
for (var i = 0; i < obj.length; i++) {
var it = obj[i];
if (it !== undefined) {
if (typeof it == "string" || _typeof(it) == "object") {
args.msg = it;
} else if (typeof it == "boolean") {
args.showClose = it;
} else if (typeof it == "function") {
args.onClose = it;
} else if (typeof it == "number") {
args.duration = it;
}
}
}
args.type = type;
return createMsgEl(args);
}
function createMsgEl(args) {
var type = args.type,
duration = args.duration,
msg = args.msg,
showClose = args.showClose,
onClose = args.onClose;
var closable = duration === 0;
var iconObj = getIconObj();
if (type == "loading") {
msg = msg === "" ? "正在加载,请稍后" : msg;
closable = showClose;
duration = 0;
}
var el = c({
className: "coco-msg-wrapper"
}, [c({
className: "coco-msg coco-msg-fade-in " + type
}, [c({
className: "coco-msg-icon"
}, iconObj[type]), c({
className: "coco-msg-content"
}, msg), c({
className: "coco-msg-wait " + (closable ? "coco-msg-pointer" : ""),
_click: function _click() {
if (closable) {
closeMsg(el, onClose);
}
}
}, getMsgRight(closable))])]);
var anm = el.querySelector(".coco-msg__circle");
if (anm) {
css(anm, {
animation: "coco-msg_" + type + " " + duration + "ms linear"
});
if ("onanimationend" in window) {
addAnimationEnd(anm, function () {
closeMsg(el, onClose);
});
} else {
setTimeout(function () {
closeMsg(el, onClose);
}, duration);
}
}
if (type == "loading" && duration !== 0) {
setTimeout(function () {
closeMsg(el, onClose);
}, duration);
}
if (!msgWrapper.children.length) {
document.body.appendChild(msgWrapper);
}
msgWrapper.appendChild(el);
css(el, {
height: el.offsetHeight + "px"
});
setTimeout(function () {
removeClass(el.children[0], "coco-msg-fade-in");
}, 300);
if (type == "loading") {
return function () {
closeMsg(el, onClose);
};
}
}
function getMsgRight(showClose) {
if (showClose) {
return "\n <svg class=\"coco-msg-close\" viewBox=\"0 0 1024 1024\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" p-id=\"5514\"><path d=\"M810 274l-238 238 238 238-60 60-238-238-238 238-60-60 238-238-238-238 60-60 238 238 238-238z\" p-id=\"5515\"></path></svg>\n ";
} else {
return "<svg class=\"coco-msg-progress\" viewBox=\"0 0 33.83098862 33.83098862\" xmlns=\"http://www.w3.org/2000/svg\">\n <circle class=\"coco-msg__background\" cx=\"16.9\" cy=\"16.9\" r=\"15.9\"></circle>\n <circle class=\"coco-msg__circle\" stroke-dasharray=\"100,100\" cx=\"16.9\" cy=\"16.9\" r=\"15.9\"></circle>\n </svg>\n ";
}
}
function closeMsg(el, cb) {
if (!el) return;
css(el, {
padding: 0,
height: 0
});
addClass(el.children[0], "coco-msg-fade-out");
cb && cb();
setTimeout(function () {
if (!el) return;
var has = false;
for (var i = 0; i < msgWrapper.children.length; i++) {
if (msgWrapper.children[i] === el) {
has = true;
}
}
has && removeChild(el);
el = null;
if (!msgWrapper.children.length) {
has && removeChild(msgWrapper);
}
}, 300);
}
function getIconObj() {
return {
info: "\n <svg t=\"1609810636603\" viewBox=\"0 0 1024 1024\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" p-id=\"3250\"><path d=\"M469.333333 341.333333h85.333334v469.333334H469.333333z\" fill=\"#ffffff\" p-id=\"3251\"></path><path d=\"M469.333333 213.333333h85.333334v85.333334H469.333333z\" fill=\"#ffffff\" p-id=\"3252\"></path><path d=\"M384 341.333333h170.666667v85.333334H384z\" fill=\"#ffffff\" p-id=\"3253\"></path><path d=\"M384 725.333333h256v85.333334H384z\" fill=\"#ffffff\" p-id=\"3254\"></path></svg>\n ",
success: "\n <svg t=\"1609781242911\" viewBox=\"0 0 1024 1024\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" p-id=\"1807\"><path d=\"M455.42 731.04c-8.85 0-17.75-3.05-24.99-9.27L235.14 553.91c-16.06-13.81-17.89-38.03-4.09-54.09 13.81-16.06 38.03-17.89 54.09-4.09l195.29 167.86c16.06 13.81 17.89 38.03 4.09 54.09-7.58 8.83-18.31 13.36-29.1 13.36z\" p-id=\"1808\" fill=\"#ffffff\"></path><path d=\"M469.89 731.04c-8.51 0-17.07-2.82-24.18-8.6-16.43-13.37-18.92-37.53-5.55-53.96L734.1 307.11c13.37-16.44 37.53-18.92 53.96-5.55 16.43 13.37 18.92 37.53 5.55 53.96L499.67 716.89c-7.58 9.31-18.64 14.15-29.78 14.15z\" p-id=\"1809\" fill=\"#ffffff\"></path></svg>\n ",
warning: "\n <svg t=\"1609776406944\" viewBox=\"0 0 1024 1024\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" p-id=\"18912\"><path d=\"M468.114286 621.714286c7.314286 21.942857 21.942857 36.571429 43.885714 36.571428s36.571429-14.628571 43.885714-36.571428L585.142857 219.428571c0-43.885714-36.571429-73.142857-73.142857-73.142857-43.885714 0-73.142857 36.571429-73.142857 80.457143l29.257143 394.971429zM512 731.428571c-43.885714 0-73.142857 29.257143-73.142857 73.142858s29.257143 73.142857 73.142857 73.142857 73.142857-29.257143 73.142857-73.142857-29.257143-73.142857-73.142857-73.142858z\" p-id=\"18913\" fill=\"#ffffff\"></path></svg>\n ",
error: "\n <svg t=\"1609810716933\" viewBox=\"0 0 1024 1024\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" p-id=\"5514\"><path d=\"M810 274l-238 238 238 238-60 60-238-238-238 238-60-60 238-238-238-238 60-60 238 238 238-238z\" p-id=\"5515\" fill=\"#ffffff\"></path></svg>\n ",
loading: "\n <div class=\"coco-msg_loading\">\n <svg class=\"coco-msg-circular\" viewBox=\"25 25 50 50\">\n <circle class=\"coco-msg-path\" cx=\"50\" cy=\"50\" r=\"20\" fill=\"none\" stroke-width=\"4\" stroke-miterlimit=\"10\"/>\n </svg>\n </div>\n "
};
}
function removeChild(el) {
el && el.parentNode.removeChild(el);
}
function _destroyAll() {
for (var i = 0; i < msgWrapper.children.length; i++) {
var element = msgWrapper.children[i];
closeMsg(element);
}
}
window.addEventListener('DOMContentLoaded', function () {
insertCssInHead();
});
function insertCssInHead() {
var doc = document;
if (doc && doc.head) {
var head = doc.head;
var _css = doc.createElement('style');
var cssStr = "\n\n[class|=coco],[class|=coco]::after,[class|=coco]::before{box-sizing:border-box;outline:0}.coco-msg-progress{width:13px;height:13px}.coco-msg__circle{stroke-width:2;stroke-linecap:square;fill:none;transform:rotate(-90deg);transform-origin:center}.coco-msg-stage:hover .coco-msg__circle{-webkit-animation-play-state:paused!important;animation-play-state:paused!important}.coco-msg__background{stroke-width:2;fill:none}.coco-msg-stage{position:fixed;top:20px;left:50%;width:auto;transform:translate(-50%,0);z-index:3000}.coco-msg-wrapper{position:relative;left:50%;transform:translate(-50%,0);transform:translate3d(-50%,0,0);transition:height .3s ease,padding .3s ease;padding:6px 0;will-change:transform,opacity}.coco-msg{padding:15px 21px;border-radius:3px;position:relative;left:50%;transform:translate(-50%,0);transform:translate3d(-50%,0,0);display:flex;align-items:center}.coco-msg-content,.coco-msg-icon,.coco-msg-wait{display:inline-block}.coco-msg-icon{position:relative;width:13px;height:13px;border-radius:100%;display:flex;justify-content:center;align-items:center}.coco-msg-icon svg{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:11px;height:11px}.coco-msg-wait{width:20px;height:20px;position:relative;fill:#4eb127}.coco-msg-wait svg{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%)}.coco-msg-close{width:14px;height:14px}.coco-msg-content{margin:0 10px;min-width:240px;text-align:left;font-size:14px;font-weight:500;font-family:-apple-system,Microsoft Yahei,sans-serif;text-shadow:0 0 1px rgba(0,0,0,.01)}.coco-msg.info{color:#0fafad;background-color:#e7fdfc;box-shadow:0 0 2px 0 rgba(0,1,1,.01),0 0 0 1px #c0faf9}.coco-msg.info .coco-msg-icon{background-color:#0fafad}.coco-msg.success{color:#4ebb23;background-color:#f3ffe8;box-shadow:0 0 2px 0 rgba(0,1,0,.01),0 0 0 1px #d9f8bb}.coco-msg.success .coco-msg-icon{background-color:#4ebb23}.coco-msg.warning{color:#f1b306;background-color:#fff9eb;box-shadow:0 0 2px 0 rgba(1,1,0,.01),0 0 0 1px #fcf2cd}.coco-msg.warning .coco-msg-icon{background-color:#f1b306}.coco-msg.error{color:#f34b51;background-color:#fff7f7;box-shadow:0 0 2px 0 rgba(1,0,0,.01),0 0 0 1px #ffe3e3}.coco-msg.error .coco-msg-icon{background-color:#f34b51}.coco-msg.loading{color:#0fafad;background-color:#e7fdfc;box-shadow:0 0 2px 0 rgba(0,1,1,.01),0 0 0 1px #c2faf9}.coco-msg_loading{flex-shrink:0;width:20px;height:20px;position:relative}.coco-msg-circular{-webkit-animation:coco-msg-rotate 2s linear infinite both;animation:coco-msg-rotate 2s linear infinite both;transform-origin:center center;height:18px!important;width:18px!important}.coco-msg-path{stroke-dasharray:1,200;stroke-dashoffset:0;stroke:#0fafad;-webkit-animation:coco-msg-dash 1.5s ease-in-out infinite;animation:coco-msg-dash 1.5s ease-in-out infinite;stroke-linecap:round}@-webkit-keyframes coco-msg-rotate{100%{transform:translate(-50%,-50%) rotate(360deg)}}@keyframes coco-msg-rotate{100%{transform:translate(-50%,-50%) rotate(360deg)}}@-webkit-keyframes coco-msg-dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}@keyframes coco-msg-dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}100%{stroke-dasharray:89,200;stroke-dashoffset:-124px}}.coco-msg.info .coco-msg-wait{fill:#0fafad}.coco-msg.success .coco-msg-wait{fill:#4ebb23}.coco-msg.warning .coco-msg-wait{fill:#f1b306}.coco-msg.error .coco-msg-wait{fill:#f34b51}.coco-msg.loading .coco-msg-wait{fill:#0fafad}.coco-msg-pointer{cursor:pointer}@-webkit-keyframes coco-msg_info{0%{stroke:#0fafad}to{stroke:#0fafad;stroke-dasharray:0 100}}@keyframes coco-msg_info{0%{stroke:#0fafad}to{stroke:#0fafad;stroke-dasharray:0 100}}@-webkit-keyframes coco-msg_success{0%{stroke:#4eb127}to{stroke:#4eb127;stroke-dasharray:0 100}}@keyframes coco-msg_success{0%{stroke:#4eb127}to{stroke:#4eb127;stroke-dasharray:0 100}}@-webkit-keyframes coco-msg_warning{0%{stroke:#fcbc0b}to{stroke:#fcbc0b;stroke-dasharray:0 100}}@keyframes coco-msg_warning{0%{stroke:#fcbc0b}to{stroke:#fcbc0b;stroke-dasharray:0 100}}@-webkit-keyframes coco-msg_error{0%{stroke:#eb262d}to{stroke:#eb262d;stroke-dasharray:0 100}}@keyframes coco-msg_error{0%{stroke:#eb262d}to{stroke:#eb262d;stroke-dasharray:0 100}}.coco-msg-fade-in{-webkit-animation:coco-msg-fade .2s ease-out both;animation:coco-msg-fade .2s ease-out both}.coco-msg-fade-out{animation:coco-msg-fade .3s linear reverse both}@-webkit-keyframes coco-msg-fade{0%{opacity:0;transform:translate(-50%,0);transform:translate3d(-50%,-80%,0)}to{opacity:1;transform:translate(-50%,0);transform:translate3d(-50%,0,0)}}@keyframes coco-msg-fade{0%{opacity:0;transform:translate(-50%,0);transform:translate3d(-50%,-80%,0)}to{opacity:1;transform:translate(-50%,0);transform:translate3d(-50%,0,0)}}\n ";
_css.innerHTML = cssStr;
if (head.children.length) {
head.insertBefore(_css, head.children[0]);
} else {
head.appendChild(_css);
}
}
}
return cocoMessage;
});
@@ -0,0 +1 @@
@-webkit-keyframes nprogress-spinner{0%{-webkit-transform:rotate(0deg)}to{-webkit-transform:rotate(360deg)}}@keyframes nprogress-spinner{0%{transform:rotate(0deg)}to{transform:rotate(360deg)}}#nprogress{pointer-events:none}#nprogress .bar{background:#172eff;position:fixed;z-index:1031;top:0;left:0;width:100%;height:2px}#nprogress .peg{display:block;position:absolute;right:0;width:100px;height:100%;box-shadow:0 0 10px #29d,0 0 5px #29d;opacity:1;-webkit-transform:rotate(3deg) translate(0,-4px);-ms-transform:rotate(3deg) translate(0,-4px);transform:rotate(3deg) translate(0,-4px)}#nprogress .spinner{display:block;position:fixed;z-index:1031;top:15px;right:15px}#nprogress .spinner-icon{width:18px;height:18px;box-sizing:border-box;border:solid 2px transparent;border-top-color:#29d;border-left-color:#29d;border-radius:50%;-webkit-animation:nprogress-spinner 400ms linear infinite;animation:nprogress-spinner 400ms linear infinite}.nprogress-custom-parent{overflow:hidden;position:relative}.nprogress-custom-parent #nprogress .bar,.nprogress-custom-parent #nprogress .spinner{position:absolute}
@@ -0,0 +1,500 @@
/* NProgress, (c) 2013, 2014 Rico Sta. Cruz - http://ricostacruz.com/nprogress
* @license MIT */
;(function(root, factory) {
if (typeof define === 'function' && define.amd) {
define(factory);
} else if (typeof exports === 'object') {
module.exports = factory();
} else {
root.NProgress = factory();
}
})(this, function() {
var NProgress = {};
NProgress.version = '0.2.0';
var Settings = NProgress.settings = {
minimum: 0.08,
easing: 'linear',
positionUsing: '',
speed: 200,
trickle: true,
trickleSpeed: 200,
showSpinner: true,
barSelector: '[role="bar"]',
spinnerSelector: '[role="spinner"]',
parent: 'body',
template: '<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'
};
/**
* Updates configuration.
*
* NProgress.configure({
* minimum: 0.1
* });
*/
NProgress.configure = function(options) {
var key, value;
for (key in options) {
value = options[key];
if (value !== undefined && options.hasOwnProperty(key)) Settings[key] = value;
}
return this;
};
/**
* Last number.
*/
NProgress.status = null;
/**
* Sets the progress bar status, where `n` is a number from `0.0` to `1.0`.
*
* NProgress.set(0.4);
* NProgress.set(1.0);
*/
NProgress.set = function(n) {
var started = NProgress.isStarted();
n = clamp(n, Settings.minimum, 1);
NProgress.status = (n === 1 ? null : n);
var progress = NProgress.render(!started),
bar = progress.querySelector(Settings.barSelector),
speed = Settings.speed,
ease = Settings.easing;
progress.offsetWidth; /* Repaint */
queue(function(next) {
// Set positionUsing if it hasn't already been set
if (Settings.positionUsing === '') Settings.positionUsing = NProgress.getPositioningCSS();
// Add transition
css(bar, barPositionCSS(n, speed, ease));
if (n === 1) {
// Fade out
css(progress, {
transition: 'none',
opacity: 1
});
progress.offsetWidth; /* Repaint */
setTimeout(function() {
css(progress, {
transition: 'all ' + speed + 'ms linear',
opacity: 0
});
setTimeout(function() {
NProgress.remove();
next();
}, speed);
}, speed);
} else {
setTimeout(next, speed);
}
});
return this;
};
NProgress.isStarted = function() {
return typeof NProgress.status === 'number';
};
/**
* Shows the progress bar.
* This is the same as setting the status to 0%, except that it doesn't go backwards.
*
* NProgress.start();
*
*/
NProgress.start = function() {
if (!NProgress.status) NProgress.set(0);
var work = function() {
setTimeout(function() {
if (!NProgress.status) return;
NProgress.trickle();
work();
}, Settings.trickleSpeed);
};
if (Settings.trickle) work();
return this;
};
/**
* Hides the progress bar.
* This is the *sort of* the same as setting the status to 100%, with the
* difference being `done()` makes some placebo effect of some realistic motion.
*
* NProgress.done();
*
* If `true` is passed, it will show the progress bar even if its hidden.
*
* NProgress.done(true);
*/
NProgress.done = function(force) {
if (!force && !NProgress.status) return this;
return NProgress.inc(0.3 + 0.5 * Math.random()).set(1);
};
/**
* Increments by a random amount.
*/
NProgress.inc = function(amount) {
var n = NProgress.status;
if (!n) {
return NProgress.start();
} else if(n > 1) {
return;
} else {
if (typeof amount !== 'number') {
if (n >= 0 && n < 0.2) { amount = 0.1; }
else if (n >= 0.2 && n < 0.5) { amount = 0.04; }
else if (n >= 0.5 && n < 0.8) { amount = 0.02; }
else if (n >= 0.8 && n < 0.99) { amount = 0.005; }
else { amount = 0; }
}
n = clamp(n + amount, 0, 0.994);
return NProgress.set(n);
}
};
NProgress.trickle = function() {
return NProgress.inc();
};
/**
* Waits for all supplied jQuery promises and
* increases the progress as the promises resolve.
*
* @param $promise jQUery Promise
*/
(function() {
var initial = 0, current = 0;
NProgress.promise = function($promise) {
if (!$promise || $promise.state() === "resolved") {
return this;
}
if (current === 0) {
NProgress.start();
}
initial++;
current++;
$promise.always(function() {
current--;
if (current === 0) {
initial = 0;
NProgress.done();
} else {
NProgress.set((initial - current) / initial);
}
});
return this;
};
})();
/**
* (Internal) renders the progress bar markup based on the `template`
* setting.
*/
NProgress.render = function(fromStart) {
if (NProgress.isRendered()) return document.getElementById('nprogress');
addClass(document.documentElement, 'nprogress-busy');
var progress = document.createElement('div');
progress.id = 'nprogress';
progress.innerHTML = Settings.template;
var bar = progress.querySelector(Settings.barSelector),
perc = fromStart ? '-100' : toBarPerc(NProgress.status || 0),
parent = isDOM(Settings.parent)
? Settings.parent
: document.querySelector(Settings.parent),
spinner
css(bar, {
transition: 'all 0 linear',
transform: 'translate3d(' + perc + '%,0,0)'
});
if (!Settings.showSpinner) {
spinner = progress.querySelector(Settings.spinnerSelector);
spinner && removeElement(spinner);
}
if (parent != document.body) {
addClass(parent, 'nprogress-custom-parent');
}
parent.appendChild(progress);
return progress;
};
/**
* Removes the element. Opposite of render().
*/
NProgress.remove = function() {
removeClass(document.documentElement, 'nprogress-busy');
var parent = isDOM(Settings.parent)
? Settings.parent
: document.querySelector(Settings.parent)
removeClass(parent, 'nprogress-custom-parent')
var progress = document.getElementById('nprogress');
progress && removeElement(progress);
};
/**
* Checks if the progress bar is rendered.
*/
NProgress.isRendered = function() {
return !!document.getElementById('nprogress');
};
/**
* Determine which positioning CSS rule to use.
*/
NProgress.getPositioningCSS = function() {
// Sniff on document.body.style
var bodyStyle = document.body.style;
// Sniff prefixes
var vendorPrefix = ('WebkitTransform' in bodyStyle) ? 'Webkit' :
('MozTransform' in bodyStyle) ? 'Moz' :
('msTransform' in bodyStyle) ? 'ms' :
('OTransform' in bodyStyle) ? 'O' : '';
if (vendorPrefix + 'Perspective' in bodyStyle) {
// Modern browsers with 3D support, e.g. Webkit, IE10
return 'translate3d';
} else if (vendorPrefix + 'Transform' in bodyStyle) {
// Browsers without 3D support, e.g. IE9
return 'translate';
} else {
// Browsers without translate() support, e.g. IE7-8
return 'margin';
}
};
/**
* Helpers
*/
function isDOM (obj) {
if (typeof HTMLElement === 'object') {
return obj instanceof HTMLElement
}
return (
obj &&
typeof obj === 'object' &&
obj.nodeType === 1 &&
typeof obj.nodeName === 'string'
)
}
function clamp(n, min, max) {
if (n < min) return min;
if (n > max) return max;
return n;
}
/**
* (Internal) converts a percentage (`0..1`) to a bar translateX
* percentage (`-100%..0%`).
*/
function toBarPerc(n) {
return (-1 + n) * 100;
}
/**
* (Internal) returns the correct CSS for changing the bar's
* position given an n percentage, and speed and ease from Settings
*/
function barPositionCSS(n, speed, ease) {
var barCSS;
if (Settings.positionUsing === 'translate3d') {
barCSS = { transform: 'translate3d('+toBarPerc(n)+'%,0,0)' };
} else if (Settings.positionUsing === 'translate') {
barCSS = { transform: 'translate('+toBarPerc(n)+'%,0)' };
} else {
barCSS = { 'margin-left': toBarPerc(n)+'%' };
}
barCSS.transition = 'all '+speed+'ms '+ease;
return barCSS;
}
/**
* (Internal) Queues a function to be executed.
*/
var queue = (function() {
var pending = [];
function next() {
var fn = pending.shift();
if (fn) {
fn(next);
}
}
return function(fn) {
pending.push(fn);
if (pending.length == 1) next();
};
})();
/**
* (Internal) Applies css properties to an element, similar to the jQuery
* css method.
*
* While this helper does assist with vendor prefixed property names, it
* does not perform any manipulation of values prior to setting styles.
*/
var css = (function() {
var cssPrefixes = [ 'Webkit', 'O', 'Moz', 'ms' ],
cssProps = {};
function camelCase(string) {
return string.replace(/^-ms-/, 'ms-').replace(/-([\da-z])/gi, function(match, letter) {
return letter.toUpperCase();
});
}
function getVendorProp(name) {
var style = document.body.style;
if (name in style) return name;
var i = cssPrefixes.length,
capName = name.charAt(0).toUpperCase() + name.slice(1),
vendorName;
while (i--) {
vendorName = cssPrefixes[i] + capName;
if (vendorName in style) return vendorName;
}
return name;
}
function getStyleProp(name) {
name = camelCase(name);
return cssProps[name] || (cssProps[name] = getVendorProp(name));
}
function applyCss(element, prop, value) {
prop = getStyleProp(prop);
element.style[prop] = value;
}
return function(element, properties) {
var args = arguments,
prop,
value;
if (args.length == 2) {
for (prop in properties) {
value = properties[prop];
if (value !== undefined && properties.hasOwnProperty(prop)) applyCss(element, prop, value);
}
} else {
applyCss(element, args[1], args[2]);
}
}
})();
/**
* (Internal) Determines if an element or space separated list of class names contains a class name.
*/
function hasClass(element, name) {
var list = typeof element == 'string' ? element : classList(element);
return list.indexOf(' ' + name + ' ') >= 0;
}
/**
* (Internal) Adds a class to an element.
*/
function addClass(element, name) {
var oldList = classList(element),
newList = oldList + name;
if (hasClass(oldList, name)) return;
// Trim the opening space.
element.className = newList.substring(1);
}
/**
* (Internal) Removes a class from an element.
*/
function removeClass(element, name) {
var oldList = classList(element),
newList;
if (!hasClass(element, name)) return;
// Replace the class name.
newList = oldList.replace(' ' + name + ' ', ' ');
// Trim the opening and closing spaces.
element.className = newList.substring(1, newList.length - 1);
}
/**
* (Internal) Gets a space separated list of the class names on the element.
* The list is wrapped with a single space on each end to facilitate finding
* matches within the list.
*/
function classList(element) {
return (' ' + (element && element.className || '') + ' ').replace(/\s+/gi, ' ');
}
/**
* (Internal) Removes an element from the DOM.
*/
function removeElement(element) {
element && element.parentNode && element.parentNode.removeChild(element);
}
return NProgress;
});
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
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
+1
View File
@@ -0,0 +1 @@
function waterfall(a){function b(a,b){var c=window.getComputedStyle(b);return parseFloat(c["margin"+a])||0}function c(a){return a+"px"}function d(a){return parseFloat(a.style.top)}function e(a){return parseFloat(a.style.left)}function f(a){return a.clientWidth}function g(a){return a.clientHeight}function h(a){return d(a)+g(a)+b("Bottom",a)}function i(a){return e(a)+f(a)+b("Right",a)}function j(a){a=a.sort(function(a,b){return h(a)===h(b)?e(b)-e(a):h(b)-h(a)})}function k(b){f(a)!=t&&(b.target.removeEventListener(b.type,arguments.callee),waterfall(a))}"string"==typeof a&&(a=document.querySelector(a));var l=[].map.call(a.children,function(a){return a.style.position="absolute",a});a.style.position="relative";var m=[];l.length&&(l[0].style.top="0px",l[0].style.left=c(b("Left",l[0])),m.push(l[0]));for(var n=1;n<l.length;n++){var o=l[n-1],p=l[n],q=i(o)+f(p)<=f(a);if(!q)break;p.style.top=o.style.top,p.style.left=c(i(o)+b("Left",p)),m.push(p)}for(;n<l.length;n++){j(m);var p=l[n],r=m.pop();p.style.top=c(h(r)+b("Top",p)),p.style.left=c(e(r)),m.push(p)}j(m);var s=m[0];a.style.height=c(h(s)+b("Bottom",s));var t=f(a);window.addEventListener?window.addEventListener("resize",k):document.body.onresize=k}
+659
View File
@@ -0,0 +1,659 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title = ${'追番' + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container">
<div id="article-container">
<style>
.bangumi-tabs {
margin-bottom: 15px;
margin-top: 15px
}
#article-container {
overflow-wrap: break-word;
padding: 10px;
}
#article-container a:not(.rss-plan-item) {
color: rgb(48, 122, 246);
}
#article-container a:not(.rss-plan-item):hover {
text-decoration: underline;
}
#article-container img {
display: block;
margin: 0px auto 0.8rem;
}
/* 文章字号 */
#article-container p {
font-size: 0.9rem;
line-height: 1.7;
font-weight: 400;
}
#article-container p {
margin: 1rem 0;
text-align: left;
letter-spacing: 0.6px;
}
/* 文章中的超链接 */
#article-container a:not(.rss-plan-item) {
text-decoration: none;
border-bottom: 2px solid #23ea6f;
color: #069d53;
font-weight: bold;
padding: 0 4px;
border-radius: 4px 4px 0 0;
}
#article-container a:not(.fancybox):not(.rss-plan-item):hover {
opacity: 1;
text-decoration: none;
border-bottom: 2px solid #00000000;
color: #00bb5e;
background: #23ea6f;
border-radius: 4px;
box-shadow: var(--accent-shadow);
}
/* 文章图片 */
#article-container img {
border-radius: 12px;
margin-bottom: 0.5rem;
object-fit: cover;
}
.bangumi-tab {
padding: 5px
}
a.bangumi-tab {
text-decoration: none
}
.bangumi-active {
background: #657b83;
color: #fff
}
.bangumi-item {
position: relative;
clear: both;
padding: 10px 0;
border-bottom: 1px solid #ddd;
min-height: 180px
}
@media screen and (max-width: 600px) {
.bangumi-item {
width: 100%
}
}
.bangumi-picture {
position: absolute;
left: 0;
top: 10px;
width: 110px
}
.bangumi-picture img {
margin: 10px 0
}
.bangumi-info {
padding-left: 120px;
margin-top: 10px
}
.bangumi-meta {
font-size: 12px;
padding-right: 10px;
height: 45px
}
.bangumi-comments {
min-height: 5.1rem;
font-size: 12px;
margin-top: 10px
}
.bangumi-comments > p {
word-break: break-all;
text-overflow: ellipsis;
overflow: hidden;
white-space: normal;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3
}
.bangumi-pagination {
margin-top: 15px;
text-align: center;
margin-bottom: 10px
}
.bangumi-button {
padding: 5px
}
.bangumi-button:hover {
background: #657b83;
color: #fff
}
.bangumi-hide {
display: none
}
.bangumi-show {
display: block
}
.bangumi-title {
font-size: 18px
}
.bangumi-title a {
line-height: 1;
text-decoration: none
}
.bangumi-info-items {
font-size: 11px;
color: #2fd8d8;
padding-top: 10px;
line-height: 1;
float: left;
width: 100%
}
.bangumi-info-item {
display: inline-block;
width: 13%;
border-right: 1px solid #2fd8d8;
text-align: center;
height: 34px
}
.bangumi-info-label {
display: block;
line-height: 12px
}
.bangumi-info-item em {
display: block;
padding-top: 6px;
line-height: 17px;
font-style: normal;
font-weight: 700
}
.bangumi-info-total {
padding-top: 11px;
display: block;
line-height: 12px;
font-weight: 700
}
.bangumi-info-item-score {
border-right: 1px solid #0000;
width: 50px
}
.bangumi-info-label-em {
color: transparent;
opacity: 0;
visibility: hidden;
line-height: 6px !important;
padding: 0 !important
}
@media (max-width: 650px) {
.bangumi-coin,
.bangumi-type {
display: none
}
.bangumi-info-item {
width: 16%
}
}
@media (max-width: 590px) {
.bangumi-danmaku,
.bangumi-wish {
display: none
}
.bangumi-info-item {
width: 19%
}
}
@media (max-width: 520px) {
.bangumi-doing,
.bangumi-play {
display: none
}
.bangumi-info-item {
width: 24%
}
}
@media (max-width: 480px) {
.bangumi-collect,
.bangumi-follow {
display: none
}
.bangumi-info-item {
width: 30%
}
}
@media (max-width: 400px) {
.bangumi-area {
display: none
}
.bangumi-info-item {
width: 45%
}
}
.bangumi-my-comments {
border: 1px dashed #8f8f8f;
padding: 3px;
border-radius: 5px;
margin-left: -120px
}
.bangumi-starstop {
background: url(https://cdn.jsdelivr.net/npm/hexo-bilibili-bangumi@1.7.9/lib/img/rate_star_2x.png) 100% 100%/10px 19.5px repeat-x;
height: 10px;
width: 50px;
display: inline-block;
float: none
}
.bangumi-starlight {
background: url(https://cdn.jsdelivr.net/npm/hexo-bilibili-bangumi@1.7.9/lib/img/rate_star_2x.png) 0 0/10px 19.5px repeat-x;
height: 10px;
display: block;
width: 100%
}
.bangumi-starlight.stars1 {
width: 5px
}
.bangumi-starlight.stars2 {
width: 10px
}
.bangumi-starlight.stars3 {
width: 15px
}
.bangumi-starlight.stars4 {
width: 20px
}
.bangumi-starlight.stars5 {
width: 25px
}
.bangumi-starlight.stars6 {
width: 30px
}
.bangumi-starlight.stars7 {
width: 35px
}
.bangumi-starlight.stars8 {
width: 40px
}
.bangumi-starlight.stars9 {
width: 45px
}
.bangumi-starlight.stars10 {
width: 50px
}
#article-container .bangumi-picture a {
padding-left: 0px;
padding-right: 0px;
border-bottom-width: 0px;
}
#article-container .bangumi-tab.bangumi-active {
background: #c6dbce;
color: #00bb5e;
border-radius: 10px;
}
#article-container .bangumi-tabs .bangumi-tab {
border-bottom: none !important;
border-radius: 10px;
}
#article-container .bangumi-tabs a.bangumi-tab:hover {
text-decoration: none !important;
border-radius: 10px;
}
#article-container .bangumi-pagination a.bangumi-button {
border-bottom: none;
border-radius: 10px;
}
.bangumi-button:hover {
background: #23ea6f !important;
border-radius: 10px !important;
color: #c6dbce !important;
}
a.bangumi-button.bangumi-nextpage:hover {
text-decoration: none !important;
}
.bangumi-button {
padding: 5px 10px !important;
}
a.bangumi-tab {
padding: 5px 10px !important;
}
svg.icon.faa-tada {
font-size: 1.1em;
}
.bangumi-info-item {
border-right: 1px solid #00bb5e;
}
.bangumi-info-item span {
color: #00bb5e;
}
.bangumi-info-item em {
color: #00bb5e;
}
.bangumi-pagenum {
color: #00bb5e;
}
.dark #article-container .bangumi-tab.bangumi-active{
background: #c6dbce ;
}
.dark #article-container .bangumi-tab,.dark .bangumi-title,.dark .bangumi-info .bangumi-title a{
color: #e5e8ff ;
}
.dark .bangumi-comments{
color: var(--text-color) ;
}
</style>
<style th:if="${theme.config.style.theme_set == 'purple-gay'}">
/* 文章中的超链接 */
#article-container a:not(.rss-plan-item) {
text-decoration: none;
border-bottom: 2px solid #9498CDFF;
color: var(--text-a);
font-weight: bold;
padding: 0 4px;
border-radius: 4px 4px 0 0;
}
#article-container a:not(.fancybox):not(.rss-plan-item):hover {
opacity: 1;
text-decoration: none;
border-bottom: 2px solid #00000000;
color: var(--background-primary);
background: #9498CDFF;
border-radius: 4px;
box-shadow: var(--accent-shadow);
}
#article-container .bangumi-tab.bangumi-active {
background: #3B3EFFFF;
color: #9498CDFF;
border-radius: 10px;
}
.dark #article-container .bangumi-tab.bangumi-active{
background: #2B48FFFF;
}
.bangumi-button:hover {
background: #9498CDFF !important;
border-radius: 10px !important;
color: var(--heave-text-color) !important;
}
a.bangumi-button.bangumi-nextpage:hover {
text-decoration: none !important;
}
.bangumi-button {
padding: 5px 10px !important;
}
a.bangumi-tab {
padding: 5px 10px !important;
}
svg.icon.faa-tada {
font-size: 1.1em;
}
.bangumi-info-item {
border-right: 1px solid var(--heave-text-color);
}
.bangumi-info-item span {
color: var(--heave-text-color);
}
.bangumi-info-item em {
color: var(--heave-text-color);
}
.bangumi-pagenum {
color: var(--heave-text-color);
}
</style>
<div class="bangumi-tabs">
<a class="bangumi-tab" id="bangumi-tab1" href="javascript:;" rel="external" target="_self"
onclick="return false" data-pjax-state="">
想看
([[${bangumiFinder.getDataTotal(1,1)}]])</a>
<a class="bangumi-tab bangumi-active" id="bangumi-tab2" href="javascript:;" rel="external"
target="_self" onclick="return false" data-pjax-state="">
在看
([[${bangumiFinder.getDataTotal(1,2)}]])</a>
<a class="bangumi-tab" id="bangumi-tab3" href="javascript:;" rel="external" target="_self"
onclick="return false" data-pjax-state="">
已看
([[${bangumiFinder.getDataTotal(1,3)}]])</a>
</div>
<div>
<div id="bangumi-item1" class="bangumi-hide">
<th:block th:each="bangumi : ${bangumiFinder.getBiliDataAll(1,1)}">
<th:block th:replace="~{macro/bangumi-item :: bangumi-item(${bangumi.spec})}"/>
</th:block>
<div class="bangumi-pagination">
<a class="bangumi-button bangumi-firstpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state=""> 首页</a>
<a class="bangumi-button bangumi-previouspage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">上一页</a>
<span class="bangumi-pagenum">1 / 1</span>
<a class="bangumi-button bangumi-nextpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">下一页</a>
<a class="bangumi-button bangumi-lastpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">尾页</a>
</div>
</div>
<div id="bangumi-item2" class="bangumi-show">
<th:block th:each="bangumi : ${bangumiFinder.getBiliDataAll(1,2)}">
<th:block th:replace="~{macro/bangumi-item :: bangumi-item(${bangumi.spec})}"/>
</th:block>
<div class="bangumi-pagination">
<a class="bangumi-button bangumi-firstpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state=""> 首页</a>
<a class="bangumi-button bangumi-previouspage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">上一页</a>
<span class="bangumi-pagenum">1 / 1</span>
<a class="bangumi-button bangumi-nextpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">下一页</a>
<a class="bangumi-button bangumi-lastpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">尾页</a>
</div>
</div>
<div id="bangumi-item3" class="bangumi-hide">
<th:block th:each="bangumi : ${bangumiFinder.getBiliDataAll(1,3)}">
<th:block th:replace="~{macro/bangumi-item :: bangumi-item(${bangumi.spec})}"/>
</th:block>
<div class="bangumi-pagination">
<a class="bangumi-button bangumi-firstpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state=""> 首页</a>
<a class="bangumi-button bangumi-previouspage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">上一页</a>
<span class="bangumi-pagenum">1 / 1</span>
<a class="bangumi-button bangumi-nextpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">下一页</a>
<a class="bangumi-button bangumi-lastpage" href="javascript:;" target="_self"
onclick="return false" data-pjax-state="">尾页</a>
</div>
</div>
</div>
<script>
(function () {
const bangumiLazyload = false;
"use strict";/* eslint-disable no-plusplus */
(function () {// eslint-disable-next-line func-style
function a() {
this.classList.add("bangumi-active");
for (var a = this.siblings(), b = 0; b < a.length; b++) a[b].classList.remove("bangumi-active");// 显示对应板块
var c = this.id.replace("tab", "item"), d = document.getElementById(c);
d.classList.remove("bangumi-hide"), d.classList.add("bangumi-show"), a = document.getElementById(c).siblings();
for (var e = 0; e < a.length; e++) a[e].classList.remove("bangumi-show"), a[e].classList.add("bangumi-hide")
}
Element.prototype.siblings = function () {
for (var a = [], b = this.parentNode.children, c = 0; c < b.length; c++) b[c] !== this && a.push(b[c]);
return a
};
for (var b = document.getElementsByClassName("bangumi-tab"), c = 0; c < b.length; c++) b[c].onclick = a, b[c].onclick.apply(b[c]);
"undefined" != typeof pagenumsPre && axios.get(new URL("../bangumis.json", window.location.href)).then(function (a) {
if (a.data) {
var b = {
wantWatch: a.data.wantWatch.slice(10).map(function (a) {
return ejs.render(ejsTemplate, {
item: a,
loading: loading,
metaColor: metaColor,
type: type
})
}).join("\n"), watching: a.data.watching.slice(10).map(function (a) {
return ejs.render(ejsTemplate, {
item: a,
loading: loading,
metaColor: metaColor,
type: type
})
}).join("\n"), watched: a.data.watched.slice(10).map(function (a) {
return ejs.render(ejsTemplate, {
item: a,
loading: loading,
metaColor: metaColor,
type: type
})
}).join("\n")
};
document.querySelectorAll("#bangumi-item1>.bangumi-pagination")[0].insertAdjacentHTML("beforeBegin", b.wantWatch), document.querySelectorAll("#bangumi-item2>.bangumi-pagination")[0].insertAdjacentHTML("beforeBegin", b.watching), document.querySelectorAll("#bangumi-item3>.bangumi-pagination")[0].insertAdjacentHTML("beforeBegin", b.watched)
}
})
})();
document.getElementsByClassName('bangumi-tab')[1].click();
/* eslint-disable no-plusplus, func-style */
(function () {
var a = Math.ceil;
function b(b, c) {
return `${b + 1} / ${a(0 == c.length / 10 ? 1 : a(c.length / 10))}`
}
function c() {
const a = this.parentNode.siblings();
g(a, 0), this.parentNode.getElementsByClassName("bangumi-pagenum")[0].innerText = b(0, a)
}
function d() {
const a = this.parentNode.siblings();
let c = this.parentNode.getElementsByClassName("bangumi-pagenum")[0].innerText;
c = c.substr(0, c.indexOf("/") - 1), c = parseInt(c, 10) - 1, 0 < c && c--, g(a, c), this.parentNode.getElementsByClassName("bangumi-pagenum")[0].innerText = b(c, a)
}
function e() {
const c = this.parentNode.siblings();
let d = this.parentNode.getElementsByClassName("bangumi-pagenum")[0].innerText;
d = d.substr(0, d.indexOf("/") - 1), d = parseInt(d, 10) - 1, d < a(c.length / 10) - 1 && d++, g(c, d), this.parentNode.getElementsByClassName("bangumi-pagenum")[0].innerText = b(d, c)
}
function f() {
const c = this.parentNode.siblings();
g(c, a(c.length / 10) - 1), this.parentNode.getElementsByClassName("bangumi-pagenum")[0].innerText = b(-1 == a(c.length / 10) - 1 ? 0 : a(c.length / 10) - 1, c)
}
function g(a, b) {
for (let c = 0; c < a.length; c++) if (Math.floor(c / 10) === b) {
a[c].classList.remove("bangumi-hide");
const [b] = a[c].getElementsByTagName("img");
bangumiLazyload && (b.src = b.getAttribute("data-src"))
} else a[c].classList.add("bangumi-hide")
}
const h = document.getElementsByClassName("bangumi-firstpage"),
j = document.getElementsByClassName("bangumi-previouspage"),
k = document.getElementsByClassName("bangumi-nextpage"),
l = document.getElementsByClassName("bangumi-lastpage"),
m = document.getElementsByClassName("bangumi-pagenum");
for (let b = 0; b < h.length; b++) {
h[b].onclick = c, j[b].onclick = d, k[b].onclick = e, l[b].onclick = f;// set page num
const g = "undefined" == typeof pagenumsPre ? m[b].parentNode.siblings().length : pagenumsPre[b] ?? m[b].parentNode.siblings().length;
h[b].click(), m[b].innerText = `1 / ${0 === a(g / 10) ? 1 : a(g / 10)}`
}
})();
})();
</script>
</div>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+48
View File
@@ -0,0 +1,48 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title = ${'分类' + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container">
<div class="column_page page_wrap" uk-height-viewport="offset-top: true">
<div class="page_inner uk-grid-small uk-child-width-1-2@m" uk-grid>
<div class="column_item" th:each="categoryItem : ${categoryFinder.listAll()}">
<div class="column_inner round12">
<div class="cat_img">
<a th:href="@{${categoryItem.status.permalink}}"
th:with="cover_img=${#strings.contains(theme.config.post.category_banner,'http') ? ((#strings.contains(theme.config.post.category_banner,'?') ? theme.config.post.category_banner : theme.config.post.category_banner+'?')+','+categoryItem.metadata.name): theme.config.post.category_banner}">
<img th:src="${#strings.isEmpty(categoryItem.spec.cover) ? cover_img : thumbnail.gen(categoryItem.spec.cover, 's')}">
<div class="meta">
<div class="title">[[${categoryItem.spec.displayName}]]</div>
<p><span>[[${categoryItem.status.visiblePostCount}]]POSTS</span></p>
</div>
</a>
</div>
<th:block th:with="posts = ${postFinder.listByCategory(1,2,categoryItem.metadata.name)}">
<ul class="column_lists" th:if="${not #lists.isEmpty(posts.items)}">
<li th:each="post : ${posts.items}">
<a th:href="@{${post.status.permalink}}"><i
class="iconfont icon-huati"></i>[[${post.spec.title}]]</a>
<span>[[${#dates.format(post.spec.publishTime,'yyyy/MM/dd')}]]</span>
</li>
</ul>
</th:block>
</div>
</div>
</div>
</div>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+52
View File
@@ -0,0 +1,52 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title = ${'分类' + ': ' + category.spec.displayName + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container">
<main id="primary" class="site-main">
<div class="archive_main" uk-height-viewport="offset-top: true">
<header class="page-header">
<div class="cat_img"><img
th:src="${not #strings.isEmpty(category.spec.cover) ? thumbnail.gen(category.spec.cover, 's') : theme.config.post.category_banner}">
</div>
<div class="cat_title">
<h1 class="page-title">分类: <span>[[${category.spec.displayName}]]</span></h1>
<div class="archive-description" th:text="${category.spec.description}"></div>
</div>
</header>
<div id="post_item" class="archive_list norpost_list " th:with='postItems=${posts.items}'
th:classappend="${theme.config.post.post_list_type == 'grid' ? 'uk-grid-small uk-grid' : ''}">
<th:block th:replace="~{'macro/tpl/content-post'}"></th:block>
<th:block th:if="${#lists.isEmpty(postItems)}">
<th:block th:replace="~{macro/tpl/content-none}"/>
</th:block>
</div>
<div th:if="${posts.hasNext}" class="arc_pagenav">
<a th:data="@{${posts.nextUrl}}" th:text="${theme.config.base_set.site_page}"></a>
</div>
</div>
</main>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+15
View File
@@ -0,0 +1,15 @@
<!doctype html>
<html
xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/gateway_fragments_layout :: layout(title = |#{title} - ${site.title}|, head = null, body = ~{::body})}"
>
<th:block th:fragment="body">
<div class="gateway-wrapper">
<div th:replace="~{modules/gateway_fragments_logo::logo}"></div>
<div class="halo-form-wrapper">
<h1 class="form-title" th:text="#{title}"></h1>
<form th:replace="~{gateway_fragments/totp::form}"></form>
</div>
</div>
</th:block>
</html>
@@ -0,0 +1 @@
title=两步验证
@@ -0,0 +1 @@
title=Two-Factor Authentication
@@ -0,0 +1 @@
title=Autenticación en Dos Pasos
@@ -0,0 +1 @@
title=兩步驗證
+61
View File
@@ -0,0 +1,61 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title = ${title + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}" />
<div id="pjax-container">
<main id="primary" class="site-main">
<div class="page_content" uk-height-viewport="offset-top: true">
<article class="post-276 page type-page status-publish hentry">
<header class="entry-header">
<div class="left">
<i class="ri-focus-2-line"></i>
<h1 class="entry-title" th:text="${title}"></h1>
</div>
</header>
<div class="entry-content single-content">
<section class="db--container">
<nav class="db--nav">
<div th:each="type : ${types}" class="db--navItem JiEun"
th:classappend="${type.key == 'movie' ? 'current' : ''}"
th:data-type="${type.key}" th:text="${type.key}"></div>
</nav>
<div class="db--genres"></div>
<div class="db--type">
<div class="db--typeItem" data-status="mark">想看</div>
<div class="db--typeItem" data-status="doing">在看</div>
<div class="db--typeItem is-active" data-status="done">看过</div>
</div>
<div class="db--list db--list__card" data-type="movie">
</div>
<div class="block-more block-more__centered">
<div class="lds-ripple u-hide">
</div>
</div>
</section>
</div>
</article>
</div>
</main>
</div>
<th:block th:replace="~{modules/footer-main}" />
</div>
</th:block>
</html>
+32
View File
@@ -0,0 +1,32 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title=null)}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container">
<main id="primary" class="site-main">
<div class="nodata_main" uk-height-viewport="offset-top: true" >
<section class="error-404 not-found">
<div class="page-content no_resault">
<img src="/themes/theme-pix/assets/img/404.png">
</div>
</section>
</div>
</main>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+76
View File
@@ -0,0 +1,76 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title = ${title + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container">
<div class="blog_list">
<div class="blog_list_inner" uk-height-viewport="offset-top: true">
<div id="post_item" class="moment_list">
<div th:each="postInfo, iterstat: ${friends.items}" th:id="${'post-'+postInfo.metadata.name}"
class="loop_content p_item moment_item uk-animation-slide-bottom-small"
th:with="spec = ${postInfo.spec}">
<div class="p_item_inner">
<div class="list_user_meta">
<div class="avatar">
<img th:src="@{${spec.logo}}">
</div>
<div class="name">
<div class="avatar_title">
<a target="_blank" th:href="${spec.authorUrl}">[[${spec.author}]]</a>
</div>
<time itemprop="datePublished"
th:datetime="${#dates.format(spec.pubDate, 'yyyy-MM-dd HH:mm')}">
<th:block th:replace="~{modules/widgets/time :: time(${spec.pubDate})}"></th:block>
</time>
</div>
</div>
<div class="blog_content">
<div class="entry-content">
<div class="p_title">
<a target="_blank" th:href="${spec.postLink}"><i class="ri-at-line"></i>[[${spec.title}]]</a>
</div>
<th:block th:with="excerpt = ${#strings.length(spec.description) > 100 ? 100 : #strings.length(spec.description)}">
<div class="t_content" th:text="${#strings.substring(spec.description,0,excerpt)+'...'}">
</div>
</th:block>
</div>
</div>
</div>
</div>
<th:block th:if="${#lists.isEmpty(friends.items)}">
<th:block th:replace="~{macro/tpl/content-none}"/>
</th:block>
</div>
<th:block th:if="${friends.totalPages>1}">
<div id="t_pagination">
<div class="post-paging" th:if="${friends.hasNext()}"
th:with="_page = ${friends.page+1}">
<a th:data="${'/friends/page/'+_page+'?preview-theme=theme-pix'}" th:text="${theme.config.base_set.site_page}"></a>
</div>
</div>
</th:block>
<div id="comment_form_reset"></div>
</div>
</div>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+33
View File
@@ -0,0 +1,33 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title=null)}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container" th:with="page = ${#strings.isEmpty(param.page) ? 1 : param.page}">
<th:block th:if="${theme.config.style.home_post_type=='moment' && pluginFinder.available('PluginMoments')}">
<th:block
th:replace="~{macro/home-moment :: home-moment(${momentFinder.list(page, site.post.postPageSize)},${momentFinder.listAllTags()})}">
</th:block>
</th:block>
<th:block th:if="${theme.config.style.home_post_type=='post' || (not (theme.config.style.home_post_type=='moment' && pluginFinder.available('PluginMoments'))) }">
<th:block th:replace="~{macro/home-blog :: home-blog(${posts},'/')}"></th:block>
</th:block>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+95
View File
@@ -0,0 +1,95 @@
<!DOCTYPE html>
<html lang="zh-CN" xmlns:th="http://www.thymeleaf.org"
th:with="_title = ${singlePage.spec.title + ' - ' + site.title},
site_title = ${not #strings.isEmpty(_title) ? _title : #strings.isEmpty(site.subtitle) ? site.title : site.title +' - ' +site.subtitle }">
<head>
<th:block th:replace="~{modules/head :: head}"></th:block>
</head>
<body
class="page-template page-template-page page-template-landpage page-template-pagelandpage-php page mod_third normal">
<th:block th:if="${theme.config.landing_set.land_type == 'card' } ">
<div class="land_page" th:classappend="(${theme.config.landing_set.land_dark ? 'darkl' : ''})"
uk-height-viewport="offset-top: true">
<div class="land_content">
<div class="land_left"
th:style="${'background-image:url('+theme.config.landing_set.land_feature+')'}"></div>
<div class="land_right uk-animation-slide-bottom-small">
<div class="land_logo"><img th:src="${theme.config.landing_set.land_logo}"></div>
<div class="title">
<p>
[[${theme.config.landing_set.land_title}]]
</p>
</div>
<div class="land_des">
<th:block th:utext="${theme.config.landing_set.land_des}"></th:block>
</div>
<div class="land_nav">
<a th:each="land_btn,iterStat : ${theme.config.landing_set.land_btn}"
th:class="'bt_'+iterStat.index" th:href="${land_btn.link}"
th:target="${land_btn.open_new}">
<i th:class="${land_btn.icon}"></i><span>[[${land_btn.name}]]</span>
</a>
</div>
<div class="footer">
<div class="beian"><a href="" class="beian" target="_blank"></a></div>
<div class="copyright">
[[${theme.config.landing_set.land_diy}]]
</div>
</div>
</div>
</div>
</div>
</th:block>
<th:block th:if="${theme.config.landing_set.land_type == 'simple' } ">
<div class="land_page sim" th:classappend="(${theme.config.landing_set.land_dark ? 'darkl' : ''})"
uk-height-viewport="offset-top: true">
<div class="land_content">
<div class="land_top"
th:style="${'background-image:url('+theme.config.landing_set.land_feature+')'}">
<div class="land_meta">
<div class="land_logo"><img th:src="${theme.config.landing_set.land_logo}"></div>
<div class="title">
[[${theme.config.landing_set.land_title}]]
</div>
</div>
</div>
<div class="land_bottom">
<div class="land_des">
<th:block th:utext="${theme.config.landing_set.land_des}"></th:block>
</div>
<div class="land_nav">
<a th:each="land_btn,iterStat : ${theme.config.landing_set.land_btn}"
th:class="'bt_'+iterStat.index" th:href="${land_btn.link}"
th:target="${land_btn.open_new}">
<i th:class="${land_btn.icon}"></i><span>[[${land_btn.name}]]</span>
</a>
</div>
<div class="diy_html">
<th:block th:utext="${theme.config.landing_set.land_html}"></th:block>
</div>
<div class="footer">
<div class="beian"><a href="" class="beian" target="_blank"></a></div>
<div class="copyright">
[[${theme.config.landing_set.land_diy}]]
</div>
</div>
</div>
</div>
</div>
</th:block>
<th:block th:replace="~{modules/footer}"></th:block>
</body>
</html>
+48
View File
@@ -0,0 +1,48 @@
<!DOCTYPE html>
<html xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/layouts/layout :: layout(_head = null,_content = ~{::content},_title = ${'友链' + ' - ' + site.title})}">
<th:block th:fragment="content">
<div class="page_main uk-width-2-3@m">
<th:block th:replace="~{modules/header}"/>
<div id="pjax-container">
<div class="links_page page_wrap" uk-height-viewport="offset-top: true"
style="min-height: calc(100vh - 332px);">
<div class="page_inner">
<div class="link_group_content"
th:each="group,iterStat : ${groups}"
th:if="${not #lists.isEmpty(group.spec.displayName)}">
<div class="link_cat_name"><i class="ri-bookmark-line"></i>[[${group.spec.displayName}]]</div>
<div id="link_14" class="link_group">
<div class="item" th:title="${link.spec.description}"
th:each="link : ${group.links}">
<div class="link-avatar">
<a th:href="${link.spec.url}" target="_blank">
<img alt="avatar" th:src="${link.spec.logo}"
class="avatar avatar-80" height="80" width="80"></a>
</div>
<div class="info">
<h3 class="name">
<a th:href="${link.spec.url}"
th:text="${link.spec.displayName}"
target="_blank"></a>
</h3>
<div class="meta button">
<a th:href="${link.spec.url}" target="_blank">
<i class="iconfont icon-zhuanfa_3"></i></a>
</div>
<div class="description" th:text="${link.spec.description}"
th:title="${link.spec.description}"></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<th:block th:replace="~{modules/footer-main}"/>
</div>
</th:block>
</html>
+21
View File
@@ -0,0 +1,21 @@
<!doctype html>
<html
xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/gateway_fragments_layout :: layout(title = |#{title} - ${site.title}|, head = null, body = ~{::body})}"
>
<th:block th:fragment="body">
<div class="gateway-wrapper">
<div th:replace="~{modules/gateway_fragments_logo::logo}"></div>
<div class="halo-form-wrapper">
<div th:replace="~{gateway_fragments/login::form}"></div>
<div th:replace="~{gateway_fragments/login::formAuthProviders}"></div>
<div th:replace="~{gateway_fragments/common::socialAuthProviders}"></div>
</div>
<div th:replace="~{gateway_fragments/common::signupNoticeContent}"></div>
<div th:replace="~{gateway_fragments/common::returnToSiteContent}"></div>
<div th:replace="~{gateway_fragments/common::languageSwitcher}"></div>
</div>
</th:block>
</html>
+1
View File
@@ -0,0 +1 @@
title=登录
+1
View File
@@ -0,0 +1 @@
title=Login
+1
View File
@@ -0,0 +1 @@
title=Iniciar Sesión
+1
View File
@@ -0,0 +1 @@
title=登入
+55
View File
@@ -0,0 +1,55 @@
<!DOCTYPE html>
<html
xmlns:th="https://www.thymeleaf.org"
th:replace="~{modules/gateway_fragments_layout:: layout(title = |#{title} - ${site.title}|, head = ~{::head}, body = ~{::body})}"
>
<th:block th:fragment="body">
<div class="gateway-wrapper logout-page-wrapper">
<div th:replace="~{modules/gateway_fragments_logo::logo}"></div>
<div class="halo-form-wrapper">
<h1 class="form-title" th:text="#{form.title}"></h1>
<form th:replace="~{gateway_fragments/logout::form}"></form>
</div>
<div th:replace="~{gateway_fragments/common::languageSwitcher}"></div>
</div>
</th:block>
<th:block th:fragment="head">
<style>
.logout-page-wrapper .user-info {
border-radius: var(--rounded-lg);
padding: var(--spacing-xs);
gap: var(--spacing-lg);
display: flex;
margin-bottom: 2em;
align-items: center;
border: 1px dashed #dfe6ecb3;
}
.logout-page-wrapper .user-avatar {
width: 4em;
border-radius: 100%;
}
.logout-page-wrapper .user-details {
color: var(--color-text);
font-size: var(--text-sm);
gap: var(--spacing-xs);
display: flex;
flex-direction: column;
}
.logout-page-wrapper .user-name {
font-weight: 600;
color: #333;
}
.logout-page-wrapper .cancel-link {
color: var(--color-link);
font-size: var(--text-sm);
text-decoration: none;
text-align: center;
}
</style>
</th:block>
</html>
+2
View File
@@ -0,0 +1,2 @@
title=退出登录
form.title=确定要退出登录吗?
+2
View File
@@ -0,0 +1,2 @@
title=Logout
form.title=Are you sure want to log out?
+2
View File
@@ -0,0 +1,2 @@
title=Cerrar Sesión
form.title=¿Estás seguro de que deseas cerrar sesión?
+2
View File
@@ -0,0 +1,2 @@
title=退出登入
form.title=確定要退出登入嗎?
+50
View File
@@ -0,0 +1,50 @@
<th:block th:fragment="bangumi-item(spec)">
<div class="bangumi-item">
<div class="bangumi-picture">
<img
th:src="${spec.cover}"
referrerpolicy="no-referrer" width="110"
style="width:110px;margin:20px auto;">
</div>
<div class="bangumi-info">
<div class="bangumi-title">
<a target="_blank" th:href="${spec.url}">[[${spec.title}]]</a>
</div>
<div class="bangumi-meta">
<span class="bangumi-info-items">
<span class="bangumi-info-item">
<span class="bangumi-info-total">[[${spec.totalCount}]]</span>
<em class="bangumi-info-label-em">0</em>
</span>
<span class="bangumi-info-item bangumi-area">
<span class="bangumi-info-label">[[${spec.type}]]</span>
<em th:text="${#strings.isEmpty(spec.score)? '未知' :spec.area}"></em>
</span>
<span class="bangumi-info-item bangumi-play">
<span class="bangumi-info-label">总播放</span>
<em th:text="${#strings.isEmpty(spec.score)? '未知' :spec.view}"></em>
</span>
<span class="bangumi-info-item bangumi-follow">
<span class="bangumi-info-label">追番人数</span>
<em th:text="${#strings.isEmpty(spec.score)? '未知' :spec.follow}"></em>
</span>
<span class="bangumi-info-item bangumi-coin">
<span class="bangumi-info-label">硬币数</span>
<em th:text="${#strings.isEmpty(spec.score)? '未知' :spec.coin}"></em>
</span>
<span class="bangumi-info-item bangumi-danmaku">
<span class="bangumi-info-label">弹幕总数</span>
<em th:text="${#strings.isEmpty(spec.score)? '未知' :spec.danmaku}"></em>
</span>
<span class="bangumi-info-item bangumi-info-item-score">
<span class="bangumi-info-label">评分</span>
<em th:text="${#strings.isEmpty(spec.score)? '暂无' :spec.score}"></em>
</span>
</span>
</div>
<div class="bangumi-comments">
<p>[[${spec.des}]]</p>
</div>
</div>
</div>
</th:block>
+44
View File
@@ -0,0 +1,44 @@
<th:block th:fragment="home-blog(_posts,path)">
<div class="normal_list">
<div class="normal_list_inner" uk-height-viewport="offset-top: true">
<div class="posts_cat_nav">
<ul id="cat_nav_items">
<li><a th:data="|${path}?preview-theme=theme-pix|" class="active">全部<span></span></a>
</li>
<li th:if="${theme.config.post.post_nav == 'category'}" th:each="categoryItem,iStat : ${categoryFinder.listAll()}">
<a th:data="|${categoryItem.status.permalink}?preview-theme=theme-pix|"
class="">[[${categoryItem.spec.displayName}]]<span></span></a>
</li>
<li th:if="${theme.config.post.post_nav == 'custom_category'}"
th:each="category : ${theme.config.post.nav_category}">
<th:block th:with="categoryItem = ${categoryFinder.getByName(category)}">
<a th:if="${categoryItem!=null}"
th:data="|${categoryItem.status.permalink}?preview-theme=theme-pix|"
class="">[[${categoryItem.spec.displayName}]]<span></span>
</a>
</th:block>
</li>
</ul>
</div>
<div id="post_item" class="norpost_list " th:with='postItems=${_posts.items}'
th:classappend="${theme.config.post.post_list_type == 'grid' ? 'uk-grid-small uk-grid' : ''}">
<th:block th:replace="~{'macro/tpl/content-post'}"></th:block>
</div>
<th:block th:if="${_posts.totalPages>1}">
<div id="pagination">
<div class="post-paging" th:if="${_posts.hasNext()}"
th:with="_page = ${_posts.page+1},_path = ${path == '/archives' ? path+'?preview-theme=theme-pix&page='+_page : path +'page/'+_page+'?preview-theme=theme-pix' }">
<a th:data="${_path}" th:text="${theme.config.base_set.site_page}"></a>
</div>
</div>
</th:block>
<div id="comment_form_reset">
</div>
</div>
</div>
</th:block>
+39
View File
@@ -0,0 +1,39 @@
<th:block th:fragment="home-moment(_moments,tags)">
<div class="blog_list">
<div class="blog_list_inner" uk-height-viewport="offset-top: true">
<div class="moment_cat_nav">
<ul id="cat_nav_items">
<li><a data="/moments?preview-theme=theme-pix" class="" th:classappend="${#lists.isEmpty(param.tag) ? 'active' : ''}"
><span>全部</span></a>
</li>
<li th:each="tag,iStat : ${tags}">
<a th:data="|/moments?preview-theme=theme-pix&tag=${tag.name}|" class=""
th:classappend="${#lists.contains(param.tag, tag.name) ? 'active' : ''}"
><span>[[${tag.name}]]</span></a>
</li>
</ul>
</div>
<div id="post_item" class="moment_list">
<th:block th:replace="~{macro/tpl/content-moment :: content-moment(${_moments.items})}"></th:block>
<th:block th:if="${#lists.isEmpty(_moments.items)}">
<th:block th:replace="~{macro/tpl/content-none}"/>
</th:block>
</div>
<th:block th:if="${_moments.totalPages>1}">
<div id="t_pagination">
<div class="post-paging" th:if="${_moments.hasNext()}"
th:with="tag = ${not #lists.isEmpty(param.tag) ? '?tag='+param.tag : ''},_page = ${_moments.page+1}">
<a th:data="${'/moments/page/'+_page+tag+'?preview-theme=theme-pix'}" th:text="${theme.config.base_set.site_page}"></a>
</div>
</div>
</th:block>
<div id="comment_form_reset"></div>
</div>
</div>
</th:block>
+52
View File
@@ -0,0 +1,52 @@
<div th:id="${'post-'+post.metadata.name}"
class="loop_content p_item uk-animation-slide-bottom-small" th:classappend="${post.spec.pinned ? 'sticky' :''}">
<div class="normal_item_inner">
<div class="normal_card_content">
<div class="feature round12">
<a th:href="@{${post.status.permalink}}"
th:with="cover_img=${#strings.contains(theme.config.post.post_banner,'http') ? ((#strings.contains(theme.config.post.post_banner,'?') ? theme.config.post.post_banner : theme.config.post.post_banner+'?')+','+post.spec.title): theme.config.post.post_banner}">
<img class="round12 shadow lazy"
th:with="_cover = ${#strings.isEmpty(post.spec.cover) ? cover_img : thumbnail.gen(post.spec.cover, 's')}"
th:data-src="${_cover}" alt="">
</a>
</div>
<div class="card_right">
<div class="entry-content">
<h2 class="entry-title"><a th:href="@{${post.status.permalink}}" rel="bookmark">[[${post.spec.title}]]</a></h2>
<div class="entry_meta">
<span class="nickname">@[[${post.owner.displayName}]]</span> - <time itemprop="datePublished"
th:datetime="${#dates.format(post.spec.publishTime, 'yyyy-MM-dd HH:mm')}">
<th:block th:replace="~{modules/widgets/time :: time(${post.spec.publishTime})}"></th:block></time>
</div>
<th:block th:if="${not #strings.isEmpty(post.status.excerpt)}">
<p th:with="post_word_max = ${#conversions.convert(theme.config.post.post_word_max, 'java.lang.Integer') >= 0 ? theme.config.post.post_word_max : 100 },
excerpt = ${#strings.length(post.status.excerpt) > #conversions.convert(post_word_max, 'java.lang.Integer') ? post_word_max : #strings.length(post.status.excerpt)}">
[[${#strings.substring(post.status.excerpt,0,excerpt)+'...'}]]
</p>
</th:block>
</div>
<div class="entry-footer">
<div class="post_footer_meta">
<div class="left">
<span class="post_views"><i class="ri-eye-line"></i>[[${post.stats.visit}]]</span>
<span class="comnum"><i class="ri-chat-4-line"></i><small>[[${post.stats.comment}]]</small></span>
<a class="up_like " data-action="up" data-key="post" th:data-id="${post.metadata.name}">
<i class="ri-heart-2-line"></i>
<span>[[${post.stats.upvote}]]</span>
</a>
</div>
<div class="right">
<span th:if="${post.spec.pinned}" class="sticky_icon"><i class="ri-fire-line"></i> TOP</span>
<th:block th:if="${not #lists.isEmpty(post.categories)}">
<div class="normal_cat"># [[${post.categories[0].spec.displayName}]]</div>
</th:block>
</div>
</div>
</div>
</div>
</div>
</div>
</div>

Some files were not shown because too many files have changed in this diff Show More