diff --git a/README.md b/README.md index 8e7b5e1c..d915096f 100644 --- a/README.md +++ b/README.md @@ -3,39 +3,47 @@ [![All Contributors](https://img.shields.io/badge/all_contributors-2-orange.svg?style=flat-square)](#contributors-) +![master version](https://img.shields.io/github/package-json/v/liuzhihang/halo-theme-hao/master?color=%231ab1ad&label=master) +![master version](https://img.shields.io/github/package-json/v/liuzhihang/halo-theme-hao/dev?label=dev) +![license](https://img.shields.io/github/license/liuzhihang/halo-theme-hao?color=FF5531) + --- -> Halo-Theme-Ha 移植于 Hexo 社区 [Hexo-Theme-Butterfly](https://github.com/jerryc127/hexo-theme-butterfly) -> ,同时参考了 [Heo](https://blog.zhheo.com/) 的魔改 +预览:[程序员小航](https://liuzhihang.com) + +文档:[语雀](https://www.yuque.com/liuzhihangs/halo-theme-hao) + +> Halo-Theme-Ha 是一款 [Halo2.0](https://github.com/halo-dev/halo) 的博客主题 +> +> 移植于 Hexo 社区 [Hexo-Theme-Butterfly](https://github.com/liuzhihang/halo-theme-hao) 主题中 [Heo](https://blog.zhheo.com/) 的魔改 + +## 安裝 + +### 下载安装 +在 [Release](https://github.com/liuzhihang/halo-theme-hao/releases) 页面下载最新版本 zip 后,通过 Halo Console 后台主题安装处上传即可。 ## 说明 +> 部分功能是使用插件进行支持 -本主题是根据 [Heo](https://blog.zhheo.com/) 的博客进行开发,其中部分功能暂未支持 - -部分功能支持需要安装插件: -- [留言](https://github.com/halo-sigs/plugin-comment-widget) -- [代码高亮](https://github.com/liuzhihang/plugin-prismjs) -- [懒加载](https://github.com/liuzhihang/plugin-lazyload) -- [文章目录](https://github.com/liuzhihang/plugin-tocbot) - -图标 icon 来自于 [iconfont](https://www.iconfont.cn/): -- [Awesome常用免费开源图标](https://www.iconfont.cn/collections/detail?spm=a313x.7781069.1998910419.dc64b3430&cid=11790) - +- [x] 卡片化设计 +- [x] 多栏设置,支持单栏/双栏/三栏/四栏 +- [x] 自定义封面图位置,上部/左侧/右侧 +- [x] 响应式主题 +- [x] 夜间模式 +- [x] 文章阅读模式 +- [X] [文章目录](https://github.com/liuzhihang/plugin-tocbot)(插件) +- [X] [代码高亮/语言/复制](https://github.com/liuzhihang/plugin-prismjs)(插件) +- [ ] 文章搜索 +- [x] 显示字数统计 +- [x] 显示相关文章 +- [x] 文章过期提醒 +- [X] [评论系统](https://github.com/halo-sigs/plugin-comment-widget) +- [x] [懒加载](https://github.com/liuzhihang/plugin-lazyload) +- [x] 其他功能 ## 预览 -## 支持的功能 - -- [x] 适配 Halo 最新 2.0 版本 - -## 更新日志 - -- 2022-10-20 发布 - -## 安装 - -从 tag 处直接下载 zip 包,在 Halo2.0 后台上传即可。 ## 许可证 diff --git a/settings.yaml b/settings.yaml index 5b4858c9..bb8d3d9d 100644 --- a/settings.yaml +++ b/settings.yaml @@ -10,20 +10,11 @@ spec: - $formkit: menuRadio name: left_menu label: 导航栏左侧相关链接 - - $formkit: radio - name: right_menu - label: 右侧四个按钮 - value: true - options: - - label: 显示 - value: true - - label: 隐藏 - value: false - $formkit: text name: site_title label: 标题 placeholder: 请输入标题 - help: 支持 HTML 语法,比如 Hao,默认为站点名称 + help: '支持 HTML 语法,比如 ,留空为站点名称' - group: top label: 顶部 formSchema: @@ -37,8 +28,8 @@ spec: - label: 隐藏 value: false - $formkit: radio - name: time_list - label: 日志模块 + name: moment + label: 说说模块 value: true options: - label: 显示 @@ -70,6 +61,30 @@ spec: label: 必看精选 placeholder: 请输入地址 validation: "url" + - $formkit: radio + name: todayRecommend + label: 今日推荐 + value: false + options: + - label: 显示 + value: true + - label: 隐藏 + value: false + - $formkit: url + name: todayRecommendUrl + label: 今日推荐跳转地址 + placeholder: 请输入地址 + validation: "url" + - $formkit: text + name: todayRecommendTitle + label: 今日推荐标题 + placeholder: 请输入标题 + value: "今日推荐" + - $formkit: url + name: todayRecommendCover + label: 今日推荐背景图 + placeholder: 请输入地址 + validation: "url" - group: layout label: 布局 formSchema: @@ -203,13 +218,13 @@ spec: label: 版权声明 placeholder: '本文是原创文章,采用 CC BY-NC-ND 4.0 协议,完整转载请注明来自 程序员小航' help: "版权声明内容,支持填入 HTML 标签" - - group: right_menu + - group: rightMenu label: 右键菜单 formSchema: - $formkit: radio name: switch label: 开关 - value: true + value: false options: - label: 打开 value: true diff --git a/templates/assets/js/heo.js b/templates/assets/js/heo.js index 7e65c338..360c0250 100644 --- a/templates/assets/js/heo.js +++ b/templates/assets/js/heo.js @@ -1,126 +1,460 @@ -"use strict"; -var heo_keyboard = !0, heo = { +let heo_cookiesTime = null; +let heo_musicPlaying = false; +let heo_keyboard = false; +let heo_intype = false; +// 私有函数 +var heo = { + // 检测显示模式 darkModeStatus: function () { - "light" == ("dark" === document.documentElement.getAttribute("data-theme") ? "dark" : "light") ? $(".menu-darkmode-text").text("深色模式") : $(".menu-darkmode-text").text("浅色模式") + let theme = document.documentElement.getAttribute('data-theme') === 'dark' ? 'dark' : 'light' + if (theme == 'light') { + $(".menu-darkmode-text").text("深色模式"); + } else { + $(".menu-darkmode-text").text("浅色模式"); + } }, + //bb添加时间 + changeTimeInEssay: function () { + const relativeDate = function (selector) { + selector.forEach(item => { + const $this = item + const timeVal = $this.getAttribute('datetime') + $this.innerText = btf.diffDate(timeVal, true) + $this.style.display = 'inline' + }) + } + + if (document.querySelector('#comment')) { + relativeDate(document.querySelectorAll('#comment time')) + } + }, + + // 首页bb + initIndexEssay: function () { + if (document.querySelector('#comment-list')) { + var swiper = new Swiper('.swiper-container', { + direction: 'vertical', // 垂直切换选项 + loop: true, + autoplay: { + delay: 3000, + pauseOnMouseEnter: true + }, + }); + } + }, + + + // 只在首页显示 onlyHome: function () { - var e = window.location.pathname; - "/" == (e = decodeURIComponent(e)) ? $(".only-home").attr("style", "display: flex") : $(".only-home").attr("style", "display: none") + var urlinfo = window.location.pathname; + urlinfo = decodeURIComponent(urlinfo); + if (urlinfo == '/') { + $('.only-home').attr('style', 'display: flex'); + } else { + $('.only-home').attr('style', 'display: none'); + } }, + //是否在首页 is_Post: function () { - return 0 <= window.location.href.indexOf("/p/") + var url = window.location.href; //获取url + if (url.indexOf("/p/") >= 0) { //判断url地址中是否包含code字符串 + return true; + } else { + return false; + } }, + + //监测是否在页面开头 addNavBackgroundInit: function () { - var e, t = 0, o = 0; - document.body && (t = document.body.scrollTop), document.documentElement && (o = document.documentElement.scrollTop), e = 0 < t - o ? t : o, 0 != e && (document.getElementById("page-header").classList.add("nav-fixed"), document.getElementById("page-header").classList.add("nav-visible"), $("#cookies-window").hide(), console.log("已添加class")) + var scrollTop = 0, bodyScrollTop = 0, documentScrollTop = 0; + if (document.body) { + bodyScrollTop = document.body.scrollTop; + } + if (document.documentElement) { + documentScrollTop = document.documentElement.scrollTop; + } + scrollTop = (bodyScrollTop - documentScrollTop > 0) ? bodyScrollTop : documentScrollTop; + // console.log("滚动高度"+ scrollTop) + + if (scrollTop != 0) { + document.getElementById("page-header").classList.add("nav-fixed"); + document.getElementById("page-header").classList.add("nav-visible"); + $('#cookies-window').hide() + console.log("已添加class") + } }, + // 标签页面 + //分类条 tagPageActive: function () { - var e = window.location.pathname, e = decodeURIComponent(e); - console.log(e); - var t, o, n = /\/tags\/.*?\//.test(e); - console.log(n), n && (t = e.split("/"), console.log(t[2]), o = t[2], document.querySelector("#tag-page-tags") && document.getElementById(o).classList.add("select")) + var urlinfo = window.location.pathname; + urlinfo = decodeURIComponent(urlinfo) + // console.log(urlinfo); + // 验证是否是分类链接 + var pattern = /\/tags\/.*?\//; + var patbool = pattern.test(urlinfo); + // console.log(patbool); + // 获取当前的分类 + if (patbool) { + var valuegroup = urlinfo.split("/"); + // console.log(valuegroup[2]); + // 获取当前分类 + var nowCategorie = valuegroup[2]; + if (document.querySelector('#tag-page-tags')) { + $('a').removeClass('select') + document.getElementById(nowCategorie).classList.add("select"); + } + } }, + //分类条 categoriesBarActive: function () { - document.querySelector("#category-bar") && $(".category-bar-item").removeClass("select"); - var e, t = window.location.pathname, t = decodeURIComponent(t); - "/" == t ? document.querySelector("#category-bar") && document.getElementById("category-bar-home").classList.add("select") : /\/categories\/.*?\//.test(t) && (e = t.split("/")[2], document.querySelector("#category-bar") && document.getElementById(e).classList.add("select")) + if (document.querySelector('#category-bar')) { + $(".category-bar-item").removeClass("select") + } + var urlinfo = window.location.pathname; + urlinfo = decodeURIComponent(urlinfo); + // console.log(urlinfo); + //判断是否是首页 + if (urlinfo == '/') { + if (document.querySelector('#category-bar')) { + document.getElementById('category-bar-home').classList.add("select"); + } + } else { + // 验证是否是分类链接 + var pattern = /\/categories\/.*?\//; + var patbool = pattern.test(urlinfo); + // console.log(patbool); + // 获取当前的分类 + if (patbool) { + var valuegroup = urlinfo.split("/"); + // console.log(valuegroup[2]); + // 获取当前分类 + var nowCategorie = valuegroup[2]; + if (document.querySelector('#category-bar')) { + document.getElementById(nowCategorie).classList.add("select"); + } + } + } }, + // 页脚友链 + addFriendLinksInFooter: function () { + var fetchUrl = "https://moments.zhheo.com/randomfriend?num=3" + fetch(fetchUrl) + .then(res => res.json()) + .then(json => { + var randomFriendLinks = getArrayItems(json, 3); + + var htmlText = ''; + for (let i = 0; i < randomFriendLinks.length; ++i) { + var item = randomFriendLinks[i] + htmlText += `${item.name}`; + } + htmlText += `更多` + document.getElementById("friend-links-in-footer").innerHTML = htmlText; + }) + }, + + //禁止图片右键单击 stopImgRightDrag: function () { - $("img").on("dragstart", function () { - return !1 - }) + var img = $("img"); + img.on("dragstart", function () { + return false; + }); }, + //置顶文章横向滚动 topPostScroll: function () { - var o; - document.getElementById("recent-post-top") && (o = document.getElementById("recent-post-top")).addEventListener("mousewheel", function (e) { - var t = -e.wheelDelta / 2; - o.scrollLeft += t, document.body.clientWidth < 1300 && e.preventDefault() - }, !1) + if (document.getElementById("recent-post-top")) { + let xscroll = document.getElementById("recent-post-top"); + xscroll.addEventListener("mousewheel", function (e) { + //计算鼠标滚轮滚动的距离 + let v = -e.wheelDelta / 2; + xscroll.scrollLeft += v; + //阻止浏览器默认方法 + if (document.body.clientWidth < 1300) { + e.preventDefault(); + } + }, false); + } }, topCategoriesBarScroll: function () { - var o; - document.getElementById("category-bar-items") && (o = document.getElementById("category-bar-items")).addEventListener("mousewheel", function (e) { - var t = -e.wheelDelta / 2; - o.scrollLeft += t, e.preventDefault() - }, !1) + if (document.getElementById("category-bar-items")) { + let xscroll = document.getElementById("category-bar-items"); + xscroll.addEventListener("mousewheel", function (e) { + //计算鼠标滚轮滚动的距离 + let v = -e.wheelDelta / 2; + xscroll.scrollLeft += v; + //阻止浏览器默认方法 + e.preventDefault(); + }, false); + } }, + //作者卡片问好 sayhi: function () { - document.querySelector("#author-info__sayhi") && (document.getElementById("author-info__sayhi").innerHTML = getTimeState() + "!我是") + if (document.querySelector('#author-info__sayhi')) { + document.getElementById("author-info__sayhi").innerHTML = getTimeState() + "!我是"; + } }, + // 添加标签 addTag: function () { - document.querySelector(".heo-tag-new") && $(".heo-tag-new").append('N'), document.querySelector(".heo-tag-hot") && $(".heo-tag-hot").append('H') + //添加new标签 + if (document.querySelector('.heo-tag-new')) { + $(".heo-tag-new").append(`N`) + } + //添加hot标签 + if (document.querySelector('.heo-tag-hot')) { + $(".heo-tag-hot").append(`H`) + } }, + // 二维码 qrcodeCreate: function () { - document.getElementById("qrcode") && new QRCode(document.getElementById("qrcode"), { - text: window.location.href, - width: 250, - height: 250, - colorDark: "#000", - colorLight: "#ffffff", - correctLevel: QRCode.CorrectLevel.H - }) + if (document.getElementById('qrcode')) { + document.getElementById("qrcode").innerHTML = ""; + var qrcode = new QRCode(document.getElementById("qrcode"), { + text: window.location.href, + width: 250, + height: 250, + colorDark: "#000", + colorLight: "#ffffff", + correctLevel: QRCode.CorrectLevel.H + }); + } }, + // 刷新即刻短文瀑布流 reflashEssayWaterFall: function () { - document.querySelector("#waterfall") && setTimeout(function () { - waterfall("#waterfall"), document.getElementById("waterfall").classList.add("show") - }, 500) + if (document.querySelector('#waterfall')) { + setTimeout(function () { + waterfall('#waterfall'); + document.getElementById("waterfall").classList.add('show'); + }, 500); + } }, + // 即刻短文添加灯箱 addMediumInEssay: function () { - document.querySelector("#waterfall") && mediumZoom(document.querySelectorAll("[data-zoomable]")) + if (document.querySelector('#waterfall')) { + mediumZoom(document.querySelectorAll('[data-zoomable]')) + } }, - downloadImage: function (e, c) { - rm.hideRightMenu(), 0 == rm.downloadimging ? (rm.downloadimging = !0, btf.snackbarShow("正在下载中,请稍后", !1, 1e4), setTimeout(function () { - var a = new Image; - a.setAttribute("crossOrigin", "anonymous"), a.onload = function () { - var e = document.createElement("canvas"); - e.width = a.width, e.height = a.height, e.getContext("2d").drawImage(a, 0, 0, a.width, a.height); - var t = e.toDataURL("image/png"), o = document.createElement("a"), n = new MouseEvent("click"); - o.download = c || "photo", o.href = t, o.dispatchEvent(n) - }, a.src = e, btf.snackbarShow("图片已添加盲水印,请遵守版权协议"), rm.downloadimging = !1 - }, "10000")) : btf.snackbarShow("有正在进行中的下载,请稍后再试") + // 下载图片 + downloadImage: function (imgsrc, name) { //下载图片地址和图片名 + rm.hideRightMenu(); + if (rm.downloadimging == false) { + rm.downloadimging = true; + btf.snackbarShow('正在下载中,请稍后', false, 10000) + setTimeout(function () { + let image = new Image(); + // 解决跨域 Canvas 污染问题 + image.setAttribute("crossOrigin", "anonymous"); + image.onload = function () { + let canvas = document.createElement("canvas"); + canvas.width = image.width; + canvas.height = image.height; + let context = canvas.getContext("2d"); + context.drawImage(image, 0, 0, image.width, image.height); + let url = canvas.toDataURL("image/png"); //得到图片的base64编码数据 + let a = document.createElement("a"); // 生成一个a元素 + let event = new MouseEvent("click"); // 创建一个单击事件 + a.download = name || "photo"; // 设置图片名称 + a.href = url; // 将生成的URL设置为a.href属性 + a.dispatchEvent(event); // 触发a的单击事件 + }; + image.src = imgsrc; + btf.snackbarShow('图片已添加盲水印,请遵守版权协议'); + rm.downloadimging = false; + }, "10000"); + } else { + btf.snackbarShow('有正在进行中的下载,请稍后再试'); + } }, - changeThemeColor: function (e) { - null !== document.querySelector('meta[name="theme-color"]') && document.querySelector('meta[name="theme-color"]').setAttribute("content", e) + //控制评论弹幕 + switchCommentBarrage: function () { + let commentBarrage = document.querySelector('.comment-barrage'); + if (commentBarrage) { + if ($(".comment-barrage").is(":visible")) { + $(".comment-barrage").hide(); + $(".menu-commentBarrage-text").text("显示热评"); + document.querySelector("#consoleCommentBarrage").classList.remove("on"); + localStorage.setItem('commentBarrageSwitch', 'false'); + } else if ($(".comment-barrage").is(":hidden")) { + $(".comment-barrage").show(); + $(".menu-commentBarrage-text").text("关闭热评"); + document.querySelector("#consoleCommentBarrage").classList.add("on"); + localStorage.removeItem('commentBarrageSwitch'); + } + } + rm.hideRightMenu(); }, + //隐藏cookie窗口 + hidecookie: function () { + heo_cookiesTime = setTimeout(() => { + document.getElementById("cookies-window").classList.add('cw-hide'); + setTimeout(() => { + $('#cookies-window').hide() + }, 1000) + }, 3000) + }, + + //隐藏今日推荐 + hideTodayCard: function () { + if (document.getElementById("todayCard")) { + document.getElementById("todayCard").classList.add('hide'); + } + }, + + //更改主题色 + changeThemeColor: function (color) { + if (document.querySelector('meta[name="theme-color"]') !== null) { + document.querySelector('meta[name="theme-color"]').setAttribute('content', color) + } + }, + + //自适应主题色 initThemeColor: function () { - var e, t, o; - heo.is_Post() ? 0 === (window.scrollY || document.documentElement.scrollTop) ? (e = getComputedStyle(document.documentElement).getPropertyValue("--heo-main"), heo.changeThemeColor(e)) : (t = getComputedStyle(document.documentElement).getPropertyValue("--heo-background"), heo.changeThemeColor(t)) : (o = getComputedStyle(document.documentElement).getPropertyValue("--heo-background"), heo.changeThemeColor(o)) + if (heo.is_Post()) { + const currentTop = window.scrollY || document.documentElement.scrollTop + if (currentTop === 0) { + let themeColor = getComputedStyle(document.documentElement).getPropertyValue('--heo-main'); + heo.changeThemeColor(themeColor); + } else { + let themeColor = getComputedStyle(document.documentElement).getPropertyValue('--heo-background'); + heo.changeThemeColor(themeColor); + } + } else { + let themeColor = getComputedStyle(document.documentElement).getPropertyValue('--heo-background'); + heo.changeThemeColor(themeColor); + } }, + //跳转到指定位置 + jumpTo: function (dom) { + $(document).ready(function () { + $("html,body").animate({ + scrollTop: $(dom).eq(i).offset().top + }, 500 /*scroll实现定位滚动*/); /*让整个页面可以滚动*/ + }); + }, + //显示加载动画 showLoading: function () { - document.querySelector("#loading-box").classList.remove("loaded") + document.querySelector("#loading-box").classList.remove("loaded"); + let cardColor = getComputedStyle(document.documentElement).getPropertyValue('--heo-card-bg'); + heo.changeThemeColor(cardColor); }, + //隐藏加载动画 hideLoading: function () { - document.querySelector("#loading-box").classList.add("loaded") + document.querySelector("#loading-box").classList.add("loaded"); }, + //切换音乐播放状态 + musicToggle: function () { + let msgPlay = '播放音乐' // 此處可以更改為你想要顯示的文字 + let msgPause = '暂停音乐' // 同上,但兩處均不建議更改 + if (heo_musicPlaying) { + document.querySelector("#nav-music").classList.remove("playing"); + document.getElementById("menu-music-toggle").innerHTML = msgPlay; + document.getElementById("nav-music-hoverTips").innerHTML = "音乐已暂停"; + document.querySelector("#consoleMusic").classList.remove("on"); + heo_musicPlaying = false; + } else { + document.querySelector("#nav-music").classList.add("playing"); + document.getElementById("menu-music-toggle").innerHTML = msgPause; + document.querySelector("#consoleMusic").classList.add("on"); + heo_musicPlaying = true; + } + document.querySelector('meting-js').aplayer.toggle(); + rm.hideRightMenu(); + }, + + //音乐上一曲 + musicSkipBack: function () { + document.querySelector('meting-js').aplayer.skipBack(); + rm.hideRightMenu(); + }, + + //音乐下一曲 + musicSkipForward: function () { + document.querySelector('meting-js').aplayer.skipForward(); + rm.hideRightMenu(); + }, + + //获取音乐中的名称 + musicGetName: function () { + var x = $('.aplayer-title') + // var x = document.getElementsByClassName('txt'); + // for (var i = x.length - 1; i >= 0; i--) { + // console.log(x[i].innerText) + // } + var arr = [] + for (var i = x.length - 1; i >= 0; i--) { + arr[i] = x[i].innerText + // console.log(x[i].innerText) + } + return arr[0] + }, + + //显示中控台 showConsole: function () { - document.querySelector("#console").classList.add("show") + document.querySelector("#console").classList.add("show"); + heo.initConsoleState(); }, + //隐藏中控台 hideConsole: function () { - document.querySelector("#console").classList.remove("show") + document.querySelector("#console").classList.remove("show"); }, + //快捷键功能开关 keyboardToggle: function () { - heo_keyboard ? (heo_keyboard = !1, document.querySelector("#consoleKeyboard").classList.remove("on"), localStorage.setItem("keyboardToggle", "false")) : (heo_keyboard = !0, document.querySelector("#consoleKeyboard").classList.add("on"), localStorage.setItem("keyboardToggle", "true")) + if (heo_keyboard) { + heo_keyboard = false; + document.querySelector("#consoleKeyboard").classList.remove("on"); + localStorage.setItem('keyboardToggle', 'false'); + } else { + heo_keyboard = true; + document.querySelector("#consoleKeyboard").classList.add("on"); + localStorage.setItem('keyboardToggle', 'true'); + } + }, + + //滚动到指定id + scrollTo: function (id) { + var domTop = document.querySelector(id).offsetTop; + window.scrollTo(0, domTop - 80); + }, + + //隐藏侧边栏 + hideAsideBtn: () => { // Hide aside + const $htmlDom = document.documentElement.classList + $htmlDom.contains('hide-aside') + ? saveToLocal.set('aside-status', 'show', 2) + : saveToLocal.set('aside-status', 'hide', 2) + $htmlDom.toggle('hide-aside') + $htmlDom.contains('hide-aside') + ? document.querySelector("#consoleHideAside").classList.add("on") + : document.querySelector("#consoleHideAside").classList.remove("on") + }, + + //初始化console图标 + initConsoleState: function () { + //初始化隐藏边栏 + const $htmlDom = document.documentElement.classList + $htmlDom.contains('hide-aside') + ? document.querySelector("#consoleHideAside").classList.add("on") + : document.querySelector("#consoleHideAside").classList.remove("on") } -}; \ No newline at end of file +} \ No newline at end of file diff --git a/templates/assets/js/main.js b/templates/assets/js/main.js index eb5ef58e..b25b9b5a 100644 --- a/templates/assets/js/main.js +++ b/templates/assets/js/main.js @@ -1,256 +1,884 @@ -"use strict"; +document.addEventListener('DOMContentLoaded', function () { + const $blogName = document.getElementById('site-name') + let blogNameWidth = $blogName && $blogName.offsetWidth + const $menusEle = document.querySelector('#menus .menus_items') + let menusWidth = $menusEle && $menusEle.offsetWidth + const $searchEle = document.querySelector('#search-button') + let searchWidth = $searchEle && $searchEle.offsetWidth -document.addEventListener("DOMContentLoaded", function () { + const adjustMenu = (change = false) => { + if (change) { + blogNameWidth = $blogName && $blogName.offsetWidth + menusWidth = $menusEle && $menusEle.offsetWidth + searchWidth = $searchEle && $searchEle.offsetWidth + } + const $nav = document.getElementById('nav') + let t + if (window.innerWidth < 768) t = true + else t = blogNameWidth + menusWidth + searchWidth > $nav.offsetWidth - 120 - - let $siteName = document.getElementById("site-name"); - let blogNameWidth = $siteName && $siteName.offsetWidth; - let $menusEle = document.querySelector("#menus .menus_items"); - let menusWidth = $menusEle && $menusEle.offsetWidth; - let $search = document.querySelector("#search-button"); - let searchWidth = $search && $search.offsetWidth; - let $nav = document.getElementById("nav"); - - // 菜单栏调整 - function adjustMenu(init) { - - 0 < arguments.length && void 0 !== init && init && (blogNameWidth = $siteName && $siteName.offsetWidth, menusWidth = $menusEle && $menusEle.offsetWidth, searchWidth = $search && $search.offsetWidth); - - if (window.innerWidth < 768 || blogNameWidth + menusWidth + searchWidth > $nav.offsetWidth - 120) { - $nav.classList.add("hide-menu") + if (t) { + $nav.classList.add('hide-menu') } else { - $nav.classList.remove("hide-menu") + $nav.classList.remove('hide-menu') } } // 初始化header const initAdjust = () => { - adjustMenu(true); - $nav.classList.add("show"); - }; + adjustMenu() + document.getElementById('nav').classList.add('show') + } - // 滚动处理 - function scrollFn() { + // sidebar menus + const sidebarFn = () => { + const $toggleMenu = document.getElementById('toggle-menu') + const $mobileSidebarMenus = document.getElementById('sidebar-menus') + const $menuMask = document.getElementById('menu-mask') + const $body = document.body - const innerHeight = window.innerHeight + 56; + function openMobileSidebar() { + btf.sidebarPaddingR() + $body.style.overflow = 'hidden' + btf.fadeIn($menuMask, 0.5) + $mobileSidebarMenus.classList.add('open') + } + + function closeMobileSidebar() { + $body.style.overflow = '' + $body.style.paddingRight = '' + btf.fadeOut($menuMask, 0.5) + $mobileSidebarMenus.classList.remove('open') + } + + $toggleMenu.addEventListener('click', openMobileSidebar) + + $menuMask.addEventListener('click', e => { + if ($mobileSidebarMenus.classList.contains('open')) { + closeMobileSidebar() + } + }) + + window.addEventListener('resize', e => { + if (btf.isHidden($toggleMenu)) { + if ($mobileSidebarMenus.classList.contains('open')) closeMobileSidebar() + } + }) + } + + /** + * 首頁top_img底下的箭頭 + */ + const scrollDownInIndex = () => { + const $scrollDownEle = document.getElementById('scroll-down') + $scrollDownEle && $scrollDownEle.addEventListener('click', function () { + btf.scrollToDest(document.getElementById('content-inner').offsetTop, 300) + }) + } + + /** + * 代碼 + * 只適用於Hexo默認的代碼渲染 + */ + // const addHighlightTool = function () { + // const highLight = GLOBAL_CONFIG.highlight + // if (!highLight) return + // + // const isHighlightCopy = highLight.highlightCopy + // const isHighlightLang = highLight.highlightLang + // const isHighlightShrink = GLOBAL_CONFIG_SITE.isHighlightShrink + // const highlightHeightLimit = highLight.highlightHeightLimit + // const isShowTool = isHighlightCopy || isHighlightLang || isHighlightShrink !== undefined + // const $figureHighlight = highLight.plugin === 'highlighjs' ? document.querySelectorAll('figure.highlight') : document.querySelectorAll('pre[class*="language-"]') + // + // if (!((isShowTool || highlightHeightLimit) && $figureHighlight.length)) return + // + // const isPrismjs = highLight.plugin === 'prismjs' + // + // let highlightShrinkEle = '' + // let highlightCopyEle = '' + // const highlightShrinkClass = isHighlightShrink === true ? 'closed' : '' + // + // if (isHighlightShrink !== undefined) { + // highlightShrinkEle = `` + // } + // + // if (isHighlightCopy) { + // highlightCopyEle = '
' + // } + // + // const copy = (text, ctx) => { + // if (document.queryCommandSupported && document.queryCommandSupported('copy')) { + // document.execCommand('copy') + // if (GLOBAL_CONFIG.Snackbar !== undefined) { + // btf.snackbarShow(GLOBAL_CONFIG.copy.success) + // } else { + // const prevEle = ctx.previousElementSibling + // prevEle.innerText = GLOBAL_CONFIG.copy.success + // prevEle.style.opacity = 1 + // setTimeout(() => { + // prevEle.style.opacity = 0 + // }, 700) + // } + // } else { + // if (GLOBAL_CONFIG.Snackbar !== undefined) { + // btf.snackbarShow(GLOBAL_CONFIG.copy.noSupport) + // } else { + // ctx.previousElementSibling.innerText = GLOBAL_CONFIG.copy.noSupport + // } + // } + // } + // + // // click events + // const highlightCopyFn = (ele) => { + // const $buttonParent = ele.parentNode + // $buttonParent.classList.add('copy-true') + // const selection = window.getSelection() + // const range = document.createRange() + // if (isPrismjs) range.selectNodeContents($buttonParent.querySelectorAll('pre code')[0]) + // else range.selectNodeContents($buttonParent.querySelectorAll('table .code pre')[0]) + // selection.removeAllRanges() + // selection.addRange(range) + // const text = selection.toString() + // copy(text, ele.lastChild) + // selection.removeAllRanges() + // $buttonParent.classList.remove('copy-true') + // } + // + // const highlightShrinkFn = (ele) => { + // const $nextEle = [...ele.parentNode.children].slice(1) + // ele.firstChild.classList.toggle('closed') + // if (btf.isHidden($nextEle[$nextEle.length - 1])) { + // $nextEle.forEach(e => { + // e.style.display = 'block' + // }) + // } else { + // $nextEle.forEach(e => { + // e.style.display = 'none' + // }) + // } + // } + // + // const highlightToolsFn = function (e) { + // const $target = e.target.classList + // if ($target.contains('expand')) highlightShrinkFn(this) + // else if ($target.contains('copy-button')) highlightCopyFn(this) + // } + // + // const expandCode = function () { + // this.classList.toggle('expand-done') + // } + // + // function createEle(lang, item, service) { + // const fragment = document.createDocumentFragment() + // + // if (isShowTool) { + // const hlTools = document.createElement('div') + // hlTools.className = `highlight-tools ${highlightShrinkClass}` + // hlTools.innerHTML = highlightShrinkEle + lang + highlightCopyEle + // hlTools.addEventListener('click', highlightToolsFn) + // fragment.appendChild(hlTools) + // } + // + // if (highlightHeightLimit && item.offsetHeight > highlightHeightLimit + 30) { + // const ele = document.createElement('div') + // ele.className = 'code-expand-btn' + // ele.innerHTML = '' + // ele.addEventListener('click', expandCode) + // fragment.appendChild(ele) + // } + // + // if (service === 'hl') { + // item.insertBefore(fragment, item.firstChild) + // } else { + // item.parentNode.insertBefore(fragment, item) + // } + // } + // + // if (isHighlightLang) { + // if (isPrismjs) { + // $figureHighlight.forEach(function (item) { + // const langName = item.getAttribute('data-language') ? item.getAttribute('data-language') : 'Code' + // const highlightLangEle = `
${langName}
` + // btf.wrap(item, 'figure', '', 'highlight') + // createEle(highlightLangEle, item) + // }) + // } else { + // $figureHighlight.forEach(function (item) { + // let langName = item.getAttribute('class').split(' ')[1] + // if (langName === 'plain' || langName === undefined) langName = 'Code' + // const highlightLangEle = `
${langName}
` + // createEle(highlightLangEle, item, 'hl') + // }) + // } + // } else { + // if (isPrismjs) { + // $figureHighlight.forEach(function (item) { + // btf.wrap(item, 'figure', '', 'highlight') + // createEle('', item) + // }) + // } else { + // $figureHighlight.forEach(function (item) { + // createEle('', item, 'hl') + // }) + // } + // } + // } + + /** + * PhotoFigcaption + */ + // function addPhotoFigcaption() { + // document.querySelectorAll('#article-container img').forEach(function (item) { + // const parentEle = item.parentNode + // if (!parentEle.parentNode.classList.contains('justified-gallery')) { + // const ele = document.createElement('div') + // ele.className = 'img-alt is-center' + // ele.textContent = item.getAttribute('alt') + // parentEle.insertBefore(ele, item.nextSibling) + // } + // }) + // } + + /** + * justified-gallery 圖庫排版 + * 需要 jQuery + */ + + // let detectJgJsLoad = false + // const runJustifiedGallery = function (ele) { + // const $justifiedGallery = $(ele) + // const $imgList = $justifiedGallery.find('img') + // $imgList.unwrap() + // if ($imgList.length) { + // $imgList.each(function (i, o) { + // if ($(o).attr('data-lazy-src')) $(o).attr('src', $(o).attr('data-lazy-src')) + // $(o).wrap('
') + // }) + // } + // + // if (detectJgJsLoad) btf.initJustifiedGallery($justifiedGallery) + // else { + // $('head').append(``) + // $.getScript(`${GLOBAL_CONFIG.source.justifiedGallery.js}`, function () { + // btf.initJustifiedGallery($justifiedGallery) + // }) + // detectJgJsLoad = true + // } + // } + + /** + * fancybox和 mediumZoom + */ + // const addFancybox = function (ele) { + // const runFancybox = (ele) => { + // ele.each(function (i, o) { + // const $this = $(o) + // const lazyloadSrc = $this.attr('data-lazy-src') || $this.attr('src') + // const lazyloadSrc1600 = lazyloadSrc + '_1600w' + // const dataCaption = $this.attr('alt') || '' + // if (lazyloadSrc.indexOf('!blogimg') != -1) { + // $this.wrap(``) + // } else { + // $this.wrap(``) + // } + // + // }) + // + // $().fancybox({ + // selector: '[data-fancybox]', + // loop: true, + // transitionEffect: 'slide', + // protect: true, + // buttons: ['slideShow', 'fullScreen', 'thumbs', 'close'], + // hash: false + // }) + // } + // + // if (typeof $.fancybox === 'undefined') { + // $('head').append(``) + // $.getScript(`${GLOBAL_CONFIG.source.fancybox.js}`, function () { + // runFancybox($(ele)) + // }) + // } else { + // runFancybox($(ele)) + // } + // } + + // const addMediumZoom = () => { + // const zoom = mediumZoom(document.querySelectorAll('#article-container :not(a)>img')) + // zoom.on('open', e => { + // const photoBg = document.documentElement.getAttribute('data-theme') === 'dark' ? '#121212' : '#fff' + // zoom.update({ + // background: photoBg + // }) + // }) + // } + // + // const jqLoadAndRun = () => { + // const $fancyboxEle = GLOBAL_CONFIG.lightbox === 'fancybox' + // ? document.querySelectorAll('#article-container :not(a):not(.gallery-group) > img, #article-container > img,.bber-content-img > img') + // : [] + // const fbLengthNoZero = $fancyboxEle.length > 0 + // const $jgEle = document.querySelectorAll('#article-container .justified-gallery') + // const jgLengthNoZero = $jgEle.length > 0 + // + // if (jgLengthNoZero || fbLengthNoZero) { + // btf.isJqueryLoad(() => { + // jgLengthNoZero && runJustifiedGallery($jgEle) + // fbLengthNoZero && addFancybox($fancyboxEle) + // }) + // } + // } + + /** + * 滾動處理 + */ + const scrollFn = function () { + const $rightside = document.getElementById('rightside') + const innerHeight = window.innerHeight + 56 + + // 當滾動條小于 56 的時候 if (document.body.scrollHeight <= innerHeight) { + $rightside.style.cssText = 'opacity: 1; transform: translateX(-38px)' return } - // 滚动方向 + let initTop = 0 + let isChatShow = true + const $header = document.getElementById('page-header') + const $gulitop = document.getElementById('guli_top') + const $cookies_window = document.getElementById('cookies-window') + const isChatBtnHide = typeof chatBtnHide === 'function' + const isChatBtnShow = typeof chatBtnShow === 'function' + window.addEventListener('scroll', btf.throttle(function (e) { + const currentTop = window.scrollY || document.documentElement.scrollTop + const isDown = scrollDirection(currentTop) + if (currentTop > 56) { + if (isDown) { + if ($header.classList.contains('nav-visible')) $header.classList.remove('nav-visible') + if (isChatBtnShow && isChatShow === true) { + chatBtnHide() + isChatShow = false + } + } else { + if (!$header.classList.contains('nav-visible')) $header.classList.add('nav-visible') + if (isChatBtnHide && isChatShow === false) { + chatBtnShow() + isChatShow = true + } + } + $header.classList.add('nav-fixed') + $cookies_window.classList.add('cw-hide') + if (window.getComputedStyle($rightside).getPropertyValue('opacity') === '0') { + $rightside.style.cssText = 'opacity: 1; transform: translateX(-38px)' + } + } else { + if (currentTop === 0) { + $header.classList.remove('nav-fixed', 'nav-visible') + } + $rightside.style.cssText = "opacity: ''; transform: ''" + } + + if (document.body.scrollHeight <= innerHeight) { + $rightside.style.cssText = 'opacity: 1; transform: translateX(-38px)' + } + }, 200)) + + // find the scroll direction function scrollDirection(currentTop) { const result = currentTop > initTop // true is down & false is up initTop = currentTop return result } - - let initTop = 0; - let $header = document.getElementById("page-header"); - - window.scrollCollect = btf.throttle(function () { - - let currentTop = window.scrollY || document.documentElement.scrollTop; - let isDown = scrollDirection(currentTop); - - if (56 < currentTop) { - // 向下滚动 - if (isDown) { - // 隐藏 nav - if ($header.classList.contains("nav-visible")) { - $header.classList.remove("nav-visible"); - } - } else { - if (!$header.classList.contains("nav-visible")) { - $header.classList.add("nav-visible") - } - } - $header.classList.add("nav-fixed") - } else { - if (0 === currentTop) { - $header.classList.remove("nav-fixed", "nav-visible") - } - } - }, 200) - - window.addEventListener('scroll', scrollCollect) } - // 滚动处理 - const scrollFnToDo = function () { + /** + * toc + */ + const tocFn = function () { + const $cardTocLayout = document.getElementById('card-toc') + const $cardToc = $cardTocLayout.getElementsByClassName('toc-content')[0] + const $tocLink = $cardToc.querySelectorAll('.toc-link') + const $article = document.getElementById('article-container') - const isToc = GLOBAL_CONFIG.htmlType === 'post' && document.getElementById("card-toc"); - const $article = document.getElementById("article-container"); - - if (!($article && isToc)) return - - let $tocLink, $cardToc, scrollPercent, autoScrollToc, isExpand - - if (isToc) { - - const $cardTocLayout = document.getElementById("card-toc"); - $cardToc = $cardTocLayout.getElementsByClassName("toc-content")[0]; - $tocLink = $cardToc.querySelectorAll(".toc-link"); - - // const $tocPercentage = $cardTocLayout.querySelector(".toc-percentage"); - isExpand = $cardToc.classList.contains("is-expand"); - - scrollPercent = function (currentTop) { - const docHeight = $article.clientHeight; - const winHeight = document.documentElement.clientHeight; - const headerHeight = $article.offsetTop; - const contentMath = (docHeight > winHeight) ? (docHeight - winHeight) : (document.documentElement.scrollHeight - winHeight); - const scrollPercent = (currentTop - headerHeight) / (contentMath); - const scrollPercentRounded = Math.round(scrollPercent * 100); - const percentage = (scrollPercentRounded > 100) ? 100 : (scrollPercentRounded <= 0) ? 0 : scrollPercentRounded; - // $tocPercentage.textContent = percentage - $cardToc.setAttribute("progress-percentage", percentage); - }; - - - window.mobileToc = { - open: () => { - $cardTocLayout.style.cssText = "animation: toc-open .3s; opacity: 1; right: 45px"; - }, - - close: () => { - $cardTocLayout.style.animation = "toc-close .2s" - setTimeout(function () { - $cardTocLayout.style.cssText = "opacity:''; animation: ''; right: ''"; - }, 100); - } - } - - // toc 元素点击 - $cardToc.addEventListener("click", e => { - e.preventDefault(); - const target = e.target.classList; - if (target.contains('toc-content')) return; - const $target = e.target.classList.contains("toc-link") ? e.target : e.target.parentElement; - - btf.scrollToDest(btf.getEleTop(document.getElementById(decodeURI($target.getAttribute("href")).replace("#", ""))), 300); - if (window.innerWidth < 900) { - window.mobileToc.close() - } - }); - - autoScrollToc = item => { - const activePosition = item.getBoundingClientRect().top - const sidebarScrollTop = $cardToc.scrollTop - if (activePosition > (document.documentElement.clientHeight - 100)) { - $cardToc.scrollTop = sidebarScrollTop + 150 - } - if (activePosition < 100) { - $cardToc.scrollTop = sidebarScrollTop - 150 - } - }; + // main of scroll + window.tocScrollFn = function () { + return btf.throttle(function () { + const currentTop = window.scrollY || document.documentElement.scrollTop + scrollPercent(currentTop) + findHeadPosition(currentTop) + }, 100)() } - // find head position & add active class - const list = $article.querySelectorAll("h1,h2,h3,h4,h5,h6"); - let detectItem = ""; - const findHeadPosition = function (top) { + window.addEventListener('scroll', tocScrollFn) - if (0 === $tocLink.length || 0 === top) { + const scrollPercent = function (currentTop) { + const docHeight = $article.clientHeight + const winHeight = document.documentElement.clientHeight + const headerHeight = $article.offsetTop + const contentMath = (docHeight > winHeight) ? (docHeight - winHeight) : (document.documentElement.scrollHeight - winHeight) + const scrollPercent = (currentTop - headerHeight) / (contentMath) + const scrollPercentRounded = Math.round(scrollPercent * 100) + const percentage = (scrollPercentRounded > 100) ? 100 : (scrollPercentRounded <= 0) ? 0 : scrollPercentRounded + $cardToc.setAttribute('progress-percentage', percentage) + } + + // anchor + const isAnchor = GLOBAL_CONFIG.isanchor + const updateAnchor = function (anchor) { + if (window.history.replaceState && anchor !== window.location.hash) { + if (!anchor) anchor = location.pathname + const title = GLOBAL_CONFIG.postTitle + window.history.replaceState({ + url: location.href, + title: title + }, title, anchor) + } + } + + const mobileToc = { + open: () => { + $cardTocLayout.style.cssText = 'animation: toc-open .3s; opacity: 1; right: 45px' + }, + + close: () => { + $cardTocLayout.style.animation = 'toc-close .2s' + setTimeout(() => { + $cardTocLayout.style.cssText = "opacity:''; animation: ''; right: ''" + }, 100) + } + } + + document.getElementById('mobile-toc-button').addEventListener('click', () => { + if (window.getComputedStyle($cardTocLayout).getPropertyValue('opacity') === '0') mobileToc.open() + else mobileToc.close() + }) + + // toc元素點擊 + $cardToc.addEventListener('click', (e) => { + e.preventDefault() + const $target = e.target.classList.contains('toc-link') + ? e.target + : e.target.parentElement + btf.scrollToDest(btf.getEleTop(document.getElementById(decodeURI($target.getAttribute('href')).replace('#', ''))), 300) + if (window.innerWidth < 900) { + mobileToc.close() + } + }) + + const autoScrollToc = function (item) { + const activePosition = item.getBoundingClientRect().top + const sidebarScrollTop = $cardToc.scrollTop + if (activePosition > (document.documentElement.clientHeight - 100)) { + $cardToc.scrollTop = sidebarScrollTop + 150 + } + if (activePosition < 100) { + $cardToc.scrollTop = sidebarScrollTop - 150 + } + } + + // find head position & add active class + const list = $article.querySelectorAll('h1,h2,h3,h4,h5,h6') + let detectItem = '' + const findHeadPosition = function (top) { + if ($tocLink.length === 0 || top === 0) { return false } - let currentId = ""; - let currentIndex = ""; + let currentId = '' + let currentIndex = '' list.forEach(function (ele, index) { if (top > btf.getEleTop(ele) - 80) { - const id = ele.id - currentId = id ? "#" + encodeURI(id) : "" + currentId = '#' + encodeURI(ele.getAttribute('id')) currentIndex = index } - }) - if (detectItem === currentIndex) { + + if (detectItem === currentIndex) return + + if (isAnchor) updateAnchor(currentId) + + if (currentId === '') { + $cardToc.querySelectorAll('.active').forEach(i => { + i.classList.remove('active') + }) + detectItem = currentIndex return } detectItem = currentIndex - if (isToc) { - $cardToc.querySelectorAll(".active").forEach(i => { - i.classList.remove("active") - }); - if (currentId === "") { - return; - } + $cardToc.querySelectorAll('.active').forEach(item => { + item.classList.remove('active') + }) + const currentActive = $tocLink[currentIndex] + currentActive.classList.add('active') - const currentActive = $tocLink[currentIndex]; + setTimeout(() => { + autoScrollToc(currentActive) + }, 0) - currentActive.classList.add("active"); + let parent = currentActive.parentNode - setTimeout(() => { - autoScrollToc(currentActive) - }, 0); - - if (isExpand) return; - let parent = currentActive.parentNode; - - for (; !parent.matches(".toc-list"); parent = parent.parentNode) { - if (parent.matches("li")) parent.classList.add("active") - } + for (; !parent.matches('.toc'); parent = parent.parentNode) { + if (parent.matches('li')) parent.classList.add('active') } } - - window.tocScrollFn = function () { - return btf.throttle(function () { - let currentTop = window.scrollY || document.documentElement.scrollTop; - scrollPercent(currentTop) - findHeadPosition(currentTop); - }, 100)(); - }; - window.addEventListener("scroll", tocScrollFn); - }; - - const tabsFn = { - clickFnOfTabs() { - document - .querySelectorAll("#article-container .tab > button") - .forEach(function (item) { - item.addEventListener("click", function (t) { - const $tabItem = this.parentNode; - if (!$tabItem.classList.contains("active")) { - const $tabContent = $tabItem.parentNode.nextElementSibling - const $siblings = btf.siblings($tabItem, ".active")[0] - $siblings && $siblings.classList.remove("active") - $tabItem.classList.add("active") - const tabId = this.getAttribute("data-href").replace("#", "") - const childList = [...$tabContent.children] - childList.forEach(function (item) { - item.id === tabId ? item.classList.add("active") : item.classList.remove("active"); - }) - } - }) - }); - }, - backToTop() { - document.querySelectorAll("#article-container .tabs .tab-to-top") - .forEach(function (t) { - t.addEventListener("click", function () { - btf.scrollToDest(btf.getEleTop(btf.getParents(this, ".tabs")), 300); - }); - }); - } } + /** + * Rightside + */ + // const rightSideFn = { + // switchReadMode: () => { // read-mode + // const $body = document.body + // $body.classList.add('read-mode') + // const newEle = document.createElement('button') + // newEle.type = 'button' + // newEle.className = 'fas fa-sign-out-alt exit-readmode' + // $body.appendChild(newEle) + // + // function clickFn() { + // $body.classList.remove('read-mode') + // newEle.remove() + // newEle.removeEventListener('click', clickFn) + // } + // + // newEle.addEventListener('click', clickFn) + // }, + // switchDarkMode: () => { // Switch Between Light And Dark Mode + // const nowMode = document.documentElement.getAttribute('data-theme') === 'dark' ? 'dark' : 'light' + // if (nowMode === 'light') { + // activateDarkMode() + // saveToLocal.set('theme', 'dark', 2); + // GLOBAL_CONFIG.Snackbar !== undefined && btf.snackbarShow(GLOBAL_CONFIG.Snackbar.day_to_night, false, 2000); + // } else { + // activateLightMode(); + // saveToLocal.set('theme', 'light', 2); + // GLOBAL_CONFIG.Snackbar !== undefined && btf.snackbarShow(GLOBAL_CONFIG.Snackbar.night_to_day, false, 2000); + // } + // // handle some cases + // typeof utterancesTheme === 'function' && utterancesTheme() + // typeof FB === 'object' && window.loadFBComment() + // window.DISQUS && document.getElementById('disqus_thread').children.length && setTimeout(() => window.disqusReset(), 200) + // }, + // showOrHideBtn: () => { // rightside 點擊設置 按鈕 展開 + // document.getElementById('rightside-config-hide').classList.toggle('show') + // }, + // scrollToTop: () => { // Back to top + // btf.scrollToDest(0, 500) + // }, + // hideAsideBtn: () => { // Hide aside + // const $htmlDom = document.documentElement.classList + // $htmlDom.contains('hide-aside') + // ? saveToLocal.set('aside-status', 'show', 2) + // : saveToLocal.set('aside-status', 'hide', 2) + // $htmlDom.toggle('hide-aside') + // }, + // + // adjustFontSize: (plus) => { + // const fontSizeVal = parseInt(window.getComputedStyle(document.documentElement).getPropertyValue('--global-font-size')) + // let newValue = '' + // if (plus) { + // if (fontSizeVal >= 20) return + // newValue = fontSizeVal + 1 + // document.documentElement.style.setProperty('--global-font-size', newValue + 'px') + // !document.getElementById('nav').classList.contains('hide-menu') && adjustMenu(true) + // } else { + // if (fontSizeVal <= 10) return + // newValue = fontSizeVal - 1 + // document.documentElement.style.setProperty('--global-font-size', newValue + 'px') + // document.getElementById('nav').classList.contains('hide-menu') && adjustMenu(true) + // } + // + // saveToLocal.set('global-font-size', newValue, 2) + // // document.getElementById('font-text').innerText = newValue + // } + // } + + // document.getElementById('rightside').addEventListener('click', function (e) { + // const $target = e.target.id || e.target.parentNode.id + // switch ($target) { + // case 'go-up': + // rightSideFn.scrollToTop() + // break + // case 'rightside_config': + // rightSideFn.showOrHideBtn() + // break + // case 'readmode': + // rightSideFn.switchReadMode() + // break + // case 'darkmode': + // rightSideFn.switchDarkMode() + // break + // case 'hide-aside-btn': + // rightSideFn.hideAsideBtn() + // break + // case 'font-plus': + // rightSideFn.adjustFontSize(true) + // break + // case 'font-minus': + // rightSideFn.adjustFontSize() + // break + // default: + // break + // } + // }) + + /** + * menu + * 側邊欄sub-menu 展開/收縮 + * 解決menus在觸摸屏下,滑動屏幕menus_item_child不消失的問題(手機hover的bug) + */ + const clickFnOfSubMenu = function () { + document.querySelectorAll('#sidebar-menus .expand').forEach(function (e) { + e.addEventListener('click', function () { + this.classList.toggle('hide') + const $dom = this.parentNode.nextElementSibling + if (btf.isHidden($dom)) { + $dom.style.display = 'block' + } else { + $dom.style.display = 'none' + } + }) + }) + + window.addEventListener('touchmove', function (e) { + const $menusChild = document.querySelectorAll('#nav .menus_item_child') + $menusChild.forEach(item => { + if (!btf.isHidden(item)) item.style.display = 'none' + }) + }) + } + + /** + * 複製時加上版權信息 + */ + const addCopyright = () => { + const copyright = GLOBAL_CONFIG.copyright + document.body.oncopy = (e) => { + e.preventDefault() + let textFont; + const copyFont = window.getSelection(0).toString() + if (copyFont.length > copyright.limitCount) { + textFont = copyFont + '\n' + '\n' + '\n' + + copyright.languages.author + '\n' + + copyright.languages.link + window.location.href + '\n' + + copyright.languages.source + '\n' + + copyright.languages.info + } else { + textFont = copyFont + } + if (e.clipboardData) { + return e.clipboardData.setData('text', textFont) + } else { + return window.clipboardData.setData('text', textFont) + } + } + } + + /** + * 網頁運行時間 + */ + const addRuntime = () => { + const $runtimeCount = document.getElementById('runtimeshow') + if ($runtimeCount) { + const publishDate = $runtimeCount.getAttribute('data-publishDate') + $runtimeCount.innerText = btf.diffDate(publishDate) + ' ' + GLOBAL_CONFIG.runtime + } + } + + /** + * 最後一次更新時間 + */ + const addLastPushDate = () => { + const $lastPushDateItem = document.getElementById('last-push-date') + if ($lastPushDateItem) { + const lastPushDate = $lastPushDateItem.getAttribute('data-lastPushDate') + $lastPushDateItem.innerText = btf.diffDate(lastPushDate, true) + } + } + + /** + * table overflow + */ + const addTableWrap = function () { + const $table = document.querySelectorAll('#article-container :not(.highlight) > table, #article-container > table') + if ($table.length) { + $table.forEach(item => { + btf.wrap(item, 'div', '', 'table-wrap') + }) + } + } + + /** + * tag-hide + */ + const clickFnOfTagHide = function () { + const $hideInline = document.querySelectorAll('#article-container .hide-button') + if ($hideInline.length) { + $hideInline.forEach(function (item) { + item.addEventListener('click', function (e) { + const $this = this + const $hideContent = $this.nextElementSibling + $this.classList.toggle('open') + if ($this.classList.contains('open')) { + if ($hideContent.querySelectorAll('.justified-gallery').length > 0) { + btf.initJustifiedGallery($hideContent.querySelectorAll('.justified-gallery')) + } + } + }) + }) + } + } + + const tabsFn = { + clickFnOfTabs: function () { + document.querySelectorAll('#article-container .tab > button').forEach(function (item) { + item.addEventListener('click', function (e) { + const $this = this + const $tabItem = $this.parentNode + + if (!$tabItem.classList.contains('active')) { + const $tabContent = $tabItem.parentNode.nextElementSibling + const $siblings = btf.siblings($tabItem, '.active')[0] + $siblings && $siblings.classList.remove('active') + $tabItem.classList.add('active') + const tabId = $this.getAttribute('data-href').replace('#', '') + const childList = [...$tabContent.children] + childList.forEach(item => { + if (item.id === tabId) item.classList.add('active') + else item.classList.remove('active') + }) + const $isTabJustifiedGallery = $tabContent.querySelectorAll(`#${tabId} .justified-gallery`) + if ($isTabJustifiedGallery.length > 0) { + btf.initJustifiedGallery($isTabJustifiedGallery) + } + } + }) + }) + }, + backToTop: () => { + document.querySelectorAll('#article-container .tabs .tab-to-top').forEach(function (item) { + item.addEventListener('click', function () { + btf.scrollToDest(btf.getEleTop(btf.getParents(this, '.tabs')), 300) + }) + }) + } + } + + const toggleCardCategory = function () { + const $cardCategory = document.querySelectorAll('#aside-cat-list .card-category-list-item.parent i') + if ($cardCategory.length) { + $cardCategory.forEach(function (item) { + item.addEventListener('click', function (e) { + e.preventDefault() + const $this = this + $this.classList.toggle('expand') + const $parentEle = $this.parentNode.nextElementSibling + if (btf.isHidden($parentEle)) { + $parentEle.style.display = 'block' + } else { + $parentEle.style.display = 'none' + } + }) + }) + } + } + + // const switchComments = function () { + // let switchDone = false + // const $switchBtn = document.querySelector('#comment-switch > .switch-btn') + // $switchBtn && $switchBtn.addEventListener('click', function () { + // this.classList.toggle('move') + // document.querySelectorAll('#post-comment > .comment-wrap > div').forEach(function (item) { + // if (btf.isHidden(item)) { + // item.style.cssText = 'display: block;animation: tabshow .5s' + // } else { + // item.style.cssText = "display: none;animation: ''" + // } + // }) + // + // if (!switchDone && typeof loadOtherComment === 'function') { + // switchDone = true + // loadOtherComment() + // } + // }) + // } + + const addPostOutdateNotice = function () { + const data = GLOBAL_CONFIG.noticeOutdate + const diffDay = btf.diffDate(GLOBAL_CONFIG_SITE.postUpdate) + if (diffDay >= data.limitDay) { + const ele = document.createElement('div') + ele.className = 'post-outdate-notice' + ele.textContent = data.messagePrev + ' ' + diffDay + ' ' + data.messageNext + const $targetEle = document.getElementById('article-container') + if (data.position === 'top') { + $targetEle.insertBefore(ele, $targetEle.firstChild) + } else { + $targetEle.appendChild(ele) + } + } + } + + const lazyloadImg = () => { + window.lazyLoadInstance = new LazyLoad({ + elements_selector: 'img', + threshold: 0, + data_src: 'lazy-src' + }) + } + + const relativeDate = function (selector) { + selector.forEach(item => { + const $this = item + const timeVal = $this.getAttribute('datetime') + $this.innerText = btf.diffDate(timeVal, true) + $this.style.display = 'inline' + }) + } + + const unRefreshFn = function () { + window.addEventListener('resize', adjustMenu) + window.addEventListener('orientationchange', () => { + setTimeout(adjustMenu(true), 100) + }) + + clickFnOfSubMenu() + GLOBAL_CONFIG.islazyload && lazyloadImg() + GLOBAL_CONFIG.copyright !== undefined && addCopyright() + } window.refreshFn = function () { + initAdjust() - initAdjust(); + if (GLOBAL_CONFIG.isPost) { + GLOBAL_CONFIG.isToc && tocFn() + // GLOBAL_CONFIG.noticeOutdate !== undefined && addPostOutdateNotice() + // GLOBAL_CONFIG.relativeDate.post && relativeDate(document.querySelectorAll('#post-meta time')) + } else { + // GLOBAL_CONFIG.relativeDate.homepage && relativeDate(document.querySelectorAll('#recent-posts time')) + // GLOBAL_CONFIG.runtime && addRuntime() + addLastPushDate() + toggleCardCategory() + } - scrollFnToDo(); - scrollFn(); - tabsFn.clickFnOfTabs(); - tabsFn.backToTop(); + sidebarFn() + GLOBAL_CONFIG.isHome && scrollDownInIndex() + // addHighlightTool() + // GLOBAL_CONFIG.isPhotoFigcaption && addPhotoFigcaption() + // jqLoadAndRun() + // GLOBAL_CONFIG.lightbox === 'mediumZoom' && addMediumZoom() + scrollFn() + addTableWrap() + clickFnOfTagHide() + tabsFn.clickFnOfTabs() + tabsFn.backToTop() + // switchComments() } refreshFn() - window.addEventListener("touchmove", function (t) { - document.querySelectorAll("#nav .menus_item_child").forEach(function (t) { - btf.isHidden(t) || (t.style.display = "none"); - }); - }) -}); + unRefreshFn() +}) diff --git a/templates/assets/js/utils.js b/templates/assets/js/utils.js index d3f6b701..20fc7e51 100644 --- a/templates/assets/js/utils.js +++ b/templates/assets/js/utils.js @@ -1,6 +1,4 @@ -"use strict"; - -const btf = { +var btf = { debounce: function (func, wait, immediate) { let timeout return function () { @@ -60,40 +58,99 @@ const btf = { } }, - snackbarShow: (text, showAction = false, duration = 2000) => { - const { position, bgLight, bgDark } = GLOBAL_CONFIG.Snackbar - const bg = document.documentElement.getAttribute('data-theme') === 'light' ? bgLight : bgDark + snackbarShow: (text, showAction, duration) => { + const sa = (typeof showAction !== 'undefined') ? showAction : false + const dur = (typeof duration !== 'undefined') ? duration : 5000 + const position = GLOBAL_CONFIG.Snackbar.position + const bg = document.documentElement.getAttribute('data-theme') === 'light' ? GLOBAL_CONFIG.Snackbar.bgLight : GLOBAL_CONFIG.Snackbar.bgDark + document.styleSheets[0].addRule(':root', '--heo-snackbar-time:' + dur + 'ms!important') Snackbar.show({ text: text, backgroundColor: bg, - showAction: showAction, - duration: duration, - pos: position, - customClass: 'snackbar-css' + showAction: sa, + duration: dur, + pos: position + }) + + }, + + initJustifiedGallery: function (selector) { + if (!(selector instanceof jQuery)) { + selector = $(selector) + } + selector.each(function (i, o) { + if ($(this).is(':visible')) { + $(this).justifiedGallery({ + rowHeight: 220, + margins: 4 + }) + } }) }, - // 图库排版 - // initJustifiedGallery: function (selector) { - // selector.forEach(function (i) { - // if (!btf.isHidden(i)) { - // fjGallery(i, { - // itemSelector: '.fj-gallery-item', - // rowHeight: 220, - // gutter: 4, - // onJustify: function () { - // this.$container.style.opacity = '1' - // } - // }) - // } - // }) - // }, + diffDate: (d, more = false) => { + const dateNow = new Date() + const datePost = new Date(d) + const dateDiff = dateNow.getTime() - datePost.getTime() + const minute = 1000 * 60 + const hour = minute * 60 + const day = hour * 24 + const month = day * 30 - scrollToDest: (pos, time = 500) => { - const currentPos = window.pageYOffset - if (currentPos > pos) pos = pos - 70 + let result + if (more) { + const monthCount = dateDiff / month + const dayCount = dateDiff / day + const hourCount = dateDiff / hour + const minuteCount = dateDiff / minute - if ('scrollBehavior' in document.documentElement.style) { + if (monthCount > 12) { + // result = datePost.toLocaleDateString().replace(/\//g, '-') + result = datePost.toLocaleDateString() + } else if (dayCount >= 7) { + // } else if (monthCount >= 1) { + result = datePost.toLocaleDateString().substr(5) + // result = parseInt(monthCount) + ' ' + GLOBAL_CONFIG.date_suffix.month + } else if (dayCount >= 1) { + result = parseInt(dayCount) + '' + GLOBAL_CONFIG.date_suffix.day + } else if (hourCount >= 1) { + result = '最近' + // result = parseInt(hourCount) + ' ' + GLOBAL_CONFIG.date_suffix.hour + } else if (minuteCount >= 1) { + result = '最近' + // result = parseInt(minuteCount) + ' ' + GLOBAL_CONFIG.date_suffix.min + } else { + result = GLOBAL_CONFIG.date_suffix.just + } + } else { + result = parseInt(dateDiff / day) + } + return result + }, + + loadComment: (dom, callback) => { + if ('IntersectionObserver' in window) { + const observerItem = new IntersectionObserver((entries) => { + if (entries[0].isIntersecting) { + callback() + observerItem.disconnect() + } + }, {threshold: [0]}) + observerItem.observe(dom) + } else { + callback() + } + }, + + scrollToDest: (pos, time) => { + if (pos < 0 || time < 0) { + return + } + + const currentPos = window.scrollY || window.screenTop + pos = pos - 70 + + if ('CSS' in window && CSS.supports('scroll-behavior', 'smooth')) { window.scrollTo({ top: pos, behavior: 'smooth' @@ -102,31 +159,39 @@ const btf = { } let start = null - pos = +pos - window.requestAnimationFrame(function step (currentTime) { + time = time || 500 + window.requestAnimationFrame(function step(currentTime) { start = !start ? currentTime : start - const progress = currentTime - start if (currentPos < pos) { + const progress = currentTime - start window.scrollTo(0, ((pos - currentPos) * progress / time) + currentPos) + if (progress < time) { + window.requestAnimationFrame(step) + } else { + window.scrollTo(0, pos) + } } else { + const progress = currentTime - start window.scrollTo(0, currentPos - ((currentPos - pos) * progress / time)) - } - if (progress < time) { - window.requestAnimationFrame(step) - } else { - window.scrollTo(0, pos) + if (progress < time) { + window.requestAnimationFrame(step) + } else { + window.scrollTo(0, pos) + } } }) }, - fadeIn: function (e, t) { - e.style.cssText = "display:block;animation: to_show ".concat(t, "s") + fadeIn: (ele, time) => { + ele.style.cssText = `display:block;animation: to_show ${time}s` }, - fadeOut: function (t, e) { - t.addEventListener("animationend", function e() { - t.style.cssText = "display: none; animation: '' ", t.removeEventListener("animationend", e) - }), t.style.animation = "to_hide ".concat(e, "s") + fadeOut: (ele, time) => { + ele.addEventListener('animationend', function f() { + ele.style.cssText = "display: none; animation: '' " + ele.removeEventListener('animationend', f) + }) + ele.style.animation = `to_hide ${time}s` }, getParents: (elem, selector) => { @@ -146,20 +211,21 @@ const btf = { }, /** + * * @param {*} selector * @param {*} eleType the type of create element - * @param {*} options object key: value + * @param {*} id id + * @param {*} cn class name */ - wrap: (selector, eleType, options) => { + wrap: function (selector, eleType, id = '', cn = '') { const creatEle = document.createElement(eleType) - for (const [key, value] of Object.entries(options)) { - creatEle.setAttribute(key, value) - } + if (id) creatEle.id = id + if (cn) creatEle.className = cn selector.parentNode.insertBefore(creatEle, selector) creatEle.appendChild(selector) }, - unwrap: el => { + unwrap: function (el) { const elParentNode = el.parentNode if (elParentNode !== document.body) { elParentNode.parentNode.insertBefore(el, elParentNode) @@ -167,9 +233,17 @@ const btf = { } }, - isHidden: ele => ele.offsetHeight === 0 && ele.offsetWidth === 0, + isJqueryLoad: (fn) => { + if (typeof jQuery === 'undefined') { + getScript(GLOBAL_CONFIG.source.jQuery).then(fn) + } else { + fn() + } + }, - getEleTop: ele => { + isHidden: (ele) => ele.offsetHeight === 0 && ele.offsetWidth === 0, + + getEleTop: (ele) => { let actualTop = ele.offsetTop let current = ele.offsetParent @@ -179,6 +253,6 @@ const btf = { } return actualTop - }, + } -}; \ No newline at end of file +} diff --git a/templates/assets/libs/fast-average-color/index.browser.min.js b/templates/assets/libs/fast-average-color/index.browser.min.js new file mode 100644 index 00000000..506f0805 --- /dev/null +++ b/templates/assets/libs/fast-average-color/index.browser.min.js @@ -0,0 +1,2 @@ +/*! Fast Average Color | © 2022 Denis Seleznev | MIT License | https://github.com/fast-average-color/fast-average-color */ +!function(){"use strict";function t(t){var r=t.toString(16);return 1===r.length?"0"+r:r}function r(r){return"#"+r.map(t).join("")}function e(t){return t?(r=t,Array.isArray(r[0])?t:[t]):[];var r}function n(t,r,e){for(var n=0;n=r-e&&t<=r+e}function a(t,r,e){for(var o={},i=e.ignoredColor,a=e.step,s=[0,0,0,0,0],u=0;ua?(e=i/a,s=100,u=Math.round(s/e)):(e=a/i,u=100,s=Math.round(u/e)),(s>i||u>a||s<10||u<10)&&(s=i,u=a)),{srcLeft:n,srcTop:o,srcWidth:i,srcHeight:a,destWidth:s,destHeight:u}}(d(t),r);if(!(n.srcWidth&&n.srcHeight&&n.destWidth&&n.destHeight))return p('incorrect sizes for resource "'.concat(f(t),'"'),r.silent),this.prepareResult(e);if(this.canvas||(this.canvas=g?new OffscreenCanvas(1,1):document.createElement("canvas")),!this.ctx&&(this.ctx=this.canvas.getContext&&this.canvas.getContext("2d"),!this.ctx))return p("Canvas Context 2D is not supported in this browser",r.silent),this.prepareResult(e);this.canvas.width=n.destWidth,this.canvas.height=n.destHeight;var o=e;try{this.ctx.clearRect(0,0,n.destWidth,n.destHeight),this.ctx.drawImage(t,n.srcLeft,n.srcTop,n.srcWidth,n.srcHeight,0,0,n.destWidth,n.destHeight);var i=this.ctx.getImageData(0,0,n.destWidth,n.destHeight).data;o=this.getColorFromArray4(i,r)}catch(e){p("security error (CORS) for resource ".concat(f(t),".\nDetails: https://developer.mozilla.org/en/docs/Web/HTML/CORS_enabled_image"),r.silent,e)}return this.prepareResult(o)},t.prototype.getColorFromArray4=function(t,r){r=r||{};var n=t.length,o=c(r);if(n<4)return o;var i,h=n-n%4,d=4*(r.step||1);switch(r.algorithm||"sqrt"){case"simple":i=s;break;case"sqrt":i=u;break;case"dominant":i=a;break;default:throw m("".concat(r.algorithm," is unknown algorithm"))}return i(t,h,{defaultColor:o,ignoredColor:e(r.ignoredColor),step:d})},t.prototype.prepareResult=function(t){var e,n=t.slice(0,3),o=[t[0],t[1],t[2],t[3]/255],i=(299*(e=t)[0]+587*e[1]+114*e[2])/1e3<128;return{value:[t[0],t[1],t[2],t[3]],rgb:"rgb("+n.join(",")+")",rgba:"rgba("+o.join(",")+")",hex:r(n),hexa:r(t),isDark:i,isLight:!i}},t.prototype.destroy=function(){this.canvas&&(this.canvas.width=1,this.canvas.height=1,this.canvas=null),this.ctx=null},t.prototype.bindImageEvents=function(t,r){var e=this;return new Promise((function(n,o){var i=function(){u();var i=e.getColor(t,r);i.error?o(i.error):n(i)},a=function(){u(),o(m('Error loading image "'.concat(t.src,'".')))},s=function(){u(),o(m('Image "'.concat(t.src,'" loading aborted')))},u=function(){t.removeEventListener("load",i),t.removeEventListener("error",a),t.removeEventListener("abort",s)};t.addEventListener("load",i),t.addEventListener("error",a),t.addEventListener("abort",s)}))},t}();("undefined"!=typeof window?window:self).FastAverageColor=C}(); \ No newline at end of file diff --git a/templates/assets/libs/iconfont/iconfont.css b/templates/assets/libs/iconfont/iconfont.css index 8bfca7f5..3db87717 100644 --- a/templates/assets/libs/iconfont/iconfont.css +++ b/templates/assets/libs/iconfont/iconfont.css @@ -1,8 +1,8 @@ @font-face { font-family: "iconfont"; /* Project id 3736806 */ - src: url('iconfont.woff2?t=1667571412098') format('woff2'), - url('iconfont.woff?t=1667571412098') format('woff'), - url('iconfont.ttf?t=1667571412098') format('truetype'); + src: url('iconfont.woff2?t=1668096101462') format('woff2'), + url('iconfont.woff?t=1668096101462') format('woff'), + url('iconfont.ttf?t=1668096101462') format('truetype'); } .iconfont { @@ -13,6 +13,26 @@ -moz-osx-font-smoothing: grayscale; } +.icon-logo-hao-pro:before { + content: "\f290"; +} + +.icon-logo-hao:before { + content: "\e609"; +} + +.icon-logo-moment:before { + content: "\e6af"; +} + +.icon-indent:before { + content: "\f027"; +} + +.icon-bars:before { + content: "\ef34"; +} + .icon-mail-line:before { content: "\e668"; } @@ -197,10 +217,6 @@ content: "\e767"; } -.icon-bars:before { - content: "\e9ee"; -} - .icon-arrowup:before { content: "\e64c"; } diff --git a/templates/assets/libs/iconfont/iconfont.js b/templates/assets/libs/iconfont/iconfont.js index fde049e4..2d82915c 100644 --- a/templates/assets/libs/iconfont/iconfont.js +++ b/templates/assets/libs/iconfont/iconfont.js @@ -1 +1 @@ -window._iconfont_svg_string_3736806='',function(o){var c=(c=document.getElementsByTagName("script"))[c.length-1],l=c.getAttribute("data-injectcss"),c=c.getAttribute("data-disable-injectsvg");if(!c){var i,t,h,v,m,a=function(c,l){l.parentNode.insertBefore(c,l)};if(l&&!o.__iconfont__svg__cssinject__){o.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(c){console&&console.log(c)}}i=function(){var c,l=document.createElement("div");l.innerHTML=o._iconfont_svg_string_3736806,(l=l.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",l=l,(c=document.body).firstChild?a(l,c.firstChild):c.appendChild(l))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(i,0):(t=function(){document.removeEventListener("DOMContentLoaded",t,!1),i()},document.addEventListener("DOMContentLoaded",t,!1)):document.attachEvent&&(h=i,v=o.document,m=!1,e(),v.onreadystatechange=function(){"complete"==v.readyState&&(v.onreadystatechange=null,s())})}function s(){m||(m=!0,h())}function e(){try{v.documentElement.doScroll("left")}catch(c){return void setTimeout(e,50)}s()}}(window); \ No newline at end of file +window._iconfont_svg_string_3736806='',function(o){var c=(c=document.getElementsByTagName("script"))[c.length-1],l=c.getAttribute("data-injectcss"),c=c.getAttribute("data-disable-injectsvg");if(!c){var i,h,t,v,m,a=function(c,l){l.parentNode.insertBefore(c,l)};if(l&&!o.__iconfont__svg__cssinject__){o.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(c){console&&console.log(c)}}i=function(){var c,l=document.createElement("div");l.innerHTML=o._iconfont_svg_string_3736806,(l=l.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",l=l,(c=document.body).firstChild?a(l,c.firstChild):c.appendChild(l))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(i,0):(h=function(){document.removeEventListener("DOMContentLoaded",h,!1),i()},document.addEventListener("DOMContentLoaded",h,!1)):document.attachEvent&&(t=i,v=o.document,m=!1,z(),v.onreadystatechange=function(){"complete"==v.readyState&&(v.onreadystatechange=null,s())})}function s(){m||(m=!0,t())}function z(){try{v.documentElement.doScroll("left")}catch(c){return void setTimeout(z,50)}s()}}(window); \ No newline at end of file diff --git a/templates/assets/libs/iconfont/iconfont.json b/templates/assets/libs/iconfont/iconfont.json index c9188bae..c0569d52 100644 --- a/templates/assets/libs/iconfont/iconfont.json +++ b/templates/assets/libs/iconfont/iconfont.json @@ -5,6 +5,41 @@ "css_prefix_text": "icon-", "description": "", "glyphs": [ + { + "icon_id": "32796142", + "name": "logo-hao-copy", + "font_class": "logo-hao-pro", + "unicode": "f290", + "unicode_decimal": 62096 + }, + { + "icon_id": "32787589", + "name": "logo-hao", + "font_class": "logo-hao", + "unicode": "e609", + "unicode_decimal": 58889 + }, + { + "icon_id": "16440935", + "name": "logo-moment", + "font_class": "logo-moment", + "unicode": "e6af", + "unicode_decimal": 59055 + }, + { + "icon_id": "5634161", + "name": "indent", + "font_class": "indent", + "unicode": "f027", + "unicode_decimal": 61479 + }, + { + "icon_id": "5633834", + "name": "bars", + "font_class": "bars", + "unicode": "ef34", + "unicode_decimal": 61236 + }, { "icon_id": "20817029", "name": "mail-line", @@ -327,13 +362,6 @@ "unicode": "e767", "unicode_decimal": 59239 }, - { - "icon_id": "348268", - "name": "bars", - "font_class": "bars", - "unicode": "e9ee", - "unicode_decimal": 59886 - }, { "icon_id": "433860", "name": "arrow-up", diff --git a/templates/assets/libs/iconfont/iconfont.ttf b/templates/assets/libs/iconfont/iconfont.ttf index 7f1ea13b..24656970 100644 Binary files a/templates/assets/libs/iconfont/iconfont.ttf and b/templates/assets/libs/iconfont/iconfont.ttf differ diff --git a/templates/assets/libs/iconfont/iconfont.woff b/templates/assets/libs/iconfont/iconfont.woff index 60a46690..c3a44fb4 100644 Binary files a/templates/assets/libs/iconfont/iconfont.woff and b/templates/assets/libs/iconfont/iconfont.woff differ diff --git a/templates/assets/libs/iconfont/iconfont.woff2 b/templates/assets/libs/iconfont/iconfont.woff2 index d5d8103a..aa2c2867 100644 Binary files a/templates/assets/libs/iconfont/iconfont.woff2 and b/templates/assets/libs/iconfont/iconfont.woff2 differ diff --git a/templates/assets/libs/swiper/swiper-bundle.min.css b/templates/assets/libs/swiper/swiper-bundle.min.css new file mode 100644 index 00000000..a0b3f590 --- /dev/null +++ b/templates/assets/libs/swiper/swiper-bundle.min.css @@ -0,0 +1,13 @@ +/** + * Swiper 8.4.4 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * https://swiperjs.com + * + * Copyright 2014-2022 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: October 12, 2022 + */ + +@font-face{font-family:swiper-icons;src:url('data:application/font-woff;charset=utf-8;base64, d09GRgABAAAAAAZgABAAAAAADAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABGRlRNAAAGRAAAABoAAAAci6qHkUdERUYAAAWgAAAAIwAAACQAYABXR1BPUwAABhQAAAAuAAAANuAY7+xHU1VCAAAFxAAAAFAAAABm2fPczU9TLzIAAAHcAAAASgAAAGBP9V5RY21hcAAAAkQAAACIAAABYt6F0cBjdnQgAAACzAAAAAQAAAAEABEBRGdhc3AAAAWYAAAACAAAAAj//wADZ2x5ZgAAAywAAADMAAAD2MHtryVoZWFkAAABbAAAADAAAAA2E2+eoWhoZWEAAAGcAAAAHwAAACQC9gDzaG10eAAAAigAAAAZAAAArgJkABFsb2NhAAAC0AAAAFoAAABaFQAUGG1heHAAAAG8AAAAHwAAACAAcABAbmFtZQAAA/gAAAE5AAACXvFdBwlwb3N0AAAFNAAAAGIAAACE5s74hXjaY2BkYGAAYpf5Hu/j+W2+MnAzMYDAzaX6QjD6/4//Bxj5GA8AuRwMYGkAPywL13jaY2BkYGA88P8Agx4j+/8fQDYfA1AEBWgDAIB2BOoAeNpjYGRgYNBh4GdgYgABEMnIABJzYNADCQAACWgAsQB42mNgYfzCOIGBlYGB0YcxjYGBwR1Kf2WQZGhhYGBiYGVmgAFGBiQQkOaawtDAoMBQxXjg/wEGPcYDDA4wNUA2CCgwsAAAO4EL6gAAeNpj2M0gyAACqxgGNWBkZ2D4/wMA+xkDdgAAAHjaY2BgYGaAYBkGRgYQiAHyGMF8FgYHIM3DwMHABGQrMOgyWDLEM1T9/w8UBfEMgLzE////P/5//f/V/xv+r4eaAAeMbAxwIUYmIMHEgKYAYjUcsDAwsLKxc3BycfPw8jEQA/gZBASFhEVExcQlJKWkZWTl5BUUlZRVVNXUNTQZBgMAAMR+E+gAEQFEAAAAKgAqACoANAA+AEgAUgBcAGYAcAB6AIQAjgCYAKIArAC2AMAAygDUAN4A6ADyAPwBBgEQARoBJAEuATgBQgFMAVYBYAFqAXQBfgGIAZIBnAGmAbIBzgHsAAB42u2NMQ6CUAyGW568x9AneYYgm4MJbhKFaExIOAVX8ApewSt4Bic4AfeAid3VOBixDxfPYEza5O+Xfi04YADggiUIULCuEJK8VhO4bSvpdnktHI5QCYtdi2sl8ZnXaHlqUrNKzdKcT8cjlq+rwZSvIVczNiezsfnP/uznmfPFBNODM2K7MTQ45YEAZqGP81AmGGcF3iPqOop0r1SPTaTbVkfUe4HXj97wYE+yNwWYxwWu4v1ugWHgo3S1XdZEVqWM7ET0cfnLGxWfkgR42o2PvWrDMBSFj/IHLaF0zKjRgdiVMwScNRAoWUoH78Y2icB/yIY09An6AH2Bdu/UB+yxopYshQiEvnvu0dURgDt8QeC8PDw7Fpji3fEA4z/PEJ6YOB5hKh4dj3EvXhxPqH/SKUY3rJ7srZ4FZnh1PMAtPhwP6fl2PMJMPDgeQ4rY8YT6Gzao0eAEA409DuggmTnFnOcSCiEiLMgxCiTI6Cq5DZUd3Qmp10vO0LaLTd2cjN4fOumlc7lUYbSQcZFkutRG7g6JKZKy0RmdLY680CDnEJ+UMkpFFe1RN7nxdVpXrC4aTtnaurOnYercZg2YVmLN/d/gczfEimrE/fs/bOuq29Zmn8tloORaXgZgGa78yO9/cnXm2BpaGvq25Dv9S4E9+5SIc9PqupJKhYFSSl47+Qcr1mYNAAAAeNptw0cKwkAAAMDZJA8Q7OUJvkLsPfZ6zFVERPy8qHh2YER+3i/BP83vIBLLySsoKimrqKqpa2hp6+jq6RsYGhmbmJqZSy0sraxtbO3sHRydnEMU4uR6yx7JJXveP7WrDycAAAAAAAH//wACeNpjYGRgYOABYhkgZgJCZgZNBkYGLQZtIJsFLMYAAAw3ALgAeNolizEKgDAQBCchRbC2sFER0YD6qVQiBCv/H9ezGI6Z5XBAw8CBK/m5iQQVauVbXLnOrMZv2oLdKFa8Pjuru2hJzGabmOSLzNMzvutpB3N42mNgZGBg4GKQYzBhYMxJLMlj4GBgAYow/P/PAJJhLM6sSoWKfWCAAwDAjgbRAAB42mNgYGBkAIIbCZo5IPrmUn0hGA0AO8EFTQAA');font-weight:400;font-style:normal}:root{--swiper-theme-color:#007aff}.swiper{margin-left:auto;margin-right:auto;position:relative;overflow:hidden;list-style:none;padding:0;z-index:1}.swiper-vertical>.swiper-wrapper{flex-direction:column}.swiper-wrapper{position:relative;width:100%;height:100%;z-index:1;display:flex;transition-property:transform;box-sizing:content-box}.swiper-android .swiper-slide,.swiper-wrapper{transform:translate3d(0px,0,0)}.swiper-pointer-events{touch-action:pan-y}.swiper-pointer-events.swiper-vertical{touch-action:pan-x}.swiper-slide{flex-shrink:0;width:100%;height:100%;position:relative;transition-property:transform}.swiper-slide-invisible-blank{visibility:hidden}.swiper-autoheight,.swiper-autoheight .swiper-slide{height:auto}.swiper-autoheight .swiper-wrapper{align-items:flex-start;transition-property:transform,height}.swiper-backface-hidden .swiper-slide{transform:translateZ(0);-webkit-backface-visibility:hidden;backface-visibility:hidden}.swiper-3d,.swiper-3d.swiper-css-mode .swiper-wrapper{perspective:1200px}.swiper-3d .swiper-cube-shadow,.swiper-3d .swiper-slide,.swiper-3d .swiper-slide-shadow,.swiper-3d .swiper-slide-shadow-bottom,.swiper-3d .swiper-slide-shadow-left,.swiper-3d .swiper-slide-shadow-right,.swiper-3d .swiper-slide-shadow-top,.swiper-3d .swiper-wrapper{transform-style:preserve-3d}.swiper-3d .swiper-slide-shadow,.swiper-3d .swiper-slide-shadow-bottom,.swiper-3d .swiper-slide-shadow-left,.swiper-3d .swiper-slide-shadow-right,.swiper-3d .swiper-slide-shadow-top{position:absolute;left:0;top:0;width:100%;height:100%;pointer-events:none;z-index:10}.swiper-3d .swiper-slide-shadow{background:rgba(0,0,0,.15)}.swiper-3d .swiper-slide-shadow-left{background-image:linear-gradient(to left,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-3d .swiper-slide-shadow-right{background-image:linear-gradient(to right,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-3d .swiper-slide-shadow-top{background-image:linear-gradient(to top,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-3d .swiper-slide-shadow-bottom{background-image:linear-gradient(to bottom,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-css-mode>.swiper-wrapper{overflow:auto;scrollbar-width:none;-ms-overflow-style:none}.swiper-css-mode>.swiper-wrapper::-webkit-scrollbar{display:none}.swiper-css-mode>.swiper-wrapper>.swiper-slide{scroll-snap-align:start start}.swiper-horizontal.swiper-css-mode>.swiper-wrapper{scroll-snap-type:x mandatory}.swiper-vertical.swiper-css-mode>.swiper-wrapper{scroll-snap-type:y mandatory}.swiper-centered>.swiper-wrapper::before{content:'';flex-shrink:0;order:9999}.swiper-centered.swiper-horizontal>.swiper-wrapper>.swiper-slide:first-child{margin-inline-start:var(--swiper-centered-offset-before)}.swiper-centered.swiper-horizontal>.swiper-wrapper::before{height:100%;min-height:1px;width:var(--swiper-centered-offset-after)}.swiper-centered.swiper-vertical>.swiper-wrapper>.swiper-slide:first-child{margin-block-start:var(--swiper-centered-offset-before)}.swiper-centered.swiper-vertical>.swiper-wrapper::before{width:100%;min-width:1px;height:var(--swiper-centered-offset-after)}.swiper-centered>.swiper-wrapper>.swiper-slide{scroll-snap-align:center center}.swiper-virtual .swiper-slide{-webkit-backface-visibility:hidden;transform:translateZ(0)}.swiper-virtual.swiper-css-mode .swiper-wrapper::after{content:'';position:absolute;left:0;top:0;pointer-events:none}.swiper-virtual.swiper-css-mode.swiper-horizontal .swiper-wrapper::after{height:1px;width:var(--swiper-virtual-size)}.swiper-virtual.swiper-css-mode.swiper-vertical .swiper-wrapper::after{width:1px;height:var(--swiper-virtual-size)}:root{--swiper-navigation-size:44px}.swiper-button-next,.swiper-button-prev{position:absolute;top:50%;width:calc(var(--swiper-navigation-size)/ 44 * 27);height:var(--swiper-navigation-size);margin-top:calc(0px - (var(--swiper-navigation-size)/ 2));z-index:10;cursor:pointer;display:flex;align-items:center;justify-content:center;color:var(--swiper-navigation-color,var(--swiper-theme-color))}.swiper-button-next.swiper-button-disabled,.swiper-button-prev.swiper-button-disabled{opacity:.35;cursor:auto;pointer-events:none}.swiper-button-next.swiper-button-hidden,.swiper-button-prev.swiper-button-hidden{opacity:0;cursor:auto;pointer-events:none}.swiper-navigation-disabled .swiper-button-next,.swiper-navigation-disabled .swiper-button-prev{display:none!important}.swiper-button-next:after,.swiper-button-prev:after{font-family:swiper-icons;font-size:var(--swiper-navigation-size);text-transform:none!important;letter-spacing:0;font-variant:initial;line-height:1}.swiper-button-prev,.swiper-rtl .swiper-button-next{left:10px;right:auto}.swiper-button-prev:after,.swiper-rtl .swiper-button-next:after{content:'prev'}.swiper-button-next,.swiper-rtl .swiper-button-prev{right:10px;left:auto}.swiper-button-next:after,.swiper-rtl .swiper-button-prev:after{content:'next'}.swiper-button-lock{display:none}.swiper-pagination{position:absolute;text-align:center;transition:.3s opacity;transform:translate3d(0,0,0);z-index:10}.swiper-pagination.swiper-pagination-hidden{opacity:0}.swiper-pagination-disabled>.swiper-pagination,.swiper-pagination.swiper-pagination-disabled{display:none!important}.swiper-horizontal>.swiper-pagination-bullets,.swiper-pagination-bullets.swiper-pagination-horizontal,.swiper-pagination-custom,.swiper-pagination-fraction{bottom:10px;left:0;width:100%}.swiper-pagination-bullets-dynamic{overflow:hidden;font-size:0}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{transform:scale(.33);position:relative}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active{transform:scale(1)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-main{transform:scale(1)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-prev{transform:scale(.66)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-prev-prev{transform:scale(.33)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-next{transform:scale(.66)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-next-next{transform:scale(.33)}.swiper-pagination-bullet{width:var(--swiper-pagination-bullet-width,var(--swiper-pagination-bullet-size,8px));height:var(--swiper-pagination-bullet-height,var(--swiper-pagination-bullet-size,8px));display:inline-block;border-radius:50%;background:var(--swiper-pagination-bullet-inactive-color,#000);opacity:var(--swiper-pagination-bullet-inactive-opacity, .2)}button.swiper-pagination-bullet{border:none;margin:0;padding:0;box-shadow:none;-webkit-appearance:none;appearance:none}.swiper-pagination-clickable .swiper-pagination-bullet{cursor:pointer}.swiper-pagination-bullet:only-child{display:none!important}.swiper-pagination-bullet-active{opacity:var(--swiper-pagination-bullet-opacity, 1);background:var(--swiper-pagination-color,var(--swiper-theme-color))}.swiper-pagination-vertical.swiper-pagination-bullets,.swiper-vertical>.swiper-pagination-bullets{right:10px;top:50%;transform:translate3d(0px,-50%,0)}.swiper-pagination-vertical.swiper-pagination-bullets .swiper-pagination-bullet,.swiper-vertical>.swiper-pagination-bullets .swiper-pagination-bullet{margin:var(--swiper-pagination-bullet-vertical-gap,6px) 0;display:block}.swiper-pagination-vertical.swiper-pagination-bullets.swiper-pagination-bullets-dynamic,.swiper-vertical>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic{top:50%;transform:translateY(-50%);width:8px}.swiper-pagination-vertical.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet,.swiper-vertical>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{display:inline-block;transition:.2s transform,.2s top}.swiper-horizontal>.swiper-pagination-bullets .swiper-pagination-bullet,.swiper-pagination-horizontal.swiper-pagination-bullets .swiper-pagination-bullet{margin:0 var(--swiper-pagination-bullet-horizontal-gap,4px)}.swiper-horizontal>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic,.swiper-pagination-horizontal.swiper-pagination-bullets.swiper-pagination-bullets-dynamic{left:50%;transform:translateX(-50%);white-space:nowrap}.swiper-horizontal>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet,.swiper-pagination-horizontal.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{transition:.2s transform,.2s left}.swiper-horizontal.swiper-rtl>.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{transition:.2s transform,.2s right}.swiper-pagination-progressbar{background:rgba(0,0,0,.25);position:absolute}.swiper-pagination-progressbar .swiper-pagination-progressbar-fill{background:var(--swiper-pagination-color,var(--swiper-theme-color));position:absolute;left:0;top:0;width:100%;height:100%;transform:scale(0);transform-origin:left top}.swiper-rtl .swiper-pagination-progressbar .swiper-pagination-progressbar-fill{transform-origin:right top}.swiper-horizontal>.swiper-pagination-progressbar,.swiper-pagination-progressbar.swiper-pagination-horizontal,.swiper-pagination-progressbar.swiper-pagination-vertical.swiper-pagination-progressbar-opposite,.swiper-vertical>.swiper-pagination-progressbar.swiper-pagination-progressbar-opposite{width:100%;height:4px;left:0;top:0}.swiper-horizontal>.swiper-pagination-progressbar.swiper-pagination-progressbar-opposite,.swiper-pagination-progressbar.swiper-pagination-horizontal.swiper-pagination-progressbar-opposite,.swiper-pagination-progressbar.swiper-pagination-vertical,.swiper-vertical>.swiper-pagination-progressbar{width:4px;height:100%;left:0;top:0}.swiper-pagination-lock{display:none}.swiper-scrollbar{border-radius:10px;position:relative;-ms-touch-action:none;background:rgba(0,0,0,.1)}.swiper-scrollbar-disabled>.swiper-scrollbar,.swiper-scrollbar.swiper-scrollbar-disabled{display:none!important}.swiper-horizontal>.swiper-scrollbar,.swiper-scrollbar.swiper-scrollbar-horizontal{position:absolute;left:1%;bottom:3px;z-index:50;height:5px;width:98%}.swiper-scrollbar.swiper-scrollbar-vertical,.swiper-vertical>.swiper-scrollbar{position:absolute;right:3px;top:1%;z-index:50;width:5px;height:98%}.swiper-scrollbar-drag{height:100%;width:100%;position:relative;background:rgba(0,0,0,.5);border-radius:10px;left:0;top:0}.swiper-scrollbar-cursor-drag{cursor:move}.swiper-scrollbar-lock{display:none}.swiper-zoom-container{width:100%;height:100%;display:flex;justify-content:center;align-items:center;text-align:center}.swiper-zoom-container>canvas,.swiper-zoom-container>img,.swiper-zoom-container>svg{max-width:100%;max-height:100%;object-fit:contain}.swiper-slide-zoomed{cursor:move}.swiper-lazy-preloader{width:42px;height:42px;position:absolute;left:50%;top:50%;margin-left:-21px;margin-top:-21px;z-index:10;transform-origin:50%;box-sizing:border-box;border:4px solid var(--swiper-preloader-color,var(--swiper-theme-color));border-radius:50%;border-top-color:transparent}.swiper-watch-progress .swiper-slide-visible .swiper-lazy-preloader,.swiper:not(.swiper-watch-progress) .swiper-lazy-preloader{animation:swiper-preloader-spin 1s infinite linear}.swiper-lazy-preloader-white{--swiper-preloader-color:#fff}.swiper-lazy-preloader-black{--swiper-preloader-color:#000}@keyframes swiper-preloader-spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}.swiper .swiper-notification{position:absolute;left:0;top:0;pointer-events:none;opacity:0;z-index:-1000}.swiper-free-mode>.swiper-wrapper{transition-timing-function:ease-out;margin:0 auto}.swiper-grid>.swiper-wrapper{flex-wrap:wrap}.swiper-grid-column>.swiper-wrapper{flex-wrap:wrap;flex-direction:column}.swiper-fade.swiper-free-mode .swiper-slide{transition-timing-function:ease-out}.swiper-fade .swiper-slide{pointer-events:none;transition-property:opacity}.swiper-fade .swiper-slide .swiper-slide{pointer-events:none}.swiper-fade .swiper-slide-active,.swiper-fade .swiper-slide-active .swiper-slide-active{pointer-events:auto}.swiper-cube{overflow:visible}.swiper-cube .swiper-slide{pointer-events:none;-webkit-backface-visibility:hidden;backface-visibility:hidden;z-index:1;visibility:hidden;transform-origin:0 0;width:100%;height:100%}.swiper-cube .swiper-slide .swiper-slide{pointer-events:none}.swiper-cube.swiper-rtl .swiper-slide{transform-origin:100% 0}.swiper-cube .swiper-slide-active,.swiper-cube .swiper-slide-active .swiper-slide-active{pointer-events:auto}.swiper-cube .swiper-slide-active,.swiper-cube .swiper-slide-next,.swiper-cube .swiper-slide-next+.swiper-slide,.swiper-cube .swiper-slide-prev{pointer-events:auto;visibility:visible}.swiper-cube .swiper-slide-shadow-bottom,.swiper-cube .swiper-slide-shadow-left,.swiper-cube .swiper-slide-shadow-right,.swiper-cube .swiper-slide-shadow-top{z-index:0;-webkit-backface-visibility:hidden;backface-visibility:hidden}.swiper-cube .swiper-cube-shadow{position:absolute;left:0;bottom:0px;width:100%;height:100%;opacity:.6;z-index:0}.swiper-cube .swiper-cube-shadow:before{content:'';background:#000;position:absolute;left:0;top:0;bottom:0;right:0;filter:blur(50px)}.swiper-flip{overflow:visible}.swiper-flip .swiper-slide{pointer-events:none;-webkit-backface-visibility:hidden;backface-visibility:hidden;z-index:1}.swiper-flip .swiper-slide .swiper-slide{pointer-events:none}.swiper-flip .swiper-slide-active,.swiper-flip .swiper-slide-active .swiper-slide-active{pointer-events:auto}.swiper-flip .swiper-slide-shadow-bottom,.swiper-flip .swiper-slide-shadow-left,.swiper-flip .swiper-slide-shadow-right,.swiper-flip .swiper-slide-shadow-top{z-index:0;-webkit-backface-visibility:hidden;backface-visibility:hidden}.swiper-creative .swiper-slide{-webkit-backface-visibility:hidden;backface-visibility:hidden;overflow:hidden;transition-property:transform,opacity,height}.swiper-cards{overflow:visible}.swiper-cards .swiper-slide{transform-origin:center bottom;-webkit-backface-visibility:hidden;backface-visibility:hidden;overflow:hidden} \ No newline at end of file diff --git a/templates/assets/libs/swiper/swiper-bundle.min.js b/templates/assets/libs/swiper/swiper-bundle.min.js new file mode 100644 index 00000000..c849e01e --- /dev/null +++ b/templates/assets/libs/swiper/swiper-bundle.min.js @@ -0,0 +1,14 @@ +/** + * Swiper 8.4.4 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * https://swiperjs.com + * + * Copyright 2014-2022 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: October 12, 2022 + */ + +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).Swiper=t()}(this,(function(){"use strict";function e(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function t(s,a){void 0===s&&(s={}),void 0===a&&(a={}),Object.keys(a).forEach((i=>{void 0===s[i]?s[i]=a[i]:e(a[i])&&e(s[i])&&Object.keys(a[i]).length>0&&t(s[i],a[i])}))}const s={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function a(){const e="undefined"!=typeof document?document:{};return t(e,s),e}const i={document:s,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function r(){const e="undefined"!=typeof window?window:{};return t(e,i),e}class n extends Array{constructor(e){"number"==typeof e?super(e):(super(...e||[]),function(e){const t=e.__proto__;Object.defineProperty(e,"__proto__",{get:()=>t,set(e){t.__proto__=e}})}(this))}}function l(e){void 0===e&&(e=[]);const t=[];return e.forEach((e=>{Array.isArray(e)?t.push(...l(e)):t.push(e)})),t}function o(e,t){return Array.prototype.filter.call(e,t)}function d(e,t){const s=r(),i=a();let l=[];if(!t&&e instanceof n)return e;if(!e)return new n(l);if("string"==typeof e){const s=e.trim();if(s.indexOf("<")>=0&&s.indexOf(">")>=0){let e="div";0===s.indexOf("e.split(" "))));return this.forEach((e=>{e.classList.add(...a)})),this},removeClass:function(){for(var e=arguments.length,t=new Array(e),s=0;se.split(" "))));return this.forEach((e=>{e.classList.remove(...a)})),this},hasClass:function(){for(var e=arguments.length,t=new Array(e),s=0;se.split(" "))));return o(this,(e=>a.filter((t=>e.classList.contains(t))).length>0)).length>0},toggleClass:function(){for(var e=arguments.length,t=new Array(e),s=0;se.split(" "))));this.forEach((e=>{a.forEach((t=>{e.classList.toggle(t)}))}))},attr:function(e,t){if(1===arguments.length&&"string"==typeof e)return this[0]?this[0].getAttribute(e):void 0;for(let s=0;s=0;e-=1){const i=a[e];r&&i.listener===r||r&&i.listener&&i.listener.dom7proxy&&i.listener.dom7proxy===r?(s.removeEventListener(t,i.proxyListener,n),a.splice(e,1)):r||(s.removeEventListener(t,i.proxyListener,n),a.splice(e,1))}}}return this},trigger:function(){const e=r();for(var t=arguments.length,s=new Array(t),a=0;at>0)),i.dispatchEvent(t),i.dom7EventData=[],delete i.dom7EventData}}}return this},transitionEnd:function(e){const t=this;return e&&t.on("transitionend",(function s(a){a.target===this&&(e.call(this,a),t.off("transitionend",s))})),this},outerWidth:function(e){if(this.length>0){if(e){const e=this.styles();return this[0].offsetWidth+parseFloat(e.getPropertyValue("margin-right"))+parseFloat(e.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},outerHeight:function(e){if(this.length>0){if(e){const e=this.styles();return this[0].offsetHeight+parseFloat(e.getPropertyValue("margin-top"))+parseFloat(e.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},styles:function(){const e=r();return this[0]?e.getComputedStyle(this[0],null):{}},offset:function(){if(this.length>0){const e=r(),t=a(),s=this[0],i=s.getBoundingClientRect(),n=t.body,l=s.clientTop||n.clientTop||0,o=s.clientLeft||n.clientLeft||0,d=s===e?e.scrollY:s.scrollTop,c=s===e?e.scrollX:s.scrollLeft;return{top:i.top+d-l,left:i.left+c-o}}return null},css:function(e,t){const s=r();let a;if(1===arguments.length){if("string"!=typeof e){for(a=0;a{e.apply(t,[t,s])})),this):this},html:function(e){if(void 0===e)return this[0]?this[0].innerHTML:null;for(let t=0;tt-1)return d([]);if(e<0){const s=t+e;return d(s<0?[]:[this[s]])}return d([this[e]])},append:function(){let e;const t=a();for(let s=0;s=0;i-=1)this[s].insertBefore(a.childNodes[i],this[s].childNodes[0])}else if(e instanceof n)for(i=0;i0?e?this[0].nextElementSibling&&d(this[0].nextElementSibling).is(e)?d([this[0].nextElementSibling]):d([]):this[0].nextElementSibling?d([this[0].nextElementSibling]):d([]):d([])},nextAll:function(e){const t=[];let s=this[0];if(!s)return d([]);for(;s.nextElementSibling;){const a=s.nextElementSibling;e?d(a).is(e)&&t.push(a):t.push(a),s=a}return d(t)},prev:function(e){if(this.length>0){const t=this[0];return e?t.previousElementSibling&&d(t.previousElementSibling).is(e)?d([t.previousElementSibling]):d([]):t.previousElementSibling?d([t.previousElementSibling]):d([])}return d([])},prevAll:function(e){const t=[];let s=this[0];if(!s)return d([]);for(;s.previousElementSibling;){const a=s.previousElementSibling;e?d(a).is(e)&&t.push(a):t.push(a),s=a}return d(t)},parent:function(e){const t=[];for(let s=0;s6&&(i=i.split(", ").map((e=>e.replace(",","."))).join(", ")),n=new s.WebKitCSSMatrix("none"===i?"":i)):(n=l.MozTransform||l.OTransform||l.MsTransform||l.msTransform||l.transform||l.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,"),a=n.toString().split(",")),"x"===t&&(i=s.WebKitCSSMatrix?n.m41:16===a.length?parseFloat(a[12]):parseFloat(a[4])),"y"===t&&(i=s.WebKitCSSMatrix?n.m42:16===a.length?parseFloat(a[13]):parseFloat(a[5])),i||0}function m(e){return"object"==typeof e&&null!==e&&e.constructor&&"Object"===Object.prototype.toString.call(e).slice(8,-1)}function f(e){return"undefined"!=typeof window&&void 0!==window.HTMLElement?e instanceof HTMLElement:e&&(1===e.nodeType||11===e.nodeType)}function g(){const e=Object(arguments.length<=0?void 0:arguments[0]),t=["__proto__","constructor","prototype"];for(let s=1;st.indexOf(e)<0));for(let t=0,i=s.length;tn?"next":"prev",p=(e,t)=>"next"===c&&e>=t||"prev"===c&&e<=t,u=()=>{l=(new Date).getTime(),null===o&&(o=l);const e=Math.max(Math.min((l-o)/d,1),0),r=.5-Math.cos(e*Math.PI)/2;let c=n+r*(s-n);if(p(c,s)&&(c=s),t.wrapperEl.scrollTo({[a]:c}),p(c,s))return t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.scrollSnapType="",setTimeout((()=>{t.wrapperEl.style.overflow="",t.wrapperEl.scrollTo({[a]:c})})),void i.cancelAnimationFrame(t.cssModeFrameID);t.cssModeFrameID=i.requestAnimationFrame(u)};u()}let b,x,y;function E(){return b||(b=function(){const e=r(),t=a();return{smoothScroll:t.documentElement&&"scrollBehavior"in t.documentElement.style,touch:!!("ontouchstart"in e||e.DocumentTouch&&t instanceof e.DocumentTouch),passiveListener:function(){let t=!1;try{const s=Object.defineProperty({},"passive",{get(){t=!0}});e.addEventListener("testPassiveListener",null,s)}catch(e){}return t}(),gestures:"ongesturestart"in e}}()),b}function C(e){return void 0===e&&(e={}),x||(x=function(e){let{userAgent:t}=void 0===e?{}:e;const s=E(),a=r(),i=a.navigator.platform,n=t||a.navigator.userAgent,l={ios:!1,android:!1},o=a.screen.width,d=a.screen.height,c=n.match(/(Android);?[\s\/]+([\d.]+)?/);let p=n.match(/(iPad).*OS\s([\d_]+)/);const u=n.match(/(iPod)(.*OS\s([\d_]+))?/),h=!p&&n.match(/(iPhone\sOS|iOS)\s([\d_]+)/),m="Win32"===i;let f="MacIntel"===i;return!p&&f&&s.touch&&["1024x1366","1366x1024","834x1194","1194x834","834x1112","1112x834","768x1024","1024x768","820x1180","1180x820","810x1080","1080x810"].indexOf(`${o}x${d}`)>=0&&(p=n.match(/(Version)\/([\d.]+)/),p||(p=[0,1,"13_0_0"]),f=!1),c&&!m&&(l.os="android",l.android=!0),(p||h||u)&&(l.os="ios",l.ios=!0),l}(e)),x}function T(){return y||(y=function(){const e=r();return{isSafari:function(){const t=e.navigator.userAgent.toLowerCase();return t.indexOf("safari")>=0&&t.indexOf("chrome")<0&&t.indexOf("android")<0}(),isWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(e.navigator.userAgent)}}()),y}Object.keys(c).forEach((e=>{Object.defineProperty(d.fn,e,{value:c[e],writable:!0})}));var $={on(e,t,s){const a=this;if(!a.eventsListeners||a.destroyed)return a;if("function"!=typeof t)return a;const i=s?"unshift":"push";return e.split(" ").forEach((e=>{a.eventsListeners[e]||(a.eventsListeners[e]=[]),a.eventsListeners[e][i](t)})),a},once(e,t,s){const a=this;if(!a.eventsListeners||a.destroyed)return a;if("function"!=typeof t)return a;function i(){a.off(e,i),i.__emitterProxy&&delete i.__emitterProxy;for(var s=arguments.length,r=new Array(s),n=0;n=0&&t.eventsAnyListeners.splice(s,1),t},off(e,t){const s=this;return!s.eventsListeners||s.destroyed?s:s.eventsListeners?(e.split(" ").forEach((e=>{void 0===t?s.eventsListeners[e]=[]:s.eventsListeners[e]&&s.eventsListeners[e].forEach(((a,i)=>{(a===t||a.__emitterProxy&&a.__emitterProxy===t)&&s.eventsListeners[e].splice(i,1)}))})),s):s},emit(){const e=this;if(!e.eventsListeners||e.destroyed)return e;if(!e.eventsListeners)return e;let t,s,a;for(var i=arguments.length,r=new Array(i),n=0;n{e.eventsAnyListeners&&e.eventsAnyListeners.length&&e.eventsAnyListeners.forEach((e=>{e.apply(a,[t,...s])})),e.eventsListeners&&e.eventsListeners[t]&&e.eventsListeners[t].forEach((e=>{e.apply(a,s)}))})),e}};var S={updateSize:function(){const e=this;let t,s;const a=e.$el;t=void 0!==e.params.width&&null!==e.params.width?e.params.width:a[0].clientWidth,s=void 0!==e.params.height&&null!==e.params.height?e.params.height:a[0].clientHeight,0===t&&e.isHorizontal()||0===s&&e.isVertical()||(t=t-parseInt(a.css("padding-left")||0,10)-parseInt(a.css("padding-right")||0,10),s=s-parseInt(a.css("padding-top")||0,10)-parseInt(a.css("padding-bottom")||0,10),Number.isNaN(t)&&(t=0),Number.isNaN(s)&&(s=0),Object.assign(e,{width:t,height:s,size:e.isHorizontal()?t:s}))},updateSlides:function(){const e=this;function t(t){return e.isHorizontal()?t:{width:"height","margin-top":"margin-left","margin-bottom ":"margin-right","margin-left":"margin-top","margin-right":"margin-bottom","padding-left":"padding-top","padding-right":"padding-bottom",marginRight:"marginBottom"}[t]}function s(e,s){return parseFloat(e.getPropertyValue(t(s))||0)}const a=e.params,{$wrapperEl:i,size:r,rtlTranslate:n,wrongRTL:l}=e,o=e.virtual&&a.virtual.enabled,d=o?e.virtual.slides.length:e.slides.length,c=i.children(`.${e.params.slideClass}`),p=o?e.virtual.slides.length:c.length;let u=[];const h=[],m=[];let f=a.slidesOffsetBefore;"function"==typeof f&&(f=a.slidesOffsetBefore.call(e));let g=a.slidesOffsetAfter;"function"==typeof g&&(g=a.slidesOffsetAfter.call(e));const w=e.snapGrid.length,b=e.slidesGrid.length;let x=a.spaceBetween,y=-f,E=0,C=0;if(void 0===r)return;"string"==typeof x&&x.indexOf("%")>=0&&(x=parseFloat(x.replace("%",""))/100*r),e.virtualSize=-x,n?c.css({marginLeft:"",marginBottom:"",marginTop:""}):c.css({marginRight:"",marginBottom:"",marginTop:""}),a.centeredSlides&&a.cssMode&&(v(e.wrapperEl,"--swiper-centered-offset-before",""),v(e.wrapperEl,"--swiper-centered-offset-after",""));const T=a.grid&&a.grid.rows>1&&e.grid;let $;T&&e.grid.initSlides(p);const S="auto"===a.slidesPerView&&a.breakpoints&&Object.keys(a.breakpoints).filter((e=>void 0!==a.breakpoints[e].slidesPerView)).length>0;for(let i=0;i1&&u.push(e.virtualSize-r)}if(0===u.length&&(u=[0]),0!==a.spaceBetween){const s=e.isHorizontal()&&n?"marginLeft":t("marginRight");c.filter(((e,t)=>!a.cssMode||t!==c.length-1)).css({[s]:`${x}px`})}if(a.centeredSlides&&a.centeredSlidesBounds){let e=0;m.forEach((t=>{e+=t+(a.spaceBetween?a.spaceBetween:0)})),e-=a.spaceBetween;const t=e-r;u=u.map((e=>e<0?-f:e>t?t+g:e))}if(a.centerInsufficientSlides){let e=0;if(m.forEach((t=>{e+=t+(a.spaceBetween?a.spaceBetween:0)})),e-=a.spaceBetween,e{u[s]=e-t})),h.forEach(((e,s)=>{h[s]=e+t}))}}if(Object.assign(e,{slides:c,snapGrid:u,slidesGrid:h,slidesSizesGrid:m}),a.centeredSlides&&a.cssMode&&!a.centeredSlidesBounds){v(e.wrapperEl,"--swiper-centered-offset-before",-u[0]+"px"),v(e.wrapperEl,"--swiper-centered-offset-after",e.size/2-m[m.length-1]/2+"px");const t=-e.snapGrid[0],s=-e.slidesGrid[0];e.snapGrid=e.snapGrid.map((e=>e+t)),e.slidesGrid=e.slidesGrid.map((e=>e+s))}if(p!==d&&e.emit("slidesLengthChange"),u.length!==w&&(e.params.watchOverflow&&e.checkOverflow(),e.emit("snapGridLengthChange")),h.length!==b&&e.emit("slidesGridLengthChange"),a.watchSlidesProgress&&e.updateSlidesOffset(),!(o||a.cssMode||"slide"!==a.effect&&"fade"!==a.effect)){const t=`${a.containerModifierClass}backface-hidden`,s=e.$el.hasClass(t);p<=a.maxBackfaceHiddenSlides?s||e.$el.addClass(t):s&&e.$el.removeClass(t)}},updateAutoHeight:function(e){const t=this,s=[],a=t.virtual&&t.params.virtual.enabled;let i,r=0;"number"==typeof e?t.setTransition(e):!0===e&&t.setTransition(t.params.speed);const n=e=>a?t.slides.filter((t=>parseInt(t.getAttribute("data-swiper-slide-index"),10)===e))[0]:t.slides.eq(e)[0];if("auto"!==t.params.slidesPerView&&t.params.slidesPerView>1)if(t.params.centeredSlides)(t.visibleSlides||d([])).each((e=>{s.push(e)}));else for(i=0;it.slides.length&&!a)break;s.push(n(e))}else s.push(n(t.activeIndex));for(i=0;ir?e:r}(r||0===r)&&t.$wrapperEl.css("height",`${r}px`)},updateSlidesOffset:function(){const e=this,t=e.slides;for(let s=0;s=0&&p1&&u<=t.size||p<=0&&u>=t.size)&&(t.visibleSlides.push(l),t.visibleSlidesIndexes.push(e),a.eq(e).addClass(s.slideVisibleClass)),l.progress=i?-d:d,l.originalProgress=i?-c:c}t.visibleSlides=d(t.visibleSlides)},updateProgress:function(e){const t=this;if(void 0===e){const s=t.rtlTranslate?-1:1;e=t&&t.translate&&t.translate*s||0}const s=t.params,a=t.maxTranslate()-t.minTranslate();let{progress:i,isBeginning:r,isEnd:n}=t;const l=r,o=n;0===a?(i=0,r=!0,n=!0):(i=(e-t.minTranslate())/a,r=i<=0,n=i>=1),Object.assign(t,{progress:i,isBeginning:r,isEnd:n}),(s.watchSlidesProgress||s.centeredSlides&&s.autoHeight)&&t.updateSlidesProgress(e),r&&!l&&t.emit("reachBeginning toEdge"),n&&!o&&t.emit("reachEnd toEdge"),(l&&!r||o&&!n)&&t.emit("fromEdge"),t.emit("progress",i)},updateSlidesClasses:function(){const e=this,{slides:t,params:s,$wrapperEl:a,activeIndex:i,realIndex:r}=e,n=e.virtual&&s.virtual.enabled;let l;t.removeClass(`${s.slideActiveClass} ${s.slideNextClass} ${s.slidePrevClass} ${s.slideDuplicateActiveClass} ${s.slideDuplicateNextClass} ${s.slideDuplicatePrevClass}`),l=n?e.$wrapperEl.find(`.${s.slideClass}[data-swiper-slide-index="${i}"]`):t.eq(i),l.addClass(s.slideActiveClass),s.loop&&(l.hasClass(s.slideDuplicateClass)?a.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${r}"]`).addClass(s.slideDuplicateActiveClass):a.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${r}"]`).addClass(s.slideDuplicateActiveClass));let o=l.nextAll(`.${s.slideClass}`).eq(0).addClass(s.slideNextClass);s.loop&&0===o.length&&(o=t.eq(0),o.addClass(s.slideNextClass));let d=l.prevAll(`.${s.slideClass}`).eq(0).addClass(s.slidePrevClass);s.loop&&0===d.length&&(d=t.eq(-1),d.addClass(s.slidePrevClass)),s.loop&&(o.hasClass(s.slideDuplicateClass)?a.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${o.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicateNextClass):a.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${o.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicateNextClass),d.hasClass(s.slideDuplicateClass)?a.children(`.${s.slideClass}:not(.${s.slideDuplicateClass})[data-swiper-slide-index="${d.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicatePrevClass):a.children(`.${s.slideClass}.${s.slideDuplicateClass}[data-swiper-slide-index="${d.attr("data-swiper-slide-index")}"]`).addClass(s.slideDuplicatePrevClass)),e.emitSlidesClasses()},updateActiveIndex:function(e){const t=this,s=t.rtlTranslate?t.translate:-t.translate,{slidesGrid:a,snapGrid:i,params:r,activeIndex:n,realIndex:l,snapIndex:o}=t;let d,c=e;if(void 0===c){for(let e=0;e=a[e]&&s=a[e]&&s=a[e]&&(c=e);r.normalizeSlideIndex&&(c<0||void 0===c)&&(c=0)}if(i.indexOf(s)>=0)d=i.indexOf(s);else{const e=Math.min(r.slidesPerGroupSkip,c);d=e+Math.floor((c-e)/r.slidesPerGroup)}if(d>=i.length&&(d=i.length-1),c===n)return void(d!==o&&(t.snapIndex=d,t.emit("snapIndexChange")));const p=parseInt(t.slides.eq(c).attr("data-swiper-slide-index")||c,10);Object.assign(t,{snapIndex:d,realIndex:p,previousIndex:n,activeIndex:c}),t.emit("activeIndexChange"),t.emit("snapIndexChange"),l!==p&&t.emit("realIndexChange"),(t.initialized||t.params.runCallbacksOnInit)&&t.emit("slideChange")},updateClickedSlide:function(e){const t=this,s=t.params,a=d(e).closest(`.${s.slideClass}`)[0];let i,r=!1;if(a)for(let e=0;eo?o:a&&en?"next":r=o.length&&(g=o.length-1);const v=-o[g];if(l.normalizeSlideIndex)for(let e=0;e=s&&t=s&&t=s&&(n=e)}if(r.initialized&&n!==p){if(!r.allowSlideNext&&vr.translate&&v>r.maxTranslate()&&(p||0)!==n)return!1}let b;if(n!==(c||0)&&s&&r.emit("beforeSlideChangeStart"),r.updateProgress(v),b=n>p?"next":n{r.wrapperEl.style.scrollSnapType="",r._swiperImmediateVirtual=!1}))}else{if(!r.support.smoothScroll)return w({swiper:r,targetPosition:s,side:e?"left":"top"}),!0;h.scrollTo({[e?"left":"top"]:s,behavior:"smooth"})}return!0}return r.setTransition(t),r.setTranslate(v),r.updateActiveIndex(n),r.updateSlidesClasses(),r.emit("beforeTransitionStart",t,a),r.transitionStart(s,b),0===t?r.transitionEnd(s,b):r.animating||(r.animating=!0,r.onSlideToWrapperTransitionEnd||(r.onSlideToWrapperTransitionEnd=function(e){r&&!r.destroyed&&e.target===this&&(r.$wrapperEl[0].removeEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.$wrapperEl[0].removeEventListener("webkitTransitionEnd",r.onSlideToWrapperTransitionEnd),r.onSlideToWrapperTransitionEnd=null,delete r.onSlideToWrapperTransitionEnd,r.transitionEnd(s,b))}),r.$wrapperEl[0].addEventListener("transitionend",r.onSlideToWrapperTransitionEnd),r.$wrapperEl[0].addEventListener("webkitTransitionEnd",r.onSlideToWrapperTransitionEnd)),!0},slideToLoop:function(e,t,s,a){if(void 0===e&&(e=0),void 0===t&&(t=this.params.speed),void 0===s&&(s=!0),"string"==typeof e){const t=parseInt(e,10);if(!isFinite(t))throw new Error(`The passed-in 'index' (string) couldn't be converted to 'number'. [${e}] given.`);e=t}const i=this;let r=e;return i.params.loop&&(r+=i.loopedSlides),i.slideTo(r,t,s,a)},slideNext:function(e,t,s){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0);const a=this,{animating:i,enabled:r,params:n}=a;if(!r)return a;let l=n.slidesPerGroup;"auto"===n.slidesPerView&&1===n.slidesPerGroup&&n.slidesPerGroupAuto&&(l=Math.max(a.slidesPerViewDynamic("current",!0),1));const o=a.activeIndexc(e)));let h=n[u.indexOf(p)-1];if(void 0===h&&i.cssMode){let e;n.forEach(((t,s)=>{p>=t&&(e=s)})),void 0!==e&&(h=n[e>0?e-1:e])}let m=0;if(void 0!==h&&(m=l.indexOf(h),m<0&&(m=a.activeIndex-1),"auto"===i.slidesPerView&&1===i.slidesPerGroup&&i.slidesPerGroupAuto&&(m=m-a.slidesPerViewDynamic("previous",!0)+1,m=Math.max(m,0))),i.rewind&&a.isBeginning){const i=a.params.virtual&&a.params.virtual.enabled&&a.virtual?a.virtual.slides.length-1:a.slides.length-1;return a.slideTo(i,e,t,s)}return a.slideTo(m,e,t,s)},slideReset:function(e,t,s){return void 0===e&&(e=this.params.speed),void 0===t&&(t=!0),this.slideTo(this.activeIndex,e,t,s)},slideToClosest:function(e,t,s,a){void 0===e&&(e=this.params.speed),void 0===t&&(t=!0),void 0===a&&(a=.5);const i=this;let r=i.activeIndex;const n=Math.min(i.params.slidesPerGroupSkip,r),l=n+Math.floor((r-n)/i.params.slidesPerGroup),o=i.rtlTranslate?i.translate:-i.translate;if(o>=i.snapGrid[l]){const e=i.snapGrid[l];o-e>(i.snapGrid[l+1]-e)*a&&(r+=i.params.slidesPerGroup)}else{const e=i.snapGrid[l-1];o-e<=(i.snapGrid[l]-e)*a&&(r-=i.params.slidesPerGroup)}return r=Math.max(r,0),r=Math.min(r,i.slidesGrid.length-1),i.slideTo(r,e,t,s)},slideToClickedSlide:function(){const e=this,{params:t,$wrapperEl:s}=e,a="auto"===t.slidesPerView?e.slidesPerViewDynamic():t.slidesPerView;let i,r=e.clickedIndex;if(t.loop){if(e.animating)return;i=parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"),10),t.centeredSlides?re.slides.length-e.loopedSlides+a/2?(e.loopFix(),r=s.children(`.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})`).eq(0).index(),p((()=>{e.slideTo(r)}))):e.slideTo(r):r>e.slides.length-a?(e.loopFix(),r=s.children(`.${t.slideClass}[data-swiper-slide-index="${i}"]:not(.${t.slideDuplicateClass})`).eq(0).index(),p((()=>{e.slideTo(r)}))):e.slideTo(r)}else e.slideTo(r)}};var z={loopCreate:function(){const e=this,t=a(),{params:s,$wrapperEl:i}=e,r=i.children().length>0?d(i.children()[0].parentNode):i;r.children(`.${s.slideClass}.${s.slideDuplicateClass}`).remove();let n=r.children(`.${s.slideClass}`);if(s.loopFillGroupWithBlank){const e=s.slidesPerGroup-n.length%s.slidesPerGroup;if(e!==s.slidesPerGroup){for(let a=0;an.length&&e.params.loopedSlidesLimit&&(e.loopedSlides=n.length);const l=[],o=[];n.each(((e,t)=>{d(e).attr("data-swiper-slide-index",t)}));for(let t=0;t=0;e-=1)r.prepend(d(l[e].cloneNode(!0)).addClass(s.slideDuplicateClass))},loopFix:function(){const e=this;e.emit("beforeLoopFix");const{activeIndex:t,slides:s,loopedSlides:a,allowSlidePrev:i,allowSlideNext:r,snapGrid:n,rtlTranslate:l}=e;let o;e.allowSlidePrev=!0,e.allowSlideNext=!0;const d=-n[t]-e.getTranslate();if(t=s.length-a){o=-s.length+t+a,o+=a;e.slideTo(o,0,!1,!0)&&0!==d&&e.setTranslate((l?-e.translate:e.translate)-d)}e.allowSlidePrev=i,e.allowSlideNext=r,e.emit("loopFix")},loopDestroy:function(){const{$wrapperEl:e,params:t,slides:s}=this;e.children(`.${t.slideClass}.${t.slideDuplicateClass},.${t.slideClass}.${t.slideBlankClass}`).remove(),s.removeAttr("data-swiper-slide-index")}};function L(e){const t=this,s=a(),i=r(),n=t.touchEventsData,{params:l,touches:o,enabled:c}=t;if(!c)return;if(t.animating&&l.preventInteractionOnTransition)return;!t.animating&&l.cssMode&&l.loop&&t.loopFix();let p=e;p.originalEvent&&(p=p.originalEvent);let h=d(p.target);if("wrapper"===l.touchEventsTarget&&!h.closest(t.wrapperEl).length)return;if(n.isTouchEvent="touchstart"===p.type,!n.isTouchEvent&&"which"in p&&3===p.which)return;if(!n.isTouchEvent&&"button"in p&&p.button>0)return;if(n.isTouched&&n.isMoved)return;const m=!!l.noSwipingClass&&""!==l.noSwipingClass,f=e.composedPath?e.composedPath():e.path;m&&p.target&&p.target.shadowRoot&&f&&(h=d(f[0]));const g=l.noSwipingSelector?l.noSwipingSelector:`.${l.noSwipingClass}`,v=!(!p.target||!p.target.shadowRoot);if(l.noSwiping&&(v?function(e,t){return void 0===t&&(t=this),function t(s){if(!s||s===a()||s===r())return null;s.assignedSlot&&(s=s.assignedSlot);const i=s.closest(e);return i||s.getRootNode?i||t(s.getRootNode().host):null}(t)}(g,h[0]):h.closest(g)[0]))return void(t.allowClick=!0);if(l.swipeHandler&&!h.closest(l.swipeHandler)[0])return;o.currentX="touchstart"===p.type?p.targetTouches[0].pageX:p.pageX,o.currentY="touchstart"===p.type?p.targetTouches[0].pageY:p.pageY;const w=o.currentX,b=o.currentY,x=l.edgeSwipeDetection||l.iOSEdgeSwipeDetection,y=l.edgeSwipeThreshold||l.iOSEdgeSwipeThreshold;if(x&&(w<=y||w>=i.innerWidth-y)){if("prevent"!==x)return;e.preventDefault()}if(Object.assign(n,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),o.startX=w,o.startY=b,n.touchStartTime=u(),t.allowClick=!0,t.updateSize(),t.swipeDirection=void 0,l.threshold>0&&(n.allowThresholdMove=!1),"touchstart"!==p.type){let e=!0;h.is(n.focusableElements)&&(e=!1,"SELECT"===h[0].nodeName&&(n.isTouched=!1)),s.activeElement&&d(s.activeElement).is(n.focusableElements)&&s.activeElement!==h[0]&&s.activeElement.blur();const a=e&&t.allowTouchMove&&l.touchStartPreventDefault;!l.touchStartForcePreventDefault&&!a||h[0].isContentEditable||p.preventDefault()}t.params.freeMode&&t.params.freeMode.enabled&&t.freeMode&&t.animating&&!l.cssMode&&t.freeMode.onTouchStart(),t.emit("touchStart",p)}function O(e){const t=a(),s=this,i=s.touchEventsData,{params:r,touches:n,rtlTranslate:l,enabled:o}=s;if(!o)return;let c=e;if(c.originalEvent&&(c=c.originalEvent),!i.isTouched)return void(i.startMoving&&i.isScrolling&&s.emit("touchMoveOpposite",c));if(i.isTouchEvent&&"touchmove"!==c.type)return;const p="touchmove"===c.type&&c.targetTouches&&(c.targetTouches[0]||c.changedTouches[0]),h="touchmove"===c.type?p.pageX:c.pageX,m="touchmove"===c.type?p.pageY:c.pageY;if(c.preventedByNestedSwiper)return n.startX=h,void(n.startY=m);if(!s.allowTouchMove)return d(c.target).is(i.focusableElements)||(s.allowClick=!1),void(i.isTouched&&(Object.assign(n,{startX:h,startY:m,currentX:h,currentY:m}),i.touchStartTime=u()));if(i.isTouchEvent&&r.touchReleaseOnEdges&&!r.loop)if(s.isVertical()){if(mn.startY&&s.translate>=s.minTranslate())return i.isTouched=!1,void(i.isMoved=!1)}else if(hn.startX&&s.translate>=s.minTranslate())return;if(i.isTouchEvent&&t.activeElement&&c.target===t.activeElement&&d(c.target).is(i.focusableElements))return i.isMoved=!0,void(s.allowClick=!1);if(i.allowTouchCallbacks&&s.emit("touchMove",c),c.targetTouches&&c.targetTouches.length>1)return;n.currentX=h,n.currentY=m;const f=n.currentX-n.startX,g=n.currentY-n.startY;if(s.params.threshold&&Math.sqrt(f**2+g**2)=25&&(e=180*Math.atan2(Math.abs(g),Math.abs(f))/Math.PI,i.isScrolling=s.isHorizontal()?e>r.touchAngle:90-e>r.touchAngle)}if(i.isScrolling&&s.emit("touchMoveOpposite",c),void 0===i.startMoving&&(n.currentX===n.startX&&n.currentY===n.startY||(i.startMoving=!0)),i.isScrolling)return void(i.isTouched=!1);if(!i.startMoving)return;s.allowClick=!1,!r.cssMode&&c.cancelable&&c.preventDefault(),r.touchMoveStopPropagation&&!r.nested&&c.stopPropagation(),i.isMoved||(r.loop&&!r.cssMode&&s.loopFix(),i.startTranslate=s.getTranslate(),s.setTransition(0),s.animating&&s.$wrapperEl.trigger("webkitTransitionEnd transitionend"),i.allowMomentumBounce=!1,!r.grabCursor||!0!==s.allowSlideNext&&!0!==s.allowSlidePrev||s.setGrabCursor(!0),s.emit("sliderFirstMove",c)),s.emit("sliderMove",c),i.isMoved=!0;let v=s.isHorizontal()?f:g;n.diff=v,v*=r.touchRatio,l&&(v=-v),s.swipeDirection=v>0?"prev":"next",i.currentTranslate=v+i.startTranslate;let w=!0,b=r.resistanceRatio;if(r.touchReleaseOnEdges&&(b=0),v>0&&i.currentTranslate>s.minTranslate()?(w=!1,r.resistance&&(i.currentTranslate=s.minTranslate()-1+(-s.minTranslate()+i.startTranslate+v)**b)):v<0&&i.currentTranslatei.startTranslate&&(i.currentTranslate=i.startTranslate),s.allowSlidePrev||s.allowSlideNext||(i.currentTranslate=i.startTranslate),r.threshold>0){if(!(Math.abs(v)>r.threshold||i.allowThresholdMove))return void(i.currentTranslate=i.startTranslate);if(!i.allowThresholdMove)return i.allowThresholdMove=!0,n.startX=n.currentX,n.startY=n.currentY,i.currentTranslate=i.startTranslate,void(n.diff=s.isHorizontal()?n.currentX-n.startX:n.currentY-n.startY)}r.followFinger&&!r.cssMode&&((r.freeMode&&r.freeMode.enabled&&s.freeMode||r.watchSlidesProgress)&&(s.updateActiveIndex(),s.updateSlidesClasses()),s.params.freeMode&&r.freeMode.enabled&&s.freeMode&&s.freeMode.onTouchMove(),s.updateProgress(i.currentTranslate),s.setTranslate(i.currentTranslate))}function I(e){const t=this,s=t.touchEventsData,{params:a,touches:i,rtlTranslate:r,slidesGrid:n,enabled:l}=t;if(!l)return;let o=e;if(o.originalEvent&&(o=o.originalEvent),s.allowTouchCallbacks&&t.emit("touchEnd",o),s.allowTouchCallbacks=!1,!s.isTouched)return s.isMoved&&a.grabCursor&&t.setGrabCursor(!1),s.isMoved=!1,void(s.startMoving=!1);a.grabCursor&&s.isMoved&&s.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);const d=u(),c=d-s.touchStartTime;if(t.allowClick){const e=o.path||o.composedPath&&o.composedPath();t.updateClickedSlide(e&&e[0]||o.target),t.emit("tap click",o),c<300&&d-s.lastClickTime<300&&t.emit("doubleTap doubleClick",o)}if(s.lastClickTime=u(),p((()=>{t.destroyed||(t.allowClick=!0)})),!s.isTouched||!s.isMoved||!t.swipeDirection||0===i.diff||s.currentTranslate===s.startTranslate)return s.isTouched=!1,s.isMoved=!1,void(s.startMoving=!1);let h;if(s.isTouched=!1,s.isMoved=!1,s.startMoving=!1,h=a.followFinger?r?t.translate:-t.translate:-s.currentTranslate,a.cssMode)return;if(t.params.freeMode&&a.freeMode.enabled)return void t.freeMode.onTouchEnd({currentPos:h});let m=0,f=t.slidesSizesGrid[0];for(let e=0;e=n[e]&&h=n[e]&&(m=e,f=n[n.length-1]-n[n.length-2])}let g=null,v=null;a.rewind&&(t.isBeginning?v=t.params.virtual&&t.params.virtual.enabled&&t.virtual?t.virtual.slides.length-1:t.slides.length-1:t.isEnd&&(g=0));const w=(h-n[m])/f,b=ma.longSwipesMs){if(!a.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&(w>=a.longSwipesRatio?t.slideTo(a.rewind&&t.isEnd?g:m+b):t.slideTo(m)),"prev"===t.swipeDirection&&(w>1-a.longSwipesRatio?t.slideTo(m+b):null!==v&&w<0&&Math.abs(w)>a.longSwipesRatio?t.slideTo(v):t.slideTo(m))}else{if(!a.shortSwipes)return void t.slideTo(t.activeIndex);t.navigation&&(o.target===t.navigation.nextEl||o.target===t.navigation.prevEl)?o.target===t.navigation.nextEl?t.slideTo(m+b):t.slideTo(m):("next"===t.swipeDirection&&t.slideTo(null!==g?g:m+b),"prev"===t.swipeDirection&&t.slideTo(null!==v?v:m))}}function A(){const e=this,{params:t,el:s}=e;if(s&&0===s.offsetWidth)return;t.breakpoints&&e.setBreakpoint();const{allowSlideNext:a,allowSlidePrev:i,snapGrid:r}=e;e.allowSlideNext=!0,e.allowSlidePrev=!0,e.updateSize(),e.updateSlides(),e.updateSlidesClasses(),("auto"===t.slidesPerView||t.slidesPerView>1)&&e.isEnd&&!e.isBeginning&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0),e.autoplay&&e.autoplay.running&&e.autoplay.paused&&e.autoplay.run(),e.allowSlidePrev=i,e.allowSlideNext=a,e.params.watchOverflow&&r!==e.snapGrid&&e.checkOverflow()}function D(e){const t=this;t.enabled&&(t.allowClick||(t.params.preventClicks&&e.preventDefault(),t.params.preventClicksPropagation&&t.animating&&(e.stopPropagation(),e.stopImmediatePropagation())))}function G(){const e=this,{wrapperEl:t,rtlTranslate:s,enabled:a}=e;if(!a)return;let i;e.previousTranslate=e.translate,e.isHorizontal()?e.translate=-t.scrollLeft:e.translate=-t.scrollTop,0===e.translate&&(e.translate=0),e.updateActiveIndex(),e.updateSlidesClasses();const r=e.maxTranslate()-e.minTranslate();i=0===r?0:(e.translate-e.minTranslate())/r,i!==e.progress&&e.updateProgress(s?-e.translate:e.translate),e.emit("setTranslate",e.translate,!1)}let N=!1;function B(){}const H=(e,t)=>{const s=a(),{params:i,touchEvents:r,el:n,wrapperEl:l,device:o,support:d}=e,c=!!i.nested,p="on"===t?"addEventListener":"removeEventListener",u=t;if(d.touch){const t=!("touchstart"!==r.start||!d.passiveListener||!i.passiveListeners)&&{passive:!0,capture:!1};n[p](r.start,e.onTouchStart,t),n[p](r.move,e.onTouchMove,d.passiveListener?{passive:!1,capture:c}:c),n[p](r.end,e.onTouchEnd,t),r.cancel&&n[p](r.cancel,e.onTouchEnd,t)}else n[p](r.start,e.onTouchStart,!1),s[p](r.move,e.onTouchMove,c),s[p](r.end,e.onTouchEnd,!1);(i.preventClicks||i.preventClicksPropagation)&&n[p]("click",e.onClick,!0),i.cssMode&&l[p]("scroll",e.onScroll),i.updateOnWindowResize?e[u](o.ios||o.android?"resize orientationchange observerUpdate":"resize observerUpdate",A,!0):e[u]("observerUpdate",A,!0)};var X={attachEvents:function(){const e=this,t=a(),{params:s,support:i}=e;e.onTouchStart=L.bind(e),e.onTouchMove=O.bind(e),e.onTouchEnd=I.bind(e),s.cssMode&&(e.onScroll=G.bind(e)),e.onClick=D.bind(e),i.touch&&!N&&(t.addEventListener("touchstart",B),N=!0),H(e,"on")},detachEvents:function(){H(this,"off")}};const Y=(e,t)=>e.grid&&t.grid&&t.grid.rows>1;var R={addClasses:function(){const e=this,{classNames:t,params:s,rtl:a,$el:i,device:r,support:n}=e,l=function(e,t){const s=[];return e.forEach((e=>{"object"==typeof e?Object.keys(e).forEach((a=>{e[a]&&s.push(t+a)})):"string"==typeof e&&s.push(t+e)})),s}(["initialized",s.direction,{"pointer-events":!n.touch},{"free-mode":e.params.freeMode&&s.freeMode.enabled},{autoheight:s.autoHeight},{rtl:a},{grid:s.grid&&s.grid.rows>1},{"grid-column":s.grid&&s.grid.rows>1&&"column"===s.grid.fill},{android:r.android},{ios:r.ios},{"css-mode":s.cssMode},{centered:s.cssMode&&s.centeredSlides},{"watch-progress":s.watchSlidesProgress}],s.containerModifierClass);t.push(...l),i.addClass([...t].join(" ")),e.emitContainerClasses()},removeClasses:function(){const{$el:e,classNames:t}=this;e.removeClass(t.join(" ")),this.emitContainerClasses()}};var W={init:!0,direction:"horizontal",touchEventsTarget:"wrapper",initialSlide:0,speed:300,cssMode:!1,updateOnWindowResize:!0,resizeObserver:!0,nested:!1,createElements:!1,enabled:!0,focusableElements:"input, select, option, textarea, button, video, label",width:null,height:null,preventInteractionOnTransition:!1,userAgent:null,url:null,edgeSwipeDetection:!1,edgeSwipeThreshold:20,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,breakpointsBase:"window",spaceBetween:0,slidesPerView:1,slidesPerGroup:1,slidesPerGroupSkip:0,slidesPerGroupAuto:!1,centeredSlides:!1,centeredSlidesBounds:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!0,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:0,touchMoveStopPropagation:!1,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,loopedSlidesLimit:!0,loopFillGroupWithBlank:!1,loopPreventsSlide:!0,rewind:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,maxBackfaceHiddenSlides:10,containerModifierClass:"swiper-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-invisible-blank",slideActiveClass:"swiper-slide-active",slideDuplicateActiveClass:"swiper-slide-duplicate-active",slideVisibleClass:"swiper-slide-visible",slideDuplicateClass:"swiper-slide-duplicate",slideNextClass:"swiper-slide-next",slideDuplicateNextClass:"swiper-slide-duplicate-next",slidePrevClass:"swiper-slide-prev",slideDuplicatePrevClass:"swiper-slide-duplicate-prev",wrapperClass:"swiper-wrapper",runCallbacksOnInit:!0,_emitClasses:!1};function q(e,t){return function(s){void 0===s&&(s={});const a=Object.keys(s)[0],i=s[a];"object"==typeof i&&null!==i?(["navigation","pagination","scrollbar"].indexOf(a)>=0&&!0===e[a]&&(e[a]={auto:!0}),a in e&&"enabled"in i?(!0===e[a]&&(e[a]={enabled:!0}),"object"!=typeof e[a]||"enabled"in e[a]||(e[a].enabled=!0),e[a]||(e[a]={enabled:!1}),g(t,s)):g(t,s)):g(t,s)}}const j={eventsEmitter:$,update:S,translate:M,transition:{setTransition:function(e,t){const s=this;s.params.cssMode||s.$wrapperEl.transition(e),s.emit("setTransition",e,t)},transitionStart:function(e,t){void 0===e&&(e=!0);const s=this,{params:a}=s;a.cssMode||(a.autoHeight&&s.updateAutoHeight(),P({swiper:s,runCallbacks:e,direction:t,step:"Start"}))},transitionEnd:function(e,t){void 0===e&&(e=!0);const s=this,{params:a}=s;s.animating=!1,a.cssMode||(s.setTransition(0),P({swiper:s,runCallbacks:e,direction:t,step:"End"}))}},slide:k,loop:z,grabCursor:{setGrabCursor:function(e){const t=this;if(t.support.touch||!t.params.simulateTouch||t.params.watchOverflow&&t.isLocked||t.params.cssMode)return;const s="container"===t.params.touchEventsTarget?t.el:t.wrapperEl;s.style.cursor="move",s.style.cursor=e?"grabbing":"grab"},unsetGrabCursor:function(){const e=this;e.support.touch||e.params.watchOverflow&&e.isLocked||e.params.cssMode||(e["container"===e.params.touchEventsTarget?"el":"wrapperEl"].style.cursor="")}},events:X,breakpoints:{setBreakpoint:function(){const e=this,{activeIndex:t,initialized:s,loopedSlides:a=0,params:i,$el:r}=e,n=i.breakpoints;if(!n||n&&0===Object.keys(n).length)return;const l=e.getBreakpoint(n,e.params.breakpointsBase,e.el);if(!l||e.currentBreakpoint===l)return;const o=(l in n?n[l]:void 0)||e.originalParams,d=Y(e,i),c=Y(e,o),p=i.enabled;d&&!c?(r.removeClass(`${i.containerModifierClass}grid ${i.containerModifierClass}grid-column`),e.emitContainerClasses()):!d&&c&&(r.addClass(`${i.containerModifierClass}grid`),(o.grid.fill&&"column"===o.grid.fill||!o.grid.fill&&"column"===i.grid.fill)&&r.addClass(`${i.containerModifierClass}grid-column`),e.emitContainerClasses()),["navigation","pagination","scrollbar"].forEach((t=>{const s=i[t]&&i[t].enabled,a=o[t]&&o[t].enabled;s&&!a&&e[t].disable(),!s&&a&&e[t].enable()}));const u=o.direction&&o.direction!==i.direction,h=i.loop&&(o.slidesPerView!==i.slidesPerView||u);u&&s&&e.changeDirection(),g(e.params,o);const m=e.params.enabled;Object.assign(e,{allowTouchMove:e.params.allowTouchMove,allowSlideNext:e.params.allowSlideNext,allowSlidePrev:e.params.allowSlidePrev}),p&&!m?e.disable():!p&&m&&e.enable(),e.currentBreakpoint=l,e.emit("_beforeBreakpoint",o),h&&s&&(e.loopDestroy(),e.loopCreate(),e.updateSlides(),e.slideTo(t-a+e.loopedSlides,0,!1)),e.emit("breakpoint",o)},getBreakpoint:function(e,t,s){if(void 0===t&&(t="window"),!e||"container"===t&&!s)return;let a=!1;const i=r(),n="window"===t?i.innerHeight:s.clientHeight,l=Object.keys(e).map((e=>{if("string"==typeof e&&0===e.indexOf("@")){const t=parseFloat(e.substr(1));return{value:n*t,point:e}}return{value:e,point:e}}));l.sort(((e,t)=>parseInt(e.value,10)-parseInt(t.value,10)));for(let e=0;es}else e.isLocked=1===e.snapGrid.length;!0===s.allowSlideNext&&(e.allowSlideNext=!e.isLocked),!0===s.allowSlidePrev&&(e.allowSlidePrev=!e.isLocked),t&&t!==e.isLocked&&(e.isEnd=!1),t!==e.isLocked&&e.emit(e.isLocked?"lock":"unlock")}},classes:R,images:{loadImage:function(e,t,s,a,i,n){const l=r();let o;function c(){n&&n()}d(e).parent("picture")[0]||e.complete&&i?c():t?(o=new l.Image,o.onload=c,o.onerror=c,a&&(o.sizes=a),s&&(o.srcset=s),t&&(o.src=t)):c()},preloadImages:function(){const e=this;function t(){null!=e&&e&&!e.destroyed&&(void 0!==e.imagesLoaded&&(e.imagesLoaded+=1),e.imagesLoaded===e.imagesToLoad.length&&(e.params.updateOnImagesReady&&e.update(),e.emit("imagesReady")))}e.imagesToLoad=e.$el.find("img");for(let s=0;s1){const e=[];return d(t.el).each((s=>{const a=g({},t,{el:s});e.push(new V(a))})),e}const r=this;r.__swiper__=!0,r.support=E(),r.device=C({userAgent:t.userAgent}),r.browser=T(),r.eventsListeners={},r.eventsAnyListeners=[],r.modules=[...r.__modules__],t.modules&&Array.isArray(t.modules)&&r.modules.push(...t.modules);const n={};r.modules.forEach((e=>{e({swiper:r,extendParams:q(t,n),on:r.on.bind(r),once:r.once.bind(r),off:r.off.bind(r),emit:r.emit.bind(r)})}));const l=g({},W,n);return r.params=g({},l,_,t),r.originalParams=g({},r.params),r.passedParams=g({},t),r.params&&r.params.on&&Object.keys(r.params.on).forEach((e=>{r.on(e,r.params.on[e])})),r.params&&r.params.onAny&&r.onAny(r.params.onAny),r.$=d,Object.assign(r,{enabled:r.params.enabled,el:e,classNames:[],slides:d(),slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:()=>"horizontal"===r.params.direction,isVertical:()=>"vertical"===r.params.direction,activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,allowSlideNext:r.params.allowSlideNext,allowSlidePrev:r.params.allowSlidePrev,touchEvents:function(){const e=["touchstart","touchmove","touchend","touchcancel"],t=["pointerdown","pointermove","pointerup"];return r.touchEventsTouch={start:e[0],move:e[1],end:e[2],cancel:e[3]},r.touchEventsDesktop={start:t[0],move:t[1],end:t[2]},r.support.touch||!r.params.simulateTouch?r.touchEventsTouch:r.touchEventsDesktop}(),touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,focusableElements:r.params.focusableElements,lastClickTime:u(),clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,isTouchEvent:void 0,startMoving:void 0},allowClick:!0,allowTouchMove:r.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),r.emit("_swiper"),r.params.init&&r.init(),r}enable(){const e=this;e.enabled||(e.enabled=!0,e.params.grabCursor&&e.setGrabCursor(),e.emit("enable"))}disable(){const e=this;e.enabled&&(e.enabled=!1,e.params.grabCursor&&e.unsetGrabCursor(),e.emit("disable"))}setProgress(e,t){const s=this;e=Math.min(Math.max(e,0),1);const a=s.minTranslate(),i=(s.maxTranslate()-a)*e+a;s.translateTo(i,void 0===t?0:t),s.updateActiveIndex(),s.updateSlidesClasses()}emitContainerClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=e.el.className.split(" ").filter((t=>0===t.indexOf("swiper")||0===t.indexOf(e.params.containerModifierClass)));e.emit("_containerClasses",t.join(" "))}getSlideClasses(e){const t=this;return t.destroyed?"":e.className.split(" ").filter((e=>0===e.indexOf("swiper-slide")||0===e.indexOf(t.params.slideClass))).join(" ")}emitSlidesClasses(){const e=this;if(!e.params._emitClasses||!e.el)return;const t=[];e.slides.each((s=>{const a=e.getSlideClasses(s);t.push({slideEl:s,classNames:a}),e.emit("_slideClass",s,a)})),e.emit("_slideClasses",t)}slidesPerViewDynamic(e,t){void 0===e&&(e="current"),void 0===t&&(t=!1);const{params:s,slides:a,slidesGrid:i,slidesSizesGrid:r,size:n,activeIndex:l}=this;let o=1;if(s.centeredSlides){let e,t=a[l].swiperSlideSize;for(let s=l+1;sn&&(e=!0));for(let s=l-1;s>=0;s-=1)a[s]&&!e&&(t+=a[s].swiperSlideSize,o+=1,t>n&&(e=!0))}else if("current"===e)for(let e=l+1;e=0;e-=1){i[l]-i[e]1)&&e.isEnd&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0),i||a()),s.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}changeDirection(e,t){void 0===t&&(t=!0);const s=this,a=s.params.direction;return e||(e="horizontal"===a?"vertical":"horizontal"),e===a||"horizontal"!==e&&"vertical"!==e||(s.$el.removeClass(`${s.params.containerModifierClass}${a}`).addClass(`${s.params.containerModifierClass}${e}`),s.emitContainerClasses(),s.params.direction=e,s.slides.each((t=>{"vertical"===e?t.style.width="":t.style.height=""})),s.emit("changeDirection"),t&&s.update()),s}changeLanguageDirection(e){const t=this;t.rtl&&"rtl"===e||!t.rtl&&"ltr"===e||(t.rtl="rtl"===e,t.rtlTranslate="horizontal"===t.params.direction&&t.rtl,t.rtl?(t.$el.addClass(`${t.params.containerModifierClass}rtl`),t.el.dir="rtl"):(t.$el.removeClass(`${t.params.containerModifierClass}rtl`),t.el.dir="ltr"),t.update())}mount(e){const t=this;if(t.mounted)return!0;const s=d(e||t.params.el);if(!(e=s[0]))return!1;e.swiper=t;const i=()=>`.${(t.params.wrapperClass||"").trim().split(" ").join(".")}`;let r=(()=>{if(e&&e.shadowRoot&&e.shadowRoot.querySelector){const t=d(e.shadowRoot.querySelector(i()));return t.children=e=>s.children(e),t}return s.children?s.children(i()):d(s).children(i())})();if(0===r.length&&t.params.createElements){const e=a().createElement("div");r=d(e),e.className=t.params.wrapperClass,s.append(e),s.children(`.${t.params.slideClass}`).each((e=>{r.append(e)}))}return Object.assign(t,{$el:s,el:e,$wrapperEl:r,wrapperEl:r[0],mounted:!0,rtl:"rtl"===e.dir.toLowerCase()||"rtl"===s.css("direction"),rtlTranslate:"horizontal"===t.params.direction&&("rtl"===e.dir.toLowerCase()||"rtl"===s.css("direction")),wrongRTL:"-webkit-box"===r.css("display")}),!0}init(e){const t=this;if(t.initialized)return t;return!1===t.mount(e)||(t.emit("beforeInit"),t.params.breakpoints&&t.setBreakpoint(),t.addClasses(),t.params.loop&&t.loopCreate(),t.updateSize(),t.updateSlides(),t.params.watchOverflow&&t.checkOverflow(),t.params.grabCursor&&t.enabled&&t.setGrabCursor(),t.params.preloadImages&&t.preloadImages(),t.params.loop?t.slideTo(t.params.initialSlide+t.loopedSlides,0,t.params.runCallbacksOnInit,!1,!0):t.slideTo(t.params.initialSlide,0,t.params.runCallbacksOnInit,!1,!0),t.attachEvents(),t.initialized=!0,t.emit("init"),t.emit("afterInit")),t}destroy(e,t){void 0===e&&(e=!0),void 0===t&&(t=!0);const s=this,{params:a,$el:i,$wrapperEl:r,slides:n}=s;return void 0===s.params||s.destroyed||(s.emit("beforeDestroy"),s.initialized=!1,s.detachEvents(),a.loop&&s.loopDestroy(),t&&(s.removeClasses(),i.removeAttr("style"),r.removeAttr("style"),n&&n.length&&n.removeClass([a.slideVisibleClass,a.slideActiveClass,a.slideNextClass,a.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index")),s.emit("destroy"),Object.keys(s.eventsListeners).forEach((e=>{s.off(e)})),!1!==e&&(s.$el[0].swiper=null,function(e){const t=e;Object.keys(t).forEach((e=>{try{t[e]=null}catch(e){}try{delete t[e]}catch(e){}}))}(s)),s.destroyed=!0),null}static extendDefaults(e){g(_,e)}static get extendedDefaults(){return _}static get defaults(){return W}static installModule(e){V.prototype.__modules__||(V.prototype.__modules__=[]);const t=V.prototype.__modules__;"function"==typeof e&&t.indexOf(e)<0&&t.push(e)}static use(e){return Array.isArray(e)?(e.forEach((e=>V.installModule(e))),V):(V.installModule(e),V)}}function F(e,t,s,i){const r=a();return e.params.createElements&&Object.keys(i).forEach((a=>{if(!s[a]&&!0===s.auto){let n=e.$el.children(`.${i[a]}`)[0];n||(n=r.createElement("div"),n.className=i[a],e.$el.append(n)),s[a]=n,t[a]=n}})),s}function U(e){return void 0===e&&(e=""),`.${e.trim().replace(/([\.:!\/])/g,"\\$1").replace(/ /g,".")}`}function K(e){const t=this,{$wrapperEl:s,params:a}=t;if(a.loop&&t.loopDestroy(),"object"==typeof e&&"length"in e)for(let t=0;t=l)return void s.appendSlide(t);let o=n>e?n+1:n;const d=[];for(let t=l-1;t>=e;t-=1){const e=s.slides.eq(t);e.remove(),d.unshift(e)}if("object"==typeof t&&"length"in t){for(let e=0;ee?n+t.length:n}else a.append(t);for(let e=0;e{if(s.params.effect!==t)return;s.classNames.push(`${s.params.containerModifierClass}${t}`),l&&l()&&s.classNames.push(`${s.params.containerModifierClass}3d`);const e=n?n():{};Object.assign(s.params,e),Object.assign(s.originalParams,e)})),a("setTranslate",(()=>{s.params.effect===t&&i()})),a("setTransition",((e,a)=>{s.params.effect===t&&r(a)})),a("transitionEnd",(()=>{if(s.params.effect===t&&o){if(!d||!d().slideShadows)return;s.slides.each((e=>{s.$(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").remove()})),o()}})),a("virtualUpdate",(()=>{s.params.effect===t&&(s.slides.length||(c=!0),requestAnimationFrame((()=>{c&&s.slides&&s.slides.length&&(i(),c=!1)})))}))}function se(e,t){return e.transformEl?t.find(e.transformEl).css({"backface-visibility":"hidden","-webkit-backface-visibility":"hidden"}):t}function ae(e){let{swiper:t,duration:s,transformEl:a,allSlides:i}=e;const{slides:r,activeIndex:n,$wrapperEl:l}=t;if(t.params.virtualTranslate&&0!==s){let e,s=!1;e=i?a?r.find(a):r:a?r.eq(n).find(a):r.eq(n),e.transitionEnd((()=>{if(s)return;if(!t||t.destroyed)return;s=!0,t.animating=!1;const e=["webkitTransitionEnd","transitionend"];for(let t=0;t`),i.append(r)),r}Object.keys(j).forEach((e=>{Object.keys(j[e]).forEach((t=>{V.prototype[t]=j[e][t]}))})),V.use([function(e){let{swiper:t,on:s,emit:a}=e;const i=r();let n=null,l=null;const o=()=>{t&&!t.destroyed&&t.initialized&&(a("beforeResize"),a("resize"))},d=()=>{t&&!t.destroyed&&t.initialized&&a("orientationchange")};s("init",(()=>{t.params.resizeObserver&&void 0!==i.ResizeObserver?t&&!t.destroyed&&t.initialized&&(n=new ResizeObserver((e=>{l=i.requestAnimationFrame((()=>{const{width:s,height:a}=t;let i=s,r=a;e.forEach((e=>{let{contentBoxSize:s,contentRect:a,target:n}=e;n&&n!==t.el||(i=a?a.width:(s[0]||s).inlineSize,r=a?a.height:(s[0]||s).blockSize)})),i===s&&r===a||o()}))})),n.observe(t.el)):(i.addEventListener("resize",o),i.addEventListener("orientationchange",d))})),s("destroy",(()=>{l&&i.cancelAnimationFrame(l),n&&n.unobserve&&t.el&&(n.unobserve(t.el),n=null),i.removeEventListener("resize",o),i.removeEventListener("orientationchange",d)}))},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=[],l=r(),o=function(e,t){void 0===t&&(t={});const s=new(l.MutationObserver||l.WebkitMutationObserver)((e=>{if(1===e.length)return void i("observerUpdate",e[0]);const t=function(){i("observerUpdate",e[0])};l.requestAnimationFrame?l.requestAnimationFrame(t):l.setTimeout(t,0)}));s.observe(e,{attributes:void 0===t.attributes||t.attributes,childList:void 0===t.childList||t.childList,characterData:void 0===t.characterData||t.characterData}),n.push(s)};s({observer:!1,observeParents:!1,observeSlideChildren:!1}),a("init",(()=>{if(t.params.observer){if(t.params.observeParents){const e=t.$el.parents();for(let t=0;t{n.forEach((e=>{e.disconnect()})),n.splice(0,n.length)}))}]);const re=[function(e){let t,{swiper:s,extendParams:a,on:i,emit:r}=e;function n(e,t){const a=s.params.virtual;if(a.cache&&s.virtual.cache[t])return s.virtual.cache[t];const i=a.renderSlide?d(a.renderSlide.call(s,e,t)):d(`
${e}
`);return i.attr("data-swiper-slide-index")||i.attr("data-swiper-slide-index",t),a.cache&&(s.virtual.cache[t]=i),i}function l(e){const{slidesPerView:t,slidesPerGroup:a,centeredSlides:i}=s.params,{addSlidesBefore:l,addSlidesAfter:o}=s.params.virtual,{from:d,to:c,slides:p,slidesGrid:u,offset:h}=s.virtual;s.params.cssMode||s.updateActiveIndex();const m=s.activeIndex||0;let f,g,v;f=s.rtlTranslate?"right":s.isHorizontal()?"left":"top",i?(g=Math.floor(t/2)+a+o,v=Math.floor(t/2)+a+l):(g=t+(a-1)+o,v=a+l);const w=Math.max((m||0)-v,0),b=Math.min((m||0)+g,p.length-1),x=(s.slidesGrid[w]||0)-(s.slidesGrid[0]||0);function y(){s.updateSlides(),s.updateProgress(),s.updateSlidesClasses(),s.lazy&&s.params.lazy.enabled&&s.lazy.load(),r("virtualUpdate")}if(Object.assign(s.virtual,{from:w,to:b,offset:x,slidesGrid:s.slidesGrid}),d===w&&c===b&&!e)return s.slidesGrid!==u&&x!==h&&s.slides.css(f,`${x}px`),s.updateProgress(),void r("virtualUpdate");if(s.params.virtual.renderExternal)return s.params.virtual.renderExternal.call(s,{offset:x,from:w,to:b,slides:function(){const e=[];for(let t=w;t<=b;t+=1)e.push(p[t]);return e}()}),void(s.params.virtual.renderExternalUpdate?y():r("virtualUpdate"));const E=[],C=[];if(e)s.$wrapperEl.find(`.${s.params.slideClass}`).remove();else for(let e=d;e<=c;e+=1)(eb)&&s.$wrapperEl.find(`.${s.params.slideClass}[data-swiper-slide-index="${e}"]`).remove();for(let t=0;t=w&&t<=b&&(void 0===c||e?C.push(t):(t>c&&C.push(t),t{s.$wrapperEl.append(n(p[e],e))})),E.sort(((e,t)=>t-e)).forEach((e=>{s.$wrapperEl.prepend(n(p[e],e))})),s.$wrapperEl.children(".swiper-slide").css(f,`${x}px`),y()}a({virtual:{enabled:!1,slides:[],cache:!0,renderSlide:null,renderExternal:null,renderExternalUpdate:!0,addSlidesBefore:0,addSlidesAfter:0}}),s.virtual={cache:{},from:void 0,to:void 0,slides:[],offset:0,slidesGrid:[]},i("beforeInit",(()=>{s.params.virtual.enabled&&(s.virtual.slides=s.params.virtual.slides,s.classNames.push(`${s.params.containerModifierClass}virtual`),s.params.watchSlidesProgress=!0,s.originalParams.watchSlidesProgress=!0,s.params.initialSlide||l())})),i("setTranslate",(()=>{s.params.virtual.enabled&&(s.params.cssMode&&!s._immediateVirtual?(clearTimeout(t),t=setTimeout((()=>{l()}),100)):l())})),i("init update resize",(()=>{s.params.virtual.enabled&&s.params.cssMode&&v(s.wrapperEl,"--swiper-virtual-size",`${s.virtualSize}px`)})),Object.assign(s.virtual,{appendSlide:function(e){if("object"==typeof e&&"length"in e)for(let t=0;t{const a=e[s],r=a.attr("data-swiper-slide-index");r&&a.attr("data-swiper-slide-index",parseInt(r,10)+i),t[parseInt(s,10)+i]=a})),s.virtual.cache=t}l(!0),s.slideTo(a,0)},removeSlide:function(e){if(null==e)return;let t=s.activeIndex;if(Array.isArray(e))for(let a=e.length-1;a>=0;a-=1)s.virtual.slides.splice(e[a],1),s.params.virtual.cache&&delete s.virtual.cache[e[a]],e[a]0&&0===t.$el.parents(`.${t.params.slideActiveClass}`).length)return;const a=t.$el,i=a[0].clientWidth,r=a[0].clientHeight,n=o.innerWidth,l=o.innerHeight,d=t.$el.offset();s&&(d.left-=t.$el[0].scrollLeft);const c=[[d.left,d.top],[d.left+i,d.top],[d.left,d.top+r],[d.left+i,d.top+r]];for(let t=0;t=0&&s[0]<=n&&s[1]>=0&&s[1]<=l){if(0===s[0]&&0===s[1])continue;e=!0}}if(!e)return}t.isHorizontal()?((d||c||p||u)&&(a.preventDefault?a.preventDefault():a.returnValue=!1),((c||u)&&!s||(d||p)&&s)&&t.slideNext(),((d||p)&&!s||(c||u)&&s)&&t.slidePrev()):((d||c||h||m)&&(a.preventDefault?a.preventDefault():a.returnValue=!1),(c||m)&&t.slideNext(),(d||h)&&t.slidePrev()),n("keyPress",i)}}function p(){t.keyboard.enabled||(d(l).on("keydown",c),t.keyboard.enabled=!0)}function u(){t.keyboard.enabled&&(d(l).off("keydown",c),t.keyboard.enabled=!1)}t.keyboard={enabled:!1},s({keyboard:{enabled:!1,onlyInViewport:!0,pageUpDown:!0}}),i("init",(()=>{t.params.keyboard.enabled&&p()})),i("destroy",(()=>{t.keyboard.enabled&&u()})),Object.assign(t.keyboard,{enable:p,disable:u})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=r();let l;s({mousewheel:{enabled:!1,releaseOnEdges:!1,invert:!1,forceToAxis:!1,sensitivity:1,eventsTarget:"container",thresholdDelta:null,thresholdTime:null}}),t.mousewheel={enabled:!1};let o,c=u();const h=[];function m(){t.enabled&&(t.mouseEntered=!0)}function f(){t.enabled&&(t.mouseEntered=!1)}function g(e){return!(t.params.mousewheel.thresholdDelta&&e.delta=6&&u()-c<60||(e.direction<0?t.isEnd&&!t.params.loop||t.animating||(t.slideNext(),i("scroll",e.raw)):t.isBeginning&&!t.params.loop||t.animating||(t.slidePrev(),i("scroll",e.raw)),c=(new n.Date).getTime(),!1)))}function v(e){let s=e,a=!0;if(!t.enabled)return;const r=t.params.mousewheel;t.params.cssMode&&s.preventDefault();let n=t.$el;if("container"!==t.params.mousewheel.eventsTarget&&(n=d(t.params.mousewheel.eventsTarget)),!t.mouseEntered&&!n[0].contains(s.target)&&!r.releaseOnEdges)return!0;s.originalEvent&&(s=s.originalEvent);let c=0;const m=t.rtlTranslate?-1:1,f=function(e){let t=0,s=0,a=0,i=0;return"detail"in e&&(s=e.detail),"wheelDelta"in e&&(s=-e.wheelDelta/120),"wheelDeltaY"in e&&(s=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=s,s=0),a=10*t,i=10*s,"deltaY"in e&&(i=e.deltaY),"deltaX"in e&&(a=e.deltaX),e.shiftKey&&!a&&(a=i,i=0),(a||i)&&e.deltaMode&&(1===e.deltaMode?(a*=40,i*=40):(a*=800,i*=800)),a&&!t&&(t=a<1?-1:1),i&&!s&&(s=i<1?-1:1),{spinX:t,spinY:s,pixelX:a,pixelY:i}}(s);if(r.forceToAxis)if(t.isHorizontal()){if(!(Math.abs(f.pixelX)>Math.abs(f.pixelY)))return!0;c=-f.pixelX*m}else{if(!(Math.abs(f.pixelY)>Math.abs(f.pixelX)))return!0;c=-f.pixelY}else c=Math.abs(f.pixelX)>Math.abs(f.pixelY)?-f.pixelX*m:-f.pixelY;if(0===c)return!0;r.invert&&(c=-c);let v=t.getTranslate()+c*r.sensitivity;if(v>=t.minTranslate()&&(v=t.minTranslate()),v<=t.maxTranslate()&&(v=t.maxTranslate()),a=!!t.params.loop||!(v===t.minTranslate()||v===t.maxTranslate()),a&&t.params.nested&&s.stopPropagation(),t.params.freeMode&&t.params.freeMode.enabled){const e={time:u(),delta:Math.abs(c),direction:Math.sign(c)},a=o&&e.time=t.minTranslate()&&(n=t.minTranslate()),n<=t.maxTranslate()&&(n=t.maxTranslate()),t.setTransition(0),t.setTranslate(n),t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses(),(!d&&t.isBeginning||!u&&t.isEnd)&&t.updateSlidesClasses(),t.params.freeMode.sticky){clearTimeout(l),l=void 0,h.length>=15&&h.shift();const s=h.length?h[h.length-1]:void 0,a=h[0];if(h.push(e),s&&(e.delta>s.delta||e.direction!==s.direction))h.splice(0);else if(h.length>=15&&e.time-a.time<500&&a.delta-e.delta>=1&&e.delta<=6){const s=c>0?.8:.2;o=e,h.splice(0),l=p((()=>{t.slideToClosest(t.params.speed,!0,void 0,s)}),0)}l||(l=p((()=>{o=e,h.splice(0),t.slideToClosest(t.params.speed,!0,void 0,.5)}),500))}if(a||i("scroll",s),t.params.autoplay&&t.params.autoplayDisableOnInteraction&&t.autoplay.stop(),n===t.minTranslate()||n===t.maxTranslate())return!0}}else{const s={time:u(),delta:Math.abs(c),direction:Math.sign(c),raw:e};h.length>=2&&h.shift();const a=h.length?h[h.length-1]:void 0;if(h.push(s),a?(s.direction!==a.direction||s.delta>a.delta||s.time>a.time+150)&&g(s):g(s),function(e){const s=t.params.mousewheel;if(e.direction<0){if(t.isEnd&&!t.params.loop&&s.releaseOnEdges)return!0}else if(t.isBeginning&&!t.params.loop&&s.releaseOnEdges)return!0;return!1}(s))return!0}return s.preventDefault?s.preventDefault():s.returnValue=!1,!1}function w(e){let s=t.$el;"container"!==t.params.mousewheel.eventsTarget&&(s=d(t.params.mousewheel.eventsTarget)),s[e]("mouseenter",m),s[e]("mouseleave",f),s[e]("wheel",v)}function b(){return t.params.cssMode?(t.wrapperEl.removeEventListener("wheel",v),!0):!t.mousewheel.enabled&&(w("on"),t.mousewheel.enabled=!0,!0)}function x(){return t.params.cssMode?(t.wrapperEl.addEventListener(event,v),!0):!!t.mousewheel.enabled&&(w("off"),t.mousewheel.enabled=!1,!0)}a("init",(()=>{!t.params.mousewheel.enabled&&t.params.cssMode&&x(),t.params.mousewheel.enabled&&b()})),a("destroy",(()=>{t.params.cssMode&&b(),t.mousewheel.enabled&&x()})),Object.assign(t.mousewheel,{enable:b,disable:x})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;function r(e){let s;return e&&(s=d(e),t.params.uniqueNavElements&&"string"==typeof e&&s.length>1&&1===t.$el.find(e).length&&(s=t.$el.find(e))),s}function n(e,s){const a=t.params.navigation;e&&e.length>0&&(e[s?"addClass":"removeClass"](a.disabledClass),e[0]&&"BUTTON"===e[0].tagName&&(e[0].disabled=s),t.params.watchOverflow&&t.enabled&&e[t.isLocked?"addClass":"removeClass"](a.lockClass))}function l(){if(t.params.loop)return;const{$nextEl:e,$prevEl:s}=t.navigation;n(s,t.isBeginning&&!t.params.rewind),n(e,t.isEnd&&!t.params.rewind)}function o(e){e.preventDefault(),(!t.isBeginning||t.params.loop||t.params.rewind)&&(t.slidePrev(),i("navigationPrev"))}function c(e){e.preventDefault(),(!t.isEnd||t.params.loop||t.params.rewind)&&(t.slideNext(),i("navigationNext"))}function p(){const e=t.params.navigation;if(t.params.navigation=F(t,t.originalParams.navigation,t.params.navigation,{nextEl:"swiper-button-next",prevEl:"swiper-button-prev"}),!e.nextEl&&!e.prevEl)return;const s=r(e.nextEl),a=r(e.prevEl);s&&s.length>0&&s.on("click",c),a&&a.length>0&&a.on("click",o),Object.assign(t.navigation,{$nextEl:s,nextEl:s&&s[0],$prevEl:a,prevEl:a&&a[0]}),t.enabled||(s&&s.addClass(e.lockClass),a&&a.addClass(e.lockClass))}function u(){const{$nextEl:e,$prevEl:s}=t.navigation;e&&e.length&&(e.off("click",c),e.removeClass(t.params.navigation.disabledClass)),s&&s.length&&(s.off("click",o),s.removeClass(t.params.navigation.disabledClass))}s({navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock",navigationDisabledClass:"swiper-navigation-disabled"}}),t.navigation={nextEl:null,$nextEl:null,prevEl:null,$prevEl:null},a("init",(()=>{!1===t.params.navigation.enabled?h():(p(),l())})),a("toEdge fromEdge lock unlock",(()=>{l()})),a("destroy",(()=>{u()})),a("enable disable",(()=>{const{$nextEl:e,$prevEl:s}=t.navigation;e&&e[t.enabled?"removeClass":"addClass"](t.params.navigation.lockClass),s&&s[t.enabled?"removeClass":"addClass"](t.params.navigation.lockClass)})),a("click",((e,s)=>{const{$nextEl:a,$prevEl:r}=t.navigation,n=s.target;if(t.params.navigation.hideOnClick&&!d(n).is(r)&&!d(n).is(a)){if(t.pagination&&t.params.pagination&&t.params.pagination.clickable&&(t.pagination.el===n||t.pagination.el.contains(n)))return;let e;a?e=a.hasClass(t.params.navigation.hiddenClass):r&&(e=r.hasClass(t.params.navigation.hiddenClass)),i(!0===e?"navigationShow":"navigationHide"),a&&a.toggleClass(t.params.navigation.hiddenClass),r&&r.toggleClass(t.params.navigation.hiddenClass)}}));const h=()=>{t.$el.addClass(t.params.navigation.navigationDisabledClass),u()};Object.assign(t.navigation,{enable:()=>{t.$el.removeClass(t.params.navigation.navigationDisabledClass),p(),l()},disable:h,update:l,init:p,destroy:u})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const r="swiper-pagination";let n;s({pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,formatFractionCurrent:e=>e,formatFractionTotal:e=>e,bulletClass:`${r}-bullet`,bulletActiveClass:`${r}-bullet-active`,modifierClass:`${r}-`,currentClass:`${r}-current`,totalClass:`${r}-total`,hiddenClass:`${r}-hidden`,progressbarFillClass:`${r}-progressbar-fill`,progressbarOppositeClass:`${r}-progressbar-opposite`,clickableClass:`${r}-clickable`,lockClass:`${r}-lock`,horizontalClass:`${r}-horizontal`,verticalClass:`${r}-vertical`,paginationDisabledClass:`${r}-disabled`}}),t.pagination={el:null,$el:null,bullets:[]};let l=0;function o(){return!t.params.pagination.el||!t.pagination.el||!t.pagination.$el||0===t.pagination.$el.length}function c(e,s){const{bulletActiveClass:a}=t.params.pagination;e[s]().addClass(`${a}-${s}`)[s]().addClass(`${a}-${s}-${s}`)}function p(){const e=t.rtl,s=t.params.pagination;if(o())return;const a=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.slides.length,r=t.pagination.$el;let p;const u=t.params.loop?Math.ceil((a-2*t.loopedSlides)/t.params.slidesPerGroup):t.snapGrid.length;if(t.params.loop?(p=Math.ceil((t.activeIndex-t.loopedSlides)/t.params.slidesPerGroup),p>a-1-2*t.loopedSlides&&(p-=a-2*t.loopedSlides),p>u-1&&(p-=u),p<0&&"bullets"!==t.params.paginationType&&(p=u+p)):p=void 0!==t.snapIndex?t.snapIndex:t.activeIndex||0,"bullets"===s.type&&t.pagination.bullets&&t.pagination.bullets.length>0){const a=t.pagination.bullets;let i,o,u;if(s.dynamicBullets&&(n=a.eq(0)[t.isHorizontal()?"outerWidth":"outerHeight"](!0),r.css(t.isHorizontal()?"width":"height",n*(s.dynamicMainBullets+4)+"px"),s.dynamicMainBullets>1&&void 0!==t.previousIndex&&(l+=p-(t.previousIndex-t.loopedSlides||0),l>s.dynamicMainBullets-1?l=s.dynamicMainBullets-1:l<0&&(l=0)),i=Math.max(p-l,0),o=i+(Math.min(a.length,s.dynamicMainBullets)-1),u=(o+i)/2),a.removeClass(["","-next","-next-next","-prev","-prev-prev","-main"].map((e=>`${s.bulletActiveClass}${e}`)).join(" ")),r.length>1)a.each((e=>{const t=d(e),a=t.index();a===p&&t.addClass(s.bulletActiveClass),s.dynamicBullets&&(a>=i&&a<=o&&t.addClass(`${s.bulletActiveClass}-main`),a===i&&c(t,"prev"),a===o&&c(t,"next"))}));else{const e=a.eq(p),r=e.index();if(e.addClass(s.bulletActiveClass),s.dynamicBullets){const e=a.eq(i),n=a.eq(o);for(let e=i;e<=o;e+=1)a.eq(e).addClass(`${s.bulletActiveClass}-main`);if(t.params.loop)if(r>=a.length){for(let e=s.dynamicMainBullets;e>=0;e-=1)a.eq(a.length-e).addClass(`${s.bulletActiveClass}-main`);a.eq(a.length-s.dynamicMainBullets-1).addClass(`${s.bulletActiveClass}-prev`)}else c(e,"prev"),c(n,"next");else c(e,"prev"),c(n,"next")}}if(s.dynamicBullets){const i=Math.min(a.length,s.dynamicMainBullets+4),r=(n*i-n)/2-u*n,l=e?"right":"left";a.css(t.isHorizontal()?l:"top",`${r}px`)}}if("fraction"===s.type&&(r.find(U(s.currentClass)).text(s.formatFractionCurrent(p+1)),r.find(U(s.totalClass)).text(s.formatFractionTotal(u))),"progressbar"===s.type){let e;e=s.progressbarOpposite?t.isHorizontal()?"vertical":"horizontal":t.isHorizontal()?"horizontal":"vertical";const a=(p+1)/u;let i=1,n=1;"horizontal"===e?i=a:n=a,r.find(U(s.progressbarFillClass)).transform(`translate3d(0,0,0) scaleX(${i}) scaleY(${n})`).transition(t.params.speed)}"custom"===s.type&&s.renderCustom?(r.html(s.renderCustom(t,p+1,u)),i("paginationRender",r[0])):i("paginationUpdate",r[0]),t.params.watchOverflow&&t.enabled&&r[t.isLocked?"addClass":"removeClass"](s.lockClass)}function u(){const e=t.params.pagination;if(o())return;const s=t.virtual&&t.params.virtual.enabled?t.virtual.slides.length:t.slides.length,a=t.pagination.$el;let r="";if("bullets"===e.type){let i=t.params.loop?Math.ceil((s-2*t.loopedSlides)/t.params.slidesPerGroup):t.snapGrid.length;t.params.freeMode&&t.params.freeMode.enabled&&!t.params.loop&&i>s&&(i=s);for(let s=0;s`;a.html(r),t.pagination.bullets=a.find(U(e.bulletClass))}"fraction"===e.type&&(r=e.renderFraction?e.renderFraction.call(t,e.currentClass,e.totalClass):` / `,a.html(r)),"progressbar"===e.type&&(r=e.renderProgressbar?e.renderProgressbar.call(t,e.progressbarFillClass):``,a.html(r)),"custom"!==e.type&&i("paginationRender",t.pagination.$el[0])}function h(){t.params.pagination=F(t,t.originalParams.pagination,t.params.pagination,{el:"swiper-pagination"});const e=t.params.pagination;if(!e.el)return;let s=d(e.el);0!==s.length&&(t.params.uniqueNavElements&&"string"==typeof e.el&&s.length>1&&(s=t.$el.find(e.el),s.length>1&&(s=s.filter((e=>d(e).parents(".swiper")[0]===t.el)))),"bullets"===e.type&&e.clickable&&s.addClass(e.clickableClass),s.addClass(e.modifierClass+e.type),s.addClass(t.isHorizontal()?e.horizontalClass:e.verticalClass),"bullets"===e.type&&e.dynamicBullets&&(s.addClass(`${e.modifierClass}${e.type}-dynamic`),l=0,e.dynamicMainBullets<1&&(e.dynamicMainBullets=1)),"progressbar"===e.type&&e.progressbarOpposite&&s.addClass(e.progressbarOppositeClass),e.clickable&&s.on("click",U(e.bulletClass),(function(e){e.preventDefault();let s=d(this).index()*t.params.slidesPerGroup;t.params.loop&&(s+=t.loopedSlides),t.slideTo(s)})),Object.assign(t.pagination,{$el:s,el:s[0]}),t.enabled||s.addClass(e.lockClass))}function m(){const e=t.params.pagination;if(o())return;const s=t.pagination.$el;s.removeClass(e.hiddenClass),s.removeClass(e.modifierClass+e.type),s.removeClass(t.isHorizontal()?e.horizontalClass:e.verticalClass),t.pagination.bullets&&t.pagination.bullets.removeClass&&t.pagination.bullets.removeClass(e.bulletActiveClass),e.clickable&&s.off("click",U(e.bulletClass))}a("init",(()=>{!1===t.params.pagination.enabled?f():(h(),u(),p())})),a("activeIndexChange",(()=>{(t.params.loop||void 0===t.snapIndex)&&p()})),a("snapIndexChange",(()=>{t.params.loop||p()})),a("slidesLengthChange",(()=>{t.params.loop&&(u(),p())})),a("snapGridLengthChange",(()=>{t.params.loop||(u(),p())})),a("destroy",(()=>{m()})),a("enable disable",(()=>{const{$el:e}=t.pagination;e&&e[t.enabled?"removeClass":"addClass"](t.params.pagination.lockClass)})),a("lock unlock",(()=>{p()})),a("click",((e,s)=>{const a=s.target,{$el:r}=t.pagination;if(t.params.pagination.el&&t.params.pagination.hideOnClick&&r&&r.length>0&&!d(a).hasClass(t.params.pagination.bulletClass)){if(t.navigation&&(t.navigation.nextEl&&a===t.navigation.nextEl||t.navigation.prevEl&&a===t.navigation.prevEl))return;const e=r.hasClass(t.params.pagination.hiddenClass);i(!0===e?"paginationShow":"paginationHide"),r.toggleClass(t.params.pagination.hiddenClass)}}));const f=()=>{t.$el.addClass(t.params.pagination.paginationDisabledClass),t.pagination.$el&&t.pagination.$el.addClass(t.params.pagination.paginationDisabledClass),m()};Object.assign(t.pagination,{enable:()=>{t.$el.removeClass(t.params.pagination.paginationDisabledClass),t.pagination.$el&&t.pagination.$el.removeClass(t.params.pagination.paginationDisabledClass),h(),u(),p()},disable:f,render:u,update:p,init:h,destroy:m})},function(e){let{swiper:t,extendParams:s,on:i,emit:r}=e;const n=a();let l,o,c,u,h=!1,m=null,f=null;function g(){if(!t.params.scrollbar.el||!t.scrollbar.el)return;const{scrollbar:e,rtlTranslate:s,progress:a}=t,{$dragEl:i,$el:r}=e,n=t.params.scrollbar;let l=o,d=(c-o)*a;s?(d=-d,d>0?(l=o-d,d=0):-d+o>c&&(l=c+d)):d<0?(l=o+d,d=0):d+o>c&&(l=c-d),t.isHorizontal()?(i.transform(`translate3d(${d}px, 0, 0)`),i[0].style.width=`${l}px`):(i.transform(`translate3d(0px, ${d}px, 0)`),i[0].style.height=`${l}px`),n.hide&&(clearTimeout(m),r[0].style.opacity=1,m=setTimeout((()=>{r[0].style.opacity=0,r.transition(400)}),1e3))}function v(){if(!t.params.scrollbar.el||!t.scrollbar.el)return;const{scrollbar:e}=t,{$dragEl:s,$el:a}=e;s[0].style.width="",s[0].style.height="",c=t.isHorizontal()?a[0].offsetWidth:a[0].offsetHeight,u=t.size/(t.virtualSize+t.params.slidesOffsetBefore-(t.params.centeredSlides?t.snapGrid[0]:0)),o="auto"===t.params.scrollbar.dragSize?c*u:parseInt(t.params.scrollbar.dragSize,10),t.isHorizontal()?s[0].style.width=`${o}px`:s[0].style.height=`${o}px`,a[0].style.display=u>=1?"none":"",t.params.scrollbar.hide&&(a[0].style.opacity=0),t.params.watchOverflow&&t.enabled&&e.$el[t.isLocked?"addClass":"removeClass"](t.params.scrollbar.lockClass)}function w(e){return t.isHorizontal()?"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].clientX:e.clientX:"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].clientY:e.clientY}function b(e){const{scrollbar:s,rtlTranslate:a}=t,{$el:i}=s;let r;r=(w(e)-i.offset()[t.isHorizontal()?"left":"top"]-(null!==l?l:o/2))/(c-o),r=Math.max(Math.min(r,1),0),a&&(r=1-r);const n=t.minTranslate()+(t.maxTranslate()-t.minTranslate())*r;t.updateProgress(n),t.setTranslate(n),t.updateActiveIndex(),t.updateSlidesClasses()}function x(e){const s=t.params.scrollbar,{scrollbar:a,$wrapperEl:i}=t,{$el:n,$dragEl:o}=a;h=!0,l=e.target===o[0]||e.target===o?w(e)-e.target.getBoundingClientRect()[t.isHorizontal()?"left":"top"]:null,e.preventDefault(),e.stopPropagation(),i.transition(100),o.transition(100),b(e),clearTimeout(f),n.transition(0),s.hide&&n.css("opacity",1),t.params.cssMode&&t.$wrapperEl.css("scroll-snap-type","none"),r("scrollbarDragStart",e)}function y(e){const{scrollbar:s,$wrapperEl:a}=t,{$el:i,$dragEl:n}=s;h&&(e.preventDefault?e.preventDefault():e.returnValue=!1,b(e),a.transition(0),i.transition(0),n.transition(0),r("scrollbarDragMove",e))}function E(e){const s=t.params.scrollbar,{scrollbar:a,$wrapperEl:i}=t,{$el:n}=a;h&&(h=!1,t.params.cssMode&&(t.$wrapperEl.css("scroll-snap-type",""),i.transition("")),s.hide&&(clearTimeout(f),f=p((()=>{n.css("opacity",0),n.transition(400)}),1e3)),r("scrollbarDragEnd",e),s.snapOnRelease&&t.slideToClosest())}function C(e){const{scrollbar:s,touchEventsTouch:a,touchEventsDesktop:i,params:r,support:l}=t,o=s.$el;if(!o)return;const d=o[0],c=!(!l.passiveListener||!r.passiveListeners)&&{passive:!1,capture:!1},p=!(!l.passiveListener||!r.passiveListeners)&&{passive:!0,capture:!1};if(!d)return;const u="on"===e?"addEventListener":"removeEventListener";l.touch?(d[u](a.start,x,c),d[u](a.move,y,c),d[u](a.end,E,p)):(d[u](i.start,x,c),n[u](i.move,y,c),n[u](i.end,E,p))}function T(){const{scrollbar:e,$el:s}=t;t.params.scrollbar=F(t,t.originalParams.scrollbar,t.params.scrollbar,{el:"swiper-scrollbar"});const a=t.params.scrollbar;if(!a.el)return;let i=d(a.el);t.params.uniqueNavElements&&"string"==typeof a.el&&i.length>1&&1===s.find(a.el).length&&(i=s.find(a.el)),i.addClass(t.isHorizontal()?a.horizontalClass:a.verticalClass);let r=i.find(`.${t.params.scrollbar.dragClass}`);0===r.length&&(r=d(`
`),i.append(r)),Object.assign(e,{$el:i,el:i[0],$dragEl:r,dragEl:r[0]}),a.draggable&&t.params.scrollbar.el&&t.scrollbar.el&&C("on"),i&&i[t.enabled?"removeClass":"addClass"](t.params.scrollbar.lockClass)}function $(){const e=t.params.scrollbar,s=t.scrollbar.$el;s&&s.removeClass(t.isHorizontal()?e.horizontalClass:e.verticalClass),t.params.scrollbar.el&&t.scrollbar.el&&C("off")}s({scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag",scrollbarDisabledClass:"swiper-scrollbar-disabled",horizontalClass:"swiper-scrollbar-horizontal",verticalClass:"swiper-scrollbar-vertical"}}),t.scrollbar={el:null,dragEl:null,$el:null,$dragEl:null},i("init",(()=>{!1===t.params.scrollbar.enabled?S():(T(),v(),g())})),i("update resize observerUpdate lock unlock",(()=>{v()})),i("setTranslate",(()=>{g()})),i("setTransition",((e,s)=>{!function(e){t.params.scrollbar.el&&t.scrollbar.el&&t.scrollbar.$dragEl.transition(e)}(s)})),i("enable disable",(()=>{const{$el:e}=t.scrollbar;e&&e[t.enabled?"removeClass":"addClass"](t.params.scrollbar.lockClass)})),i("destroy",(()=>{$()}));const S=()=>{t.$el.addClass(t.params.scrollbar.scrollbarDisabledClass),t.scrollbar.$el&&t.scrollbar.$el.addClass(t.params.scrollbar.scrollbarDisabledClass),$()};Object.assign(t.scrollbar,{enable:()=>{t.$el.removeClass(t.params.scrollbar.scrollbarDisabledClass),t.scrollbar.$el&&t.scrollbar.$el.removeClass(t.params.scrollbar.scrollbarDisabledClass),T(),v(),g()},disable:S,updateSize:v,setTranslate:g,init:T,destroy:$})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({parallax:{enabled:!1}});const i=(e,s)=>{const{rtl:a}=t,i=d(e),r=a?-1:1,n=i.attr("data-swiper-parallax")||"0";let l=i.attr("data-swiper-parallax-x"),o=i.attr("data-swiper-parallax-y");const c=i.attr("data-swiper-parallax-scale"),p=i.attr("data-swiper-parallax-opacity");if(l||o?(l=l||"0",o=o||"0"):t.isHorizontal()?(l=n,o="0"):(o=n,l="0"),l=l.indexOf("%")>=0?parseInt(l,10)*s*r+"%":l*s*r+"px",o=o.indexOf("%")>=0?parseInt(o,10)*s+"%":o*s+"px",null!=p){const e=p-(p-1)*(1-Math.abs(s));i[0].style.opacity=e}if(null==c)i.transform(`translate3d(${l}, ${o}, 0px)`);else{const e=c-(c-1)*(1-Math.abs(s));i.transform(`translate3d(${l}, ${o}, 0px) scale(${e})`)}},r=()=>{const{$el:e,slides:s,progress:a,snapGrid:r}=t;e.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((e=>{i(e,a)})),s.each(((e,s)=>{let n=e.progress;t.params.slidesPerGroup>1&&"auto"!==t.params.slidesPerView&&(n+=Math.ceil(s/2)-a*(r.length-1)),n=Math.min(Math.max(n,-1),1),d(e).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((e=>{i(e,n)}))}))};a("beforeInit",(()=>{t.params.parallax.enabled&&(t.params.watchSlidesProgress=!0,t.originalParams.watchSlidesProgress=!0)})),a("init",(()=>{t.params.parallax.enabled&&r()})),a("setTranslate",(()=>{t.params.parallax.enabled&&r()})),a("setTransition",((e,s)=>{t.params.parallax.enabled&&function(e){void 0===e&&(e=t.params.speed);const{$el:s}=t;s.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each((t=>{const s=d(t);let a=parseInt(s.attr("data-swiper-parallax-duration"),10)||e;0===e&&(a=0),s.transition(a)}))}(s)}))},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;const n=r();s({zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}}),t.zoom={enabled:!1};let l,o,c,p=1,u=!1;const m={$slideEl:void 0,slideWidth:void 0,slideHeight:void 0,$imageEl:void 0,$imageWrapEl:void 0,maxRatio:3},f={isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},g={x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0};let v=1;function w(e){if(e.targetTouches.length<2)return 1;const t=e.targetTouches[0].pageX,s=e.targetTouches[0].pageY,a=e.targetTouches[1].pageX,i=e.targetTouches[1].pageY;return Math.sqrt((a-t)**2+(i-s)**2)}function b(e){const s=t.support,a=t.params.zoom;if(o=!1,c=!1,!s.gestures){if("touchstart"!==e.type||"touchstart"===e.type&&e.targetTouches.length<2)return;o=!0,m.scaleStart=w(e)}m.$slideEl&&m.$slideEl.length||(m.$slideEl=d(e.target).closest(`.${t.params.slideClass}`),0===m.$slideEl.length&&(m.$slideEl=t.slides.eq(t.activeIndex)),m.$imageEl=m.$slideEl.find(`.${a.containerClass}`).eq(0).find("picture, img, svg, canvas, .swiper-zoom-target").eq(0),m.$imageWrapEl=m.$imageEl.parent(`.${a.containerClass}`),m.maxRatio=m.$imageWrapEl.attr("data-swiper-zoom")||a.maxRatio,0!==m.$imageWrapEl.length)?(m.$imageEl&&m.$imageEl.transition(0),u=!0):m.$imageEl=void 0}function x(e){const s=t.support,a=t.params.zoom,i=t.zoom;if(!s.gestures){if("touchmove"!==e.type||"touchmove"===e.type&&e.targetTouches.length<2)return;c=!0,m.scaleMove=w(e)}m.$imageEl&&0!==m.$imageEl.length?(s.gestures?i.scale=e.scale*p:i.scale=m.scaleMove/m.scaleStart*p,i.scale>m.maxRatio&&(i.scale=m.maxRatio-1+(i.scale-m.maxRatio+1)**.5),i.scalef.touchesStart.x))return void(f.isTouched=!1);if(!t.isHorizontal()&&(Math.floor(f.minY)===Math.floor(f.startY)&&f.touchesCurrent.yf.touchesStart.y))return void(f.isTouched=!1)}e.cancelable&&e.preventDefault(),e.stopPropagation(),f.isMoved=!0,f.currentX=f.touchesCurrent.x-f.touchesStart.x+f.startX,f.currentY=f.touchesCurrent.y-f.touchesStart.y+f.startY,f.currentXf.maxX&&(f.currentX=f.maxX-1+(f.currentX-f.maxX+1)**.8),f.currentYf.maxY&&(f.currentY=f.maxY-1+(f.currentY-f.maxY+1)**.8),g.prevPositionX||(g.prevPositionX=f.touchesCurrent.x),g.prevPositionY||(g.prevPositionY=f.touchesCurrent.y),g.prevTime||(g.prevTime=Date.now()),g.x=(f.touchesCurrent.x-g.prevPositionX)/(Date.now()-g.prevTime)/2,g.y=(f.touchesCurrent.y-g.prevPositionY)/(Date.now()-g.prevTime)/2,Math.abs(f.touchesCurrent.x-g.prevPositionX)<2&&(g.x=0),Math.abs(f.touchesCurrent.y-g.prevPositionY)<2&&(g.y=0),g.prevPositionX=f.touchesCurrent.x,g.prevPositionY=f.touchesCurrent.y,g.prevTime=Date.now(),m.$imageWrapEl.transform(`translate3d(${f.currentX}px, ${f.currentY}px,0)`)}}function C(){const e=t.zoom;m.$slideEl&&t.previousIndex!==t.activeIndex&&(m.$imageEl&&m.$imageEl.transform("translate3d(0,0,0) scale(1)"),m.$imageWrapEl&&m.$imageWrapEl.transform("translate3d(0,0,0)"),e.scale=1,p=1,m.$slideEl=void 0,m.$imageEl=void 0,m.$imageWrapEl=void 0)}function T(e){const s=t.zoom,a=t.params.zoom;if(m.$slideEl||(e&&e.target&&(m.$slideEl=d(e.target).closest(`.${t.params.slideClass}`)),m.$slideEl||(t.params.virtual&&t.params.virtual.enabled&&t.virtual?m.$slideEl=t.$wrapperEl.children(`.${t.params.slideActiveClass}`):m.$slideEl=t.slides.eq(t.activeIndex)),m.$imageEl=m.$slideEl.find(`.${a.containerClass}`).eq(0).find("picture, img, svg, canvas, .swiper-zoom-target").eq(0),m.$imageWrapEl=m.$imageEl.parent(`.${a.containerClass}`)),!m.$imageEl||0===m.$imageEl.length||!m.$imageWrapEl||0===m.$imageWrapEl.length)return;let i,r,l,o,c,u,h,g,v,w,b,x,y,E,C,T,$,S;t.params.cssMode&&(t.wrapperEl.style.overflow="hidden",t.wrapperEl.style.touchAction="none"),m.$slideEl.addClass(`${a.zoomedSlideClass}`),void 0===f.touchesStart.x&&e?(i="touchend"===e.type?e.changedTouches[0].pageX:e.pageX,r="touchend"===e.type?e.changedTouches[0].pageY:e.pageY):(i=f.touchesStart.x,r=f.touchesStart.y),s.scale=m.$imageWrapEl.attr("data-swiper-zoom")||a.maxRatio,p=m.$imageWrapEl.attr("data-swiper-zoom")||a.maxRatio,e?($=m.$slideEl[0].offsetWidth,S=m.$slideEl[0].offsetHeight,l=m.$slideEl.offset().left+n.scrollX,o=m.$slideEl.offset().top+n.scrollY,c=l+$/2-i,u=o+S/2-r,v=m.$imageEl[0].offsetWidth,w=m.$imageEl[0].offsetHeight,b=v*s.scale,x=w*s.scale,y=Math.min($/2-b/2,0),E=Math.min(S/2-x/2,0),C=-y,T=-E,h=c*s.scale,g=u*s.scale,hC&&(h=C),gT&&(g=T)):(h=0,g=0),m.$imageWrapEl.transition(300).transform(`translate3d(${h}px, ${g}px,0)`),m.$imageEl.transition(300).transform(`translate3d(0,0,0) scale(${s.scale})`)}function $(){const e=t.zoom,s=t.params.zoom;m.$slideEl||(t.params.virtual&&t.params.virtual.enabled&&t.virtual?m.$slideEl=t.$wrapperEl.children(`.${t.params.slideActiveClass}`):m.$slideEl=t.slides.eq(t.activeIndex),m.$imageEl=m.$slideEl.find(`.${s.containerClass}`).eq(0).find("picture, img, svg, canvas, .swiper-zoom-target").eq(0),m.$imageWrapEl=m.$imageEl.parent(`.${s.containerClass}`)),m.$imageEl&&0!==m.$imageEl.length&&m.$imageWrapEl&&0!==m.$imageWrapEl.length&&(t.params.cssMode&&(t.wrapperEl.style.overflow="",t.wrapperEl.style.touchAction=""),e.scale=1,p=1,m.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),m.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),m.$slideEl.removeClass(`${s.zoomedSlideClass}`),m.$slideEl=void 0)}function S(e){const s=t.zoom;s.scale&&1!==s.scale?$():T(e)}function M(){const e=t.support;return{passiveListener:!("touchstart"!==t.touchEvents.start||!e.passiveListener||!t.params.passiveListeners)&&{passive:!0,capture:!1},activeListenerWithCapture:!e.passiveListener||{passive:!1,capture:!0}}}function P(){return`.${t.params.slideClass}`}function k(e){const{passiveListener:s}=M(),a=P();t.$wrapperEl[e]("gesturestart",a,b,s),t.$wrapperEl[e]("gesturechange",a,x,s),t.$wrapperEl[e]("gestureend",a,y,s)}function z(){l||(l=!0,k("on"))}function L(){l&&(l=!1,k("off"))}function O(){const e=t.zoom;if(e.enabled)return;e.enabled=!0;const s=t.support,{passiveListener:a,activeListenerWithCapture:i}=M(),r=P();s.gestures?(t.$wrapperEl.on(t.touchEvents.start,z,a),t.$wrapperEl.on(t.touchEvents.end,L,a)):"touchstart"===t.touchEvents.start&&(t.$wrapperEl.on(t.touchEvents.start,r,b,a),t.$wrapperEl.on(t.touchEvents.move,r,x,i),t.$wrapperEl.on(t.touchEvents.end,r,y,a),t.touchEvents.cancel&&t.$wrapperEl.on(t.touchEvents.cancel,r,y,a)),t.$wrapperEl.on(t.touchEvents.move,`.${t.params.zoom.containerClass}`,E,i)}function I(){const e=t.zoom;if(!e.enabled)return;const s=t.support;e.enabled=!1;const{passiveListener:a,activeListenerWithCapture:i}=M(),r=P();s.gestures?(t.$wrapperEl.off(t.touchEvents.start,z,a),t.$wrapperEl.off(t.touchEvents.end,L,a)):"touchstart"===t.touchEvents.start&&(t.$wrapperEl.off(t.touchEvents.start,r,b,a),t.$wrapperEl.off(t.touchEvents.move,r,x,i),t.$wrapperEl.off(t.touchEvents.end,r,y,a),t.touchEvents.cancel&&t.$wrapperEl.off(t.touchEvents.cancel,r,y,a)),t.$wrapperEl.off(t.touchEvents.move,`.${t.params.zoom.containerClass}`,E,i)}Object.defineProperty(t.zoom,"scale",{get:()=>v,set(e){if(v!==e){const t=m.$imageEl?m.$imageEl[0]:void 0,s=m.$slideEl?m.$slideEl[0]:void 0;i("zoomChange",e,t,s)}v=e}}),a("init",(()=>{t.params.zoom.enabled&&O()})),a("destroy",(()=>{I()})),a("touchStart",((e,s)=>{t.zoom.enabled&&function(e){const s=t.device;m.$imageEl&&0!==m.$imageEl.length&&(f.isTouched||(s.android&&e.cancelable&&e.preventDefault(),f.isTouched=!0,f.touchesStart.x="touchstart"===e.type?e.targetTouches[0].pageX:e.pageX,f.touchesStart.y="touchstart"===e.type?e.targetTouches[0].pageY:e.pageY))}(s)})),a("touchEnd",((e,s)=>{t.zoom.enabled&&function(){const e=t.zoom;if(!m.$imageEl||0===m.$imageEl.length)return;if(!f.isTouched||!f.isMoved)return f.isTouched=!1,void(f.isMoved=!1);f.isTouched=!1,f.isMoved=!1;let s=300,a=300;const i=g.x*s,r=f.currentX+i,n=g.y*a,l=f.currentY+n;0!==g.x&&(s=Math.abs((r-f.currentX)/g.x)),0!==g.y&&(a=Math.abs((l-f.currentY)/g.y));const o=Math.max(s,a);f.currentX=r,f.currentY=l;const d=f.width*e.scale,c=f.height*e.scale;f.minX=Math.min(m.slideWidth/2-d/2,0),f.maxX=-f.minX,f.minY=Math.min(m.slideHeight/2-c/2,0),f.maxY=-f.minY,f.currentX=Math.max(Math.min(f.currentX,f.maxX),f.minX),f.currentY=Math.max(Math.min(f.currentY,f.maxY),f.minY),m.$imageWrapEl.transition(o).transform(`translate3d(${f.currentX}px, ${f.currentY}px,0)`)}()})),a("doubleTap",((e,s)=>{!t.animating&&t.params.zoom.enabled&&t.zoom.enabled&&t.params.zoom.toggle&&S(s)})),a("transitionEnd",(()=>{t.zoom.enabled&&t.params.zoom.enabled&&C()})),a("slideChange",(()=>{t.zoom.enabled&&t.params.zoom.enabled&&t.params.cssMode&&C()})),Object.assign(t.zoom,{enable:O,disable:I,in:T,out:$,toggle:S})},function(e){let{swiper:t,extendParams:s,on:a,emit:i}=e;s({lazy:{checkInView:!1,enabled:!1,loadPrevNext:!1,loadPrevNextAmount:1,loadOnTransitionStart:!1,scrollingElement:"",elementClass:"swiper-lazy",loadingClass:"swiper-lazy-loading",loadedClass:"swiper-lazy-loaded",preloaderClass:"swiper-lazy-preloader"}}),t.lazy={};let n=!1,l=!1;function o(e,s){void 0===s&&(s=!0);const a=t.params.lazy;if(void 0===e)return;if(0===t.slides.length)return;const r=t.virtual&&t.params.virtual.enabled?t.$wrapperEl.children(`.${t.params.slideClass}[data-swiper-slide-index="${e}"]`):t.slides.eq(e),n=r.find(`.${a.elementClass}:not(.${a.loadedClass}):not(.${a.loadingClass})`);!r.hasClass(a.elementClass)||r.hasClass(a.loadedClass)||r.hasClass(a.loadingClass)||n.push(r[0]),0!==n.length&&n.each((e=>{const n=d(e);n.addClass(a.loadingClass);const l=n.attr("data-background"),c=n.attr("data-src"),p=n.attr("data-srcset"),u=n.attr("data-sizes"),h=n.parent("picture");t.loadImage(n[0],c||l,p,u,!1,(()=>{if(null!=t&&t&&(!t||t.params)&&!t.destroyed){if(l?(n.css("background-image",`url("${l}")`),n.removeAttr("data-background")):(p&&(n.attr("srcset",p),n.removeAttr("data-srcset")),u&&(n.attr("sizes",u),n.removeAttr("data-sizes")),h.length&&h.children("source").each((e=>{const t=d(e);t.attr("data-srcset")&&(t.attr("srcset",t.attr("data-srcset")),t.removeAttr("data-srcset"))})),c&&(n.attr("src",c),n.removeAttr("data-src"))),n.addClass(a.loadedClass).removeClass(a.loadingClass),r.find(`.${a.preloaderClass}`).remove(),t.params.loop&&s){const e=r.attr("data-swiper-slide-index");if(r.hasClass(t.params.slideDuplicateClass)){o(t.$wrapperEl.children(`[data-swiper-slide-index="${e}"]:not(.${t.params.slideDuplicateClass})`).index(),!1)}else{o(t.$wrapperEl.children(`.${t.params.slideDuplicateClass}[data-swiper-slide-index="${e}"]`).index(),!1)}}i("lazyImageReady",r[0],n[0]),t.params.autoHeight&&t.updateAutoHeight()}})),i("lazyImageLoad",r[0],n[0])}))}function c(){const{$wrapperEl:e,params:s,slides:a,activeIndex:i}=t,r=t.virtual&&s.virtual.enabled,n=s.lazy;let c=s.slidesPerView;function p(t){if(r){if(e.children(`.${s.slideClass}[data-swiper-slide-index="${t}"]`).length)return!0}else if(a[t])return!0;return!1}function u(e){return r?d(e).attr("data-swiper-slide-index"):d(e).index()}if("auto"===c&&(c=0),l||(l=!0),t.params.watchSlidesProgress)e.children(`.${s.slideVisibleClass}`).each((e=>{o(r?d(e).attr("data-swiper-slide-index"):d(e).index())}));else if(c>1)for(let e=i;e1||n.loadPrevNextAmount&&n.loadPrevNextAmount>1){const e=n.loadPrevNextAmount,t=Math.ceil(c),s=Math.min(i+t+Math.max(e,t),a.length),r=Math.max(i-Math.max(t,e),0);for(let e=i+t;e0&&o(u(t));const a=e.children(`.${s.slidePrevClass}`);a.length>0&&o(u(a))}}function p(){const e=r();if(!t||t.destroyed)return;const s=t.params.lazy.scrollingElement?d(t.params.lazy.scrollingElement):d(e),a=s[0]===e,i=a?e.innerWidth:s[0].offsetWidth,l=a?e.innerHeight:s[0].offsetHeight,o=t.$el.offset(),{rtlTranslate:u}=t;let h=!1;u&&(o.left-=t.$el[0].scrollLeft);const m=[[o.left,o.top],[o.left+t.width,o.top],[o.left,o.top+t.height],[o.left+t.width,o.top+t.height]];for(let e=0;e=0&&t[0]<=i&&t[1]>=0&&t[1]<=l){if(0===t[0]&&0===t[1])continue;h=!0}}const f=!("touchstart"!==t.touchEvents.start||!t.support.passiveListener||!t.params.passiveListeners)&&{passive:!0,capture:!1};h?(c(),s.off("scroll",p,f)):n||(n=!0,s.on("scroll",p,f))}a("beforeInit",(()=>{t.params.lazy.enabled&&t.params.preloadImages&&(t.params.preloadImages=!1)})),a("init",(()=>{t.params.lazy.enabled&&(t.params.lazy.checkInView?p():c())})),a("scroll",(()=>{t.params.freeMode&&t.params.freeMode.enabled&&!t.params.freeMode.sticky&&c()})),a("scrollbarDragMove resize _freeModeNoMomentumRelease",(()=>{t.params.lazy.enabled&&(t.params.lazy.checkInView?p():c())})),a("transitionStart",(()=>{t.params.lazy.enabled&&(t.params.lazy.loadOnTransitionStart||!t.params.lazy.loadOnTransitionStart&&!l)&&(t.params.lazy.checkInView?p():c())})),a("transitionEnd",(()=>{t.params.lazy.enabled&&!t.params.lazy.loadOnTransitionStart&&(t.params.lazy.checkInView?p():c())})),a("slideChange",(()=>{const{lazy:e,cssMode:s,watchSlidesProgress:a,touchReleaseOnEdges:i,resistanceRatio:r}=t.params;e.enabled&&(s||a&&(i||0===r))&&c()})),a("destroy",(()=>{t.$el&&t.$el.find(`.${t.params.lazy.loadingClass}`).removeClass(t.params.lazy.loadingClass)})),Object.assign(t.lazy,{load:c,loadInSlide:o})},function(e){let{swiper:t,extendParams:s,on:a}=e;function i(e,t){const s=function(){let e,t,s;return(a,i)=>{for(t=-1,e=a.length;e-t>1;)s=e+t>>1,a[s]<=i?t=s:e=s;return e}}();let a,i;return this.x=e,this.y=t,this.lastIndex=e.length-1,this.interpolate=function(e){return e?(i=s(this.x,e),a=i-1,(e-this.x[a])*(this.y[i]-this.y[a])/(this.x[i]-this.x[a])+this.y[a]):0},this}function r(){t.controller.control&&t.controller.spline&&(t.controller.spline=void 0,delete t.controller.spline)}s({controller:{control:void 0,inverse:!1,by:"slide"}}),t.controller={control:void 0},a("beforeInit",(()=>{t.controller.control=t.params.controller.control})),a("update",(()=>{r()})),a("resize",(()=>{r()})),a("observerUpdate",(()=>{r()})),a("setTranslate",((e,s,a)=>{t.controller.control&&t.controller.setTranslate(s,a)})),a("setTransition",((e,s,a)=>{t.controller.control&&t.controller.setTransition(s,a)})),Object.assign(t.controller,{setTranslate:function(e,s){const a=t.controller.control;let r,n;const l=t.constructor;function o(e){const s=t.rtlTranslate?-t.translate:t.translate;"slide"===t.params.controller.by&&(!function(e){t.controller.spline||(t.controller.spline=t.params.loop?new i(t.slidesGrid,e.slidesGrid):new i(t.snapGrid,e.snapGrid))}(e),n=-t.controller.spline.interpolate(-s)),n&&"container"!==t.params.controller.by||(r=(e.maxTranslate()-e.minTranslate())/(t.maxTranslate()-t.minTranslate()),n=(s-t.minTranslate())*r+e.minTranslate()),t.params.controller.inverse&&(n=e.maxTranslate()-n),e.updateProgress(n),e.setTranslate(n,t),e.updateActiveIndex(),e.updateSlidesClasses()}if(Array.isArray(a))for(let e=0;e{s.updateAutoHeight()})),s.$wrapperEl.transitionEnd((()=>{i&&(s.params.loop&&"slide"===t.params.controller.by&&s.loopFix(),s.transitionEnd())})))}if(Array.isArray(i))for(r=0;r{n(e),"BUTTON"!==e[0].tagName&&(o(e,"button"),e.on("keydown",m)),p(e,s),function(e,t){e.attr("aria-controls",t)}(e,t)},w=()=>{t.a11y.clicked=!0},b=()=>{requestAnimationFrame((()=>{requestAnimationFrame((()=>{t.a11y.clicked=!1}))}))},x=e=>{if(t.a11y.clicked)return;const s=e.target.closest(`.${t.params.slideClass}`);if(!s||!t.slides.includes(s))return;const a=t.slides.indexOf(s)===t.activeIndex,i=t.params.watchSlidesProgress&&t.visibleSlides&&t.visibleSlides.includes(s);a||i||(t.isHorizontal()?t.el.scrollLeft=0:t.el.scrollTop=0,t.slideTo(t.slides.indexOf(s),0))},y=()=>{const e=t.params.a11y;e.itemRoleDescriptionMessage&&c(d(t.slides),e.itemRoleDescriptionMessage),e.slideRole&&o(d(t.slides),e.slideRole);const s=t.params.loop?t.slides.filter((e=>!e.classList.contains(t.params.slideDuplicateClass))).length:t.slides.length;e.slideLabelMessage&&t.slides.each(((a,i)=>{const r=d(a),n=t.params.loop?parseInt(r.attr("data-swiper-slide-index"),10):i;p(r,e.slideLabelMessage.replace(/\{\{index\}\}/,n+1).replace(/\{\{slidesLength\}\}/,s))}))},E=()=>{const e=t.params.a11y;t.$el.append(i);const s=t.$el;e.containerRoleDescriptionMessage&&c(s,e.containerRoleDescriptionMessage),e.containerMessage&&p(s,e.containerMessage);const a=t.$wrapperEl,r=e.id||a.attr("id")||`swiper-wrapper-${n=16,void 0===n&&(n=16),"x".repeat(n).replace(/x/g,(()=>Math.round(16*Math.random()).toString(16)))}`;var n;const l=t.params.autoplay&&t.params.autoplay.enabled?"off":"polite";var o;let d,u;o=r,a.attr("id",o),function(e,t){e.attr("aria-live",t)}(a,l),y(),t.navigation&&t.navigation.$nextEl&&(d=t.navigation.$nextEl),t.navigation&&t.navigation.$prevEl&&(u=t.navigation.$prevEl),d&&d.length&&v(d,r,e.nextSlideMessage),u&&u.length&&v(u,r,e.prevSlideMessage),g()&&t.pagination.$el.on("keydown",U(t.params.pagination.bulletClass),m),t.$el.on("focus",x,!0),t.$el.on("pointerdown",w,!0),t.$el.on("pointerup",b,!0)};a("beforeInit",(()=>{i=d(``)})),a("afterInit",(()=>{t.params.a11y.enabled&&E()})),a("slidesLengthChange snapGridLengthChange slidesGridLengthChange",(()=>{t.params.a11y.enabled&&y()})),a("fromEdge toEdge afterInit lock unlock",(()=>{t.params.a11y.enabled&&function(){if(t.params.loop||t.params.rewind||!t.navigation)return;const{$nextEl:e,$prevEl:s}=t.navigation;s&&s.length>0&&(t.isBeginning?(u(s),l(s)):(h(s),n(s))),e&&e.length>0&&(t.isEnd?(u(e),l(e)):(h(e),n(e)))}()})),a("paginationUpdate",(()=>{t.params.a11y.enabled&&function(){const e=t.params.a11y;f()&&t.pagination.bullets.each((s=>{const a=d(s);t.params.pagination.clickable&&(n(a),t.params.pagination.renderBullet||(o(a,"button"),p(a,e.paginationBulletMessage.replace(/\{\{index\}\}/,a.index()+1)))),a.is(`.${t.params.pagination.bulletActiveClass}`)?a.attr("aria-current","true"):a.removeAttr("aria-current")}))}()})),a("destroy",(()=>{t.params.a11y.enabled&&function(){let e,s;i&&i.length>0&&i.remove(),t.navigation&&t.navigation.$nextEl&&(e=t.navigation.$nextEl),t.navigation&&t.navigation.$prevEl&&(s=t.navigation.$prevEl),e&&e.off("keydown",m),s&&s.off("keydown",m),g()&&t.pagination.$el.off("keydown",U(t.params.pagination.bulletClass),m),t.$el.off("focus",x,!0),t.$el.off("pointerdown",w,!0),t.$el.off("pointerup",b,!0)}()}))},function(e){let{swiper:t,extendParams:s,on:a}=e;s({history:{enabled:!1,root:"",replaceState:!1,key:"slides",keepQuery:!1}});let i=!1,n={};const l=e=>e.toString().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,""),o=e=>{const t=r();let s;s=e?new URL(e):t.location;const a=s.pathname.slice(1).split("/").filter((e=>""!==e)),i=a.length;return{key:a[i-2],value:a[i-1]}},d=(e,s)=>{const a=r();if(!i||!t.params.history.enabled)return;let n;n=t.params.url?new URL(t.params.url):a.location;const o=t.slides.eq(s);let d=l(o.attr("data-history"));if(t.params.history.root.length>0){let s=t.params.history.root;"/"===s[s.length-1]&&(s=s.slice(0,s.length-1)),d=`${s}/${e}/${d}`}else n.pathname.includes(e)||(d=`${e}/${d}`);t.params.history.keepQuery&&(d+=n.search);const c=a.history.state;c&&c.value===d||(t.params.history.replaceState?a.history.replaceState({value:d},null,d):a.history.pushState({value:d},null,d))},c=(e,s,a)=>{if(s)for(let i=0,r=t.slides.length;i{n=o(t.params.url),c(t.params.speed,n.value,!1)};a("init",(()=>{t.params.history.enabled&&(()=>{const e=r();if(t.params.history){if(!e.history||!e.history.pushState)return t.params.history.enabled=!1,void(t.params.hashNavigation.enabled=!0);i=!0,n=o(t.params.url),(n.key||n.value)&&(c(0,n.value,t.params.runCallbacksOnInit),t.params.history.replaceState||e.addEventListener("popstate",p))}})()})),a("destroy",(()=>{t.params.history.enabled&&(()=>{const e=r();t.params.history.replaceState||e.removeEventListener("popstate",p)})()})),a("transitionEnd _freeModeNoMomentumRelease",(()=>{i&&d(t.params.history.key,t.activeIndex)})),a("slideChange",(()=>{i&&t.params.cssMode&&d(t.params.history.key,t.activeIndex)}))},function(e){let{swiper:t,extendParams:s,emit:i,on:n}=e,l=!1;const o=a(),c=r();s({hashNavigation:{enabled:!1,replaceState:!1,watchState:!1}});const p=()=>{i("hashChange");const e=o.location.hash.replace("#","");if(e!==t.slides.eq(t.activeIndex).attr("data-hash")){const s=t.$wrapperEl.children(`.${t.params.slideClass}[data-hash="${e}"]`).index();if(void 0===s)return;t.slideTo(s)}},u=()=>{if(l&&t.params.hashNavigation.enabled)if(t.params.hashNavigation.replaceState&&c.history&&c.history.replaceState)c.history.replaceState(null,null,`#${t.slides.eq(t.activeIndex).attr("data-hash")}`||""),i("hashSet");else{const e=t.slides.eq(t.activeIndex),s=e.attr("data-hash")||e.attr("data-history");o.location.hash=s||"",i("hashSet")}};n("init",(()=>{t.params.hashNavigation.enabled&&(()=>{if(!t.params.hashNavigation.enabled||t.params.history&&t.params.history.enabled)return;l=!0;const e=o.location.hash.replace("#","");if(e){const s=0;for(let a=0,i=t.slides.length;a{t.params.hashNavigation.enabled&&t.params.hashNavigation.watchState&&d(c).off("hashchange",p)})),n("transitionEnd _freeModeNoMomentumRelease",(()=>{l&&u()})),n("slideChange",(()=>{l&&t.params.cssMode&&u()}))},function(e){let t,{swiper:s,extendParams:i,on:r,emit:n}=e;function l(){if(!s.size)return s.autoplay.running=!1,void(s.autoplay.paused=!1);const e=s.slides.eq(s.activeIndex);let a=s.params.autoplay.delay;e.attr("data-swiper-autoplay")&&(a=e.attr("data-swiper-autoplay")||s.params.autoplay.delay),clearTimeout(t),t=p((()=>{let e;s.params.autoplay.reverseDirection?s.params.loop?(s.loopFix(),e=s.slidePrev(s.params.speed,!0,!0),n("autoplay")):s.isBeginning?s.params.autoplay.stopOnLastSlide?d():(e=s.slideTo(s.slides.length-1,s.params.speed,!0,!0),n("autoplay")):(e=s.slidePrev(s.params.speed,!0,!0),n("autoplay")):s.params.loop?(s.loopFix(),e=s.slideNext(s.params.speed,!0,!0),n("autoplay")):s.isEnd?s.params.autoplay.stopOnLastSlide?d():(e=s.slideTo(0,s.params.speed,!0,!0),n("autoplay")):(e=s.slideNext(s.params.speed,!0,!0),n("autoplay")),(s.params.cssMode&&s.autoplay.running||!1===e)&&l()}),a)}function o(){return void 0===t&&(!s.autoplay.running&&(s.autoplay.running=!0,n("autoplayStart"),l(),!0))}function d(){return!!s.autoplay.running&&(void 0!==t&&(t&&(clearTimeout(t),t=void 0),s.autoplay.running=!1,n("autoplayStop"),!0))}function c(e){s.autoplay.running&&(s.autoplay.paused||(t&&clearTimeout(t),s.autoplay.paused=!0,0!==e&&s.params.autoplay.waitForTransition?["transitionend","webkitTransitionEnd"].forEach((e=>{s.$wrapperEl[0].addEventListener(e,h)})):(s.autoplay.paused=!1,l())))}function u(){const e=a();"hidden"===e.visibilityState&&s.autoplay.running&&c(),"visible"===e.visibilityState&&s.autoplay.paused&&(l(),s.autoplay.paused=!1)}function h(e){s&&!s.destroyed&&s.$wrapperEl&&e.target===s.$wrapperEl[0]&&(["transitionend","webkitTransitionEnd"].forEach((e=>{s.$wrapperEl[0].removeEventListener(e,h)})),s.autoplay.paused=!1,s.autoplay.running?l():d())}function m(){s.params.autoplay.disableOnInteraction?d():(n("autoplayPause"),c()),["transitionend","webkitTransitionEnd"].forEach((e=>{s.$wrapperEl[0].removeEventListener(e,h)}))}function f(){s.params.autoplay.disableOnInteraction||(s.autoplay.paused=!1,n("autoplayResume"),l())}s.autoplay={running:!1,paused:!1},i({autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!0,stopOnLastSlide:!1,reverseDirection:!1,pauseOnMouseEnter:!1}}),r("init",(()=>{if(s.params.autoplay.enabled){o();a().addEventListener("visibilitychange",u),s.params.autoplay.pauseOnMouseEnter&&(s.$el.on("mouseenter",m),s.$el.on("mouseleave",f))}})),r("beforeTransitionStart",((e,t,a)=>{s.autoplay.running&&(a||!s.params.autoplay.disableOnInteraction?s.autoplay.pause(t):d())})),r("sliderFirstMove",(()=>{s.autoplay.running&&(s.params.autoplay.disableOnInteraction?d():c())})),r("touchEnd",(()=>{s.params.cssMode&&s.autoplay.paused&&!s.params.autoplay.disableOnInteraction&&l()})),r("destroy",(()=>{s.$el.off("mouseenter",m),s.$el.off("mouseleave",f),s.autoplay.running&&d();a().removeEventListener("visibilitychange",u)})),Object.assign(s.autoplay,{pause:c,run:l,start:o,stop:d})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({thumbs:{swiper:null,multipleActiveThumbs:!0,autoScrollOffset:0,slideThumbActiveClass:"swiper-slide-thumb-active",thumbsContainerClass:"swiper-thumbs"}});let i=!1,r=!1;function n(){const e=t.thumbs.swiper;if(!e||e.destroyed)return;const s=e.clickedIndex,a=e.clickedSlide;if(a&&d(a).hasClass(t.params.thumbs.slideThumbActiveClass))return;if(null==s)return;let i;if(i=e.params.loop?parseInt(d(e.clickedSlide).attr("data-swiper-slide-index"),10):s,t.params.loop){let e=t.activeIndex;t.slides.eq(e).hasClass(t.params.slideDuplicateClass)&&(t.loopFix(),t._clientLeft=t.$wrapperEl[0].clientLeft,e=t.activeIndex);const s=t.slides.eq(e).prevAll(`[data-swiper-slide-index="${i}"]`).eq(0).index(),a=t.slides.eq(e).nextAll(`[data-swiper-slide-index="${i}"]`).eq(0).index();i=void 0===s?a:void 0===a?s:a-e1&&!t.params.centeredSlides&&(i=t.params.slidesPerView),t.params.thumbs.multipleActiveThumbs||(i=1),i=Math.floor(i),s.slides.removeClass(r),s.params.loop||s.params.virtual&&s.params.virtual.enabled)for(let e=0;e1?a:o:a-ot.previousIndex?"next":"prev"}else i=t.realIndex,r=i>t.previousIndex?"next":"prev";l&&(i+="next"===r?n:-1*n),s.visibleSlidesIndexes&&s.visibleSlidesIndexes.indexOf(i)<0&&(s.params.centeredSlides?i=i>o?i-Math.floor(a/2)+1:i+Math.floor(a/2)-1:i>o&&s.params.slidesPerGroup,s.slideTo(i,e?0:void 0))}}t.thumbs={swiper:null},a("beforeInit",(()=>{const{thumbs:e}=t.params;e&&e.swiper&&(l(),o(!0))})),a("slideChange update resize observerUpdate",(()=>{o()})),a("setTransition",((e,s)=>{const a=t.thumbs.swiper;a&&!a.destroyed&&a.setTransition(s)})),a("beforeDestroy",(()=>{const e=t.thumbs.swiper;e&&!e.destroyed&&r&&e.destroy()})),Object.assign(t.thumbs,{init:l,update:o})},function(e){let{swiper:t,extendParams:s,emit:a,once:i}=e;s({freeMode:{enabled:!1,momentum:!0,momentumRatio:1,momentumBounce:!0,momentumBounceRatio:1,momentumVelocityRatio:1,sticky:!1,minimumVelocity:.02}}),Object.assign(t,{freeMode:{onTouchStart:function(){const e=t.getTranslate();t.setTranslate(e),t.setTransition(0),t.touchEventsData.velocities.length=0,t.freeMode.onTouchEnd({currentPos:t.rtl?t.translate:-t.translate})},onTouchMove:function(){const{touchEventsData:e,touches:s}=t;0===e.velocities.length&&e.velocities.push({position:s[t.isHorizontal()?"startX":"startY"],time:e.touchStartTime}),e.velocities.push({position:s[t.isHorizontal()?"currentX":"currentY"],time:u()})},onTouchEnd:function(e){let{currentPos:s}=e;const{params:r,$wrapperEl:n,rtlTranslate:l,snapGrid:o,touchEventsData:d}=t,c=u()-d.touchStartTime;if(s<-t.minTranslate())t.slideTo(t.activeIndex);else if(s>-t.maxTranslate())t.slides.length1){const e=d.velocities.pop(),s=d.velocities.pop(),a=e.position-s.position,i=e.time-s.time;t.velocity=a/i,t.velocity/=2,Math.abs(t.velocity)150||u()-e.time>300)&&(t.velocity=0)}else t.velocity=0;t.velocity*=r.freeMode.momentumVelocityRatio,d.velocities.length=0;let e=1e3*r.freeMode.momentumRatio;const s=t.velocity*e;let c=t.translate+s;l&&(c=-c);let p,h=!1;const m=20*Math.abs(t.velocity)*r.freeMode.momentumBounceRatio;let f;if(ct.minTranslate())r.freeMode.momentumBounce?(c-t.minTranslate()>m&&(c=t.minTranslate()+m),p=t.minTranslate(),h=!0,d.allowMomentumBounce=!0):c=t.minTranslate(),r.loop&&r.centeredSlides&&(f=!0);else if(r.freeMode.sticky){let e;for(let t=0;t-c){e=t;break}c=Math.abs(o[e]-c){t.loopFix()})),0!==t.velocity){if(e=l?Math.abs((-c-t.translate)/t.velocity):Math.abs((c-t.translate)/t.velocity),r.freeMode.sticky){const s=Math.abs((l?-c:c)-t.translate),a=t.slidesSizesGrid[t.activeIndex];e=s{t&&!t.destroyed&&d.allowMomentumBounce&&(a("momentumBounce"),t.setTransition(r.speed),setTimeout((()=>{t.setTranslate(p),n.transitionEnd((()=>{t&&!t.destroyed&&t.transitionEnd()}))}),0))}))):t.velocity?(a("_freeModeNoMomentumRelease"),t.updateProgress(c),t.setTransition(e),t.setTranslate(c),t.transitionStart(!0,t.swipeDirection),t.animating||(t.animating=!0,n.transitionEnd((()=>{t&&!t.destroyed&&t.transitionEnd()})))):t.updateProgress(c),t.updateActiveIndex(),t.updateSlidesClasses()}else{if(r.freeMode.sticky)return void t.slideToClosest();r.freeMode&&a("_freeModeNoMomentumRelease")}(!r.freeMode.momentum||c>=r.longSwipesMs)&&(t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses())}}}})},function(e){let t,s,a,{swiper:i,extendParams:r}=e;r({grid:{rows:1,fill:"column"}}),i.grid={initSlides:e=>{const{slidesPerView:r}=i.params,{rows:n,fill:l}=i.params.grid;s=t/n,a=Math.floor(e/n),t=Math.floor(e/n)===e/n?e:Math.ceil(e/n)*n,"auto"!==r&&"row"===l&&(t=Math.max(t,r*n))},updateSlide:(e,r,n,l)=>{const{slidesPerGroup:o,spaceBetween:d}=i.params,{rows:c,fill:p}=i.params.grid;let u,h,m;if("row"===p&&o>1){const s=Math.floor(e/(o*c)),a=e-c*o*s,i=0===s?o:Math.min(Math.ceil((n-s*c*o)/c),o);m=Math.floor(a/i),h=a-m*i+s*o,u=h+m*t/c,r.css({"-webkit-order":u,order:u})}else"column"===p?(h=Math.floor(e/c),m=e-h*c,(h>a||h===a&&m===c-1)&&(m+=1,m>=c&&(m=0,h+=1))):(m=Math.floor(e/s),h=e-m*s);r.css(l("margin-top"),0!==m?d&&`${d}px`:"")},updateWrapperSize:(e,s,a)=>{const{spaceBetween:r,centeredSlides:n,roundLengths:l}=i.params,{rows:o}=i.params.grid;if(i.virtualSize=(e+r)*t,i.virtualSize=Math.ceil(i.virtualSize/o)-r,i.$wrapperEl.css({[a("width")]:`${i.virtualSize+r}px`}),n){s.splice(0,s.length);const e=[];for(let t=0;t{const{slides:e}=t,s=t.params.fadeEffect;for(let a=0;a{const{transformEl:s}=t.params.fadeEffect;(s?t.slides.find(s):t.slides).transition(e),ae({swiper:t,duration:e,transformEl:s,allSlides:!0})},overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}});const i=(e,t,s)=>{let a=s?e.find(".swiper-slide-shadow-left"):e.find(".swiper-slide-shadow-top"),i=s?e.find(".swiper-slide-shadow-right"):e.find(".swiper-slide-shadow-bottom");0===a.length&&(a=d(`
`),e.append(a)),0===i.length&&(i=d(`
`),e.append(i)),a.length&&(a[0].style.opacity=Math.max(-t,0)),i.length&&(i[0].style.opacity=Math.max(t,0))};te({effect:"cube",swiper:t,on:a,setTranslate:()=>{const{$el:e,$wrapperEl:s,slides:a,width:r,height:n,rtlTranslate:l,size:o,browser:c}=t,p=t.params.cubeEffect,u=t.isHorizontal(),h=t.virtual&&t.params.virtual.enabled;let m,f=0;p.shadow&&(u?(m=s.find(".swiper-cube-shadow"),0===m.length&&(m=d('
'),s.append(m)),m.css({height:`${r}px`})):(m=e.find(".swiper-cube-shadow"),0===m.length&&(m=d('
'),e.append(m))));for(let e=0;e-1&&(f=90*s+90*d,l&&(f=90*-s-90*d)),t.transform(v),p.slideShadows&&i(t,d,u)}if(s.css({"-webkit-transform-origin":`50% 50% -${o/2}px`,"transform-origin":`50% 50% -${o/2}px`}),p.shadow)if(u)m.transform(`translate3d(0px, ${r/2+p.shadowOffset}px, ${-r/2}px) rotateX(90deg) rotateZ(0deg) scale(${p.shadowScale})`);else{const e=Math.abs(f)-90*Math.floor(Math.abs(f)/90),t=1.5-(Math.sin(2*e*Math.PI/360)/2+Math.cos(2*e*Math.PI/360)/2),s=p.shadowScale,a=p.shadowScale/t,i=p.shadowOffset;m.transform(`scale3d(${s}, 1, ${a}) translate3d(0px, ${n/2+i}px, ${-n/2/a}px) rotateX(-90deg)`)}const g=c.isSafari||c.isWebView?-o/2:0;s.transform(`translate3d(0px,0,${g}px) rotateX(${t.isHorizontal()?0:f}deg) rotateY(${t.isHorizontal()?-f:0}deg)`),s[0].style.setProperty("--swiper-cube-translate-z",`${g}px`)},setTransition:e=>{const{$el:s,slides:a}=t;a.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),t.params.cubeEffect.shadow&&!t.isHorizontal()&&s.find(".swiper-cube-shadow").transition(e)},recreateShadows:()=>{const e=t.isHorizontal();t.slides.each((t=>{const s=Math.max(Math.min(t.progress,1),-1);i(d(t),s,e)}))},getEffectParams:()=>t.params.cubeEffect,perspective:()=>!0,overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({flipEffect:{slideShadows:!0,limitRotation:!0,transformEl:null}});const i=(e,s,a)=>{let i=t.isHorizontal()?e.find(".swiper-slide-shadow-left"):e.find(".swiper-slide-shadow-top"),r=t.isHorizontal()?e.find(".swiper-slide-shadow-right"):e.find(".swiper-slide-shadow-bottom");0===i.length&&(i=ie(a,e,t.isHorizontal()?"left":"top")),0===r.length&&(r=ie(a,e,t.isHorizontal()?"right":"bottom")),i.length&&(i[0].style.opacity=Math.max(-s,0)),r.length&&(r[0].style.opacity=Math.max(s,0))};te({effect:"flip",swiper:t,on:a,setTranslate:()=>{const{slides:e,rtlTranslate:s}=t,a=t.params.flipEffect;for(let r=0;r{const{transformEl:s}=t.params.flipEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),ae({swiper:t,duration:e,transformEl:s})},recreateShadows:()=>{const e=t.params.flipEffect;t.slides.each((s=>{const a=d(s);let r=a[0].progress;t.params.flipEffect.limitRotation&&(r=Math.max(Math.min(s.progress,1),-1)),i(a,r,e)}))},getEffectParams:()=>t.params.flipEffect,perspective:()=>!0,overwriteParams:()=>({slidesPerView:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({coverflowEffect:{rotate:50,stretch:0,depth:100,scale:1,modifier:1,slideShadows:!0,transformEl:null}}),te({effect:"coverflow",swiper:t,on:a,setTranslate:()=>{const{width:e,height:s,slides:a,slidesSizesGrid:i}=t,r=t.params.coverflowEffect,n=t.isHorizontal(),l=t.translate,o=n?e/2-l:s/2-l,d=n?r.rotate:-r.rotate,c=r.depth;for(let e=0,t=a.length;e0?p:0),s.length&&(s[0].style.opacity=-p>0?-p:0)}}},setTransition:e=>{const{transformEl:s}=t.params.coverflowEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)},perspective:()=>!0,overwriteParams:()=>({watchSlidesProgress:!0})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({creativeEffect:{transformEl:null,limitProgress:1,shadowPerProgress:!1,progressMultiplier:1,perspective:!0,prev:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1},next:{translate:[0,0,0],rotate:[0,0,0],opacity:1,scale:1}}});const i=e=>"string"==typeof e?e:`${e}px`;te({effect:"creative",swiper:t,on:a,setTranslate:()=>{const{slides:e,$wrapperEl:s,slidesSizesGrid:a}=t,r=t.params.creativeEffect,{progressMultiplier:n}=r,l=t.params.centeredSlides;if(l){const e=a[0]/2-t.params.slidesOffsetBefore||0;s.transform(`translateX(calc(50% - ${e}px))`)}for(let s=0;s0&&(f=r.prev,m=!0),u.forEach(((e,t)=>{u[t]=`calc(${e}px + (${i(f.translate[t])} * ${Math.abs(d*n)}))`})),h.forEach(((e,t)=>{h[t]=f.rotate[t]*Math.abs(d*n)})),a[0].style.zIndex=-Math.abs(Math.round(o))+e.length;const g=u.join(", "),v=`rotateX(${h[0]}deg) rotateY(${h[1]}deg) rotateZ(${h[2]}deg)`,w=c<0?`scale(${1+(1-f.scale)*c*n})`:`scale(${1-(1-f.scale)*c*n})`,b=c<0?1+(1-f.opacity)*c*n:1-(1-f.opacity)*c*n,x=`translate3d(${g}) ${v} ${w}`;if(m&&f.shadow||!m){let e=a.children(".swiper-slide-shadow");if(0===e.length&&f.shadow&&(e=ie(r,a)),e.length){const t=r.shadowPerProgress?d*(1/r.limitProgress):d;e[0].style.opacity=Math.min(Math.max(Math.abs(t),0),1)}}const y=se(r,a);y.transform(x).css({opacity:b}),f.origin&&y.css("transform-origin",f.origin)}},setTransition:e=>{const{transformEl:s}=t.params.creativeEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow").transition(e),ae({swiper:t,duration:e,transformEl:s,allSlides:!0})},perspective:()=>t.params.creativeEffect.perspective,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})},function(e){let{swiper:t,extendParams:s,on:a}=e;s({cardsEffect:{slideShadows:!0,transformEl:null,rotate:!0,perSlideRotate:2,perSlideOffset:8}}),te({effect:"cards",swiper:t,on:a,setTranslate:()=>{const{slides:e,activeIndex:s}=t,a=t.params.cardsEffect,{startTranslate:i,isTouched:r}=t.touchEventsData,n=t.translate;for(let l=0;l0&&c<1&&(r||t.params.cssMode)&&n-1&&(r||t.params.cssMode)&&n>i;if(b||x){const e=(1-Math.abs((Math.abs(c)-.5)/.5))**.5;g+=-28*c*e,f+=-.5*e,v+=96*e,h=-25*e*Math.abs(c)+"%"}if(u=c<0?`calc(${u}px + (${v*Math.abs(c)}%))`:c>0?`calc(${u}px + (-${v*Math.abs(c)}%))`:`${u}px`,!t.isHorizontal()){const e=h;h=u,u=e}const y=c<0?""+(1+(1-f)*c):""+(1-(1-f)*c),E=`\n translate3d(${u}, ${h}, ${m}px)\n rotateZ(${a.rotate?g:0}deg)\n scale(${y})\n `;if(a.slideShadows){let e=o.find(".swiper-slide-shadow");0===e.length&&(e=ie(a,o)),e.length&&(e[0].style.opacity=Math.min(Math.max((Math.abs(c)-.5)/.5,0),1))}o[0].style.zIndex=-Math.abs(Math.round(d))+e.length;se(a,o).transform(E)}},setTransition:e=>{const{transformEl:s}=t.params.cardsEffect;(s?t.slides.find(s):t.slides).transition(e).find(".swiper-slide-shadow").transition(e),ae({swiper:t,duration:e,transformEl:s})},perspective:()=>!0,overwriteParams:()=>({watchSlidesProgress:!0,virtualTranslate:!t.params.cssMode})})}];return V.use(re),V})); +//# sourceMappingURL=swiper-bundle.min.js.map \ No newline at end of file diff --git a/templates/assets/zhheo/blogex.js b/templates/assets/zhheo/blogex.js index 9cd3ec34..477fcbbd 100644 --- a/templates/assets/zhheo/blogex.js +++ b/templates/assets/zhheo/blogex.js @@ -1,315 +1,789 @@ -"use strict"; +// var full_page = document.getElementsByClassName("full_page"); +// if (full_page.length != 0) { +// full_page[0].style.background = "transparent"; +// } -function _createForOfIteratorHelper(e, t) { - var o = "undefined" != typeof Symbol && e[Symbol.iterator] || e["@@iterator"]; - if (!o) { - if (Array.isArray(e) || (o = _unsupportedIterableToArray(e)) || t && e && "number" == typeof e.length) { - o && (e = o); - var n = 0, r = function () { - }; - return { - s: r, n: function () { - return n >= e.length ? {done: !0} : {done: !1, value: e[n++]} - }, e: function (e) { - throw e - }, f: r - } - } - throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.") - } - var a, i = !0, c = !1; - return { - s: function () { - o = o.call(e) - }, n: function () { - var e = o.next(); - return i = e.done, e - }, e: function (e) { - c = !0, a = e - }, f: function () { - try { - i || null == o.return || o.return() - } finally { - if (c) throw a - } - } - } -} - -function _unsupportedIterableToArray(e, t) { - if (e) { - if ("string" == typeof e) return _arrayLikeToArray(e, t); - var o = Object.prototype.toString.call(e).slice(8, -1); - return "Object" === o && e.constructor && (o = e.constructor.name), "Map" === o || "Set" === o ? Array.from(e) : "Arguments" === o || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o) ? _arrayLikeToArray(e, t) : void 0 - } -} - -function _arrayLikeToArray(e, t) { - (null == t || t > e.length) && (t = e.length); - for (var o = 0, n = new Array(t); o < t; o++) n[o] = e[o]; - return n -} - -function _typeof(e) { - return (_typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (e) { - return typeof e - } : function (e) { - return e && "function" == typeof Symbol && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e - })(e) -} function checkOpen() { } -// https://blog.zhheo.com/p/c86d8f1f.html -// ?imageAve 使用 七牛云获取图片主色调,阿里云 oss 则是 @imageAve -// 效果比较低微,这块应该添加配置项 -// 用户选择是否开启主色调背景 -// 然后选择是使用图床的 API 获取主色还是选择使用 js 获取 -// https://lokeshdhakar.com/projects/color-thief/ -function coverColor() { - - let img = document.getElementById("post-cover"); - let path = img.src; - if (void 0 !== path) { - - const colorThief = new ColorThief(); - - // Make sure image is finished loading - if (img.complete) { - loadColor(colorThief.getColor(img)); - } else { - img.addEventListener('load', function () { - loadColor(colorThief.getColor(img)); - }); - } - - - function loadColor(rgbColor) { - - let hexColor = rgbToHex(rgbColor[0], rgbColor[1], rgbColor[2]); - - if ("light" === getContrastYIQ(hexColor)) { - hexColor = LightenDarkenColor(colorHex(hexColor), -40); - document.styleSheets[0].addRule(":root", "--heo-main:" + hexColor + "!important"); - document.styleSheets[0].addRule(":root", "--heo-main-op:" + hexColor + "23!important"); - document.styleSheets[0].addRule(":root", "--heo-main-none:" + hexColor + "00!important"); - heo.initThemeColor(); - document.getElementById("coverdiv").classList.add("loaded"); - } - - } - - - } else { - document.styleSheets[0].addRule(":root", "--heo-main: var(--heo-theme)!important"); - document.styleSheets[0].addRule(":root", "--heo-main-op: var(--heo-theme-op)!important"); - document.styleSheets[0].addRule(":root", "--heo-main-none: var(--heo-theme-none)!important"); - heo.initThemeColor(); - } -} - -function rgbToHex(r, g, b) { - return '#' + [r, g, b].map(x => { - const hex = x.toString(16) - return hex.length === 1 ? '0' + hex : hex - }).join(''); -} - - -function colorHex(e) { - var t = e; - if (/^(rgb|RGB)/.test(t)) { - for (var o = t.replace(/(?:\(|\)|rgb|RGB)*/g, "").split(","), n = "#", r = 0; r < o.length; r++) { - var a = Number(o[r]).toString(16); - "0" === a && (a += a), n += a - } - return 7 !== n.length && (n = t), n - } - if (!/^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/.test(t)) return t; - var i = t.replace(/#/, "").split(""); - if (6 === i.length) return t; - if (3 === i.length) { - for (var c = "#", r = 0; r < i.length; r += 1) c += i[r] + i[r]; - return c - } -} - -function colorRgb(e) { - var t = e.toLowerCase(); - if (t && /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/.test(t)) { - if (4 === t.length) { - for (var o = "#", n = 1; n < 4; n += 1) o += t.slice(n, n + 1).concat(t.slice(n, n + 1)); - t = o - } - for (var r = [], n = 1; n < 7; n += 2) r.push(parseInt("0x" + t.slice(n, n + 2))); - return "rgb(" + r.join(",") + ")" - } - return t -} - -function LightenDarkenColor(e, t) { - var o = !1; - "#" == e[0] && (e = e.slice(1), o = !0); - var n = parseInt(e, 16), r = (n >> 16) + t; - 255 < r ? r = 255 : r < 0 && (r = 0); - var a = (n >> 8 & 255) + t; - 255 < a ? a = 255 : a < 0 && (a = 0); - var i = (255 & n) + t; - return 255 < i ? i = 255 : i < 0 && (i = 0), (o ? "#" : "") + String("000000" + (i | a << 8 | r << 16).toString(16)).slice(-6) -} - -function getContrastYIQ(e) { - var t = colorRgb(e).match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/), o = 299 * t[1] + 587 * t[2] + 114 * t[3]; - return .5 <= (o /= 255e3) ? "light" : "dark" -} - -function navTitle() { - var e = document.title.replace(" | halo", ""); - document.getElementById("page-name-text").innerHTML = e -} - checkOpen.toString = function () { - this.opened = !0 -}, window.onload = function () { - for (var e = document.getElementsByClassName("copybtn"), t = 0; t < e.length; t++) document.getElementsByClassName("copybtn")[t].addEventListener("click", function () { - showcopy() - }); - heo.initThemeColor() + this.opened = true; }; -var getTimeState = function () { - var e = (new Date).getHours(), t = ""; - return 0 <= e && e <= 5 ? t = "晚安" : 5 < e && e <= 10 ? t = "早上好" : 10 < e && e <= 14 ? t = "中午好" : 14 < e && e <= 18 ? t = "下午好" : 18 < e && e <= 24 && (t = "晚上好"), t +//封面纯色 +function coverColor() { + var path = document.getElementById("post-cover")?.src; + // console.log(path); + if (path !== undefined) { + + // 获取颜色 https://github.com/fast-average-color/fast-average-color + const fac = new FastAverageColor(); + + fac.getColorAsync(path,{ + // 忽略白色 + ignoredColor: [255, 255, 255, 255] + }) + .then(color => { + /** + * 获取数据后的处理程序 + */ + var value = color.hex; + // console.log(value); + // document.getElementById('page-header').style.backgroundColor=value; + // document.styleSheets[0].addRule('#page-header:before','background: '+ value +'!important'); + + if (getContrastYIQ(value) === "light") { + value = LightenDarkenColor(colorHex(value), -40) + } + + document.styleSheets[0].addRule(':root', '--heo-main:' + value + '!important'); + document.styleSheets[0].addRule(':root', '--heo-main-op:' + value + '23!important'); + document.styleSheets[0].addRule(':root', '--heo-main-op-deep:' + value + 'dd!important'); + document.styleSheets[0].addRule(':root', '--heo-main-none:' + value + '00!important'); + heo.initThemeColor() + document.getElementById("coverdiv").classList.add("loaded"); + }) + .catch(e => { + console.log(e); + }); + + } else { + // document.styleSheets[0].addRule('#page-header:before','background: none!important'); + document.styleSheets[0].addRule(':root', '--heo-main: var(--heo-theme)!important'); + document.styleSheets[0].addRule(':root', '--heo-main-op: var(--heo-theme-op)!important'); + document.styleSheets[0].addRule(':root', '--heo-main-op-deep:var(--heo-theme-op-deep)!important'); + document.styleSheets[0].addRule(':root', '--heo-main-none: var(--heo-theme-none)!important'); + heo.initThemeColor() + } +} + +//RGB颜色转化为16进制颜色 +function colorHex(str) { + var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/; + var that = str; + if (/^(rgb|RGB)/.test(that)) { + var aColor = that.replace(/(?:\(|\)|rgb|RGB)*/g, "").split(","); + var strHex = "#"; + for (var i = 0; i < aColor.length; i++) { + var hex = Number(aColor[i]).toString(16); + if (hex === "0") { + hex += hex; + } + strHex += hex; + } + if (strHex.length !== 7) { + strHex = that; + } + return strHex; + } else if (reg.test(that)) { + var aNum = that.replace(/#/, "").split(""); + if (aNum.length === 6) { + return that; + } else if (aNum.length === 3) { + var numHex = "#"; + for (var i = 0; i < aNum.length; i += 1) { + numHex += (aNum[i] + aNum[i]); + } + return numHex; + } + } else { + return that; + } +} + +//16进制颜色转化为RGB颜色 +function colorRgb(str) { + var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/; + var sColor = str.toLowerCase(); + if (sColor && reg.test(sColor)) { + if (sColor.length === 4) { + var sColorNew = "#"; + for (var i = 1; i < 4; i += 1) { + sColorNew += sColor.slice(i, i + 1).concat(sColor.slice(i, i + 1)); + } + sColor = sColorNew; + } + //处理六位的颜色值 + var sColorChange = []; + for (var i = 1; i < 7; i += 2) { + sColorChange.push(parseInt("0x" + sColor.slice(i, i + 2))); + } + return "rgb(" + sColorChange.join(",") + ")"; + } else { + return sColor; + } +} + +//变暗变亮主方法 +function LightenDarkenColor(col, amt) { + var usePound = false; + + if (col[0] == "#") { + col = col.slice(1); + usePound = true; + } + + var num = parseInt(col, 16); + + var r = (num >> 16) + amt; + + if (r > 255) r = 255; + else if (r < 0) r = 0; + + var b = ((num >> 8) & 0x00FF) + amt; + + if (b > 255) b = 255; + else if (b < 0) b = 0; + + var g = (num & 0x0000FF) + amt; + + if (g > 255) g = 255; + else if (g < 0) g = 0; + + + return (usePound ? "#" : "") + String("000000" + (g | (b << 8) | (r << 16)).toString(16)).slice(-6); +} + +//判断是否为亮色 +function getContrastYIQ(hexcolor) { + var colorrgb = colorRgb(hexcolor); + var colors = colorrgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/); + var red = colors[1]; + var green = colors[2]; + var blue = colors[3]; + var brightness; + brightness = (red * 299) + (green * 587) + (blue * 114); + brightness = brightness / 255000; + if (brightness >= 0.5) { + return "light"; + } else { + return "dark"; + } +} + +//导航栏文章 +function navTitle() { + var titlevalue = document.title; + var simptitle = titlevalue.replace(' | XXXX', '') + document.getElementById("page-name-text").innerHTML = simptitle; +} + +window.onload = function () { + var copybtnlist = document.getElementsByClassName("copybtn") + for (var i = 0; i < copybtnlist.length; i++) { + document.getElementsByClassName("copybtn")[i].addEventListener("click", function () { + showcopy(); + }); + } + heo.initThemeColor(); +} + +function showcopy() { + if (GLOBAL_CONFIG.Snackbar !== undefined) { + btf.snackbarShow(GLOBAL_CONFIG.copy.success) + } else { + const prevEle = ctx.previousElementSibling + prevEle.innerText = GLOBAL_CONFIG.copy.success + prevEle.style.opacity = 1 + setTimeout(() => { + prevEle.style.opacity = 0 + }, 700) + } +} + +//导航栏上显示标题 +// var OriginTitile = document.title; +// var titleTime; +// document.addEventListener('visibilitychange', function () { +// if (document.hidden) { +// // $('[rel="shortcut icon"]').attr('href', "https://cdn.jsdelivr.net/gh/Akilarlxh/Akilarlxh.github.io@v3.3.3_3/img/siteicon/favicon.png"); +// document.title = '张洪Heo'; +// clearTimeout(titleTime); +// } +// else { +// // $('[rel="shortcut icon"]').attr('href', "https://cdn.jsdelivr.net/gh/Akilarlxh/Akilarlxh.github.io@v3.3.3_3/img/siteicon/favicon.png"); +// document.title = OriginTitile; +// // titleTime = setTimeout(function () { +// // document.title = OriginTitile; +// // }, 2000); +// } +// }); + +// 早上好问好 +// 获取时间 +var getTimeState = () => { + // 获取当前时间 + var timeNow = new Date(); + // 获取当前小时 + var hours = timeNow.getHours(); + // 设置默认文字 + var text = ``; + // 判断当前时间段 + if (hours >= 0 && hours <= 5) { + text = `晚安`; + } else if (hours > 5 && hours <= 10) { + text = `早上好`; + } else if (hours > 10 && hours <= 14) { + text = `中午好`; + } else if (hours > 14 && hours <= 18) { + text = `下午好`; + } else if (hours > 18 && hours <= 24) { + text = `晚上好`; + } + //    console.log(`hours >>>>>`, hours); + //    console.log(`text >>>>`, text); + // 返回当前时间段对应的状态 + return text; }; function fly_to_top() { - document.getElementById("guli_top").classList.add("open_wing"), setTimeout(function () { - document.getElementById("guli_top").classList.add("flying"), btf.scrollToDest(0, 300) - }, 300), setTimeout(function () { - document.getElementById("guli_top").classList.remove("flying"), document.getElementById("guli_top").classList.remove("open_wing"), document.getElementById("guli_top").style.cssText = "opacity: ''; transform: ''" + document.getElementById("guli_top").classList.add("open_wing"); + setTimeout(function () { + document.getElementById("guli_top").classList.add("flying"); + btf.scrollToDest(0, 300); + }, 300); + setTimeout(function () { + // 这里就是处理的事件 + document.getElementById("guli_top").classList.remove("flying"); + document.getElementById("guli_top").classList.remove("open_wing"); + document.getElementById("guli_top").style.cssText = "opacity: ''; transform: ''"; }, 600) } +//深色模式切换 var navFn = { - switchDarkMode: function () { - "light" == ("dark" === document.documentElement.getAttribute("data-theme") ? "dark" : "light") ? (activateDarkMode(), saveToLocal.set("theme", "dark", 2), void 0 !== GLOBAL_CONFIG.Snackbar && btf.snackbarShow(GLOBAL_CONFIG.Snackbar.day_to_night, !1, 2e3)) : (activateLightMode(), saveToLocal.set("theme", "light", 2), void 0 !== GLOBAL_CONFIG.Snackbar && btf.snackbarShow(GLOBAL_CONFIG.Snackbar.night_to_day, !1, 2e3)), "function" == typeof utterancesTheme && utterancesTheme(), "object" === ("undefined" == typeof FB ? "undefined" : _typeof(FB)) && window.loadFBComment(), window.DISQUS && document.getElementById("disqus_thread").children.length && setTimeout(function () { - return window.disqusReset() - }, 200); - var e, t, o, n = "light" === document.documentElement.getAttribute("data-theme") ? "#363636" : "#F7F7FA"; - document.getElementById("posts-chart") && ((e = postsOption).textStyle.color = n, e.title.textStyle.color = n, e.xAxis.axisLine.lineStyle.color = n, e.yAxis.axisLine.lineStyle.color = n, postsChart.setOption(e)), document.getElementById("tags-chart") && ((t = tagsOption).textStyle.color = n, t.title.textStyle.color = n, t.xAxis.axisLine.lineStyle.color = n, t.yAxis.axisLine.lineStyle.color = n, tagsChart.setOption(t)), document.getElementById("categories-chart") && ((o = categoriesOption).textStyle.color = n, o.title.textStyle.color = n, o.legend.textStyle.color = n, categoriesChart.setOption(o)) - } -}; + switchDarkMode: () => { // Switch Between Light And Dark Mode + const nowMode = document.documentElement.getAttribute('data-theme') === 'dark' ? 'dark' : 'light' + if (nowMode === 'light') { + activateDarkMode() + saveToLocal.set('theme', 'dark', 2) + GLOBAL_CONFIG.Snackbar !== undefined && btf.snackbarShow(GLOBAL_CONFIG.Snackbar.day_to_night, false, 2000) + } else { + activateLightMode() + saveToLocal.set('theme', 'light', 2) + GLOBAL_CONFIG.Snackbar !== undefined && btf.snackbarShow(GLOBAL_CONFIG.Snackbar.night_to_day, false, 2000) + } + // handle some cases + typeof utterancesTheme === 'function' && utterancesTheme(); + typeof FB === 'object' && window.loadFBComment(); + window.DISQUS && document.getElementById('disqus_thread').children.length && setTimeout(() => window.disqusReset(), 200) + //统计图 + let color = document.documentElement.getAttribute('data-theme') === 'light' ? '#363636' : '#F7F7FA' + if (document.getElementById('posts-chart')) { + let postsOptionNew = postsOption + postsOptionNew.textStyle.color = color + postsOptionNew.title.textStyle.color = color + postsOptionNew.xAxis.axisLine.lineStyle.color = color + postsOptionNew.yAxis.axisLine.lineStyle.color = color + postsChart.setOption(postsOptionNew) + } + if (document.getElementById('tags-chart')) { + let tagsOptionNew = tagsOption + tagsOptionNew.textStyle.color = color + tagsOptionNew.title.textStyle.color = color + tagsOptionNew.xAxis.axisLine.lineStyle.color = color + tagsOptionNew.yAxis.axisLine.lineStyle.color = color + tagsChart.setOption(tagsOptionNew) + } + if (document.getElementById('categories-chart')) { + let categoriesOptionNew = categoriesOption + categoriesOptionNew.textStyle.color = color + categoriesOptionNew.title.textStyle.color = color + categoriesOptionNew.legend.textStyle.color = color + categoriesChart.setOption(categoriesOptionNew) + } + } +} + +// 移除赞赏蒙版 function RemoveRewardMask() { - $(".reward-main").attr("style", "display: none"), $("#quit-box").attr("style", "display: none") + $('.reward-main').attr('style', 'display: none'); + $('#quit-box').attr('style', 'display: none'); +} + +//添加赞赏蒙版 +function AddRewardMask() { + $('.reward-main').attr('style', 'display: flex'); +} + +//监听蒙版关闭 +document.addEventListener('touchstart', e => { + RemoveRewardMask() +}, false) + +//监听ctrl+C +$(document).unbind('keydown').bind('keydown', function (e) { + if ((e.ctrlKey || e.metaKey) && (e.keyCode == 67) && (selectTextNow != '')) { + btf.snackbarShow('复制成功,复制和转载请标注本文地址'); + rm.rightmenuCopyText(selectTextNow); + return false; + } +}) + +//判断国内国外 +// var foreignTips = (function () { +// var fetchUrl = "https://api.ooomn.com/api/ip" +// fetch(fetchUrl) +// .then(res => res.json()) +// .then(json =>{ +// var country = json.country; +// console.log(country); +// if (country != '中国'){ +// btf.snackbarShow('使用国外网络访问可能无法访问文章图片,敬请谅解。Blog pictures only serve mainland China.') +// } +// }) +// }); + +//颜色 +document.addEventListener('scroll', btf.throttle(function () { + heo.initThemeColor() +}, 200)) + +//友链随机传送 +function travelling() { + var fetchUrl = "https://moments.zhheo.com/randomfriend" + fetch(fetchUrl) + .then(res => res.json()) + .then(json => { + var name = json.name; + var link = json.link; + var msg = "点击前往按钮进入随机一个友链,不保证跳转网站的安全性和可用性。本次随机到的是本站友链:「" + name + "」"; + document.styleSheets[0].addRule(':root', '--heo-snackbar-time:' + 8000 + 'ms!important'); + Snackbar.show({ + text: msg, + duration: 8000, + pos: 'top-center', + actionText: '前往', + onActionClick: function (element) { + //Set opacity of element to 0 to close Snackbar + $(element).css('opacity', 0); + window.open(link, '_blank'); + } + }); + }) +} + +//前往黑洞 +function toforeverblog() { + var msg = "点击前往按钮进入「十年之约」项目中的成员博客,不保证跳转网站的安全性和可用性"; + Snackbar.show({ + text: msg, + duration: 8000, + pos: 'top-center', + actionText: '前往', + onActionClick: function (element) { + //Set opacity of element to 0 to close Snackbar + $(element).css('opacity', 0); + window.open(link, 'https://www.foreverblog.cn/go.html'); + } + }); +} + +//前往开往项目 +function totraveling() { + btf.snackbarShow('即将跳转到「开往」项目的成员博客,不保证跳转网站的安全性和可用性', false, 5000); + setTimeout(function () { + window.open('https://travellings.link/'); + }, "5000"); } // 移除加载动画 function removeLoading() { setTimeout(function () { - preloader.endLoading() - }, 3e3) + preloader.endLoading(); + }, 3000) } -function getArrayItems(e, t) { - var o = new Array; - for (var n in e) o.push(e[n]); - for (var r = new Array, a = 0; a < t && 0 < o.length; a++) { - var i = Math.floor(Math.random() * o.length); - r[a] = o[i], o.splice(i, 1) +//移除pwa +navigator.serviceWorker.getRegistrations().then(function (registrations) { + for (let registration of registrations) { + registration.unregister() } - return r +}) + +function addFriendLink() { + var input = document.getElementsByClassName('el-textarea__inner')[0]; + let evt = document.createEvent('HTMLEvents'); + evt.initEvent('input', true, true); + input.value = '昵称(请勿包含博客等字样):\n网站地址(要求博客地址,请勿提交个人主页):\n头像图片url(请提供尽可能清晰的图片,我会上传到我自己的图床):\n描述:\n'; + input.dispatchEvent(evt); + heo.scrollTo("#post-comment"); + input.focus(); + input.setSelectionRange(-1, -1); } +//从一个给定的数组arr中,随机返回num个不重复项 +function getArrayItems(arr, num) { + //新建一个数组,将传入的数组复制过来,用于运算,而不要直接操作传入的数组; + var temp_array = new Array(); + for (var index in arr) { + temp_array.push(arr[index]); + } + //取出的数值项,保存在此数组 + var return_array = new Array(); + for (var i = 0; i < num; i++) { + //判断如果数组还有可以取出的元素,以防下标越界 + if (temp_array.length > 0) { + //在数组中产生一个随机索引 + var arrIndex = Math.floor(Math.random() * temp_array.length); + //将此随机索引的对应的数组元素值复制出来 + return_array[i] = temp_array[arrIndex]; + //然后删掉此索引的数组元素,这时候temp_array变为新的数组 + temp_array.splice(arrIndex, 1); + } else { + //数组中数据项取完后,退出循环,比如数组本来只有10项,但要求取出20项. + break; + } + } + return return_array; +} + +// 检测按键 +window.onkeydown = function (e) { + if (e.keyCode === 123) { + btf.snackbarShow('开发者模式已打开,请遵循GPL协议', false, 3000) + } +} + +// 阻止搜索滚动 +// document.querySelector('#algolia-search').addEventListener('wheel', (e) => { +// e.preventDefault() +// }) +document.querySelector('#console').addEventListener('wheel', (e) => { + e.preventDefault() +}) +// document.querySelector('#loading-box').addEventListener('wheel', (e) => { +// e.preventDefault() +// }) + +//自动调整即刻短文尺寸 +window.addEventListener('resize', function () { + if (document.querySelector('#waterfall')) { + heo.reflashEssayWaterFall(); + } +}); + +//首页大卡片恢复显示 +$(".topGroup").hover(function () { + // console.log("卡片悬浮"); +}, function () { + hoverOnCommentBarrage = false; + + if (document.getElementById("todayCard")) { + document.getElementById("todayCard").classList.remove('hide'); + document.getElementById('todayCard').style.zIndex = 1; + // console.log("卡片停止悬浮"); + } +}); + +//评论增加放大功能 +// 如果当前页有评论就执行函数 +if (document.getElementById('post-comment')) owoBig(); + function owoBig() { - document.getElementById("post-comment").addEventListener("DOMNodeInserted", function (e) { - var t, o, n, a; - !e.target.classList || "OwO-body" != e.target.classList.value || (t = e.target) && (n = !(o = ""), (a = document.createElement("div")).id = "owo-big", document.querySelector("body").appendChild(a), t.addEventListener("contextmenu", function (e) { - return e.preventDefault() - }), t.addEventListener("mouseover", function (r) { - "LI" == r.target.tagName && n && (n = !1, o = setTimeout(function () { - var e = 3 * r.path[0].clientHeight, t = 3 * r.path[0].clientWidth, - o = r.x - r.offsetX - (t - r.path[0].clientWidth) / 2, n = r.y - r.offsetY; - a.style.height = e + "px", a.style.width = t + "px", a.style.left = o + "px", a.style.top = n + "px", a.style.display = "flex", a.innerHTML = '') - }, 300)) - }), t.addEventListener("mouseout", function (e) { - a.style.display = "none", n = !0, clearTimeout(o) - })) - }) -} + // 监听dom插入 + document.getElementById('post-comment').addEventListener('DOMNodeInserted', (dom) => { + // 如果有class且值为OwO-body + if (dom.target.classList && dom.target.classList.value == 'OwO-body') { + let owo_body = dom.target + if (owo_body) { + let owo_time = '' + let flag = true; + // 创建盒子 + let div = document.createElement('div') + div.id = 'owo-big' + document.querySelector('body').appendChild(div) -function percent() { - var e = document.documentElement.scrollTop || window.pageYOffset, - t = Math.max(document.body.scrollHeight, document.documentElement.scrollHeight, document.body.offsetHeight, document.documentElement.offsetHeight, document.body.clientHeight, document.documentElement.clientHeight) - document.documentElement.clientHeight, - o = Math.round(e / t * 100), n = document.querySelector("#percent"), - r = window.scrollY + document.documentElement.clientHeight, - a = document.getElementById("post-tools") || document.getElementById("footer"); - a.offsetTop + a.offsetHeight / 2 < r || 90 < o ? (document.querySelector("#nav-totop").classList.add("long"), n.innerHTML = "返回顶部") : (document.querySelector("#nav-totop").classList.remove("long"), n.innerHTML = o) -} + // 禁用右键(手机端长按会出现右键菜单,为了体验给禁用掉) + owo_body.addEventListener('contextmenu', e => e.preventDefault()) -document.addEventListener("touchstart", function (e) { - RemoveRewardMask() -}, !1); + // 鼠标移入 + owo_body.addEventListener('mouseover', (e) => { + if (e.target.tagName == 'LI' && flag) { + flag = false; + // 移入300毫秒后显示盒子 + owo_time = setTimeout(() => { + let m = 3 // 设置倍数 + let height = e.path[0].clientHeight * m // 盒子高 + let width = e.path[0].clientWidth * m // 盒子宽 + let left = (e.x - e.offsetX) - (width - e.path[0].clientWidth) / 2 // 盒子与屏幕左边距离 + let top = e.y - e.offsetY // 盒子与屏幕顶部距离 -$(document).unbind("keydown").bind("keydown", function (e) { - if ((e.ctrlKey || e.metaKey) && 67 == e.keyCode && "" != selectTextNow) return btf.snackbarShow("复制成功,复制和转载请标注本文地址"), rm.rightmenuCopyText(selectTextNow), !1 -}); + div.style.height = height + 'px' + div.style.width = width + 'px' + div.style.left = left + 'px' + div.style.top = top + 'px' + div.style.display = 'flex' + div.innerHTML = `` + }, 300); + } + }) -document.addEventListener("scroll", btf.throttle(function () { - heo.initThemeColor() -}, 200)); - -navigator.serviceWorker.getRegistrations().then(function (e) { - var t, o = _createForOfIteratorHelper(e); - try { - for (o.s(); !(t = o.n()).done;) { - t.value.unregister() + // 鼠标移出 + owo_body.addEventListener('mouseout', (e) => { + div.style.display = 'none'; + flag = true + clearTimeout(owo_time) + }) + } + } + }); +} + +//文章页面上一篇下一篇 +document.addEventListener('scroll', btf.throttle(function () { + //滚动条高度+视窗高度 = 可见区域底部高度 + var visibleBottom = window.scrollY + document.documentElement.clientHeight; + //可见区域顶部高度 + var visibleTop = window.scrollY; + // 获取翻页按钮容器 + var pagination = document.getElementById('pagination'); + // 获取位置监测容器,此处采用评论区 + var eventlistner = document.getElementById('post-tools'); + if (eventlistner && pagination) { + var centerY = eventlistner.offsetTop + (eventlistner.offsetHeight / 2); + if (document.body.clientWidth > 1300) { + if (centerY < visibleBottom) { + pagination.classList.add("show-window"); + } else { + pagination.classList.remove("show-window"); + } } - } catch (e) { - o.e(e) - } finally { - o.f() } +}, 200)) + + +// 页面百分比 +function percent() { + let a = document.documentElement.scrollTop || window.pageYOffset, // 卷去高度 + b = Math.max(document.body.scrollHeight, document.documentElement.scrollHeight, document.body.offsetHeight, document.documentElement.offsetHeight, document.body.clientHeight, document.documentElement.clientHeight) - document.documentElement.clientHeight, // 整个网页高度 + result = Math.round(a / b * 100), // 计算百分比 + btn = document.querySelector("#percent"); // 获取按钮 + //滚动条高度+视窗高度 = 可见区域底部高度 + var visibleBottom = window.scrollY + document.documentElement.clientHeight; + // 获取位置监测容器,此处采用评论区 + var eventlistner = document.getElementById('post-tools') || document.getElementById('footer'); + var centerY = eventlistner.offsetTop + (eventlistner.offsetHeight / 2); + if ((centerY < visibleBottom) || (result > 90)) { + document.querySelector("#nav-totop").classList.add("long"); + btn.innerHTML = "返回顶部"; + } else { + document.querySelector("#nav-totop").classList.remove("long"); + btn.innerHTML = result; + } + window.onscroll = percent; +} + +//检查是否开启快捷键 +// if (localStorage.getItem('keyboardToggle') !== 'false') { +// document.querySelector("#consoleKeyboard").classList.add("on"); +// } else { +// document.querySelector("#consoleKeyboard").classList.remove("on"); +// } + +//响应esc键 +$(window).on('keydown', function (ev) { + + // Escape + if (ev.keyCode == 27) { + heo.hideLoading(); + heo.hideConsole(); + rm.hideRightMenu(); + } + + if (heo_keyboard && ev.shiftKey && !heo_intype) { + + // 显示快捷键面板 shift键 + // if (ev.keyCode == 16) { + // document.querySelector("#keyboard-tips").classList.add("show"); + // } + + //关闭快捷键 shift+K + if (ev.keyCode == 75) { + heo.keyboardToggle(); + return false; + } + + //响应打开控制台键 shift+A + if (ev.keyCode == 65) { + heo.showConsole(); + return false; + } + + //音乐控制 shift+M + if (ev.keyCode == 77) { + heo.musicToggle(); + return false; + } + + //随机文章 shift+R + if (ev.keyCode == 82) { + toRandomPost(); + return false; + } + + //回到首页 shift+H + if (ev.keyCode == 72) { + pjax.loadUrl("/"); + return false; + } + + //深色模式 shift+D + if (ev.keyCode == 68) { + rm.switchDarkMode(); + return false; + } + + //友链鱼塘 shift+F + if (ev.keyCode == 70) { + pjax.loadUrl("/moments/"); + return false; + } + + //友情链接页面 shift+L + if (ev.keyCode == 76) { + pjax.loadUrl("/link/"); + return false; + } + + //关于本站 shift+P + if (ev.keyCode == 80) { + pjax.loadUrl("/about/"); + return false; + } + + //在线工具 shift+T + if (ev.keyCode == 84) { + pjax.loadUrl("/tlink/"); + return false; + } + + } + }); -window.onkeydown = function (e) { - 123 === e.keyCode && btf.snackbarShow("开发者模式已打开,请遵循GPL协议", !1, 3e3) -}; +// $(window).on('keyup', function (ev) { +// // 显示快捷键面板 +// if (ev.keyCode == 16) { +// document.querySelector("#keyboard-tips").classList.remove("show"); +// } +// }); -document.querySelector("#console").addEventListener("wheel", function (e) { - e.preventDefault() +//输入状态检测 +$("input").focus(function () { + heo_intype = true; +}); +$("textarea").focus(function () { + heo_intype = true; +}); +$("input").focusout(function () { + heo_intype = false; +}); +$("textarea").focusout(function () { + heo_intype = false; }); -window.addEventListener("resize", function () { - document.querySelector("#waterfall") && heo.reflashEssayWaterFall() -}); +//老旧浏览器检测 +function browserTC() { + btf.snackbarShow(""); + Snackbar.show({ + text: '为了保护访客访问安全,本站已停止对你正在使用的过低版本浏览器的支持', + actionText: '关闭', + duration: '6000', + pos: 'bottom-right' + }); +} +function browserVersion() { + var userAgent = navigator.userAgent; + var isIE = userAgent.indexOf("compatible") > -1 && userAgent.indexOf("MSIE") > -1; + var isIE11 = userAgent.indexOf('Trident') > -1 && userAgent.indexOf("rv:11.0") > -1; + var isEdge = userAgent.indexOf("Edge") > -1 && !isIE; + var isFirefox = userAgent.indexOf("Firefox") > -1; + var isOpera = userAgent.indexOf("Opera") > -1 || userAgent.indexOf("OPR") > -1; + var isChrome = userAgent.indexOf("Chrome") > -1 && userAgent.indexOf("Safari") > -1 && userAgent.indexOf("Edge") == -1 && userAgent.indexOf("OPR") == -1; + var isSafari = userAgent.indexOf("Safari") > -1 && userAgent.indexOf("Chrome") == -1 && userAgent.indexOf("Edge") == -1 && userAgent.indexOf("OPR") == -1; + if (isEdge) { + if (userAgent.split('Edge/')[1].split('.')[0] < 90) { + browserTC() + } + } else if (isFirefox) { + if (userAgent.split('Firefox/')[1].split('.')[0] < 90) { + browserTC() + } + } else if (isOpera) { + if (userAgent.split('OPR/')[1].split('.')[0] < 80) { + browserTC() + } + } else if (isChrome) { + if (userAgent.split('Chrome/')[1].split('.')[0] < 90) { + browserTC() + } + } else if (isSafari) { + //不知道Safari多少版本才算老旧 + } +} -document.getElementById("post-comment") && owoBig(), document.addEventListener("scroll", btf.throttle(function () { - var e, t = window.scrollY + document.documentElement.clientHeight, - o = (window.scrollY, document.getElementById("pagination")), n = document.getElementById("post-tools"); - n && o && (e = n.offsetTop + n.offsetHeight / 2, 1300 < document.body.clientWidth && (e < t ? o.classList.add("show-window") : o.classList.remove("show-window"))) -}, 200)); +function setCookies(obj, limitTime) { + let data = new Date(new Date().getTime() + limitTime * 24 * 60 * 60 * 1000).toUTCString() + for (let i in obj) { + document.cookie = i + '=' + obj[i] + ';expires=' + data + } +} -document.addEventListener("pjax:send", function () { - heo.showLoading() -}); +function getCookie(name) { + var arr, reg = new RegExp("(^| )" + name + "=([^;]*)(;|$)"); + if (arr = document.cookie.match(reg)) + return unescape(arr[2]); + else + return null; +} -document.addEventListener("load", function () { - heo.categoriesBarActive(); - heo.tagPageActive(); - heo.onlyHome(); - heo.addNavBackgroundInit(); - heo.reflashEssayWaterFall(); - heo.darkModeStatus(); - heo.initThemeColor(); - percent(); - heo.hideLoading(); -}); -heo.initThemeColor(); +if (getCookie('browsertc') != 1) { + setCookies({ + browsertc: 1, + }, 1); //设置cookie缓存一天,即一天弹一次 + browserVersion(); +} + +//当前窗口得到焦点  +// window.onfocus = function () { +// document.querySelector("#keyboard-tips").classList.remove("show"); +// }; + +//注入函数 +document.addEventListener('pjax:send', function () { + console.clear(); + Pace.restart(); + heo.showLoading(); +}) + +document.addEventListener('load', function () { + coverColor() + navTitle() + percent() + heo.topPostScroll() + heo.topCategoriesBarScroll() + heo.sayhi() + heo.addTag() + heo.stopImgRightDrag() + heo.addFriendLinksInFooter() + heo.qrcodeCreate() + heo.hidecookie() + heo.onlyHome() + heo.addNavBackgroundInit() + heo.initIndexEssay() + heo.changeTimeInEssay() + heo.reflashEssayWaterFall() + heo.addMediumInEssay() + heo.darkModeStatus() + heo.categoriesBarActive() + heo.initThemeColor() + heo.hideLoading() + heo.tagPageActive() +}) window.onscroll = function () { percent(); -}; - - +}; \ No newline at end of file diff --git a/templates/assets/zhheo/commentBarrage.css b/templates/assets/zhheo/commentBarrage.css new file mode 100644 index 00000000..b96dfb56 --- /dev/null +++ b/templates/assets/zhheo/commentBarrage.css @@ -0,0 +1,165 @@ +.comment-barrage { + position: fixed; + bottom: 0; + right: 20px; + padding: 0 0 20px 10px; + z-index: 100; + display: flex; + flex-direction: column; + justify-content: end; + align-items: flex-end; + z-index: 999; + transition: 0.3s; +} + +@media screen and (max-width: 768px) { + .comment-barrage { + display: none !important; + } +} + +.comment-barrage-item { + min-width: 300px; + max-width: 300px; + width: fit-content; + min-height: 80px; + max-height: 150px; + margin: 4px; + padding: 8px 14px; + background: var(--heo-maskbgdeep); + border-radius: 8px; + color: var(--heo-fontcolor); + animation: barrageIn 0.6s cubic-bezier(0.42, 0, 0.3, 1.11); + transition: 0.3s; + display: flex; + flex-direction: column; + border: var(--style-border); + backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); + position: fixed; + box-shadow: var(--heo-shadow-border); + overflow: hidden; +} + +.comment-barrage-item:hover { + border: var(--style-border-hover); + box-shadow: var(--heo-shadow-main); +} + +.comment-barrage-item.out { + opacity: 0; + animation: barrageOut 0.6s cubic-bezier(0.42, 0, 0.3, 1.11); +} + +.comment-barrage-item.hovered { + opacity: 0; +} + +.comment-barrage-item .comment-barrage-close { + color: var(--heo-secondtext); + cursor: pointer; + line-height: 1; + padding: 4px; +} + +.comment-barrage-item .comment-barrage-close:hover { + color: var(--heo-main); +} + +.comment-barrage-item pre { + display: none; +} + +.comment-barrage-item p img:not(.tk-owo-emotion) { + display: none; +} + +.comment-barrage-item p img.tk-owo-emotion { + width: 16px; + padding: 0; + margin: 0; + transform: translateY(2px); +} + +.comment-barrage-item blockquote { + display: none; +} + +.comment-barrage-item br { + display: none; +} + +.comment-barrage-item .barrageHead { + height: 30px; + padding: 0; + line-height: 30px; + font-size: 12px; + border-bottom: var(--style-border); + display: flex; + justify-content: space-between; + align-items: center; + font-weight: bold; + padding-bottom: 6px; +} + +.comment-barrage-item .barrageHead .barrageTitle { + color: var(--heo-card-bg); + margin-right: 8px; + background: var(--heo-fontcolor); + line-height: 1; + padding: 4px; + border-radius: 4px; +} + +.comment-barrage-item .barrageHead .barrageTitle:hover { + background: var(--heo-main); + color: var(--heo-white); +} + +.comment-barrage-item .barrageAvatar { + width: 16px; + height: 16px; + margin: 0; + margin-left: auto; + margin-right: 8px; + border-radius: 50%; + background: var(--heo-secondbg); +} + +.comment-barrage-item .barrageContent { + font-size: 14px !important; + font-weight: normal !important; + height: calc(100% - 30px); + overflow: hidden; + width: fit-content; +} + +.comment-barrage-item .barrageContent a { + pointer-events: none; +} + +.comment-barrage-item .barrageContent::-webkit-scrollbar { + height: 0; + width: 4px; +} + +.comment-barrage-item .barrageContent::-webkit-scrollbar-button { + display: none; +} + +.comment-barrage-item p { + margin: 8px 0; + line-height: 1.3; + overflow: hidden; + text-overflow: ellipsis; + -webkit-line-clamp: 2; + display: -webkit-box; + -webkit-box-orient: vertical; + font-size: 14; +} + +.comment-barrage-item .barrageContent h1, .comment-barrage-item .barrageContent h2, .comment-barrage-item .barrageContent h3, .comment-barrage-item .barrageContent h4 { + font-size: 14px !important; + font-weight: normal !important; + margin: 8px 0 !important; +} \ No newline at end of file diff --git a/templates/assets/zhheo/commentBarrage.js b/templates/assets/zhheo/commentBarrage.js new file mode 100644 index 00000000..d7b66a70 --- /dev/null +++ b/templates/assets/zhheo/commentBarrage.js @@ -0,0 +1,150 @@ +var commentBarrageConfig = { + //同时最多显示弹幕数 + maxBarrage: 1, + //弹幕显示间隔时间ms + barrageTime: 4000, + //twikoo部署地址腾讯云的为环境ID + twikooUrl: "xxxx", + //token获取见上方 + accessToken: "xxxx", + pageUrl: window.location.pathname, + barrageTimer: [], + barrageList: [], + barrageIndex: 0, + dom: document.querySelector('.comment-barrage'), +} + +var commentInterval = null; +var hoverOnCommentBarrage = false; + +$(".comment-barrage").hover(function () { + hoverOnCommentBarrage = true; + console.log("热评悬浮"); +}, function () { + hoverOnCommentBarrage = false; + console.log("停止悬浮"); +}); + +function initCommentBarrage() { + // console.log("开始创建热评") + + var data = JSON.stringify({ + "event": "COMMENT_GET", + "commentBarrageConfig.accessToken": commentBarrageConfig.accessToken, + "url": commentBarrageConfig.pageUrl + }); + var xhr = new XMLHttpRequest(); + xhr.withCredentials = true; + xhr.addEventListener("readystatechange", function () { + if (this.readyState === 4) { + commentBarrageConfig.barrageList = commentLinkFilter(JSON.parse(this.responseText).data); + commentBarrageConfig.dom.innerHTML = ''; + } + }); + xhr.open("POST", commentBarrageConfig.twikooUrl); + xhr.setRequestHeader("Content-Type", "application/json"); + xhr.send(data); + + + clearInterval(commentInterval); + commentInterval = null; + + commentInterval = setInterval(() => { + if (commentBarrageConfig.barrageList.length && !hoverOnCommentBarrage) { + popCommentBarrage(commentBarrageConfig.barrageList[commentBarrageConfig.barrageIndex]); + commentBarrageConfig.barrageIndex += 1; + commentBarrageConfig.barrageIndex %= commentBarrageConfig.barrageList.length; + } + if ((commentBarrageConfig.barrageTimer.length > (commentBarrageConfig.barrageList.length > commentBarrageConfig.maxBarrage ? commentBarrageConfig.maxBarrage : commentBarrageConfig.barrageList.length)) && !hoverOnCommentBarrage) { + removeCommentBarrage(commentBarrageConfig.barrageTimer.shift()) + } + }, commentBarrageConfig.barrageTime) +} + +function commentLinkFilter(data) { + data.sort((a, b) => { + return a.created - b.created; + }) + let newData = []; + data.forEach(item => { + newData.push(...getCommentReplies(item)); + }); + return newData; +} + +function getCommentReplies(item) { + if (item.replies) { + let replies = [item]; + item.replies.forEach(item => { + replies.push(...getCommentReplies(item)); + }) + return replies; + } else { + return []; + } +} + +function popCommentBarrage(data) { + let barrage = document.createElement('div'); + let width = commentBarrageConfig.dom.clientWidth; + let height = commentBarrageConfig.dom.clientHeight; + barrage.className = 'comment-barrage-item' + barrage.innerHTML = ` +
+ 热评 +
${data.nick}
+ + +
+ ${data.comment} + ` + commentBarrageConfig.barrageTimer.push(barrage); + commentBarrageConfig.dom.append(barrage); +} + +function removeCommentBarrage(barrage) { + barrage.className = 'comment-barrage-item out'; + setTimeout(() => { + commentBarrageConfig.dom.removeChild(barrage); + }, 1000) +} + + +// 自动隐藏 +document.addEventListener('scroll', btf.throttle(function () { + //滚动条高度+视窗高度 = 可见区域底部高度 + var visibleBottom = window.scrollY + document.documentElement.clientHeight; + //可见区域顶部高度 + var visibleTop = window.scrollY; + // 获取翻页按钮容器 + var pagination = document.querySelector('.comment-barrage'); + // 获取位置监测容器,此处采用评论区 + var eventlistner = document.getElementById('post-tools'); + if (eventlistner && pagination) { + var centerY = eventlistner.offsetTop + (eventlistner.offsetHeight / 2); + if (document.body.clientWidth > 768) { + if (centerY > visibleBottom) { + pagination.style.bottom = '0'; + } else { + pagination.style.bottom = '-200px'; + } + } + } +}, 200)) + +initCommentBarrage(); + +if (localStorage.getItem('commentBarrageSwitch') !== 'false') { + $(".comment-barrage").show(); + $(".menu-commentBarrage-text").text("关闭热评"); + document.querySelector("#consoleCommentBarrage").classList.add("on"); +} else { + $(".comment-barrage").hide(); + $(".menu-commentBarrage-text").text("显示热评"); + document.querySelector("#consoleCommentBarrage").classList.remove("on"); +} + + +document.addEventListener('pjax:send', function () { + clearInterval(commentInterval); +}); \ No newline at end of file diff --git a/templates/assets/zhheo/rightmenu.js b/templates/assets/zhheo/rightmenu.js index 22f75cf2..463a82c1 100644 --- a/templates/assets/zhheo/rightmenu.js +++ b/templates/assets/zhheo/rightmenu.js @@ -1,342 +1,419 @@ -"use strict"; +// 初始化函数 +let rm = {}; -function asyncGeneratorStep(e, n, t, o, i, r, c) { - try { - var m = e[r](c), - a = m.value; - } catch (e) { - return void t(e); +//禁止图片拖拽 +rm.stopdragimg = $("img"); +rm.stopdragimg.on("dragstart", function () { + return false; +}); + +// 显示菜单 +rm.showRightMenu = function (isTrue, x = 0, y = 0) { + let $rightMenu = $('#rightMenu'); + $rightMenu.css('top', x + 'px').css('left', y + 'px'); + if (isTrue) { + $rightMenu.show(); + stopMaskScroll() + } else { + $rightMenu.hide(); } - m.done ? n(a) : Promise.resolve(a).then(o, i); } -function _asyncToGenerator(m) { - return function () { - var e = this, - c = arguments; - return new Promise(function (n, t) { - var o = m.apply(e, c); - - function i(e) { - asyncGeneratorStep(o, n, t, i, r, "next", e); - } - - function r(e) { - asyncGeneratorStep(o, n, t, i, r, "throw", e); - } - - i(void 0); - }); - }; +// 隐藏菜单 +rm.hideRightMenu = function () { + rm.showRightMenu(false); + $('#rightmenu-mask').attr('style', 'display: none'); } -var rm = {}; -(rm.stopdragimg = $("img")), - rm.stopdragimg.on("dragstart", function () { - return !1; - }), - (rm.showRightMenu = function (e) { - var n = 1 < arguments.length && void 0 !== arguments[1] ? arguments[1] : 0, - t = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : 0, - o = $("#rightMenu"); - o.css("top", n + "px").css("left", t + "px"), - e ? (o.show(), stopMaskScroll()) : o.hide(); - }), - (rm.hideRightMenu = function () { - rm.showRightMenu(!1), $("#rightmenu-mask").attr("style", "display: none"); - }); -var rmWidth = $("#rightMenu").width(), - rmHeight = $("#rightMenu").height(); +// 尺寸 +let rmWidth = $('#rightMenu').width(); +let rmHeight = $('#rightMenu').height(); + +// 重新定义尺寸 rm.reloadrmSize = function () { - (rmWidth = $("#rightMenu").width()), (rmHeight = $("#rightMenu").height()); + rmWidth = $('#rightMenu').width(); + rmHeight = $('#rightMenu').height(); +} + +// 获取点击的href +let domhref = ''; +let domImgSrc = ''; +let globalEvent = null; + +// 监听右键初始化 +window.oncontextmenu = function (event) { + if (document.body.clientWidth > 768) { + let pageX = event.clientX + 10; //加10是为了防止显示时鼠标遮在菜单上 + let pageY = event.clientY; + // console.log(event); + + //其他额外菜单 + let $rightMenuOther = $('.rightMenuOther'); + let $rightMenuPlugin = $('.rightMenuPlugin'); + let $rightMenuCopyText = $('#menu-copytext'); + let $rightMenuPasteText = $('#menu-pastetext'); + let $rightMenuCommentText = $('#menu-commenttext'); + let $rightMenuNewWindow = $('#menu-newwindow'); + let $rightMenuCopyLink = $('#menu-copylink'); + let $rightMenuCopyImg = $('#menu-copyimg'); + let $rightMenuDownloadImg = $('#menu-downloadimg'); + let $rightMenuSearch = $('#menu-search'); + let $rightMenuSearchBaidu = $('#menu-searchBaidu'); + let $rightMenuMusicToggle = $('#menu-music-toggle'); + let $rightMenuMusicBack = $('#menu-music-back'); + let $rightMenuMusicForward = $('#menu-music-forward'); + let $rightMenuMusicPlaylist = $('#menu-music-playlist'); + let $rightMenuMusicCopyMusicName = $('#menu-music-copyMusicName'); + let href = event.target.href; + let imgsrc = event.target.currentSrc; + + // 判断模式 扩展模式为有事件 + let pluginMode = false; + $rightMenuOther.show(); + globalEvent = event; + + // 检查是否需要复制 是否有选中文本 + if (selectTextNow && window.getSelection()) { + pluginMode = true; + $rightMenuCopyText.show(); + $rightMenuCommentText.show(); + $rightMenuSearch.show(); + $rightMenuSearchBaidu.show(); + } else { + $rightMenuCopyText.hide(); + $rightMenuCommentText.hide(); + $rightMenuSearchBaidu.hide(); + $rightMenuSearch.hide(); + } + + //检查是否右键点击了链接a标签 + if (href) { + pluginMode = true; + $rightMenuNewWindow.show(); + $rightMenuCopyLink.show(); + domhref = href; + } else { + $rightMenuNewWindow.hide(); + $rightMenuCopyLink.hide(); + } + + //检查是否需要复制图片 + if (imgsrc) { + pluginMode = true; + $rightMenuCopyImg.show(); + $rightMenuDownloadImg.show(); + domImgSrc = imgsrc; + } else { + $rightMenuCopyImg.hide(); + $rightMenuDownloadImg.hide(); + } + + // 判断是否为输入框 + if (event.target.tagName.toLowerCase() === 'input' || event.target.tagName.toLowerCase() === 'textarea') { + console.log('这是一个输入框') + pluginMode = true; + $rightMenuPasteText.show(); + } else { + $rightMenuPasteText.hide(); + } + + //判断是否是音乐 + if (event.target.nodeName == "METING-JS") { + console.log('这是一个音乐'); + pluginMode = true; + $rightMenuMusicToggle.show(); + $rightMenuMusicBack.show(); + $rightMenuMusicForward.show(); + $rightMenuMusicPlaylist.show(); + $rightMenuMusicCopyMusicName.show(); + } else { + $rightMenuMusicToggle.hide(); + $rightMenuMusicBack.hide(); + $rightMenuMusicForward.hide(); + $rightMenuMusicPlaylist.hide(); + $rightMenuMusicCopyMusicName.hide() + } + + // 如果不是扩展模式则隐藏扩展模块 + if (pluginMode) { + $rightMenuOther.hide(); + $rightMenuPlugin.show(); + } else { + $rightMenuPlugin.hide() + } + + rm.reloadrmSize() + + // 鼠标默认显示在鼠标右下方,当鼠标靠右或考下时,将菜单显示在鼠标左方\上方 + if (pageX + rmWidth > window.innerWidth) { + pageX -= rmWidth + 10; + } + if (pageY + rmHeight > window.innerHeight) { + pageY -= pageY + rmHeight - window.innerHeight; + } + + rm.showRightMenu(true, pageY, pageX); + $('#rightmenu-mask').attr('style', 'display: flex'); + return false; + } }; -var domhref = "", - domImgSrc = "", - globalEvent = null; -function imageToBlob(e) { - var t = new Image(), - o = document.createElement("canvas"), - i = o.getContext("2d"); - return ( - (t.crossOrigin = ""), - (t.src = e), - new Promise(function (n) { - t.onload = function () { - (o.width = this.naturalWidth), - (o.height = this.naturalHeight), - i.drawImage(this, 0, 0), - o.toBlob( - function (e) { - n(e); - }, - "image/png", - 0.75 - ); - }; - }) - ); +// 下载图片状态 +rm.downloadimging = false; + +// 复制图片到剪贴板 +rm.writeClipImg = function (imgsrc) { + console.log('按下复制'); + rm.hideRightMenu(); + btf.snackbarShow('正在下载中,请稍后', false, 10000) + if (rm.downloadimging == false) { + rm.downloadimging = true; + setTimeout(function () { + copyImage(imgsrc); + btf.snackbarShow('复制成功!图片已添加盲水印,请遵守版权协议'); + rm.downloadimging = false; + }, "10000") + } } -function copyImage(e) { - return _copyImage.apply(this, arguments); +function imageToBlob(imageURL) { + const img = new Image; + const c = document.createElement("canvas"); + const ctx = c.getContext("2d"); + img.crossOrigin = ""; + img.src = imageURL; + return new Promise(resolve => { + img.onload = function () { + c.width = this.naturalWidth; + c.height = this.naturalHeight; + ctx.drawImage(this, 0, 0); + c.toBlob((blob) => { + // here the image is a blob + resolve(blob) + }, "image/png", 0.75); + }; + }) } -function _copyImage() { - return (_copyImage = _asyncToGenerator( - regeneratorRuntime.mark(function e(n) { - var t, o; - return regeneratorRuntime.wrap(function (e) { - for (; ;) - switch ((e.prev = e.next)) { - case 0: - return (e.next = 2), imageToBlob(n); - case 2: - (t = e.sent), - (o = new ClipboardItem({"image/png": t})), - navigator.clipboard.write([o]); - case 5: - case "end": - return e.stop(); - } - }, e); - }) - )).apply(this, arguments); +async function copyImage(imageURL) { + const blob = await imageToBlob(imageURL) + const item = new ClipboardItem({"image/png": blob}); + navigator.clipboard.write([item]); +} + +rm.switchDarkMode = function () { + navFn.switchDarkMode(); + rm.hideRightMenu(); + heo.darkModeStatus(); +} + +rm.copyUrl = function (id) { + $("body").after(""); + var text = id; + var input = document.getElementById("copyVal"); + input.value = text; + input.select(); + input.setSelectionRange(0, input.value.length); + document.execCommand("copy"); + $("#copyVal").remove(); } function stopMaskScroll() { - document.getElementById("rightmenu-mask") && - document.getElementById("rightmenu-mask").addEventListener( - "mousewheel", - function (e) { + if (document.getElementById("rightmenu-mask")) { + let xscroll = document.getElementById("rightmenu-mask"); + xscroll.addEventListener("mousewheel", function (e) { + //阻止浏览器默认方法 rm.hideRightMenu(); - }, - !1 - ), - document.getElementById("rightMenu") && - document.getElementById("rightMenu").addEventListener( - "mousewheel", - function (e) { + // e.preventDefault(); + }, false); + } + if (document.getElementById("rightMenu")) { + let xscroll = document.getElementById("rightMenu"); + xscroll.addEventListener("mousewheel", function (e) { + //阻止浏览器默认方法 rm.hideRightMenu(); - }, - !1 - ); + // e.preventDefault(); + }, false); + } } -(window.oncontextmenu = function (e) { - if (768 < document.body.clientWidth) { - var n = e.clientX + 10, - t = e.clientY, - o = $(".rightMenuOther"), - i = $(".rightMenuPlugin"), - r = $("#menu-copytext"), - c = $("#menu-pastetext"), - m = $("#menu-commenttext"), - a = $("#menu-newwindow"), - u = $("#menu-copylink"), - h = $("#menu-copyimg"), - d = $("#menu-downloadimg"), - s = $("#menu-search"), - l = $("#menu-searchBaidu"), - g = $("#menu-music-toggle"), - w = $("#menu-music-back"), - f = $("#menu-music-forward"), - p = $("#menu-music-playlist"), - k = $("#menu-music-copyMusicName"), - y = e.target.href, - v = e.target.currentSrc, - M = !1; - return ( - o.show(), - (globalEvent = e), - selectTextNow && window.getSelection() - ? ((M = !0), r.show(), m.show(), s.show(), l.show()) - : (r.hide(), m.hide(), l.hide(), s.hide()), - y ? ((M = !0), a.show(), u.show(), (domhref = y)) : (a.hide(), u.hide()), - v - ? ((M = !0), h.show(), d.show(), (domImgSrc = v)) - : (h.hide(), d.hide()), - "input" === e.target.tagName.toLowerCase() || - "textarea" === e.target.tagName.toLowerCase() - ? (console.log("这是一个输入框"), (M = !0), c.show()) - : c.hide(), - "METING-JS" == e.target.nodeName - ? (console.log("这是一个音乐"), - (M = !0), - g.show(), - w.show(), - f.show(), - p.show(), - k.show()) - : (g.hide(), w.hide(), f.hide(), p.hide(), k.hide()), - M ? (o.hide(), i.show()) : i.hide(), - rm.reloadrmSize(), - n + rmWidth > window.innerWidth && (n -= rmWidth + 10), - t + rmHeight > window.innerHeight && - (t -= t + rmHeight - window.innerHeight), - rm.showRightMenu(!0, t, n), - $("#rightmenu-mask").attr("style", "display: flex"), - !1 - ); +rm.rightmenuCopyText = function (txt) { + if (navigator.clipboard) { + navigator.clipboard.writeText(txt); } -}), - (rm.downloadimging = !1), - (rm.writeClipImg = function (e) { - console.log("按下复制"), - rm.hideRightMenu(), - btf.snackbarShow("正在下载中,请稍后", !1, 1e4), - 0 == rm.downloadimging && - ((rm.downloadimging = !0), - setTimeout(function () { - copyImage(e), - btf.snackbarShow("复制成功!图片已添加盲水印,请遵守版权协议"), - (rm.downloadimging = !1); - }, "10000")); - }), - (rm.switchDarkMode = function () { - navFn.switchDarkMode(), rm.hideRightMenu(), heo.darkModeStatus(); - }), - (rm.copyUrl = function (e) { - $("body").after(""); - var n = e, - t = document.getElementById("copyVal"); - (t.value = n), - t.select(), - t.setSelectionRange(0, t.value.length), - document.execCommand("copy"), - $("#copyVal").remove(); - }), - (rm.rightmenuCopyText = function (e) { - navigator.clipboard && navigator.clipboard.writeText(e), rm.hideRightMenu(); - }), - (rm.copyPageUrl = function () { - var e = window.location.href; - rm.copyUrl(e), - btf.snackbarShow("复制本页链接地址成功", !1, 2e3), - rm.hideRightMenu(); - }), - (rm.sharePage = function () { - window.location.href; - rm.copyUrl(url), - btf.snackbarShow("复制本页链接地址成功", !1, 2e3), - rm.hideRightMenu(); - }); -var selectTextNow = ""; + rm.hideRightMenu(); +} + +rm.copyPageUrl = function () { + var url = window.location.href; + rm.copyUrl(url); + btf.snackbarShow('复制本页链接地址成功', false, 2000); + rm.hideRightMenu(); +} + +rm.sharePage = function () { + var content = window.location.href; + rm.copyUrl(url); + btf.snackbarShow('复制本页链接地址成功', false, 2000); + rm.hideRightMenu(); +} + +// 复制当前选中文本 +var selectTextNow = ''; +document.onmouseup = document.ondbclick = selceText; function selceText() { - var e = document.selection - ? document.selection.createRange().text - : window.getSelection() + ""; - selectTextNow = e || ""; + var txt; + if (document.selection) { + txt = document.selection.createRange().text; + } else { + txt = window.getSelection() + ''; + } + if (txt) { + selectTextNow = txt; + // console.log(selectTextNow); + } else { + selectTextNow = ''; + } } -function replaceAll(e, n, t) { - return e.split(n).join(t); +// 读取剪切板 +rm.readClipboard = function () { + if (navigator.clipboard) { + navigator.clipboard.readText().then(clipText => rm.insertAtCaret(globalEvent.target, clipText)); + } +} + +// 粘贴文本到焦点 +rm.insertAtCaret = function (elemt, value) { + const startPos = elemt.selectionStart, + endPos = elemt.selectionEnd; + if (document.selection) { + elemt.focus(); + var sel = document.selection.createRange(); + sel.text = value; + elemt.focus(); + } else { + if (startPos || startPos == '0') { + var scrollTop = elemt.scrollTop; + elemt.value = elemt.value.substring(0, startPos) + value + elemt.value.substring(endPos, elemt.value.length); + elemt.focus(); + elemt.selectionStart = startPos + value.length; + elemt.selectionEnd = startPos + value.length; + elemt.scrollTop = scrollTop; + } else { + elemt.value += value; + elemt.focus(); + } + } +} + +//粘贴文本 +rm.pasteText = function () { + const result = rm.readClipboard() || ''; + rm.hideRightMenu(); +} + +//引用到评论 +rm.rightMenuCommentText = function (txt) { + rm.hideRightMenu(); + var input = document.getElementsByClassName('el-textarea__inner')[0]; + let evt = document.createEvent('HTMLEvents'); + evt.initEvent('input', true, true); + let inputValue = replaceAll(txt, '\n', '\n> ') + input.value = '> ' + inputValue + '\n\n'; + input.dispatchEvent(evt); + var domTop = document.querySelector("#post-comment").offsetTop; + window.scrollTo(0, domTop - 80); + input.focus(); + input.setSelectionRange(-1, -1); + if (document.getElementById("comment-tips")) { + document.getElementById("comment-tips").classList.add("show"); + } +} + +//替换所有内容 +function replaceAll(string, search, replace) { + return string.split(search).join(replace); +} + +// 百度搜索 +rm.searchBaidu = function () { + btf.snackbarShow('即将跳转到百度搜索', false, 2000); + setTimeout(function () { + window.open('https://www.baidu.com/s?wd=' + selectTextNow); + }, "2000"); + rm.hideRightMenu(); +} + +//分享链接 +rm.copyLink = function () { + rm.rightmenuCopyText(domhref); + btf.snackbarShow('已复制链接地址'); } function addRightMenuClickEvent() { - $("#menu-backward").on("click", function () { - window.history.back(), rm.hideRightMenu(); - }), - $("#menu-forward").on("click", function () { - window.history.forward(), rm.hideRightMenu(); - }), - $("#menu-refresh").on("click", function () { - window.location.reload(); - }), - $("#menu-top").on("click", function () { - btf.scrollToDest(0, 500), rm.hideRightMenu(); - }), - $(".menu-link").on("click", rm.hideRightMenu), - $("#menu-darkmode").on("click", rm.switchDarkMode), - $("#menu-home").on("click", function () { - window.location.href = window.location.origin; - }), - // $("#menu-randomPost").on("click", function () { - // toRandomPost(); - // }), - $("#menu-commentBarrage").on("click", heo.switchCommentBarrage), - $("#rightmenu-mask").on("click", rm.hideRightMenu), - $("#rightmenu-mask").contextmenu(function () { - return rm.hideRightMenu(), !1; - }), - $("#menu-copy").on("click", rm.copyPageUrl), - $("#menu-pastetext").on("click", rm.pasteText), - $("#menu-copytext").on("click", function () { - rm.rightmenuCopyText(selectTextNow), - btf.snackbarShow("复制成功,复制和转载请标注本文地址"); - }), - $("#menu-commenttext").on("click", function () { - rm.rightMenuCommentText(selectTextNow); - }), - $("#menu-newwindow").on("click", function () { - window.open(domhref), rm.hideRightMenu(); - }), - $("#menu-copylink").on("click", rm.copyLink), - $("#menu-downloadimg").on("click", function () { - heo.downloadImage(domImgSrc, "zhheo"); - }), - $("#menu-copyimg").on("click", function () { - rm.writeClipImg(domImgSrc); - }), - $("#menu-searchBaidu").on("click", rm.searchBaidu), - $("#menu-music-toggle").on("click", heo.musicToggle), - $("#menu-music-back").on("click", heo.musicSkipBack), - $("#menu-music-forward").on("click", heo.musicSkipForward), - $("#menu-music-copyMusicName").on("click", function () { - rm.rightmenuCopyText(heo.musicGetName()), - btf.snackbarShow("复制歌曲名称成功", !1, 3e3); - }); -} - -(document.onmouseup = document.ondbclick = selceText), - (rm.readClipboard = function () { - navigator.clipboard && - navigator.clipboard.readText().then(function (e) { - return rm.insertAtCaret(globalEvent.target, e); - }); - }), - (rm.insertAtCaret = function (e, n) { - var t, - o = e.selectionStart, - i = e.selectionEnd; - document.selection - ? (e.focus(), (document.selection.createRange().text = n), e.focus()) - : o || "0" == o - ? ((t = e.scrollTop), - (e.value = - e.value.substring(0, o) + n + e.value.substring(i, e.value.length)), - e.focus(), - (e.selectionStart = o + n.length), - (e.selectionEnd = o + n.length), - (e.scrollTop = t)) - : ((e.value += n), e.focus()); - }), - (rm.pasteText = function () { - rm.readClipboard(); + // 添加点击事件 + $('#menu-backward').on('click', function () { + window.history.back(); rm.hideRightMenu(); - }), - (rm.rightMenuCommentText = function (e) { - rm.hideRightMenu(); - var n = document.getElementsByClassName("el-textarea__inner")[0], - t = document.createEvent("HTMLEvents"); - t.initEvent("input", !0, !0); - var o = replaceAll(e, "\n", "\n> "); - (n.value = "> " + o + "\n\n"), n.dispatchEvent(t); - var i = document.querySelector("#post-comment").offsetTop; - window.scrollTo(0, i - 80), - n.focus(), - n.setSelectionRange(-1, -1), - document.getElementById("comment-tips") && - document.getElementById("comment-tips").classList.add("show"); - }), - (rm.searchBaidu = function () { - btf.snackbarShow("即将跳转到百度搜索", !1, 2e3), - setTimeout(function () { - window.open("https://www.baidu.com/s?wd=" + selectTextNow); - }, "2000"), - rm.hideRightMenu(); - }), - (rm.copyLink = function () { - rm.rightmenuCopyText(domhref), btf.snackbarShow("已复制链接地址"); }); + $('#menu-forward').on('click', function () { + window.history.forward(); + rm.hideRightMenu(); + }); + $('#menu-refresh').on('click', function () { + window.location.reload(); + }); + $('#menu-top').on('click', function () { + btf.scrollToDest(0, 500); + rm.hideRightMenu(); + }); + $('.menu-link').on('click', rm.hideRightMenu); + $('#menu-darkmode').on('click', rm.switchDarkMode); + $('#menu-home').on('click', function () { + window.location.href = window.location.origin; + }); + $('#menu-randomPost').on('click', function () { + toRandomPost() + }); + $('#menu-commentBarrage').on('click', heo.switchCommentBarrage); + $('#rightmenu-mask').on('click', rm.hideRightMenu); + $('#rightmenu-mask').contextmenu(function () { + rm.hideRightMenu(); + return false; + }); + $('#menu-translate').on('click', function () { + rm.hideRightMenu(); + translateInitialization(); + }); + $('#menu-copy').on('click', rm.copyPageUrl); + $('#menu-pastetext').on('click', rm.pasteText); + $('#menu-copytext').on('click', function () { + rm.rightmenuCopyText(selectTextNow); + btf.snackbarShow('复制成功,复制和转载请标注本文地址'); + }); + $('#menu-commenttext').on('click', function () { + rm.rightMenuCommentText(selectTextNow); + }); + $('#menu-newwindow').on('click', function () { + window.open(domhref); + rm.hideRightMenu(); + }); + $('#menu-copylink').on('click', rm.copyLink); + $('#menu-downloadimg').on('click', function () { + heo.downloadImage(domImgSrc, 'zhheo'); + }); + $('#menu-copyimg').on('click', function () { + rm.writeClipImg(domImgSrc); + }); + $('#menu-searchBaidu').on('click', rm.searchBaidu); + //音乐 + $('#menu-music-toggle').on('click', heo.musicToggle); + $('#menu-music-back').on('click', heo.musicSkipBack); + $('#menu-music-forward').on('click', heo.musicSkipForward); + $('#menu-music-copyMusicName').on('click', function () { + rm.rightmenuCopyText(heo.musicGetName()); + btf.snackbarShow('复制歌曲名称成功', false, 3000); + }); +} diff --git a/templates/assets/zhheo/zhheoblog.css b/templates/assets/zhheo/zhheoblog.css index 03233b3f..6456a65b 100644 --- a/templates/assets/zhheo/zhheoblog.css +++ b/templates/assets/zhheo/zhheoblog.css @@ -1,3 +1,5 @@ +@charset "UTF-8"; + :root { --heo-white: #fff; --heo-white-op: rgba(255, 255, 255, 0.2); @@ -9,6 +11,7 @@ --heo-vip: #e5a80d; --heo-main: var(--heo-theme); --heo-main-op: var(--heo-theme-op); + --heo-main-op-deep: var(--heo-theme-op-deep); --heo-main-none: var(--heo-theme-none); --heo-shadow-theme: 0 8px 12px -3px var(--heo-theme-op); --heo-shadow-blackdeep: 0 2px 16px -3px rgba(0, 0, 0, 0.15); @@ -33,7 +36,7 @@ color: var(--heo-background); } -[data-theme="light"] { +[data-theme=light] { --heo-theme: #425AEF; --heo-theme-op: #4259ef23; --heo-theme-op-deep: #4259efdd; @@ -70,7 +73,7 @@ --style-border-forever: 2px solid var(--heo-main); } -[data-theme="dark"] { +[data-theme=dark] { --heo-theme: #0084FF; --heo-theme-op: #0084FF23; --heo-theme-op-deep: #0084ffdd; @@ -138,6 +141,7 @@ } } +/* 旧版css */ html { line-height: 1.15; text-size-adjust: 100%; @@ -282,10 +286,6 @@ textarea { font: inherit; } -details { - display: block; -} - summary { display: list-item; } @@ -323,6 +323,13 @@ template { .article-sort-item-title, .limit-more-line, .relatedPosts > .relatedPosts-list .content .title, + /*figure.gallery-group .gallery-group-name,*/ + /*figure.gallery-group p {*/ + /* display: -webkit-box;*/ + /* overflow: hidden;*/ + /* -webkit-box-orient: vertical;*/ + /*}*/ + #article-container h1::before, #article-container h2::before, #article-container h3::before, @@ -741,7 +748,7 @@ body { position: relative; min-height: 100%; background: var(--global-bg); - color: var(--font-color); + color: var(--heo-fontcolor); font-size: var(--global-font-size); font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei"; line-height: 2; @@ -750,7 +757,7 @@ body { } input::placeholder { - color: var(--font-color); + color: var(--heo-fontcolor); } #web_bg { @@ -914,6 +921,133 @@ img[src=""] { --hlexpand-bg: linear-gradient(180deg, rgba(33, 33, 33, 0.6), rgba(33, 33, 33, 0.9)); } +/*figure.highlight table::-webkit-scrollbar-thumb {*/ +/* background: var(--hlscrollbar-bg);*/ +/*}*/ + +/*figure.highlight pre .deletion {*/ +/* color: rgb(191, 66, 191);*/ +/*}*/ + +/*figure.highlight pre .addition {*/ +/* color: rgb(16, 94, 222);*/ +/*}*/ + +/*figure.highlight pre .meta {*/ +/* color: rgb(199, 146, 234);*/ +/*}*/ + +/*figure.highlight pre .comment {*/ +/* color: rgb(150, 152, 150);*/ +/*}*/ + +/*figure.highlight pre .attribute,*/ +/*figure.highlight pre .css .class,*/ +/*figure.highlight pre .css .id,*/ +/*figure.highlight pre .css .pseudo,*/ +/*figure.highlight pre .html .doctype,*/ +/*figure.highlight pre .regexp,*/ +/*figure.highlight pre .ruby .constant,*/ +/*figure.highlight pre .tag .name,*/ +/*figure.highlight pre .variable,*/ +/*figure.highlight pre .xml .doctype,*/ +/*figure.highlight pre .xml .pi,*/ +/*figure.highlight pre .xml .tag .title {*/ +/* color: var(--heo-red);*/ +/*}*/ + +/*figure.highlight pre .tag {*/ +/* color: rgb(137, 221, 255);*/ +/*}*/ + +/*figure.highlight pre .command,*/ +/*figure.highlight pre .constant,*/ +/*figure.highlight pre .literal,*/ +/*figure.highlight pre .number,*/ +/*figure.highlight pre .params,*/ +/*figure.highlight pre .preprocessor {*/ +/* color: var(--heo-orange);*/ +/*}*/ + +/*figure.highlight pre .built_in {*/ +/* color: var(--heo-yellow);*/ +/*}*/ + +/*figure.highlight pre .css .rules .attribute,*/ +/*figure.highlight pre .formula,*/ +/*figure.highlight pre .header,*/ +/*figure.highlight pre .inheritance,*/ +/*figure.highlight pre .number,*/ +/*figure.highlight pre .ruby .class .title,*/ +/*figure.highlight pre .ruby .symbol,*/ +/*figure.highlight pre .special,*/ +/*figure.highlight pre .string,*/ +/*figure.highlight pre .value,*/ +/*figure.highlight pre .xml .cdata {*/ +/* color: var(--heo-green);*/ +/*}*/ + +/*figure.highlight pre .css .hexcolor,*/ +/*figure.highlight pre .keyword,*/ +/*figure.highlight pre .title {*/ +/* color: rgb(137, 221, 255);*/ +/*}*/ + +/*figure.highlight pre .coffeescript .title,*/ +/*figure.highlight pre .function,*/ +/*figure.highlight pre .javascript .title,*/ +/*figure.highlight pre .perl .sub,*/ +/*figure.highlight pre .python .decorator,*/ +/*figure.highlight pre .python .title,*/ +/*figure.highlight pre .ruby .function .title,*/ +/*figure.highlight pre .ruby .title .keyword {*/ +/* color: var(--heo-blue);*/ +/*}*/ + +/*figure.highlight pre .javascript .function,*/ +/*figure.highlight pre .tag .attr {*/ +/* color: rgb(199, 146, 234);*/ +/*}*/ + +/*#article-container figure.highlight .line.marked {*/ +/* background-color: rgba(97, 97, 97, 0.314);*/ +/*}*/ + +/*#article-container figure.highlight table {*/ +/* display: block;*/ +/* overflow: auto;*/ +/* border: none;*/ +/*}*/ + +/*#article-container figure.highlight table td {*/ +/* padding: 0px;*/ +/* border: none;*/ +/*}*/ + +/*#article-container figure.highlight .gutter pre {*/ +/* padding-right: 0.5rem;*/ +/* padding-left: 0.5rem;*/ +/* background-color: var(--hlnumber-bg);*/ +/* color: var(--hlnumber-color);*/ +/* text-align: right;*/ +/*}*/ + +/*#article-container figure.highlight .code pre {*/ +/* padding-right: 0.5rem;*/ +/* padding-left: 0.5rem;*/ +/* width: 100%;*/ +/*}*/ + +/*#article-container figure.highlight,*/ +/*#article-container pre {*/ +/* overflow: auto;*/ +/* margin: 0px 0px 1rem;*/ +/* padding: 0px;*/ +/* background: var(--hl-bg);*/ +/* color: var(--hl-color);*/ +/* line-height: 1.6;*/ +/*}*/ + blockquote { margin: 0px 0px 1rem; padding: 0.1rem 0.8rem; @@ -940,6 +1074,118 @@ blockquote footer cite::before { content: "—"; } +/*#article-container code,*/ +/*#article-container pre {*/ +/* font-size: var(--global-font-size);*/ +/* font-family: consolas, Menlo, "PingFang SC", "Microsoft YaHei", sans-serif !important;*/ +/*}*/ + +/*#article-container code {*/ +/* padding: 0.1rem 0.2rem;*/ +/* background: rgba(27, 31, 35, 0.05);*/ +/* color: rgb(244, 116, 102);*/ +/*}*/ + +/*#article-container pre {*/ +/* padding: 10px 20px;*/ +/*}*/ + +/*#article-container pre code {*/ +/* padding: 0px;*/ +/* background: 0px 0px;*/ +/* color: var(--hl-color);*/ +/* text-shadow: none;*/ +/*}*/ + +/*#article-container figure.highlight {*/ +/* position: relative;*/ +/*}*/ + +/*#article-container figure.highlight pre {*/ +/* margin: 0px;*/ +/* padding: 8px 0px;*/ +/* border: none;*/ +/*}*/ + +/*#article-container figure.highlight .caption,*/ +/*#article-container figure.highlight figcaption {*/ +/* padding: 0.3rem 0px 0.1rem 0.7rem;*/ +/* font-size: var(--global-font-size);*/ +/* line-height: 1em;*/ +/*}*/ + +/*#article-container figure.highlight .caption a,*/ +/*#article-container figure.highlight figcaption a {*/ +/* float: right;*/ +/* padding-right: 10px;*/ +/* color: var(--hl-color);*/ +/*}*/ + +/*#article-container figure.highlight .caption a:hover,*/ +/*#article-container figure.highlight figcaption a:hover {*/ +/* border-bottom-color: var(--hl-color);*/ +/*}*/ + +/*#article-container .highlight-tools {*/ +/* position: relative;*/ +/* display: flex;*/ +/* -webkit-box-align: center;*/ +/* align-items: center;*/ +/* overflow: hidden;*/ +/* min-height: 1.2rem;*/ +/* height: 2.15em;*/ +/* background: var(--hltools-bg);*/ +/* color: var(--hltools-color);*/ +/* font-size: var(--global-font-size);*/ +/*}*/ + +/*#article-container .highlight-tools.closed + table {*/ +/* display: none;*/ +/*}*/ + +/*#article-container .highlight-tools .expand {*/ +/* position: absolute;*/ +/* padding: 0.4rem 0.7rem;*/ +/* cursor: pointer;*/ +/* transition: transform 0.3s ease 0s;*/ +/*}*/ + +/*#article-container .highlight-tools .expand + .code-lang {*/ +/* left: 1.7rem;*/ +/*}*/ + +/*#article-container .highlight-tools .expand.closed {*/ +/* transition: all 0.3s ease 0s;*/ +/* transform: rotate(-90deg) !important;*/ +/*}*/ + +/*#article-container .highlight-tools .code-lang {*/ +/* position: absolute;*/ +/* left: 0.7rem;*/ +/* text-transform: uppercase;*/ +/* font-weight: 700;*/ +/* font-size: 1.15em;*/ +/* user-select: none;*/ +/*}*/ + +/*#article-container .highlight-tools .copy-notice {*/ +/* position: absolute;*/ +/* right: 1.7rem;*/ +/* opacity: 0;*/ +/* transition: opacity 0.4s ease 0s;*/ +/*}*/ + +/*#article-container .highlight-tools .copy-button {*/ +/* position: absolute;*/ +/* right: 0.7rem;*/ +/* cursor: pointer;*/ +/* transition: color 0.2s ease 0s;*/ +/*}*/ + +/*#article-container .highlight-tools .copy-button:hover {*/ +/* color: rgb(48, 122, 246);*/ +/*}*/ + #article-container .gutter { user-select: none; } @@ -957,6 +1203,34 @@ blockquote footer cite::before { border: var(--style-border-always); } + +/*#article-container .code-expand-btn {*/ +/* position: absolute;*/ +/* bottom: 0px;*/ +/* z-index: 10;*/ +/* width: 100%;*/ +/* background: var(--hlexpand-bg);*/ +/* text-align: center;*/ +/* font-size: var(--global-font-size);*/ +/* cursor: pointer;*/ +/*}*/ + +/*#article-container .code-expand-btn i {*/ +/* padding: 0.3rem 0px;*/ +/* color: var(--hlnumber-color);*/ +/* animation: 1.2s ease 0s infinite normal none running code-expand-key;*/ +/*}*/ + +/*#article-container .code-expand-btn.expand-done {*/ +/* display: none !important;*/ +/*}*/ + +/*#article-container .code-expand-btn:not(.expand-done) ~ pre,*/ +/*#article-container .code-expand-btn:not(.expand-done) ~ table {*/ +/* overflow: hidden;*/ +/* height: 400px;*/ +/*}*/ + @-webkit-keyframes code-expand-key { 0% { opacity: 0.6; @@ -1085,7 +1359,7 @@ blockquote footer cite::before { } .article-sort-item-title { - color: var(--font-color); + color: var(--heo-fontcolor); font-size: 1.1em; transition: all 0.3s ease 0s; -webkit-line-clamp: 2; @@ -1140,7 +1414,7 @@ blockquote footer cite::before { } #page .category-lists .category-list a { - color: var(--font-color); + color: var(--heo-fontcolor); } #page .category-lists .category-list a:hover { @@ -1250,6 +1524,217 @@ blockquote footer cite::before { } } +.layout.hide-aside { + max-width: 1000px; +} + +@media screen and (min-width: 2000px) { + .layout.hide-aside { + max-width: 1300px; + } +} + +.layout.hide-aside > div { + width: 100% !important; +} + +.flink#article-container .flink-desc { + margin: 0.2rem 0px 0.5rem; +} + +.flink#article-container .flink-list { + overflow: auto; + padding: 10px 10px 0px; + text-align: center; +} + +.flink#article-container .flink-list > .flink-list-item { + position: relative; + float: left; + overflow: hidden; + margin: 15px 7px; + width: calc(25% - 12px); + height: 90px; + border-radius: 5px; + line-height: 17px; + transform: translateZ(0px); + transition: all 0.3s ease 0s; +} + +@media screen and (max-width: 1200px) { + .flink#article-container .flink-list > .flink-list-item { + width: calc(25% - 12px) !important; + } +} + +@media screen and (max-width: 1024px) { + .flink#article-container .flink-list > .flink-list-item { + width: calc(33.3333% - 12px) !important; + } +} + +@media screen and (max-width: 768px) { + .flink#article-container .flink-list > .flink-list-item { + width: calc(50% - 12px) !important; + } +} + +@media screen and (max-width: 600px) { + .flink#article-container .flink-list > .flink-list-item { + width: calc(100% - 12px) !important; + } +} + +.flink#article-container .flink-list > .flink-list-item:hover { + background: rgb(0, 108, 242); + transform: scale(1.05); +} + +.flink#article-container .flink-list > .flink-list-item a { + color: var(--heo-fontcolor); + text-decoration: none; +} + +.flink#article-container .flink-list > .flink-list-item a img { + float: left; + margin: 15px 10px; + width: 60px; + height: 60px; + border-radius: 35px; + transition: all 0.3s ease 0s; +} + +.flink#article-container .flink-list > .flink-list-item a .img-alt { + display: none; +} + +.flink#article-container .flink-list > .flink-list-item a .flink-item-name { + display: block; + padding: 16px 10px 0px 0px; + height: 40px; + font-weight: 700; + font-size: 1.43em; +} + +.flink#article-container .flink-list > .flink-list-item a .flink-item-desc { + display: block; + padding: 16px 10px 16px 0px; + height: 50px; + font-size: 0.93em; +} + +.flink#article-container .site-card-group { + display: flex; + flex-wrap: wrap; + -webkit-box-pack: start; + justify-content: flex-start; + margin: -8px; + -webkit-box-align: stretch; + align-items: stretch; +} + +.flink#article-container .site-card { + margin: 8px; + width: calc(20% - 16px); + display: block; + line-height: 1.4; + height: 100%; +} + +@media screen and (max-width: 1200px) { + .flink#article-container .site-card { + width: calc(20% - 16px) !important; + } +} + +@media screen and (max-width: 1024px) { + .flink#article-container .site-card { + width: calc(25% - 16px) !important; + } +} + +@media screen and (max-width: 768px) { + .flink#article-container .site-card { + width: calc(33.3333% - 16px) !important; + } +} + +@media screen and (max-width: 600px) { + .flink#article-container .site-card { + width: calc(50% - 16px) !important; + } +} + +.flink#article-container .site-card .img { + width: 100%; + height: 120px; + overflow: hidden; + border-radius: 12px 12px 0px 0px; + background: rgb(246, 246, 246); +} + +@media screen and (max-width: 500px) { + .flink#article-container .site-card .img { + height: 100px; + } +} + +.flink#article-container .site-card .img img { + width: 100%; + height: 100%; + transition: transform 2s ease 0s; + object-fit: cover; +} + +.flink#article-container .site-card .info { + margin-top: 8px; +} + +.flink#article-container .site-card .info img { + width: 32px; + height: 32px; + border-radius: 16px; + float: left; + margin-right: 8px; + margin-top: 2px; +} + +.flink#article-container .site-card .info span { + display: block; +} + +.flink#article-container .site-card .info .title { + font-weight: 600; + color: rgb(68, 68, 68); + display: -webkit-box; + -webkit-box-orient: vertical; + overflow: hidden; + -webkit-line-clamp: 1; + transition: all 0.3s ease 0s; +} + +.flink#article-container .site-card .info .desc { + overflow-wrap: break-word; + line-height: 1.2; + color: rgb(136, 136, 136); + display: -webkit-box; + -webkit-box-orient: vertical; + overflow: hidden; + -webkit-line-clamp: 2; +} + +.flink#article-container .site-card .img { + transition: all 0.3s ease 0s; +} + +.flink#article-container .site-card .img-alt { + display: none; +} + +.flink#article-container .site-card:hover .info .title { + color: rgb(255, 87, 34); +} + #recent-posts > .recent-post-item:not(:first-child) { margin-top: 1rem; } @@ -1281,7 +1766,7 @@ blockquote footer cite::before { transform: scale(1.1); } -#recent-posts > .recent-post-item .cover_radius { +#recent-posts > .recent-post-item .left_radius { border-radius: 5px 0px 0px 8px; } @@ -1298,7 +1783,7 @@ blockquote footer cite::before { overflow: hidden; width: 45%; height: 100%; - -webkit-mask-image: -webkit-radial-gradient(center center, rgb(255, 255, 255), rgb(0, 0, 0)); + -webkit-mask-image: -webkit-radial-gradient(center, rgb(255, 255, 255), rgb(0, 0, 0)); } #recent-posts > .recent-post-item .post_cover img.post_bg { @@ -1616,7 +2101,7 @@ blockquote footer cite::before { } #aside-content .card-info .card-info-data > .card-info-data-item a .headline { - color: var(--font-color); + color: var(--heo-fontcolor); font-size: 1em; } @@ -1632,7 +2117,7 @@ blockquote footer cite::before { #aside-content .card-info .card-info-social-icons .social-icon { margin: 0px 0.5rem; - color: var(--font-color); + color: var(--heo-fontcolor); font-size: 1.4em; cursor: pointer; } @@ -1754,7 +2239,7 @@ blockquote footer cite::before { #aside-content .aside-list > .aside-list-item .content > .comment, #aside-content .aside-list > .aside-list-item .content > .title { - color: var(--font-color); + color: var(--heo-fontcolor); font-size: 95%; line-height: 1.5; -webkit-line-clamp: 2; @@ -1781,7 +2266,7 @@ blockquote footer cite::before { display: inline-block; padding: 0.15rem 0.5rem; width: 100%; - color: var(--font-color); + color: var(--heo-fontcolor); transition: all 0.4s ease 0s; border-radius: 5px; } @@ -1944,6 +2429,21 @@ blockquote footer cite::before { animation: 1s ease 0s infinite normal none running more-btn-move; } +@media screen and (min-width: 900px) { + html.hide-aside .layout { + -webkit-box-pack: center; + justify-content: center; + } + + html.hide-aside .layout > .aside-content { + display: none; + } + + html.hide-aside .layout > div:first-child { + width: 80%; + } +} + .page .sticky_layout { display: flex; -webkit-box-orient: vertical; @@ -2279,7 +2779,7 @@ blockquote footer cite::before { } #page-header.not-top-img #nav a { - color: var(--font-color); + color: var(--heo-fontcolor); text-shadow: none; } @@ -2294,7 +2794,7 @@ blockquote footer cite::before { #page-header.nav-fixed #nav #site-name, #page-header.nav-fixed #nav #toggle-menu, #page-header.nav-fixed #nav a { - color: var(--font-color); + color: var(--heo-fontcolor); text-shadow: none; } @@ -2362,20 +2862,15 @@ blockquote footer cite::before { } @media screen and (min-width: 768px) { - #post-info #post-meta > .meta-secondline > span:first-child { - display: none; - } + /*#post-info #post-meta > .meta-secondline > span:first-child {*/ + /* display: none;*/ + /*}*/ } @media screen and (max-width: 768px) { #post-info #post-meta { font-size: 90%; } - - #post-info #post-meta > .meta-firstline, - #post-info #post-meta > .meta-secondline { - display: inline; - } } #post-info #post-meta .post-meta-separator { @@ -3129,7 +3624,7 @@ ul { margin: 3px; width: calc(33.333% - 6px); height: 200px; - background: rgb(0, 0, 0); + background: var(--heo-main); vertical-align: bottom; } @@ -3257,6 +3752,48 @@ ul { color: rgb(133, 133, 133); } +#rightside #rightside-config-hide { + transition: transform 0.4s ease 0s; + transform: translate(35px, 0px); +} + +#rightside #rightside-config-hide.show { + transform: translate(0px, 0px) !important; +} + +#rightside > div > a, +#rightside > div > button { + display: block; + margin-bottom: 2px; + width: 30px; + height: 30px; + background-color: var(--btn-bg); + color: var(--btn-color); + text-align: center; + font-size: 16px; +} + +#rightside > div > a:hover, +#rightside > div > button:hover { + background-color: var(--btn-hover-color); +} + +#rightside #mobile-toc-button { + display: none; +} + +@media screen and (max-width: 900px) { + #rightside #mobile-toc-button { + display: block; + } +} + +@media screen and (max-width: 900px) { + #rightside #hide-aside-btn { + display: none; + } +} + #sidebar #menu-mask { position: fixed; z-index: 102; @@ -3276,12 +3813,39 @@ ul { height: 100%; background: var(--sidebar-bg); transition: all 0.5s ease 0s; + padding-top: 30px; + z-index: 1001; } #sidebar #sidebar-menus.open { transform: translate3d(-100%, 0px, 0px); } +#sidebar #sidebar-menus .back-menu-list-groups { + padding: 0 16px; +} + +#sidebar #sidebar-menus .back-menu-list-groups .back-menu-list-title { + font-size: 12px; + color: var(--heo-secondtext); +} + +#sidebar #sidebar-menus .back-menu-list-groups .back-menu-list { + width: calc(100% + 16px); + justify-content: flex-start; + margin: 0 -8px; +} + +#sidebar #sidebar-menus .back-menu-list-groups .back-menu-list .back-menu-item { + background: var(--heo-card-bg); + border: var(--style-border-always); + border-radius: 8px; +} + +#sidebar #sidebar-menus .back-home-button { + display: none; +} + #sidebar #sidebar-menus > .author-avatar { padding: 1.3rem 1.5rem 0px; text-align: center; @@ -3315,7 +3879,7 @@ ul { } #sidebar #sidebar-menus .site-data .data-item .data-item-link .headline { - color: var(--font-color); + color: var(--heo-fontcolor); } #sidebar #sidebar-menus hr { @@ -3323,31 +3887,30 @@ ul { } #sidebar #sidebar-menus .menus_items { - padding: 0px 0.5rem 2rem; + padding: 0 16px; } #sidebar #sidebar-menus .menus_items .site-page { position: relative; display: block; - padding: 0.3rem 1.5rem; - color: var(--font-color); + padding: 0; + color: var(--heo-fontcolor); font-size: 1.15em; cursor: pointer; -} - -#sidebar #sidebar-menus .menus_items .site-page i:first-child { - width: 25%; - text-align: left; -} - -#sidebar #sidebar-menus .menus_items .site-page span { - width: 75%; + font-size: 14px; + font-weight: bold; } #sidebar #sidebar-menus .menus_items .site-page span:hover { color: rgb(48, 122, 246); } +#sidebar #sidebar-menus .menus_item > .site-page { + display: flex; + font-size: 12px; + color: var(--heo-secondtext); +} + #sidebar #sidebar-menus .menus_items .expand { position: absolute; top: 0.78em; @@ -3362,6 +3925,89 @@ ul { #sidebar #sidebar-menus .menus_items .menus_item_child { margin: 0px; list-style: none; + display: flex; + flex-direction: row; + flex-wrap: wrap; +} + +#sidebar #sidebar-menus .menus_item_child .site-page.child { + display: flex; + flex-direction: column; + align-items: center; + padding: 8px; + border-radius: 12px; + border: var(--style-border-always); + background: var(--heo-card-bg); +} + +#sidebar #sidebar-menus .menus_item_child li { + width: calc(50% - 8px); + margin: 4px; +} + +#sidebar #sidebar-menus .menus_item_child .site-page.child span { + line-height: 1; + margin-top: 8px; + font-size: 14px; +} + +#sidebar #sidebar-menus .card-tag-cloud { + padding: 0 16px; + display: flex; + flex-direction: row; + flex-wrap: wrap; + margin-bottom: 60px; +} + +#sidebar #sidebar-menus .card-tag-cloud a { + color: var(--heo-fontcolor) !important; + padding: 2px 8px 2px 12px; + margin: 4px; + border-radius: 8px; + border: var(--style-border-always); + background: var(--heo-card-bg); + font-size: 14px; +} + +#sidebar #sidebar-menus .card-tag-cloud a sup { + opacity: 0.6; + margin-left: 4px; +} + +#sidebar #sidebar-menus span.sidebar-menu-item-title { + font-size: 12px; + color: var(--heo-secondtext); + margin-left: 16px; +} + +#sidebar #sidebar-menus .sidebar-menu-item { + display: flex; + flex-direction: column; + padding: 0 16px; +} + +#sidebar #sidebar-menus .sidebar-menu-item a.menu-child { + width: 100%; + background: var(--heo-card-bg); + border-radius: 8px; + border: var(--style-border-always); + display: flex; + align-items: center; +} + +#sidebar #sidebar-menus .sidebar-menu-item a.menu-child i { + margin: 0 8px; +} + +#sidebar #sidebar-menus .webinfo { + padding: 0 16px; + display: flex; + white-space: nowrap; + flex-direction: column; +} + +#sidebar #sidebar-menus .webinfo .webinfo-item { + justify-content: space-between; } #vcomment, @@ -3456,6 +4102,9 @@ mjx-container[jax="CHTML"][display="true"] { padding-bottom: 0.3rem; } +.aplayer { +} + #article-container .aplayer { margin: 0px 0px 1rem; } @@ -3614,6 +4263,105 @@ mjx-container[jax="CHTML"][display="true"] { background: rgb(92, 184, 92); } +figure.gallery-group { + position: relative; + float: left; + overflow: hidden; + margin: 0.3rem 0.2rem; + width: calc(50% - 0.4rem); + height: 250px; + border-radius: 5px; + background: rgb(0, 0, 0); + transform: translate3d(0px, 0px, 0px); +} + +@media screen and (max-width: 600px) { + figure.gallery-group { + width: calc(100% - 0.4rem); + } +} + +figure.gallery-group:hover img { + opacity: 0.4; + transform: translate3d(0px, 0px, 0px); +} + +figure.gallery-group:hover .gallery-group-name::after { + transform: translate3d(0px, 0px, 0px); +} + +figure.gallery-group:hover p { + opacity: 1; + filter: none; + transform: translate3d(0px, 0px, 0px); +} + +figure.gallery-group img { + position: relative; + max-width: none; + width: calc(100% + 20px); + height: 250px; + backface-visibility: hidden; + opacity: 0.8; + transition: opacity 0.35s ease 0s, transform 0.35s ease 0s; + transform: translate3d(-10px, 0px, 0px); + object-fit: cover; + margin: 0px !important; +} + +figure.gallery-group figcaption { + position: absolute; + top: 0px; + left: 0px; + padding: 1.5rem; + width: 100%; + height: 100%; + color: rgb(255, 255, 255); + text-transform: uppercase; + backface-visibility: hidden; +} + +figure.gallery-group figcaption > a { + position: absolute; + inset: 0px; + z-index: 1000; + opacity: 0; +} + +figure.gallery-group p { + margin: 0px; + padding: 0.4rem 0px 0px; + letter-spacing: 1px; + font-size: 1.1em; + line-height: 1.5; + opacity: 0; + transition: opacity 0.35s ease 0s, transform 0.35s ease 0s; + transform: translate3d(100%, 0px, 0px); + -webkit-line-clamp: 4; +} + +figure.gallery-group .gallery-group-name { + position: relative; + margin: 0px; + padding: 0.4rem 0px; + font-weight: 700; + font-size: 1.65em; + line-height: 1.5; + -webkit-line-clamp: 2; +} + +figure.gallery-group .gallery-group-name::after { + position: absolute; + bottom: 0px; + left: 0px; + width: 100%; + height: 2px; + background: rgb(255, 255, 255); + content: ""; + transition: transform 0.35s ease 0s; + transform: translate3d(-100%, 0px, 0px); +} + .gallery-group-main { overflow: auto; padding: 0px 0px 0.8rem; @@ -3952,6 +4700,7 @@ blockquote.pullquote.right { .note table:last-child, .note ul:last-child { margin-bottom: 0px !important; + font-size: 14px !important; } .note:not(.no-icon) { @@ -3960,7 +4709,7 @@ blockquote.pullquote.right { .note:not(.no-icon)::before { position: absolute; - top: calc(50% - 0.8rem); + top: calc(50% - 15px); left: 0.7rem; font-size: larger; } @@ -4210,7 +4959,7 @@ blockquote.pullquote.right { } #article-container .tabs > .nav-tabs > .tab { - margin: 0px; + margin: 4px; padding: 0px; list-style: none; } @@ -4222,17 +4971,6 @@ blockquote.pullquote.right { } } -#article-container .tabs > .nav-tabs > .tab button { - display: block; - padding: 0.5rem 1rem; - width: 100%; - border-top: 2px solid var(--tab-border-color); - background: var(--tab-botton-bg); - color: var(--tab-botton-color); - line-height: 2; - transition: all 0.4s ease 0s; -} - #article-container .tabs > .nav-tabs > .tab button i { width: 1.5em; } @@ -4252,6 +4990,8 @@ blockquote.pullquote.right { position: relative; display: none; padding: 1.8rem 1.2rem; + background: var(--heo-background); + border: var(--style-border-always); } @media screen and (max-width: 768px) { @@ -4268,7 +5008,7 @@ blockquote.pullquote.right { #article-container .tabs .tab-to-top { position: relative; display: block; - margin: 0px 0px 0px auto; + margin: 16px 0px 0px auto; color: rgb(153, 169, 191); } @@ -4340,6 +5080,22 @@ blockquote.pullquote.right { content: ""; } +[data-theme="dark"] #article-container pre > code { + background: rgb(23, 23, 23); +} + +[data-theme="dark"] #article-container figure.highlight { + box-shadow: none; +} + +[data-theme="dark"] #article-container .note code { + background: rgba(27, 31, 35, 0.05); +} + +[data-theme="dark"] #article-container .aplayer { + filter: brightness(0.8); +} + [data-theme="dark"] #article-container kbd { border-color: rgb(105, 105, 105); background-color: rgb(82, 82, 82); @@ -4555,44 +5311,39 @@ blockquote.pullquote.right { height: 1.5rem; } -:root { - --heo-main: var(--heo-theme) !important; -} -:root { - --heo-main-op: var(--heo-theme-op) !important; -} +/* 全局 +---------------------------------------------------------------- */ -:root { - --heo-main-none: var(--heo-theme-none) !important; -} - -:root { - --heo-snackbar-time: 3000ms !important; -} +/* 深色模式图片 */ +/* [data-theme=dark] img{ + filter: brightness(.9); +} */ +/* 最小网页大小 */ #page { min-height: calc(100vh - 464px); } -::-webkit-scrollbar { +/* 滚动条 */ +*::-webkit-scrollbar { width: 6px; height: 6px; } -::-webkit-scrollbar-thumb { +*::-webkit-scrollbar-thumb { background: var(--heo-scrollbar); border-radius: 8px; cursor: pointer; } -::-webkit-scrollbar-thumb:hover { +*::-webkit-scrollbar-thumb:hover { background: var(--heo-main); opacity: 1; display: block !important; } -::-webkit-scrollbar-track { +*::-webkit-scrollbar-track { background-color: var(--heo-none); } @@ -4600,23 +5351,31 @@ html { overflow-y: overlay; } +/* 网页最大宽度 */ +.layout.hide-aside { + max-width: 1400px; +} + +/* 深色模式图片 */ [data-theme="dark"] img { filter: brightness(1); } +/* 导航栏中的样式 */ #nav { flex-wrap: nowrap; justify-content: space-between; } #nav .menus_items .menus_item .menus_item_child { - padding: 6px 4px 8px; + padding: 6px 4px 8px 4px; border-radius: 100px; background-color: var(--heo-card-bg); box-shadow: var(--heo-shadow-black); border: var(--style-border); - transition: all 0.3s ease 0s; + transition: 0.3s; backdrop-filter: blur(20px); + -webkit-backdrop-filter: blur(20px); top: 35px; } @@ -4630,10 +5389,6 @@ html { box-shadow: none; } -#sidebar #sidebar-menus .menus_items .menus_item_child { - margin-left: 1rem; -} - #sidebar #sidebar-menus .menus_items .site-page span:hover { color: var(--heo-fontcolor); } @@ -4644,6 +5399,7 @@ html { .fa, .fa-brands, +.fas, .fa-light, .fa-regular, .fa-solid, @@ -4658,17 +5414,33 @@ html { line-height: 1; } -#nav .menus_items .menus_item .menus_item_child::before { +#nav .menus_items .menus_item .menus_item_child:before { top: -10px; } +/* #menus > div.menus_items > div:nth-child(1) > ul{ + right: -200px!important; +} + +#menus > div.menus_items > div:nth-child(2) > ul{ + right: -250px!important; +} + +#menus > div.menus_items > div:nth-child(3) > ul{ + right: -140px!important; +} + +#menus > div.menus_items > div:nth-child(4) > ul{ + right: -200px!important; +} */ + #nav .menus_items .menus_item .menus_item_child li a:hover { - box-shadow: var(--heo-shadow-main); - margin: 0px auto; - padding: 0.3rem 0.7rem; background: var(--heo-main) !important; color: var(--heo-white) !important; + box-shadow: var(--heo-shadow-main); + margin: 0 auto; transform: scale(1) !important; + padding: 0.3rem 0.7rem; } #nav .menus_items .menus_item .menus_item_child li a i:not(.fa-brands) { @@ -4677,7 +5449,7 @@ html { } #nav .menus_items .menus_item { - padding: 0px 0.4rem; + padding: 0 0.4rem; display: flex; flex-direction: column; align-items: center; @@ -4688,9 +5460,10 @@ html { display: inline-flex; list-style: none; border-radius: 5px; - margin: 0px 4px; + margin: 0 4px; } +/* 导航栏按钮悬浮 */ #nav a { border-radius: 8px; color: var(--heo-white); @@ -4698,22 +5471,22 @@ html { .nav-fixed #nav a { color: var(--heo-fontcolor); - transition: all 0.3s ease 0s; + transition: 0.3s; } #assist-open a { - padding: 0px; + padding: 0; pointer-events: none; } #assist-open { - transition: all 0.3s ease 0s; + transition: 0.3s; border-radius: 40px; } #assist-open:hover { - background: var(--heo-white-op); color: var(--heo-white) !important; + background: var(--heo-white-op); } #page-header.nav-fixed #assist-open:hover { @@ -4730,9 +5503,10 @@ html { } .topbar-html { - background: rgb(174, 174, 174) !important; + background: #aeaeae !important; } +/* 无障碍 */ @media screen and (max-width: 768px) { #assist-open { display: none; @@ -4745,9 +5519,9 @@ html { } .topbar-html-content { + height: 160px !important; align-items: flex-end; padding-bottom: 12px; - height: 160px !important; } .topbar-html { @@ -4764,11 +5538,14 @@ html { border-radius: 12px !important; } + +/* 导航栏禁止隐藏 */ #page-header.nav-fixed #nav { - top: 0px; + top: 0; box-shadow: none; border-bottom: var(--style-border); backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); background: var(--heo-background); } @@ -4776,19 +5553,22 @@ html { padding: 0px; } +#page-header #nav { + box-shadow: none; + transition: 0s; + display: flex; + justify-content: center; + z-index: 1000 !important; +} + @media screen and (max-width: 768px) { #nav { padding: 0px; } -} -#page-header #nav { - box-shadow: none; - transition: all 0s ease 0s; - display: flex; - justify-content: center; - background: linear-gradient(to top, var(--heo-main-none) 0, var(--heo-main) 100%); - z-index: 1000 !important; + #page-header #nav { + background: linear-gradient(to top, var(--heo-main-none) 0%, var(--heo-main) 100%); + } } #page-header #nav #nav-group { @@ -4796,13 +5576,13 @@ html { width: 100%; display: flex; position: relative; - padding: 0px 1.5rem; + padding: 0 1.5rem; align-items: center; } #page-header #nav #nav-right { position: absolute; - right: 0px; + right: 0; z-index: 102; display: flex; flex-direction: row; @@ -4832,8 +5612,8 @@ html { cursor: pointer; } -#page-header #nav #nav-left .nav-button a, -#page-header #nav #nav-right .nav-button a { +#page-header #nav #nav-right .nav-button a, +#page-header #nav #nav-left .nav-button a { height: 35px; width: 35px; display: flex; @@ -4842,17 +5622,18 @@ html { border-radius: 40px; } -#page-header #nav #nav-left .nav-button a i, -#page-header #nav #nav-right .nav-button a i { +#page-header #nav #nav-right .nav-button a i, +#page-header #nav #nav-left .nav-button a i { line-height: 1; } -#page-header #nav #nav-left div, -#page-header #nav #nav-right div { +#page-header #nav #nav-right div, +#page-header #nav #nav-left div { margin-left: 0.5rem; - padding: 0px; + padding: 0; } + @media screen and (max-width: 768px) { #nav #menus { display: none !important; @@ -4870,7 +5651,7 @@ html { width: 100%; display: flex; position: relative; - padding: 0px 12px; + padding: 0 12px; } #page-header #nav #nav-right { @@ -4879,17 +5660,19 @@ html { } #nav.show { - top: 0px; - transition: all 0.2s ease 0s; + transform: translate3d(0px, 0px, 0px) !important; + top: 0; + transition: 0.2s; position: fixed; z-index: 91; - transform: translate3d(0px, 0px, 0px) !important; } + #page-header.not-top-img #nav { - transition: all 0.3s ease 0s; + transition: 0.3s; background: var(--heo-maskbgdeep); backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } @media screen and (max-width: 768px) { @@ -4911,21 +5694,22 @@ html { } #page-header.nav-fixed #nav #menus > div.menus_items { - transition: all 0.3s ease 0s; + transition: 0.3s; height: 40px; - margin: auto 0px; + margin: auto 0; } #page-header.not-top-img { - margin-bottom: 0px; + margin-bottom: 0rem; } #nav #toggle-menu { - padding: 0px 0.4rem; + padding: 0 0.4rem; } +/* 无顶图时导航栏间距 */ #page-header.no-top-img { - margin-bottom: 0px; + margin-bottom: 0rem; } .layout { @@ -4940,9 +5724,10 @@ html { } } +/* 导航栏logo */ #site-name .iconfont { font-size: 20px; - font-weight: 400; + font-weight: normal; line-height: 48px; } @@ -4954,13 +5739,16 @@ html { transform: scale(1.03); } +/* 返回顶部 */ + #nav-totop { position: relative; width: 35px; height: 35px; + transition: 0.3s; display: flex; border-radius: 40px; - transition: all 0.3s ease-in-out 0s; + transition: all 0.3s ease-in-out; align-items: center; } @@ -4969,7 +5757,7 @@ html { } #nav-totop .totopbtn { - padding-top: 0px; + padding-top: 0; } #nav-totop .totopbtn i { @@ -4982,7 +5770,7 @@ html { #nav-totop:hover .totopbtn i { opacity: 1; color: var(--heo-white); - transition: all 0.3s ease 0s; + transition: 0.3s; } #nav-totop #percent { @@ -4991,7 +5779,7 @@ html { display: flex; justify-content: center; align-items: center; - transition: all 0.3s ease 0s; + transition: 0.3s; white-space: nowrap; } @@ -5002,37 +5790,38 @@ html { display: flex; justify-content: center; align-items: center; - transition: all 0.3s ease 0s; + transition: 0.3s; white-space: nowrap; } #page-header:not(.nav-fixed) #percent { - transition: all 0.3s ease 0s; + transition: 0.3s; } #page-header:not(.nav-fixed) #nav-totop { - width: 0px; + width: 0; transform: scale(0); + transition: 0.3s; + margin-left: 0 !important; overflow: hidden; - transition: all 0.3s ease-in 0s; - margin-left: 0px !important; + transition: 0.3s ease-in; } #nav-totop:hover #percent { opacity: 0; - font-weight: 700; + font-weight: bold; } #page-header #nav #nav-right .nav-button a.totopbtn { width: 25px; height: 25px; border-radius: 40px; - background: var(--font-color); + background: var(--heo-fontcolor); color: var(--card-bg); position: absolute; top: 5px; right: 5px; - transition: all 0.3s ease 0s; + transition: 0.3s; } #page-header #nav #nav-right .nav-button.long a.totopbtn { @@ -5046,27 +5835,35 @@ html { #page-header #nav #nav-right .nav-button:not(.long):hover a.totopbtn { width: 35px; height: 35px; - top: 0px; - right: 0px; + top: 0; + right: 0; } +/* 导航栏图标 */ #nav #site-name i { font-size: 50px; line-height: 35px; - padding: 0px 12px; + padding: 0 12px; } .back-home-button { display: flex; width: 35px; height: 35px; + padding: 0 !important; align-items: center; justify-content: center; margin-right: 4px; - transition: all 0.3s ease 0s; + transition: 0.3s; + border-radius: 8px; color: var(--heo-white); border-radius: 40px; - padding: 0px !important; +} + +@media screen and (max-width: 768px) { + .back-home-button { + display: none; + } } .nav-fixed #nav .back-home-button { @@ -5082,50 +5879,51 @@ html { color: var(--heo-white) !important; } -.back-home-button .back-menu-list { +.back-menu-list-groups .back-menu-list { display: flex; - flex-flow: row wrap; + flex-direction: row; + flex-wrap: wrap; width: 340px; justify-content: space-between; } -.back-home-button .back-menu-list::before { +.back-menu-list-groups .back-menu-list::before { position: absolute; top: -15px; - left: 0px; + left: 0; width: 100%; height: 20px; - content: ""; + content: ''; } -.back-home-button .back-menu-list .back-menu-item { +.back-menu-list-groups .back-menu-list .back-menu-item { display: flex; align-items: center; margin: 4px 8px; - transition: all 0.3s ease 0s; - border-radius: 8px; padding: 4px 8px !important; + transition: 0.3s; + border-radius: 8px; } -.back-home-button .back-menu-list .back-menu-item:hover { +.back-menu-list-groups .back-menu-list .back-menu-item:hover { background: var(--heo-main) !important; transform: scale(1) !important; } -.back-home-button .back-menu-list .back-menu-item .back-menu-item-icon { +.back-menu-list-groups .back-menu-list .back-menu-item .back-menu-item-icon { width: 24px; height: 24px; border-radius: 8px; background: var(--heo-none); } -.back-home-button .back-menu-list .back-menu-item .back-menu-item-text { +.back-menu-list-groups .back-menu-list .back-menu-item .back-menu-item-text { font-size: var(--global-font-size); margin-left: 0.5rem; color: var(--heo-fontcolor); } -.back-home-button .back-menu-list .back-menu-item:hover .back-menu-item-text { +.back-menu-list-groups .back-menu-list .back-menu-item:hover .back-menu-item-text { color: var(--heo-white); } @@ -5145,7 +5943,7 @@ html { font-size: 12px; color: var(--heo-secondtext); box-shadow: var(--heo-shadow-border); - transition: all 0s ease 0s; + transition: 0s; opacity: 0; pointer-events: none; } @@ -5155,8 +5953,8 @@ html { } .back-home-button .back-menu-list-group .back-menu-list-title { - margin: 8px 0px 0px 16px; - transition: all 0.3s ease 0s; + margin: 8px 0 0 16px; + transition: 0.3s; } .back-home-button .back-menu-list-group:hover .back-menu-list-title { @@ -5166,7 +5964,7 @@ html { .back-home-button:hover .back-menu-list-groups { display: flex; opacity: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; top: 55px; pointer-events: auto; left: 1.5rem; @@ -5177,14 +5975,15 @@ html { } @media screen and (max-width: 768px) { + .back-home-button .back-menu-list-groups { - left: 0px; + left: 0; } .back-home-button:hover .back-menu-list-groups { padding-bottom: 8px; box-shadow: var(--heo-shadow-border); - left: 0px; + left: 0; } } @@ -5194,38 +5993,48 @@ html { display: flex; align-items: center; z-index: 102; - transition: all 0.3s ease 0s; + transition: 0.3s; } +/* 导航栏文字 */ @media screen and (min-width: 900px) { #nav #site-name { opacity: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; overflow: hidden; } #nav #site-name i { - transition: all 0.3s ease 0s; + transition: 0.3s; } #nav #site-name:hover i { opacity: 0; - transition: all 0.3s ease 0s; + transition: 0.3s; + } + + #nav #site-name span { + transition: 0.3s; + } + + #nav #site-name:hover span { + opacity: 0; + transition: 0.3s; } #page-header.nav-fixed #nav #site-name { opacity: 1; - transition: all 0.1s ease 0s; + transition: 0.1s; border-radius: 40px; } #page-header.nav-visible #nav #site-name { opacity: 1; - transition: all 0.1s ease 0s; + transition: 0.1s; } - #nav #site-name::after { - background: url(../images/home.webp) 50% 50% no-repeat; + #nav #site-name:after { + background: url(../images/home.webp) no-repeat 50% 50%; opacity: 0; position: absolute; display: flex; @@ -5233,7 +6042,8 @@ html { width: 74px; height: 58px; content: ""; - transition: all 0s ease-in 0s; + transition: 0s; + transition-timing-function: ease-in; transform: scale(0.4); } @@ -5245,7 +6055,7 @@ html { background: var(--heo-main); } - #nav #site-name:hover::after { + #nav #site-name:hover:after { opacity: 1; transform: translateY(0px) scale(0.3); transition-timing-function: ease-in; @@ -5257,53 +6067,54 @@ html { #nav #page-name-text { display: inline; - font-weight: 700; + font-weight: bold; padding: 4px 8px; opacity: 0; - transition: all 0.1s ease 0s; + transition: 0.1s; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; position: relative; text-align: center; cursor: pointer; - top: 0px; + top: 0; font-size: 0.9rem; animation-timing-function: ease-in; + -webkit-animation-timing-function: ease-in; } #nav #page-name-text:hover { + color: var(--heo-main) !important; background: var(--heo-none); box-shadow: none; - color: var(--heo-main) !important; } #page-header.nav-fixed #nav #page-name-text { display: inline; opacity: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; line-height: 1; } - #page-header.nav-fixed #nav #page-name-text:hover::after { + #page-header.nav-fixed #nav #page-name-text:hover:after { opacity: 1; line-height: 36px; } #page-header.nav-fixed #nav div.menus_items { - transition: all 0.15s ease 0s; + transition: 0.15s; position: relative; top: -60px; } #page-header.nav-fixed.nav-visible #nav #page-name-text { display: inline; - transition: all 0.15s ease 0s; + transition: 0.15s; } #page-header.nav-fixed.nav-visible #nav div.menus_items { opacity: 1; - transition: all 0.15s ease 0s; + transition: 0.15s; position: relative; top: 0px; } @@ -5320,6 +6131,7 @@ html { margin: auto; justify-content: center; animation-timing-function: ease-out; + -webkit-animation-timing-function: ease-out; } #page-header.nav-fixed #nav #menus { @@ -5332,14 +6144,14 @@ html { #page-header.nav-fixed #page-name { z-index: 101; - transition: all 0.3s ease 0s; + transition: 0.3s; top: 10px; } #page-header.nav-fixed.nav-visible #page-name { z-index: 100; top: 62px; - transition: all 0.3s ease 0s; + transition: 0.3s; } #page-name-mask { @@ -5347,7 +6159,7 @@ html { height: 100%; position: absolute; overflow: hidden; - left: 0px; + left: 0; } } @@ -5357,6 +6169,7 @@ html { } } +/* 导航栏音乐 */ @media screen and (max-width: 1300px) { #nav-music { display: none !important; @@ -5371,7 +6184,7 @@ html { bottom: 20px; left: 20px; cursor: pointer; - transition: all 0.3s ease 0s; + transition: 0.3s; transform-origin: left bottom; box-shadow: var(--heo-shadow-border); border-radius: 40px; @@ -5382,21 +6195,21 @@ html { } #nav-music.playing { - box-shadow: 0 0 12px -3px var(--heo-none); - animation: 5s linear 0s infinite normal none running playingShadow; + box-shadow: 0 0px 12px -3px var(--heo-none); + -webkit-animation: playingShadow 5s linear infinite; } @-webkit-keyframes playingShadow { 0% { - box-shadow: 0 0 12px -3px var(--heo-none); + box-shadow: 0 0px 12px -3px var(--heo-none); } 50% { - box-shadow: 0 0 12px 0 var(--heo-main); + box-shadow: 0 0px 12px 0px var(--heo-main); } 100% { - box-shadow: 0 0 12px -3px var(--heo-none); + box-shadow: 0 0px 12px -3px var(--heo-none); } } @@ -5405,51 +6218,53 @@ html { width: 25px; border-radius: 40px; z-index: 1; - transition: all 0.3s ease 0s; - transform: rotate(0deg) scale(1); + transition: 0.3s; + -webkit-transform: rotate(0deg) scale(1); border: var(--style-border-always); - animation: 24s linear 0s infinite normal none paused changeright; + -webkit-animation: changeright 24s linear infinite; + animation-play-state: paused; } #nav-music.playing .aplayer.aplayer-withlrc .aplayer-pic { - box-shadow: rgba(255, 255, 255, 0.65) 0px 0px 14px; - transform: rotate(0deg) scale(1.1); + box-shadow: 0 0 14px #ffffffa6; + -webkit-transform: rotate(0deg) scale(1.1); border-color: var(--heo-white); animation-play-state: running; } @-webkit-keyframes changeright { + 0% { - transform: rotate(0deg) scale(1.1); - box-shadow: rgba(255, 255, 255, 0) 0px 0px 2px; + -webkit-transform: rotate(0deg) scale(1.1); + box-shadow: 0 0 2px #ffffff00; } 25% { - transform: rotate(90deg) scale(1.1); - box-shadow: rgb(255, 255, 255) 0px 0px 14px; + -webkit-transform: rotate(90deg) scale(1.1); + box-shadow: 0 0 14px #ffffff; } 50% { - transform: rotate(180deg) scale(1.1); - box-shadow: rgba(255, 255, 255, 0) 0px 0px 2px; + -webkit-transform: rotate(180deg) scale(1.1); + box-shadow: 0 0 2px #ffffff00; } 75% { - transform: rotate(270deg) scale(1.1); - box-shadow: rgb(255, 255, 255) 0px 0px 14px; + -webkit-transform: rotate(270deg) scale(1.1); + box-shadow: 0 0 14px #ffffff; } 100% { - transform: rotate(360deg) scale(1.1); - box-shadow: rgba(255, 255, 255, 0) 0px 0px 2px; + -webkit-transform: rotate(360deg) scale(1.1); + box-shadow: 0 0 2px #ffffff00; } } #nav-music .aplayer.aplayer-withlrc .aplayer-info { height: 100%; - color: var(--font-color); + color: var(--heo-fontcolor); margin-left: 8px; - padding: 0px; + padding: 0; display: flex; align-items: center; } @@ -5464,17 +6279,18 @@ html { width: 100%; height: 100%; position: absolute; - top: 0px; - left: 0px; + top: 0; + left: 0; align-items: center; justify-content: center; display: flex; border-radius: 40px; opacity: 0; font-size: 12px; + transition: 0s; z-index: 2; pointer-events: none; - transition: all 0.3s ease 0s; + transition: 0.3s; } #nav-music:hover:not(.playing) #nav-music-hoverTips { @@ -5490,9 +6306,9 @@ html { border-radius: 60px; height: 41px; display: flex; - margin: 0px; + margin: 0; pointer-events: none; - transition: all 0.3s ease 0s; + transition: 0.3s; border: var(--style-border); box-shadow: none; } @@ -5501,6 +6317,7 @@ html { background: var(--heo-main-op-deep); border: var(--style-border-hover); backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } #nav-music .aplayer .aplayer-notice { @@ -5515,7 +6332,8 @@ html { position: relative; display: flex; align-items: center; - padding: 0px 12px 0px 8px; + padding: 0 8px; + padding-right: 12px; } #nav-music .aplayer .aplayer-pic .aplayer-play { @@ -5527,10 +6345,10 @@ html { } #nav-music .aplayer .aplayer-info .aplayer-music { - margin: 0px; + margin: 0; display: flex; align-items: center; - padding: 0px; + padding: 0; z-index: 1; } @@ -5558,25 +6376,25 @@ html { max-width: 120px; overflow: hidden; text-overflow: ellipsis; - transition: all 0.3s ease 0s; + transition: 0.3s; } #nav-music .aplayer .aplayer-info .aplayer-controller { position: absolute; width: 100%; height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; } #nav-music .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap { - margin: 0px; - padding: 0px; + margin: 0; + padding: 0; } #nav-music .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar { height: 100%; - background: 0px 0px; + background: none; } #nav-music .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-loaded { @@ -5586,11 +6404,12 @@ html { #nav-music .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-played { height: 100%; opacity: 0.1; - animation: 5s ease 0s infinite normal none running lightBar; background-color: var(--heo-white) !important; + -webkit-animation: lightBar 5s ease infinite; } @-webkit-keyframes lightBar { + 0% { opacity: 0.1; } @@ -5604,17 +6423,19 @@ html { } } + +/* 歌词 */ #nav-music .aplayer.aplayer-withlrc .aplayer-lrc { - width: 0px; + width: 0; opacity: 0; - transition: all 0.3s ease 0s; + transition: 0.3s; margin-left: 8px; margin-top: -2px; } #nav-music.playing .aplayer.aplayer-withlrc .aplayer-lrc { width: 200px; - margin-bottom: 0px; + margin-bottom: 0; opacity: 1; } @@ -5623,36 +6444,45 @@ html { border: none; } -#nav-music .aplayer .aplayer-lrc::after, -#nav-music .aplayer .aplayer-lrc::before { +#nav-music .aplayer .aplayer-lrc:after, +#nav-music .aplayer .aplayer-lrc:before { display: none; } #nav-music .aplayer .aplayer-lrc p { - color: rgba(255, 255, 255, 0.7); + color: #ffffffb3; } +/* 导航栏隐藏文字 */ +/* #menus > div.menus_items > div > a > span{ + display: none; +} */ + + +/* 品牌图标放大 */ i.fab { font-size: 20px; vertical-align: middle; margin-bottom: 4px; } -#body-wrap .full_page::before { +/* 去除header背景 */ +#body-wrap .full_page:before { background-color: var(--heo-none) !important; - transition: all 0s ease 0s !important; + transition: 0ms !important; } -.full_page #page-header::before { +.full_page #page-header:before { display: none !important; } +/* 消息弹窗 */ .snackbar-container { - display: flex; - justify-content: center; background: var(--heo-main) !important; color: var(--heo-white) !important; - border-radius: 0px !important; + border-radius: 0 !important; + display: flex; + justify-content: center !important; max-width: none !important; min-width: 100% !important; margin: 0px !important; @@ -5662,20 +6492,19 @@ i.fab { } .snackbar-container p { - font-weight: 700 !important; + font-weight: bold !important; text-align: center !important; font-size: 0.8rem !important; display: flex !important; justify-content: center !important; - margin: auto !important; } .snackbar-container .action { - font-weight: 700; - transition: all 0.3s ease 0s; color: var(--heo-white) !important; padding: 4px 6px !important; + font-weight: bold; border-radius: 8px !important; + transition: 0.3s; border: var(--style-border) !important; } @@ -5686,10 +6515,10 @@ i.fab { .snackbar-container::after { position: absolute; - width: 0px; + width: 0; height: 100%; - left: 0px; - top: 0px; + left: 0; + top: 0; background: var(--heo-white); opacity: 0.1; content: ""; @@ -5698,50 +6527,51 @@ i.fab { } @keyframes snackbar-progress { - 0% { - width: 0px; + from { + width: 0; } - 100% { + to { width: 100%; } } +/* 导航栏按钮 */ #nav a { - transition: all 0.3s ease 0s; + transition: 0.3s; } #nav a:hover { - background: var(--heo-white-op); - transition: all 0.3s ease 0s; color: var(--heo-white) !important; + background: var(--heo-white-op); + transition: 0.3s; } .page #nav a:hover { - background: var(--heo-main); - transition: all 0.3s ease 0s; - box-shadow: var(--heo-shadow-main); color: var(--heo-white) !important; + background: var(--heo-main); + transition: 0.3s; + box-shadow: var(--heo-shadow-main); } .nav-fixed #nav a:hover { background: var(--heo-main); - transition: all 0.3s ease 0s; + transition: 0.3s; } @media screen and (min-width: 768px) { .menus_item:hover > a.site-page { - background: var(--heo-white-op); - transition: all 0.3s ease 0s; - box-shadow: var(--heo-shadow-main); color: var(--heo-white) !important; + background: var(--heo-white-op); + transition: 0.3s; + box-shadow: var(--heo-shadow-main); } .page .menus_item:hover > a.site-page { - background: var(--heo-main); - transition: all 0.3s ease 0s; - box-shadow: var(--heo-shadow-main); color: var(--heo-white) !important; + background: var(--heo-main); + transition: 0.3s; + box-shadow: var(--heo-shadow-main); } .nav-fixed .menus_item:hover > a.site-page { @@ -5758,35 +6588,37 @@ i.fab { #sidebar #sidebar-menus .menus_items li .site-page span:hover { color: var(--heo-white); } - - #sidebar #sidebar-menus { - z-index: 1001; - } } + .nav-fixed #nav #site-name i { color: var(--heo-fontcolor); - transition: all 0.3s ease 0s; + transition: 0.3s; } #nav #site-name:hover i { color: var(--heo-white); } + +/* 搜索背景模糊 */ #search-mask { backdrop-filter: blur(12px); + -webkit-backdrop-filter: blur(12px); background: var(--heo-maskbg); } +/* 搜索输入框 */ #algolia-search .search-dialog .ais-search-box input { - border: var(--style-border); border-radius: 8px !important; + border: var(--style-border); } #algolia-search .search-dialog .ais-search-box input:focus { border: var(--style-border-hover); } + #algolia-search .search-dialog .ais-search-box input::placeholder { opacity: 0.6; } @@ -5795,12 +6627,13 @@ i.fab { margin-bottom: 8px; } +/* 搜索窗口 */ .search-dialog { + border-radius: 12px !important; box-shadow: var(--heo-shadow-lightblack); background: var(--heo-card-bg); border: var(--style-border); - transition: all 0.3s ease 0s; - border-radius: 12px !important; + transition: 0.3s; } .search-dialog:hover { @@ -5809,7 +6642,7 @@ i.fab { } .search-dialog__title { - font-weight: 700; + font-weight: bold; color: var(--heo-main); } @@ -5821,10 +6654,11 @@ i.fab { display: none; } +/* 搜索提示文字 */ #algolia-tips { padding-top: 12px; color: var(--heo-secondtext); - right: 0px; + right: 0; margin: auto; } @@ -5832,21 +6666,22 @@ i.fab { margin-left: 0.4rem; } +/* 搜索结果间距 */ #algolia-search-results { padding-top: 8px; } -#algolia-search .search-dialog .ais-hits--item.algolia-hit-item::before { +#algolia-search .search-dialog .ais-hits--item.algolia-hit-item:before { display: none; } #algolia-search .search-dialog .ais-hits--item.algolia-hit-item { - padding-left: 0px; - font-weight: 700; + padding-left: 0rem; + font-weight: bold; } #algolia-search .search-dialog .ais-pagination.pagination { - margin: 0.2rem 0px 0px; + margin: 0.2rem 0 0; } #algolia-search .search-dialog .ais-hits--item.algolia-hit-item em { @@ -5854,16 +6689,19 @@ i.fab { font-style: normal; } +/* 搜索框间距 */ #algolia-search .search-dialog .ais-search-box { padding-top: 8px; } +/* 搜索页码样式 */ #algolia-search .search-dialog .ais-pagination.pagination .ais-pagination--item.current a { border-radius: 4px; background: var(--heo-main); color: var(--heo-white); } +/* 全局超链接 */ a { color: var(--heo-fontcolor); } @@ -5872,10 +6710,12 @@ a:hover { color: var(--heo-hovertext); } +/* 分割线 */ hr { display: none; } +/* footer样式 */ #footer-wrap { color: var(--heo-fontcolor); } @@ -5898,11 +6738,12 @@ div#footer_deal { align-items: center; } +/* 古诗词卡片 */ #card-poem { display: flex; flex-direction: column; - min-height: 130px; padding: 0.5rem !important; + min-height: 130px; } div#poem_sentence { @@ -5944,7 +6785,8 @@ div#poem_dynasty { } div#footer_deal { - flex-flow: row wrap; + flex-wrap: wrap; + flex-direction: row; } } @@ -5955,10 +6797,10 @@ a.deal_link { border-radius: 3rem; width: 32px; height: 32px; - background: var(--font-color); + background: var(--heo-fontcolor); justify-content: center; align-items: center; - transition: all 0.3s ease 0s; + transition: 0.3s; } a.deal_link:hover { @@ -5969,14 +6811,14 @@ a.deal_link:hover { img.footer_mini_logo { width: 50px; height: 50px; - margin: 0px 1rem; + margin: 0 1rem; cursor: pointer; - transition: all 0.5s cubic-bezier(0, 0, 0, 1.29) 0s; + transition: cubic-bezier(0, 0, 0, 1.29) 0.5s; } img.footer_mini_logo:hover { - backface-visibility: hidden; - transform-style: preserve-3d; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; } @media screen and (min-width: 1300px) { @@ -5989,6 +6831,7 @@ img.footer_mini_logo:hover { } } +/* logo居中 */ #weblogo { align-self: center; } @@ -5998,21 +6841,22 @@ img.footer_mini_logo:hover { } .heoblog_footerlogo_img { - filter: drop-shadow(rgba(238, 125, 121, 0.21) 0px 12px 12px); + filter: drop-shadow(0 12px 12px #ee7d7936); } .heoblog_footerlogo_img:hover { transform: scale(1.03); } +/* 导航栏居中 */ #nav #menus { display: flex; justify-content: center; width: 100%; position: absolute; height: 60px; - left: 0px; - margin: 0px; + left: 0; + margin: 0; } #nav .menus_items { @@ -6030,22 +6874,22 @@ img.footer_mini_logo:hover { #menus > div.menus_items > div > a { letter-spacing: 0.3rem; padding-left: 0.7rem; - font-weight: 700; - padding-top: 0px; - padding-bottom: 0px; + font-weight: bold; + padding-top: 0; + padding-bottom: 0; height: 35px; line-height: 35px; border-radius: 40px; } #nav .menus_items .menus_item .menus_item_child li a { - letter-spacing: 0px; + letter-spacing: 0rem; display: flex; align-items: center; border-radius: 100px; padding: 0.3rem 1rem; width: 100%; - color: var(--font-color) !important; + color: var(--heo-fontcolor) !important; text-shadow: none !important; } @@ -6053,10 +6897,11 @@ img.footer_mini_logo:hover { transform: translateX(-150px); } +/* 传送门 */ #travellings_button { display: inline; - padding: 0px 0.4rem; - transition: all 0.3s ease 0s; + padding: 0 0.4rem; + transition: 0.3s; } @media screen and (max-width: 768px) { @@ -6065,15 +6910,17 @@ img.footer_mini_logo:hover { } } +/* rightMenu右键菜单 */ #rightMenu { display: none; position: fixed; - padding: 0px 0.25rem; + padding: 0 0.25rem; width: 9rem; height: fit-content; top: 10%; left: 10%; background-color: var(--heo-maskbgdeep); + -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); color: var(--heo-fontcolor); border-radius: 12px; @@ -6090,7 +6937,7 @@ img.footer_mini_logo:hover { #rightMenu .rightMenu-group { padding: 0.35rem 0.3rem; - transition: all 0.3s ease 0s; + transition: 0.3s; } #rightMenu .rightMenu-line { @@ -6104,13 +6951,13 @@ img.footer_mini_logo:hover { #rightMenu .rightMenu-group .rightMenu-item { border-radius: 8px; - transition: all 0.3s ease 0s; + transition: 0.3s; cursor: pointer; } #rightMenu .rightMenu-line .rightMenu-item { - margin: 0.25rem 0px; - padding: 0.25rem 0px; + margin: 0.25rem 0; + padding: 0.25rem 0; } #rightMenu .rightMenu-group.rightMenu-line .rightMenu-item { @@ -6132,11 +6979,11 @@ img.footer_mini_logo:hover { text-align: center; line-height: 1.5rem; width: 1.5rem; - padding: 0px 0.25rem; + padding: 0 0.25rem; } #rightMenu .rightMenu-line .rightMenu-item i { - margin: 0px 0.25rem; + margin: 0 0.25rem; } #rightMenu .rightMenu-group .rightMenu-item span { @@ -6153,14 +7000,16 @@ img.footer_mini_logo:hover { position: fixed; width: 100vw; height: 100vh; - background: 0px 0px; - top: 0px; - left: 0px; + background: none; + top: 0; + left: 0; display: none; + z-index: 101; + margin: 0 !important; z-index: 99993; - margin: 0px !important; } +/* 深色模式切换 */ #darkmode_navswitch { display: inline; position: relative; @@ -6170,30 +7019,37 @@ img.footer_mini_logo:hover { font-size: 0.9rem; } -[data-theme="dark"] #page-header.not-top-img #nav .darkmode_switchbutton { +[data-theme=dark] #page-header.not-top-img #nav .darkmode_switchbutton { color: var(--heo-yellow); } a.darkmode_switchbutton { + padding: 4px 8px !important; cursor: pointer; + margin: 0 !important; font-size: 0.9rem; color: var(--heo-fontcolor); - padding: 4px 8px !important; - margin: 0px !important; } -[data-theme="dark"] a.darkmode_switchbutton { +[data-theme=dark] a.darkmode_switchbutton { background: var(--heo-orange) !important; color: var(--heo-white) !important; } a.console_switchbutton { - cursor: pointer; padding: 4px 8px !important; + cursor: pointer; } +@media screen and (max-width: 768px) { + #nav-console { + display: none; + } +} + +/* 导航栏图标阴影 */ #nav .site-page { - text-shadow: transparent 0.05rem 0.05rem 0.1rem; + text-shadow: 0.05rem 0.05rem 0.1rem rgba(0, 0, 0, 0); border-radius: 8px; } @@ -6207,13 +7063,13 @@ a.console_switchbutton { .post-bg #nav #site-name { color: var(--heo-white); - transition: all 0s ease 0s; + transition: 0s; } #nav #site-name { color: var(--heo-fontcolor); - padding: 0px; - transition: all 0.3s ease 0s; + padding: 0; + transition: 0.3s; display: flex; height: 35px; /*width: 75px;*/ @@ -6223,16 +7079,46 @@ a.console_switchbutton { border-radius: 40px; } +/* 搜索 */ #search-button > a > span { display: none; } +/* 下拉图标 */ #nav .menus_items .menus_item i.expand { display: none; } +/* 右下角设置按钮间距 */ +#rightside { + display: none; + padding-right: 8px; + position: fixed; + right: -38px; + bottom: 40px; + z-index: 100; + opacity: 0; + transition: all 0.5s ease 0s; +} + +#rightside > div > button, +#rightside > div > a { + margin-bottom: 8px; + transition: 0.3s; +} + +#rightside > div > button, +#rightside > div > a:hover { + transition: 0.3s; +} + +#rightside #rightside-config-hide { + transform: translate(42px, 0); +} + +/* footer背景色 */ #footer { - background: linear-gradient(180deg, var(--heo-card-bg-none) 0, var(--heo-card-bg) 25%); + background: linear-gradient(180deg, var(--heo-card-bg-none) 0%, var(--heo-card-bg) 25%); margin-top: 1rem; display: flex; flex-direction: column; @@ -6241,21 +7127,24 @@ a.console_switchbutton { @media screen and (max-width: 768px) { #footer { - background: linear-gradient(180deg, var(--heo-background) 0, var(--heo-card-bg) 25%); - margin-top: 0px; + background: linear-gradient(180deg, var(--heo-background) 0%, var(--heo-card-bg) 25%); + margin-top: 0; z-index: 999; } } +/* 搜索 */ #algolia-search .ais-hits--item.algolia-hit-item a { color: var(--heo-fontcolor); } +/* aplayer */ .aplayer .aplayer-list ol { backdrop-filter: blur(1px); + -webkit-backdrop-filter: blur(1px); } -.aplayer .aplayer-lrc::after { +.aplayer .aplayer-lrc:after { display: none !important; } @@ -6277,7 +7166,7 @@ a.console_switchbutton { #article-container.flink h2 { margin-top: 0.5rem; - margin-bottom: 0px; + margin-bottom: 0; } #algolia-hits .tag-list { @@ -6285,7 +7174,7 @@ a.console_switchbutton { border-radius: 8px; margin-right: 0.5rem; margin-top: 0.5rem; - border: var(--style-border); + border: var(--style-border-always); cursor: pointer; } @@ -6294,16 +7183,18 @@ a.console_switchbutton { color: var(--heo-white); } +/* 手机端菜单背景 */ #mobile-sidebar #mobile-sidebar-menus.open { background: var(--heo-maskbg); } #aside-content .card-info .card-info-data > .card-info-data-item { - transition: all 0.3s ease 0s; + transition: .3s; } +/* 手机端导航 */ #sidebar #sidebar-menus .site-data { - margin: 1rem 0px; + margin: 1rem 0; padding: 0.6rem 0.5rem; } @@ -6311,15 +7202,17 @@ a.console_switchbutton { display: none; } +/* 胶囊形状GitHub按钮 */ #card-info-btn { border-radius: 25px; overflow: hidden; } -#card-info-btn::before { +#card-info-btn:before { border-radius: 25px; } +/* 搜索结果文字 */ #algolia-search .search-dialog .ais-hits--item.algolia-hit-item a { color: var(--heo-fontcolor); width: auto; @@ -6329,12 +7222,14 @@ a.console_switchbutton { overflow: hidden; } +/* 其他页面封面移除 */ .not-index-bg { height: 2rem !important; background-image: none !important; background-color: var(--heo-none) !important; } + .not-index-bg img { display: none; } @@ -6343,49 +7238,82 @@ a.console_switchbutton { display: none; } +/* 进度条 */ .pace { + -webkit-pointer-events: none; pointer-events: none; + + -webkit-user-select: none; + -moz-user-select: none; user-select: none; + z-index: 2000; position: fixed; margin: auto; top: 4px; - left: 0px; - right: 0px; + left: 0; + right: 0; height: 8px; border-radius: 8px; width: 4rem; background: var(--heo-secondbg); border: var(--style-border); + overflow: hidden; } .pace-inactive .pace-progress { + /* display: none; */ + /* animation: 1s hidetip; */ opacity: 0; - transition: all 0.3s ease-in 0s; + transition: 0.3s ease-in; } .pace .pace-progress { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + -ms-box-sizing: border-box; + -o-box-sizing: border-box; box-sizing: border-box; - transform: translate3d(0px, 0px, 0px); + + -webkit-transform: translate3d(0, 0, 0); + -moz-transform: translate3d(0, 0, 0); + -ms-transform: translate3d(0, 0, 0); + -o-transform: translate3d(0, 0, 0); + transform: translate3d(0, 0, 0); + max-width: 200px; + position: fixed; z-index: 2000; display: block; position: absolute; - top: 0px; + top: 0; right: 100%; height: 100%; width: 100%; - animation: 2s ease 0s infinite normal none running gradient; + background: var(--heo-logo-color); + animation: gradient 2s ease infinite; background-size: 200%; } .pace.pace-inactive { + /* display: none; */ opacity: 0; - transition: all 0.3s ease 0s; + transition: 0.3s; top: -8px; } +/* 进度条缓慢消失 */ +/* @keyframes hidetip { + from { + opcity: 1; + } + to { + opacity: 0; + } +} */ + +/* 文章页侧边栏固定位置 */ @media screen and (max-width: 1300px) { #aside-content .sticky_layout { top: 60px; @@ -6406,11 +7334,11 @@ a.console_switchbutton { #aside-content .sticky_layout { top: 80px; - transition: top 0s ease 0s; + transition: top 0s; } #aside-content .sticky_layout .card-widget:first-child { - margin-top: 0px; + margin-top: 0; } #aside-content .card-widget:hover { @@ -6442,29 +7370,32 @@ a.console_switchbutton { } } +/* 最新文章侧边栏 */ .card-widget.card-recent-post { padding: 0.4rem 0.6rem !important; } +/* 最新文章侧边栏时间显示 */ #aside-content .aside-list > .aside-list-item .content > time { display: none; } +/* 最新文章侧边栏标题 */ #aside-content .aside-list > .aside-list-item .content > .title { -webkit-line-clamp: 3; - font-weight: 700; - padding: 2px 0px; + font-weight: bold; + padding: 2px 0; } +/* 最新文章侧边栏悬浮 */ #aside-content .aside-list > .aside-list-item { - padding-right: 8px; - padding-left: 8px; - border-radius: 12px; - transition: all 0.3s ease 0s; - margin: 4px 0px; - cursor: pointer; + padding: 8px; padding-top: 6px !important; padding-bottom: 6px !important; + border-radius: 12px; + transition: 0.3s; + margin: 4px 0; + cursor: pointer; } @media screen and (min-width: 1300px) { @@ -6482,11 +7413,11 @@ a.console_switchbutton { } #aside-content .aside-list > .aside-list-item:not(:last-child) { - border-bottom: 0 dashed var(--heo-background) !important; + border-bottom: 0px dashed var(--heo-background) !important; } #aside-content .aside-list > .aside-list-item .thumbnail { - -webkit-mask-image: -webkit-radial-gradient(center center, rgb(255, 255, 255), rgb(0, 0, 0)); + -webkit-mask-image: -webkit-radial-gradient(center, rgb(255, 255, 255), rgb(0, 0, 0)); border-radius: 8px; border: var(--style-border); } @@ -6494,7 +7425,7 @@ a.console_switchbutton { #aside-content .aside-list > .aside-list-item:hover { background: var(--heo-main); color: var(--heo-white); - transition: all 0.3s ease 0s; + transition: 0.3s; box-shadow: var(--heo-shadow-main); } @@ -6502,16 +7433,17 @@ a.console_switchbutton { color: var(--heo-white) !important; } +/* 侧边栏按钮文字 */ a.card-archive-list-link-more { + color: var(--heo-white) !important; background: var(--heo-card-btn-bg); margin-top: 8px; - color: var(--heo-white) !important; } #aside-content .card-archives ul.card-archive-list > .card-archive-list-item a, #aside-content .card-categories ul.card-category-list > .card-category-list-item a { border-radius: 8px; - margin: 4px 0px; + margin: 4px 0; display: flex; flex-direction: column; align-content: space-between; @@ -6526,14 +7458,15 @@ a.card-archive-list-link-more { #aside-content .card-archives ul.card-archive-list, #aside-content .card-categories ul.card-category-list { display: flex; - flex-flow: row wrap; + flex-direction: row; justify-content: space-between; + flex-wrap: wrap; } .card-allinfo hr { display: flex; position: relative; - margin: 1rem 0px; + margin: 1rem 0; border: 1px dashed var(--heo-theme-op); } @@ -6546,7 +7479,7 @@ span.card-archive-list-count { text-align: left; font-size: 1.1rem; line-height: 0.9; - font-weight: 700; + font-weight: bold; } .card-archive-list-count-group { @@ -6565,7 +7498,7 @@ span.card-archive-list-count { width: auto; text-align: left; font-size: 14px; - font-weight: 700; + font-weight: bold; } .card-archive-list-date { @@ -6580,7 +7513,8 @@ li.card-archive-list-item { .card-category-list { display: flex; - flex-flow: row wrap; + flex-direction: row; + flex-wrap: wrap; justify-content: space-between; } @@ -6593,10 +7527,11 @@ li.card-archive-list-item { } .card-category-list-name { - text-align: center; width: 100% !important; + text-align: center; } +/* 侧边栏统计 */ .webinfo-item { display: flex; white-space: nowrap; @@ -6613,6 +7548,7 @@ li.card-archive-list-item { text-align: center; } +/* 侧边栏配置 */ @media screen and (min-width: 1300px) { #aside-content { padding-left: 1rem; @@ -6626,45 +7562,52 @@ li.card-archive-list-item { top: calc(60px + 0.5rem); } - [data-theme="dark"] #aside-content > .card-widget.card-info { + [data-theme=dark] #aside-content > .card-widget.card-info { border: var(--style-border); } .coverdiv { height: 130%; } + } + +/* madium-zoom */ .medium-zoom-overlay { - backdrop-filter: saturate(180%) blur(20px); background: var(--heo-maskbg) !important; z-index: 99998 !important; + backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } .medium-zoom-image--opened { border-radius: 2px; } +/* 通用 */ #toggle-sidebar { bottom: 80px; } +/* 按钮样式 */ .button--animated { - transition: all 0.3s ease 0s; border-radius: 8px !important; + transition: 0.3s; } #error-wrap .error-content .error-info a:hover { background-color: var(--heo-blue); - transition: all 0.3s ease 0s; + transition: 0.3s; transform: scale(1.03); box-shadow: var(--heo-shadow-blue); } -.button--animated::before { +.button--animated:before { display: none; } +/* hexo-widget-tree 侧边文章导航 */ a.tree-list-post-link { font-size: 0.8rem; line-height: 1.2 !important; @@ -6672,9 +7615,10 @@ a.tree-list-post-link { li.tree-list-item { line-height: 1.9; - margin: 0.3rem 0px; + margin: 0.3rem 0; } +/* 通用标题 */ .title-h2-a { display: flex; align-items: center; @@ -6685,7 +7629,7 @@ li.tree-list-item { .title-h2-a a { margin-left: 0.5rem; color: var(--heo-secondtext); - font-weight: 700; + font-weight: bold; } .title-h2-a a:hover { @@ -6698,10 +7642,12 @@ li.tree-list-item { } .title-h2-a-left h2 { - margin-top: 0px !important; - margin-bottom: 0px !important; + margin-top: 0 !important; + margin-bottom: 0 !important; } +/* 基金 */ + #card-funds .funds-list::-webkit-scrollbar { display: none !important; } @@ -6711,14 +7657,14 @@ li.tree-list-item { width: 100%; text-align: center; color: var(--heo-secondtext); - margin: 0.5rem 0px 0px; + margin: 0.5rem 0 0 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; position: absolute; bottom: 0.5rem; left: 0px; - padding: 0px 1rem; + padding: 0 1rem; } .funds-list { @@ -6739,8 +7685,9 @@ span.fund_name { .funds-list-item .content { display: flex; - flex-flow: row nowrap; + flex-direction: row; justify-content: space-between; + flex-wrap: nowrap; } .fund_dayGrowth { @@ -6756,11 +7703,13 @@ span.fund_name { color: var(--heo-green); } +/* 音乐宣传 */ #aside-content .card-widget#card-music { background: var(--heo-pink); display: flex; - place-content: center; - padding: 0px; + justify-content: center; + align-content: center; + padding: 0; cursor: pointer; border: none; } @@ -6772,21 +7721,24 @@ span.fund_name { #aside-content .card-widget#card-music:hover img { transform: scale(1.03); - transition: all 0.5s ease 0s; - backface-visibility: hidden; - transform-style: preserve-3d; + transition: 0.5s; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; } .music-link { display: flex; - place-content: center; + justify-content: center; + align-content: center; } +/* 友情链接 */ #aside-content .card-widget#card-friendlinks { background: var(--heo-main); display: flex; - place-content: center; - padding: 0px; + justify-content: center; + align-content: center; + padding: 0; cursor: pointer; border: none; } @@ -6798,21 +7750,24 @@ span.fund_name { #aside-content .card-widget#card-friendlinks:hover img { transform: scale(1.03); - transition: all 0.5s ease 0s; - backface-visibility: hidden; - transform-style: preserve-3d; + transition: 0.5s; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; } .friend-link { display: flex; - place-content: center; + justify-content: center; + align-content: center; } +/* 微信公众号 */ #aside-content .card-widget#card-wechat { - background: rgb(7, 193, 96); + background: #07C160; display: flex; - place-content: center; - padding: 0px; + justify-content: center; + align-content: center; + padding: 0; cursor: pointer; border: none; height: 110px; @@ -6825,9 +7780,12 @@ span.fund_name { .friend-link { display: flex; - place-content: center; + justify-content: center; + align-content: center; } +/* 微信公众号翻转 */ + #flip-wrapper { position: relative; width: 235px; @@ -6835,39 +7793,51 @@ span.fund_name { z-index: 1; } +/* this need to be here - i dont know why?*/ #flip-wrapper { - perspective: 1000px; + -webkit-perspective: 1000; + perspective: 1000; } #flip-content { width: 100%; height: 100%; + -webkit-transform-style: preserve-3d; transform-style: preserve-3d; - transition: all 0.3s cubic-bezier(0, 0, 0, 1.29) 0s; + transition: cubic-bezier(0, 0, 0, 1.29) 0.3s; } #flip-wrapper:hover #flip-content { + -webkit-transform: rotateY(180deg); transform: rotateY(180deg); } -/* 公众号推广部分 */ .face { position: absolute; width: 100%; height: 100%; + -webkit-backface-visibility: hidden; backface-visibility: hidden; + /* background-color: #e71840; */ + /*background: url(../images/wechat/wechat1.png) center center no-repeat;*/ + background-size: 100%; } .back.face { display: block; + -webkit-transform: rotateY(180deg); transform: rotateY(180deg); box-sizing: border-box; + /* background-color: #212121; */ + /*background: url(../images/wechat/wechat2.png) center center no-repeat;*/ + background-size: 100%; } +/* 商务广告-设计周刊 */ #card-vip-designweekly.card-widget { - padding: 0px; - cursor: pointer; display: flex !important; + padding: 0; + cursor: pointer; } #card-vip-designweekly.card-widget .card-vip-designweekly-img { @@ -6887,13 +7857,15 @@ span.fund_name { color: var(--heo-white); } +/* 开关 */ #widget-tree-button { - color: var(--heo-fontcolor); background-color: var(--heo-secondbg) !important; box-shadow: var(--heo-shadow-light2black) !important; + color: var(--heo-fontcolor); } #widget-tree:hover #widget-tree-button { + /* display: none!important; */ opacity: 0; left: -1.5rem; } @@ -6903,8 +7875,9 @@ span.fund_name { } #widget-tree:hover { + left: 0 !important; backdrop-filter: blur(20px); - left: 0px !important; + -webkit-backdrop-filter: blur(20px); } #widget-tree a { @@ -6927,12 +7900,15 @@ span.fund_name { } } + +/* guli置顶 */ + .guli_top { position: fixed; z-index: 99; right: 30px; display: flex; - transition: all 0.3s ease 0s; + transition: 0.3s; opacity: 0; bottom: -25px; width: 88px; @@ -6978,6 +7954,7 @@ span.fund_name { } } +/* cookies */ #cookies-window { min-width: 300px; background: var(--heo-maskbgdeep); @@ -6989,17 +7966,18 @@ span.fund_name { right: 20px; position: fixed; border-radius: 12px; - transition: all 0.3s ease 0s; + transition: 0.3s; z-index: 1002; user-select: none; backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: saturate(180%) blur(20px); border: var(--style-border); - animation: 0.6s cubic-bezier(0.42, 0, 0.3, 1.11) 0s 1 normal none running barrageIn; + animation: barrageIn 0.6s cubic-bezier(0.42, 0, 0.3, 1.11); } #cookies-window.cw-hide { opacity: 0; - animation: 0.6s cubic-bezier(0.42, 0, 0.3, 1.11) 0s 1 normal none running barrageOut; + animation: barrageOut 0.6s cubic-bezier(0.42, 0, 0.3, 1.11); z-index: -1; } @@ -7007,7 +7985,7 @@ span.fund_name { padding-bottom: 4px; border-bottom: var(--style-border); font-size: 12px; - font-weight: 700; + font-weight: bold; } #cookies-window .cookies-window-content { @@ -7019,7 +7997,7 @@ span.fund_name { .cookie-to { margin-right: 4px; - font-weight: 700; + font-weight: bold; } .cookies-link { @@ -7035,7 +8013,7 @@ span.fund_name { .heo-tag { padding: 1px 6px; - border-radius: 6px 6px 6px 0px; + border-radius: 6px 6px 6px 0; margin-left: 4px; height: 20px; line-height: 19px; @@ -7051,42 +8029,74 @@ span.fund_name { background: var(--heo-red); } +/* 加载页 +---------------------------------------------------------------- */ + +/* 已经写在loading.pug中了 */ + +/* #loading-box .loading-bg{ + display: flex; + width: 100%; + height: 100%; + position: fixed; + background: var(--heo-card-bg); + z-index: 99999; + opacity: 1; + transition: 0.3s; + pointer-events: all; +} + +#loading-box.loaded .loading-bg{ + opacity: 0; + pointer-events: none; +} + +#loading-box .loading-img{ + width: 100px; + margin: auto; + animation-duration: 0.3s; + animation-name: loadingAction; + animation-iteration-count: infinite; + animation-direction: alternate; +} + +@keyframes loadingAction { + from { + opacity: 1; + } + + to { + opacity: 0.4; + } +} */ + +/* 主页 +---------------------------------------------------------------- */ + +/* 主页顶部封面 */ #page-header.full_page { height: 2rem; - background-color: var(--heo-none); background-image: none !important; + background-color: var(--heo-none); } #page-header.full_page #site-info { display: none; } +/* 主页导航栏让位偏移 */ +/* .layout_page .recent-posts{ + margin-top: 2em; +} +.layout_page .aside_content{ + margin-top: 2em; +} */ + .layout > div:first-child { width: calc(100% - 300px); } -/* 当隐藏边栏时,显示 100% */ -.layout.hide-aside > div:first-child { - width: 100% !important; -} - -/* 侧边栏在左侧时,显示 100% */ -.layout.left-aside > div:first-child { - -webkit-box-ordinal-group: 2; - -moz-box-ordinal-group: 2; - -o-box-ordinal-group: 2; - -ms-flex-order: 2; - -webkit-order: 2; - order: 2; -} - -/* 侧栏在左侧时,关闭左边距,打开右边距 */ -.layout.left-aside .aside-content { - padding-right: 15px; - padding-left: 0px !important; -} - - +/* 主页分类 */ div#categoryList { display: flex; width: 100%; @@ -7096,7 +8106,7 @@ div#categoryList { .categoryItem { overflow: hidden; transform: scale(1); - transition: all 0.8s cubic-bezier(0.65, 0.15, 0.37, 1.19) 0s; + transition: all 0.8s cubic-bezier(0.65, 0.15, 0.37, 1.19); height: 48%; border-radius: 12px; } @@ -7109,17 +8119,17 @@ a.categoryButton { display: inline-block; text-align: left; line-height: 4em; - font-weight: 700; + font-weight: bold; font-size: 0.9rem; color: var(--heo-white); - transition: all 0.8s cubic-bezier(0.39, 0.575, 0.565, 1) 0s; + transition: all 0.8s cubic-bezier(0.39, 0.575, 0.565, 1); transform: scale(1); overflow: hidden; - font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei"; + font-family: PingFang SC, Hiragino Sans GB, Microsoft YaHei; } a.categoryButton i { - transform: scale(1) rotate(15deg); + transform: scale(1.0) rotate(15deg); } @media screen and (min-width: 1300px) { @@ -7140,7 +8150,7 @@ a.categoryButton i { } } -a.categoryButton::after { +a.categoryButton:after { top: 50px; width: 1rem; left: 21px; @@ -7159,9 +8169,9 @@ a.categoryButton i { font-size: 5rem; opacity: 0.2; position: absolute; - right: 0px; + right: 0%; top: 20%; - transition: all 0.3s ease 0s; + transition: 0.3s; width: 100px; text-align: center; filter: blur(2px); @@ -7173,12 +8183,12 @@ a.categoryButton i { } .recent-post-top .categoryGroup { + min-width: 130px !important; margin-bottom: 0.5rem; margin-left: 1rem; max-height: 164px; overflow: hidden; position: relative; - min-width: 130px !important; } } @@ -7201,15 +8211,17 @@ div#banners { @media screen and (min-width: 1300px) { .topGroup { display: flex; - flex-flow: row wrap; - place-content: space-between flex-end; + flex-direction: row; + flex-wrap: wrap; + justify-content: flex-end; height: calc(328px + 0.5rem); + align-content: space-between; width: calc(600px + 1.5rem); position: relative; } div#bannerGroup { - width: calc((100% - 600px) - 2rem); + width: calc(100% - 600px - 2rem); margin-right: 0.5rem; height: calc(328px + 0.5rem); display: flex; @@ -7225,12 +8237,13 @@ div#banners { margin-bottom: 0.5rem; border: var(--style-border); border-radius: 12px; + overflow: hidden; position: relative; box-shadow: var(--heo-shadow-border); flex-direction: column; overflow: hidden; - transition: all 0.3s ease 0s; - clip-path: inset(0px round 12px); + transition: 0.3s; + clip-path: inset(0 0 0 0 round 12px); } div#banners:hover { @@ -7250,13 +8263,13 @@ div#banners { #banners .banner-button { padding: 8px 12px; - background: var(--font-color); + background: var(--heo-fontcolor); border-radius: 12px; color: var(--heo-card-bg); display: flex; align-items: center; z-index: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; cursor: pointer; box-shadow: var(--heo-shadow-black); } @@ -7291,10 +8304,11 @@ div#banners { top: 1.5rem; } + .banners-title-big { font-size: 36px; line-height: 1; - font-weight: 700; + font-weight: bold; margin-bottom: 8px; } @@ -7310,8 +8324,8 @@ div#banners { position: absolute; width: 100%; height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; background: var(--heo-theme); color: var(--heo-white); padding-left: 0.5rem; @@ -7319,13 +8333,13 @@ div#banners { flex-direction: column; justify-content: center; opacity: 0; - transition: all 0.6s cubic-bezier(0.71, 0.15, 0.16, 1.15) 0s; + transition: cubic-bezier(0.71, 0.15, 0.16, 1.15) 0.6s; } .bannerText { font-size: 4rem; line-height: 4rem; - font-weight: 700; + font-weight: bold; } .banner-righticon { @@ -7336,11 +8350,13 @@ div#banners { #banners:hover #banner-hover { opacity: 1; padding-left: 2rem; - background: 0% 0% / 200% rgba(66, 89, 239, 0.79); + background: #4259efc9; backdrop-filter: blur(15px); - backface-visibility: hidden; - transform-style: preserve-3d; - transition: all 0.3s ease 0s; + -webkit-backdrop-filter: blur(15px); + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; + transition: 0.3s; + background-size: 200%; cursor: pointer; } @@ -7349,13 +8365,13 @@ div#banners { width: calc(600px + 1rem); height: 100%; z-index: 1; - top: 0px; - left: 0px; + top: 0; + left: 0; background: var(--card-bg); border-radius: 12px; margin-left: 0.5rem; overflow: hidden; - transition: all 0.3s ease 0s; + transition: 0.3s; display: flex; cursor: pointer; pointer-events: all; @@ -7363,11 +8379,11 @@ div#banners { .topGroup .todayCard::after { position: absolute; - content: ""; + content: ''; width: 100%; height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; } .topGroup .todayCard.hide { @@ -7382,7 +8398,7 @@ div#banners { z-index: 2; color: var(--heo-white); max-width: 60%; - transition: all 0.3s ease 0s; + transition: 0.3s; } .topGroup .todayCard.hide .todayCard-info { @@ -7397,7 +8413,7 @@ div#banners { .topGroup .todayCard .todayCard-info .todayCard-title { font-size: 28px; - font-weight: 700; + font-weight: bold; line-height: 36px; } @@ -7406,7 +8422,7 @@ div#banners { right: 2rem; bottom: 2rem; display: flex; - transition: all 0.3s ease 0s; + transition: 0.3s; } .topGroup .todayCard.hide .banner-button-group { @@ -7420,9 +8436,10 @@ div#banners { display: flex; align-items: center; z-index: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; cursor: pointer; backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); height: 40px; width: 124px; justify-content: center; @@ -7442,11 +8459,11 @@ div#banners { position: absolute; min-width: 100%; min-height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; background-size: cover; z-index: -1; - transition: all 0.3s ease 0s; + transition: 0.3s; } .topGroup .todayCard.hide .todayCard-cover { @@ -7455,11 +8472,11 @@ div#banners { } @keyframes rowup { - 0% { - transform: translateX(0px); + from { + transform: translateX(0%); } - 100% { + to { transform: translateX(-50%); } } @@ -7476,7 +8493,7 @@ div#banners { } .tags-group-all.nowrapMove { - transform: rotate(0deg); + transform: rotate(0); padding-bottom: 2rem; } @@ -7484,15 +8501,15 @@ div#banners { margin-top: 5rem; display: flex; flex-wrap: nowrap; - animation: 60s linear 0s infinite normal none running rowup; + animation: rowup 60s linear infinite; } .nowrapMove .tags-group-wrapper { margin-top: 7rem; - animation: 120s linear 0s infinite normal none running rowup; + animation: rowup 120s linear infinite; } -.tags-group-icon-pair .tags-group-icon:nth-child(2n) { +.tags-group-icon-pair .tags-group-icon:nth-child(even) { margin-top: 1rem; transform: translate(-60px); } @@ -7505,9 +8522,9 @@ div#banners { display: flex; align-items: center; justify-content: center; - color: rgb(255, 255, 255); + color: white; font-size: 66px; - font-weight: 700; + font-weight: bold; box-shadow: var(--heo-shadow-blackdeep); } @@ -7526,19 +8543,22 @@ div#banners { object-fit: cover; } + #categoryList > div:nth-child(1) > a::before { height: 24px; width: 44px; content: ""; - background: url(../images/top.png) 0% 0% / 38px 24px no-repeat; + background: url(../images/top.png) no-repeat; + background-size: 38px 24px; position: absolute; top: 0px; - left: 0px; + left: 0; } .categoryItem:hover i { opacity: 0.8; - transition: all 0.8s ease 0.15s; + transition: 0.8s; + transition-delay: 0.15s; transform: scale(1.03) rotate(0deg); font-size: 2.5rem; filter: blur(0px); @@ -7550,6 +8570,10 @@ div#banners { } } +#categoryList > a:nth-child() > i { + padding-right: 8px; +} + .cate-button-text { box-shadow: var(--heo-shadow-black); } @@ -7560,6 +8584,7 @@ div#banners { } } +/* 新主页分类 */ .recent-post-top .categoryGroup { display: flex; flex-direction: column; @@ -7578,13 +8603,13 @@ div#banners { } .categoryItem { - width: calc(33.3333% - 0.33rem); + width: calc(100% / 3 - 0.33rem); height: 100%; margin-right: 0.5rem; } .categoryItem:last-child { - margin-right: 0px; + margin-right: 0; } .categoryItem:hover { @@ -7597,33 +8622,41 @@ div#banners { } a.categoryButton.bikan { - background: linear-gradient(to right, rgb(53, 139, 255), rgb(21, 198, 255)) 0% 0% / 200%; + background: linear-gradient(to right, #358bff, #15c6ff); + background-size: 200%; } a.categoryButton.remen { - background: linear-gradient(to right, rgb(255, 102, 85), rgb(255, 191, 55)) 0% 0% / 200%; + background: linear-gradient(to right, #ff6655, #ffbf37); + background-size: 200%; } a.categoryButton.shiyong { - background: linear-gradient(to right, rgb(24, 231, 174), rgb(30, 235, 235)) 0% 0% / 200%; + background: linear-gradient(to right, #18e7ae, #1eebeb); + background-size: 200%; } -[data-theme="dark"] a.categoryButton.bikan { - background: linear-gradient(to right, rgb(6, 83, 184), rgb(47, 203, 255)) 0% 0% / 200%; +[data-theme=dark] a.categoryButton.bikan { + background: linear-gradient(to right, #0653b8, #2fcbff); + background-size: 200%; } -[data-theme="dark"] a.categoryButton.remen { - background: linear-gradient(to right, rgb(226, 42, 22), rgb(218, 152, 12)) 0% 0% / 200%; +[data-theme=dark] a.categoryButton.remen { + background: linear-gradient(to right, #e22a16, #da980c); + background-size: 200%; } -[data-theme="dark"] a.categoryButton.shiyong { - background: linear-gradient(to right, rgb(9, 158, 116), rgb(14, 164, 164)) 0% 0% / 200%; +[data-theme=dark] a.categoryButton.shiyong { + background: linear-gradient(to right, #099e74, #0ea4a4); + background-size: 200%; } + a.categoryButton:hover { - background-position: 100% 0px; + background-position: 100% 0; } +/* 首页分类条展示 */ #category-bar { padding: 0.4rem 1rem 0.4rem 0.5rem; background: var(--heo-card-bg); @@ -7633,7 +8666,7 @@ a.categoryButton:hover { overflow: hidden; margin-bottom: 1rem; border: var(--style-border); - transition: all 0.3s ease 0s; + transition: 0.3s; width: 100%; justify-content: space-between; } @@ -7645,27 +8678,28 @@ a.categoryButton:hover { } .category-in-bar-tips { - margin-bottom: 0.25rem; + margin-bottom: .25rem; } } @media screen and (max-width: 768px) { #category-bar { - border-radius: 0px; + border-radius: 0; background: var(--heo-background); - margin-bottom: 0px; + margin-bottom: 0rem; + position: -webkit-sticky; position: sticky; top: 60px; z-index: 1; - padding: 0px 1rem 0px 16px; + padding: 0rem 1rem 0rem 16px; height: 50px; - margin-top: 0px; + margin-top: 0; align-items: center; } } #category #category-bar { - padding: 0px; + padding: 0; border: none; box-shadow: none; } @@ -7691,21 +8725,22 @@ a.categoryButton:hover { } .category-in-bar .category-in-bar-tips { - margin-bottom: 0px; + margin-bottom: 0; } .category-in-bar #category-bar { - margin-bottom: 0px; + margin-bottom: 0; } + .category-bar-items::-webkit-scrollbar { display: none; } .category-bar-item a { padding: 0.1rem 0.5rem; - margin: 0px 4px; - font-weight: 700; + margin: 0 4px; + font-weight: bold; border-radius: 8px; } @@ -7730,6 +8765,7 @@ a.categoryButton:hover { } .category-in-bar { + position: -webkit-sticky; position: sticky; top: 60px; background: var(--heo-background); @@ -7739,36 +8775,126 @@ a.categoryButton:hover { .category-bar-more { margin-left: 1rem; - font-weight: 700; + font-weight: bold; } -li, -ul { +/* 主页瞬间 */ +#comment-list { + width: 100%; + height: 25px; + line-height: 25px; + display: flex; + flex-direction: column; +} + +#moment { + overflow: hidden; + width: 100%; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +#comment-list .li-style { + width: auto; + max-width: 100%; + height: 25px; + text-align: center; + overflow: hidden; + text-overflow: ellipsis; + transition: 0.3s; + font-weight: bold; + margin: auto; + cursor: pointer; + white-space: nowrap; +} + +#commentList .li-style:hover { + color: var(--heo-theme); + transition: 0.3s; +} + +ul, +li { list-style: none; display: block; - margin: 0px; - padding: 0px; + margin: 0; + padding: 0; } +#commentList { + background: var(--heo-none); + color: var(--heo-fontcolor); + padding: 0.5rem 1rem; + border-radius: 12px; + box-shadow: var(--heo-shadow-lightblack); + display: flex; + transition: 0.3s; + margin-bottom: 1rem; + border: var(--style-border); + align-items: center; + height: 50px; +} + +#commentList:hover { + border: var(--style-border-hover); + box-shadow: var(--heo-shadow-main); +} + +@media screen and (min-width: 1300px) { + #commentList { + margin-bottom: 1rem; + } +} + +/* 哔哔前往 */ +.comment-goto { + line-height: 25px; + margin-left: 1rem; + transition: 0.3s; + cursor: pointer; +} + +.comment-goto:hover { + opacity: 0.8; + color: var(--heo-theme); +} + +/* 哔哔标志 */ +.icon-logo-moment { + font-size: 2rem; + font-size: 2rem; + line-height: 22px; + margin-right: 1rem; + transition: 0.3s; + cursor: pointer; +} + +.icon-logo-moment:hover { + opacity: 0.8; + color: var(--heo-theme); +} + +/* 文章卡片相关 */ #recent-posts > .recent-post-item > .recent-post-info { - padding: 0px; + padding: 0; } .recent-post-item .recent-post-info .recent-post-info-top { position: relative; - transition: all 0.3s ease 0s; + transition: 0.3s; padding: 32px; width: 100%; } .recent-post-item .recent-post-info .recent-post-info-top .article-title { line-height: 30px; - margin-top: 0px; - font-weight: 700; + margin-top: 0; + font-weight: bold; color: var(--heo-fontcolor); - margin-bottom: 0px; + margin-bottom: 0; width: 100%; - transition: all 0.3s ease 0s; + transition: .3s; font-size: 1rem; -webkit-line-clamp: 2; display: -webkit-box; @@ -7802,9 +8928,9 @@ ul { } #recent-posts > .recent-post-item .post_cover { + transition: 1s !important; height: 225px; width: 100%; - transition: all 1s ease 0s !important; } .recent-post-item.post-card-large .recent-post-info .recent-post-info-top .content { @@ -7819,7 +8945,7 @@ ul { .recent-post-item .recent-post-info .recent-post-info-top .content { opacity: 0; - transition: all 0.3s ease 0s; + transition: 0.3s; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; @@ -7854,7 +8980,7 @@ ul { @media screen and (max-width: 768px) { .recent-post-item .recent-post-info .recent-post-info-top { - padding: 0px 20px; + padding: 0 20px; top: 20px; } @@ -7869,22 +8995,28 @@ ul { } } +/* 文章卡片文字信息 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap a { color: var(--heo-fontcolor); } +/* 文章封面 */ + #recent-post-top .recent-post-item .post_cover { width: 100%; } +/* 文章卡片图标与文字间隙 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap i { - margin: 0px 0.4rem 0px 0px; + margin: 0 0.4rem 0 0; } +/* 文章卡片置顶标签 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap .sticky { color: var(--heo-fontcolor); } +/* 文章卡片高度 */ #recent-posts .recent-post-item { height: fit-content; background: var(--heo-card-bg); @@ -7899,12 +9031,18 @@ ul { } #recent-posts > .recent-post-item .right_radius { - border-radius: 12px 0px 0px 12px; + border-top-left-radius: 12px; + border-top-right-radius: 0px; + border-bottom-right-radius: 0px; + border-bottom-left-radius: 12px; } @media screen and (min-width: 1300px) { #recent-posts > .recent-post-item .right_radius { - border-radius: 12px 12px 0px 0px; + border-top-left-radius: 12px; + border-top-right-radius: 12px; + border-bottom-right-radius: 0px; + border-bottom-left-radius: 0px; } } @@ -7915,11 +9053,15 @@ ul { } } +/* 文章卡片偏移样式 */ @media screen and (max-width: 1300px) { - #recent-posts > .recent-post-item .cover_radius, - #recent-posts > .recent-post-item .right_radius { - border-radius: 12px 0px 0px 12px; + #recent-posts > .recent-post-item .right_radius, + #recent-posts > .recent-post-item .left_radius { + border-top-left-radius: 12px; + border-top-right-radius: 0px; + border-bottom-right-radius: 0px; + border-bottom-left-radius: 12px; width: 75%; display: flex; height: 200px; @@ -7927,9 +9069,9 @@ ul { #recent-posts > .recent-post-item:hover .post_cover img.post_bg { transform: scale(1.03); - transition: all 0.3s ease-in-out 0s; + transition: 0.3s ease-in-out; filter: brightness(0.85); - border-radius: 12px 0px 0px 12px; + border-radius: 12px 0 0 12px; } #recent-posts > .recent-post-item.post-card-large:hover .post_cover img.post_bg { @@ -7938,41 +9080,44 @@ ul { #recent-posts > .recent-post-item .post_cover img.post_bg { min-width: 100%; - backface-visibility: hidden; - transform-style: preserve-3d; - transition: all 0.3s ease-in-out 0s; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; + transition: 0.3s ease-in-out; min-height: 100%; } #recent-posts > .recent-post-item:hover > .recent-post-info { - transition: all 0.3s ease 0s; + transition: all 0.3s; position: relative; } #recent-posts > .recent-post-item > .recent-post-info { - transition: all 0.3s ease 0s; + transition: all 0.3s; } } #recent-posts > .recent-post-item:hover .post_cover img.post_bg { transform: scale(1.03); - transition: all 0.3s ease-in-out 0s; + transition: 0.3s ease-in-out; filter: brightness(0.85); - border-radius: 12px 0px 0px 12px; + border-radius: 12px 0 0 12px; } @media screen and (min-width: 1300px) { - #recent-posts > .recent-post-item .cover_radius, - #recent-posts > .recent-post-item .right_radius { - border-radius: 12px 12px 0px 0px; + #recent-posts > .recent-post-item .right_radius, + #recent-posts > .recent-post-item .left_radius { + border-top-left-radius: 12px; + border-top-right-radius: 12px; + border-bottom-right-radius: 0px; + border-bottom-left-radius: 0px; width: 100%; display: flex; } } -#recent-posts > .recent-post-item .cover_radius a, -#recent-posts > .recent-post-item .right_radius a { +#recent-posts > .recent-post-item .right_radius a, +#recent-posts > .recent-post-item .left_radius a { min-height: 100%; min-width: 100%; } @@ -7982,22 +9127,26 @@ ul { overflow: hidden; } +/* 文章置顶卡片样式 */ .recent-top-post-group { border-radius: 12px; - overflow: auto hidden; + overflow: hidden; + overflow-x: auto; width: 100%; - margin-bottom: 0px; + margin-bottom: 0rem; } .recent-post-top { display: flex; - flex-flow: row nowrap; + flex-direction: row; + flex-wrap: nowrap; width: 100%; overflow-x: scroll; } .recent-post-top::-webkit-scrollbar { display: none; + /* Chrome Safari */ } .recent-post-top .recent-post-item { @@ -8013,7 +9162,7 @@ ul { height: 164px; max-height: 164px; border: var(--style-border-always); - transition: all 0.3s ease 0s; + transition: 0.3s; position: relative; box-shadow: var(--heo-shadow-border); } @@ -8022,7 +9171,7 @@ ul { .recent-post-top .recent-post-item { border-radius: 8px; box-shadow: none; - clip-path: inset(0px round 8px); + clip-path: inset(0 0 0 0 round 8px); } .recent-post-top .recent-post-item:last-child { @@ -8046,12 +9195,13 @@ ul { .recent-top-post-group { overflow: visible; + overflow-x: visible; } } span.recent-post-top-text { position: absolute; - top: 0px; + top: 0; left: -40px; display: flex; z-index: 1; @@ -8059,13 +9209,13 @@ span.recent-post-top-text { color: var(--heo-white); padding: 2px 8px; font-size: 0.6rem; - border-radius: 12px 0px; - transition: all 0.3s ease 0s; + border-radius: 12px 0 12px 0; + transition: 0.3s; cursor: pointer; } .recent-post-item:hover .recent-post-top-text { - left: 0px; + left: 0; } @media screen and (min-width: 1300px) { @@ -8082,7 +9232,7 @@ span.recent-post-top-text { @media screen and (max-width: 768px) { .recent-top-post-group { - border-radius: 0px; + border-radius: 0; background: var(--heo-background); } @@ -8091,10 +9241,11 @@ span.recent-post-top-text { } .recent-post-top .recent-post-item .post_cover img { - border-radius: 8px 8px 0px 0px !important; + border-radius: 8px 8px 0 0 !important; } } +/* 封面 */ .recent-post-top .recent-post-item .post_cover a { height: 100px; overflow: hidden; @@ -8105,7 +9256,7 @@ span.recent-post-top-text { object-fit: cover; width: 100%; background: var(--heo-secondbg); - border-radius: 12px 12px 0px 0px; + border-radius: 12px 12px 0 0; } .recent-post-top .recent-post-item:hover .post_cover img { @@ -8113,12 +9264,13 @@ span.recent-post-top-text { } .recent-post-item .post_cover { - -webkit-mask-image: -webkit-radial-gradient(center center, rgb(255, 255, 255), rgb(0, 0, 0)); + -webkit-mask-image: -webkit-radial-gradient(center, rgb(255, 255, 255), rgb(0, 0, 0)); } +/* 标题 */ .recent-post-top .recent-post-item .recent-post-info { - transition: all 0.3s ease 0s; - padding: 0.3rem 0.5rem !important; + padding: 0.3rem 0.5rem 0.3rem 0.5rem !important; + transition: 0.3s; } .recent-post-top .recent-post-item:hover .recent-post-info a { @@ -8128,7 +9280,7 @@ span.recent-post-top-text { @media screen and (max-width: 1300px) { .recent-post-top .recent-post-item:hover .recent-post-info a { color: var(--heo-theme); - transition: all 0.3s ease 0s; + transition: 0.3s; } } @@ -8138,11 +9290,13 @@ span.recent-post-top-text { display: -webkit-box; -webkit-box-orient: vertical; line-height: 1.5; - place-content: center; + justify-content: center; align-items: flex-end; - font-weight: 700; + align-content: center; + padding-top: .5rem; + font-weight: bold; font-size: 0.8rem !important; - padding: 0px !important; + padding: 0 !important; } .title-and-tips { @@ -8153,7 +9307,7 @@ span.recent-post-top-text { .title-and-tips .page-title { line-height: 1; - margin: 0px; + margin: 0; } .title-and-tips .page-tips { @@ -8166,12 +9320,15 @@ span.recent-post-top-text { margin-left: 8px; } + +/* 主页卡片阴影 */ #aside-content .card-widget { box-shadow: var(--heo-shadow-border); background: var(--heo-card-bg); border: var(--style-border); + transition: 0.3s; border-radius: 12px; - transition: all 0.3s ease 0s; + transition: 0.3s; position: relative; overflow: hidden; margin-top: 1rem; @@ -8208,12 +9365,13 @@ span.recent-post-top-text { flex-direction: row-reverse !important; } -#recent-posts > .recent-post-item.right .cover_radius, .recent-post-item.alternate.even .cover_radius{ +#recent-posts > .recent-post-item.right .cover_radius, .recent-post-item.alternate.even .cover_radius { border-radius: 0px 12px 12px 0px !important; } @media screen and (min-width: 1300px) { + #recent-posts > .recent-post-item { flex-direction: column; } @@ -8223,7 +9381,7 @@ span.recent-post-top-text { margin-top: 0.25rem; margin-bottom: 0.75rem; box-shadow: var(--heo-shadow-border); - clip-path: inset(0px round 12px); + clip-path: inset(0 0 0 0 round 12px); } #recent-posts > .recent-post-item:not(:first-child):active { @@ -8257,62 +9415,97 @@ span.recent-post-top-text { box-shadow: var(--heo-shadow-border); } + /* 首页文章第一个 */ #recent-posts { display: flex; flex-wrap: wrap; - place-content: flex-start space-between; + justify-content: space-between; align-items: flex-start; + align-content: flex-start; } } + +/* 主页卡片手机端美化 */ @media screen and (max-width: 768px) { #recent-posts > .recent-post-item { - border-radius: 0px; + border-radius: 0; } #recent-posts > .recent-post-item:not(:first-child) { - margin: 0.5rem 1rem 1.5rem; + margin: 1.5rem 1rem; border-radius: 12px; + margin-top: 0.5rem; border: var(--style-border-always); box-shadow: var(--heo-shadow-border); display: block; position: relative; - clip-path: inset(0px round 12px); + clip-path: inset(0 0 0 0 round 12px); } #recent-posts .recent-post-item .post_cover { + border-radius: 0 !important; width: 100%; - border-radius: 0px !important; } + #commentList { + margin-top: 0; + border-radius: 0; + background: var(--heo-background); + padding: 0.5rem 20px; + } + + a.article-meta__categories { + left: 12px !important; + top: 12px !important; + border-radius: 4px !important; + padding: 2px 9px !important; + font-size: 12px; + } + + #commentList { + margin-bottom: 0rem; + } } +/* 置顶卡片数量优化 */ @media screen and (min-width: 1300px) { .topGroup .recent-post-item:nth-child(7) { display: none; } } + +/* 手机端精简优化 */ @media screen and (max-width: 768px) { + + /* 边栏头像 */ #sidebar-menus > div.author-avatar { display: none; } + /* 文章标签 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap { bottom: 0.5rem !important; } #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap time { - right: 0px; + display: absolute; + right: 0; } + /* 右下角设置按钮 */ + #rightside { + display: none; + } + /* 背景 */ #web_bg { - background: 0px 0px !important; + background: none !important; } #recent-posts > .recent-post-item .post_cover img.post_bg { - border-radius: 12px 12px 0px 0px !important; + border-radius: 12px 12px 0 0 !important; } #recent-posts > .recent-post-item .post_cover img.post_bg:hover { @@ -8327,46 +9520,84 @@ span.recent-post-top-text { transform: scale(1); } - #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap, #recent-posts > .recent-post-item > .recent-post-info > .article-title, - #recent-posts > .recent-post-item > .recent-post-info > .content { - padding: 0px 20px !important; + #recent-posts > .recent-post-item > .recent-post-info > .content, + #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap { + padding: 0 20px !important; } + } -a.article-meta__categories { +/* 主页文章封面左侧显示 */ +/* #recent-posts>.recent-post-item .right_radius{ + order: 0; + border-radius: 8px 0 0 8px; +} */ + +/* 主页文章卡片尺寸变化 */ +/* #recent-posts > div:nth-child(1){ + height: 22em; +} +#recent-posts > div:nth-child(1) > div.recent-post-info > div.content{ + height: 120px; + margin-top: 20px!important; +} +#recent-posts > div:nth-child(4){ + height: 22em; +} +#recent-posts > div:nth-child(4) > div.recent-post-info > div.content{ + height: 120px; + margin-top: 20px!important; +} +#recent-posts > div:nth-child(8){ + height: 22em; +} +#recent-posts > div:nth-child(8) > div.recent-post-info > div.content{ + height: 120px; + margin-top: 20px!important; +} */ + +.article-meta__categories { position: absolute; - padding: 1px 6px; - background: var(--heo-black-op); - border-radius: 8px; - margin-left: 0px; - font-size: 12px; - font-weight: 700; - color: var(--heo-white); top: 8px; left: 8px; - backdrop-filter: saturate(180%) blur(20px); } -a.article-meta__categories:hover { - box-shadow: var(--heo-shadow-theme); + +/* 自定义的文章分类 */ +a.article-meta__category { + padding: 2px 6px; + background: var(--heo-black-op); + border-radius: 6px; + margin: 0 5px 0 0; + font-size: 14px; + font-weight: bold; + color: var(--heo-white); + backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); +} + +a.article-meta__category:hover { background: var(--heo-theme) !important; color: var(--heo-white) !important; + box-shadow: var(--heo-shadow-theme); } +/* 文章卡片标题 */ #recent-posts > .recent-post-item > .recent-post-info > .article-title { line-height: 1.4; margin-top: 0px; - font-weight: 700; + font-weight: bold; color: var(--heo-fontcolor); margin-bottom: 0px; position: absolute; width: 100%; - left: 0px; - padding: 0px 40px; - transition: all 0.3s ease 0s; + left: 0; + padding: 0 40px; + transition: 0.3s; } + #recent-posts > .recent-post-item > .recent-post-info > .article-title:hover { color: var(--heo-fontcolor); } @@ -8389,11 +9620,14 @@ a.article-meta__categories:hover { } } +/* 文章卡片标签边距 */ .article-meta-wrap { color: var(--heo-secondtext) !important; } +/* 日期右侧显示 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap > .post-meta-date { + /* display: none; */ right: 0px; text-align: right; } @@ -8414,17 +9648,18 @@ a.article-meta__categories:hover { margin-right: 0.8rem; } +/* 文章目录 */ #aside-content #card-toc .toc-content .toc-link.active { line-height: 1.2; border-radius: 12px; border-left-color: var(--heo-hovertext); background-color: var(--heo-card-bg); color: var(--heo-lighttext); - font-weight: 700; + font-weight: bold; font-size: 20px; } -[data-theme="dark"].toc .toc-item.active .toc-link .toc-text { +[data-theme=dark].toc .toc-item.active .toc-link .toc-text { color: var(--heo-white); } @@ -8446,7 +9681,7 @@ a.article-meta__categories:hover { opacity: 0.6; cursor: pointer; filter: blur(1px); - transition: all 0.3s ease 0s; + transition: 0.3s; } #aside-content #card-toc:hover .toc-content .toc-link:not(.active) span { @@ -8458,35 +9693,41 @@ a.article-meta__categories:hover { color: var(--heo-lighttext); } +/* 目录卡片边距 */ #card-toc { - padding: 0.5rem !important; + padding: 0.5rem 0.5rem !important; } +/* 不显示分割线 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap .article-meta__separator { display: none; } .article-meta { - margin: 0px 8px 0px 0px; + margin: 0 8px 0 0; white-space: nowrap; overflow: hidden; display: inline-block; text-overflow: ellipsis; } +/* 不显示标签分割点 */ .article-meta__link { display: none; } .article-meta__tags { margin-right: 4px; - padding: 0px 0.2rem 0px 0px; + padding: 0 0.2rem 0 0; } +/* 多分类兼容性调整 */ #recent-posts > div > i .post_cover { display: none; } +/* 文章标签置底 */ + #recent-posts > .recent-post-item > .recent-post-info { height: 174px; width: 100%; @@ -8503,13 +9744,14 @@ a.article-meta__categories:hover { #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap { position: absolute; bottom: 16px; - transition: all 0.3s ease 0s; + transition: 0.3s; display: flex; - flex-flow: row nowrap; + flex-direction: row; + flex-wrap: nowrap; justify-content: space-between; width: 100%; - left: 0px; - padding: 0px 32px; + left: 0; + padding: 0 32px; white-space: nowrap; } @@ -8527,42 +9769,53 @@ a.article-meta__categories:hover { } } +/* 首页文章标签样式 */ #recent-posts > .recent-post-item > .recent-post-info > .article-meta-wrap a:hover { background-color: var(--heo-post-blockquote-bg); color: var(--heo-hovertext); } +/* 首页顶部banner区域 */ #home_top { max-width: 1400px; - margin: 0.5rem auto auto; - padding: 0px 1.5rem; + margin: auto; + margin-top: 0.5rem; + padding: 0 1.5rem; } @media screen and (max-width: 768px) { #home_top { - padding: 0px; - margin-top: 0px; + padding: 0; + margin-top: 0; } + + } +/* 热门标签提醒 */ + +/* sketch */ #aside-content .card-tag-cloud a[href*="/tags/Sketch/"] { - font-weight: 500; color: var(--heo-lighttext) !important; + font-weight: 500; } +/* 设计 */ #aside-content .card-tag-cloud a[href*="/tags/%E8%AE%BE%E8%AE%A1/"] { - font-weight: 500; color: var(--heo-lighttext) !important; + font-weight: 500; } +/* 干货 */ #aside-content .card-tag-cloud a[href*="/tags/%E5%B9%B2%E8%B4%A7/"] { - font-weight: 500; color: var(--heo-lighttext) !important; + font-weight: 500; } +/* 教程 */ #aside-content .card-tag-cloud a[href*="/tags/%E6%95%99%E7%A8%8B/"] { - font-weight: 500; color: var(--heo-lighttext) !important; + font-weight: 500; } #aside-content .card-tag-cloud a sup { @@ -8570,17 +9823,18 @@ a.article-meta__categories:hover { margin-left: 2px; } +/* 描述 */ #recent-posts > .recent-post-item > .recent-post-info > .content { line-height: 1.4; color: var(--heo-secondtext); margin-top: 0px; cursor: pointer; - transition: all 0.3s ease 0s; + transition: 0.3s; opacity: 1; position: absolute; width: 100%; - left: 0px; - padding: 0px 40px; + left: 0; + padding: 0 40px; } @media screen and (min-width: 768px) { @@ -8611,6 +9865,7 @@ a.article-meta__categories:hover { -webkit-line-clamp: 5 !important; } + /* 大文章高度 */ #recent-posts > .post-card-large { height: 20em !important; } @@ -8623,10 +9878,18 @@ a.article-meta__categories:hover { } } +/* +#recent-posts > .recent-post-item >.recent-post-info > .content:hover{ + opacity: 0.8; + transition: 0.3s; +} */ + +/* 描述行数限制 */ #recent-posts > .recent-post-item > .recent-post-info > .content { -webkit-line-clamp: 2; } +/* 作者打招呼 */ div#author-info__sayhi { text-align: left; color: var(--heo-white); @@ -8640,7 +9903,7 @@ div#author-info__sayhi { #aside-content .card-info .author-info__name { text-align: left; - font-weight: 700; + font-weight: bold; color: var(--heo-white); font-size: 28px; line-height: 1.1; @@ -8648,24 +9911,37 @@ div#author-info__sayhi { margin-bottom: 1rem; } +/* 作者卡片背景 */ #aside-content > .card-widget:first-child { - transition: all 0.3s ease 0s; + transition: 0.3s; border: none; box-shadow: none; background: var(--heo-main); margin-top: 0px; } + #aside-content > .card-widget.card-info { - background-size: 400%; + background: var(--heo-card-bg); box-shadow: var(--heo-shadow-black); - animation: 15s ease 0s infinite normal none running gradient; position: relative; } +#aside-content > .card-widget.card-info::before { + background: linear-gradient(-25deg, var(--heo-main), var(--heo-main-op-deep), var(--heo-main), var(--heo-main-op-deep)); + background-size: 400%; + position: absolute; + width: 100%; + height: 100%; + left: 0; + top: 0; + content: ''; + animation: gradient 15s ease infinite; +} + @keyframes gradient { 0% { - background-position: 0px 50%; + background-position: 0% 50%; } 50% { @@ -8673,19 +9949,21 @@ div#author-info__sayhi { } 100% { - background-position: 0px 50%; + background-position: 0% 50%; } } + @media screen and (max-width: 1300px) { #aside-content > .card-widget:first-child { min-height: 329px; } } +/* 作者卡片描述 */ #aside-content > div.card-widget.card-info > div > div.card-info-avatar.is-center > div.author-info__description { line-height: 1.38; - margin: 0.3rem 0px; + margin: .3rem 0; text-align: justify; color: rgba(255, 255, 255, 0.8); } @@ -8694,9 +9972,10 @@ div#author-info__sayhi { color: var(--heo-white); } +/* 作者卡片描述2 */ .author-info__description2 { line-height: 1.38; - margin: 0.3rem 0px; + margin: .3rem 0; text-align: justify; width: 100%; z-index: 2; @@ -8722,7 +10001,7 @@ div#author-info__sayhi { display: flex; align-items: center; z-index: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; cursor: pointer; } @@ -8736,44 +10015,49 @@ div#author-info__sayhi { font-size: 1rem; } + +/* 头像背景 */ +/* 隐藏文章数等信息 */ #aside-content .card-info .card-info-data { display: none; } +/* 作者头像 */ #aside-content .card-info a img { border-radius: 0px; height: 200px; display: inherit; - filter: drop-shadow(rgba(0, 0, 0, 0.03) -5px 14px 8px); + filter: drop-shadow(-5px 14px 8px #00000008); position: absolute; right: -24px; bottom: -82px; width: auto; z-index: 0; - transition: all 0.3s cubic-bezier(0.48, -0.21, 0, 1.5) 0s; + transition: cubic-bezier(0.48, -0.21, 0, 1.5) 0.3s; } #aside-content .card-info a img:hover { bottom: -42px; } -[data-theme="light"] #aside-content .card-info a img { - filter: drop-shadow(rgba(255, 255, 255, 0.03) -5px 14px 8px); +[data-theme=light] #aside-content .card-info a img { + filter: drop-shadow(-5px 14px 8px #ffffff08); } .card-widget.card-info { - padding: 0px !important; + padding: 0 !important; } #aside-content > div.card-widget.card-info > div.card-content { padding: 1rem 1.2rem; min-height: 330px; + position: relative; } #aside-content > div.card-widget.card-info > div.card-info-avatarimg { overflow: hidden; background: var(--heo-yellow); - transition: all 1.5s ease 0s; + transition: 1.5s; min-height: 160px; position: relative; box-shadow: var(--heo-shadow-yellow); @@ -8783,6 +10067,17 @@ div#author-info__sayhi { transform: scale(1.03); } +/* 作者文章列表链接 */ +#aside-content > div.card-widget.card-info > div > div.card-info-data > div:nth-child() > a > div.headline { + font-weight: bold; +} + +/* 作者名称和头像间距 */ +/* #aside-content .card-info .author-info__name{ + padding-top: 30px; +} */ + +/* pad端隐藏部分侧边栏 */ @media screen and (max-width: 900px) { #aside-content .card-announcement { display: none; @@ -8793,16 +10088,18 @@ div#author-info__sayhi { } } +/* 社交按钮 */ #aside-content .card-info #card-info-btn { display: none; } #aside-content .card-info .card-info-social-icons { - margin: 0px; + margin: 0; padding-top: 10px; display: flex; justify-content: flex-start; - flex-flow: row wrap; + flex-direction: row; + flex-wrap: wrap; cursor: pointer; position: absolute; bottom: 1rem; @@ -8810,7 +10107,8 @@ div#author-info__sayhi { } #aside-content .card-info .card-info-social-icons .social-icon { - margin: 0px 8px 0px 0px; + margin: 0; + margin-right: 8px; } #aside-content .card-info .card-info-social-icons i { @@ -8842,7 +10140,7 @@ div#author-info__sayhi { color: var(--heo-white); } - [data-theme="dark"] #aside-content .card-info .card-info-social-icons i { + [data-theme=dark] #aside-content .card-info .card-info-social-icons i { color: var(--heo-white); } } @@ -8857,16 +10155,18 @@ div#author-info__sayhi { color: var(--heo-blue); } +/* 公告 */ .announcement_content p { - margin: 0.5rem 0px 0px; + margin: 0.5rem 0 0 0; line-height: 1.38; } +/* 卡片标题 */ #aside-content .item-headline { - padding-bottom: 0px; + padding-bottom: 0; margin-left: 8px; font-size: 1em; - font-weight: 700; + font-weight: bold; } #aside-content .item-headline i { @@ -8875,7 +10175,7 @@ div#author-info__sayhi { #aside-content .item-headline + div, #aside-content .item-headline + ul { - padding: 0px; + padding: 0; } @media screen and (min-width: 1300px) { @@ -8890,32 +10190,33 @@ div#author-info__sayhi { } } +/* 卡片根据时间查看文章底部查看更多按钮 */ #aside-content > div.sticky_layout > div.card-widget.card-archives > div > ul > li.card-archive-list-item.more.is-center { margin-top: 8px; background: var(--heo-card-btn-bg); border-radius: 8px; - transition: all 0.3s ease 0s !important; + transition: 0.3s !important; } #aside-content > div.sticky_layout > div.card-widget.card-archives > div > ul > li.card-archive-list-item.more.is-center :hover { color: var(--heo-white); background: var(--heo-blue); border-radius: 8px; - transition: all 0.3s ease 0s !important; + transition: 0.3s !important; } #aside-content .card-archives ul.card-archive-list > .card-archive-list-item.more span, #aside-content .card-categories ul.card-category-list > .card-category-list-item.more span { - transition: all 0.3s ease 0s !important; + transition: 0.3s !important; } #aside-content .card-archives ul.card-archive-list > .card-archive-list-item:hover.more span, #aside-content .card-categories ul.card-category-list > .card-category-list-item.more span { - transition: all 0.3s ease 0s !important; + transition: 0.3s !important; } #aside-content > div.sticky_layout > div.card-widget.card-archives > div > ul > li.card-archive-list-item.more.is-center :hover span { - background: 0px 0px; + background: none; } #web_bg { @@ -8930,42 +10231,44 @@ div#author-info__sayhi { background-color: var(--heo-background); } -#web_bg::before { - opacity: 1; +#web_bg:before { background-color: var(--heo-background) !important; + opacity: 1; } -[data-theme="dark"] #footer::before, -[data-theme="dark"] #page-header::before, -[data-theme="dark"] #web_bg::before { +[data-theme='dark'] #web_bg:before, +[data-theme='dark'] #footer:before, +[data-theme='dark'] #page-header:before { background-color: var(--heo-none) !important; } -[data-theme="dark"]#web_bg { +[data-theme=dark]#web_bg { opacity: 1; } +/* 标签云卡片 */ #aside-content .card-tag-cloud a { + color: var(--heo-fontcolor) !important; font-size: 0.8rem; border-radius: 8px; - color: var(--heo-fontcolor) !important; } #aside-content .card-tag-cloud a:hover { background: var(--heo-theme); - box-shadow: var(--heo-shadow-theme); color: var(--heo-white) !important; + box-shadow: var(--heo-shadow-theme); } #aside-content .card-tag-cloud a.tags-cloud-more { width: 100%; text-align: center; + border-radius: 8px !important; border: var(--style-border); margin-top: 8px; - border-radius: 8px !important; font-size: var(--global-font-size) !important; } + @media screen and (min-width: 1300px) { #aside-content .card-tag-cloud a:hover { transform: scale(1.03); @@ -8976,6 +10279,7 @@ div#author-info__sayhi { } } +/* 时间轴卡片 */ #aside-content .card-archives ul.card-archive-list > .card-archive-list-item a:hover, #aside-content .card-categories ul.card-category-list > .card-category-list-item a:hover { color: var(--heo-white); @@ -8986,6 +10290,7 @@ div#author-info__sayhi { border: var(--style-border-hover); } + @media screen and (min-width: 1300px) { #aside-content .card-archives ul.card-archive-list > .card-archive-list-item a:hover, @@ -8999,18 +10304,19 @@ div#author-info__sayhi { } } +/* 翻页 */ a.extend.next { - right: 0px; + right: 0; } a.extend.prev { - left: 0px; + left: 0; } @media screen and (max-width: 768px) { #pagination { - margin-bottom: 0px; - margin-top: 0px; + margin-bottom: 0rem; + margin-top: 0; } } @@ -9024,8 +10330,13 @@ a.extend.prev { display: none; } -#page-header.post-bg::before { - transition: all 0s ease 0s; +/* 文章页 +---------------------------------------------------------------- */ + +/* 文章头图 */ +#page-header.post-bg:before { + transition: 0s; + opacity: 0.93; height: 20rem; background-color: var(--heo-main); opacity: 0.8; @@ -9033,11 +10344,11 @@ a.extend.prev { @media screen and (max-width: 768px) { #page-header.post-bg { - margin-bottom: -12px; height: 30rem !important; + margin-bottom: -12px; } - #page-header.post-bg::before { + #page-header.post-bg:before { height: 15rem; } @@ -9057,7 +10368,7 @@ a.extend.prev { height: 25rem; } - #page-header.post-bg::before { + #page-header.post-bg:before { height: 25rem; } @@ -9068,8 +10379,9 @@ a.extend.prev { } #page-header.post-bg { + /* backdrop-filter: blur(500px); */ background-color: var(--heo-main); - transition: all 0s ease 0s; + transition: 0s; overflow: hidden; box-shadow: var(--heo-shadow-main); } @@ -9087,8 +10399,9 @@ a.extend.prev { width: 70%; height: 100%; position: relative; - margin: 0px -20% 0px auto; + margin: 0 -20% 0 auto; overflow: hidden; + margin-bottom: 0; transform: rotate(10deg) translateY(-10%) scale(2); filter: blur(10px); } @@ -9097,20 +10410,20 @@ a.extend.prev { display: block; } -.coverdiv::after { +.coverdiv:after { position: absolute; - content: ""; + content: ''; width: 100%; height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; box-shadow: 110px -130px 300px 60px var(--heo-main) inset; } @media screen and (max-width: 768px) { .coverdiv { - margin: 0px 0px 0px auto; - transform: rotate(0deg) translateY(0px) scale(1); + margin: 0 0 0 auto; + transform: rotate(0deg) translateY(0) scale(1); filter: blur(0px); width: 100%; position: fixed; @@ -9118,24 +10431,27 @@ a.extend.prev { z-index: 1; } - .coverdiv::after { - box-shadow: 0 0 205px 59px var(--heo-main) inset; + .coverdiv:after { + box-shadow: 0px 0px 205px 59px var(--heo-main) inset; } + } #page-header { + background-image: none !important; display: flex; justify-content: center; - background-image: none !important; } +/* 顶部遮罩 */ #post-cover-rgb { position: absolute; - background: var(--heo-lighttext); width: 100% !important; height: 100% !important; + background: var(--heo-lighttext); } +/* 文章背景阴影 */ .layout > div:first-child:not(.recent-posts) { box-shadow: var(--heo-shadow-border); padding: 1rem 2rem; @@ -9159,20 +10475,20 @@ a.extend.prev { @media screen and (max-width: 768px) { .layout > div:first-child:not(.recent-posts) { - border-radius: 0px; - background: var(--heo-background); - padding: 0px 1rem !important; + border-radius: 0; + padding: 0rem 1rem !important; box-shadow: none !important; + background: var(--heo-background); } .layout { - padding: 0px 1.5rem; + padding: 0 1.5rem; } } @media screen and (max-width: 768px) { .layout { - padding: 0px; + padding: 0; } .layout > div:first-child:not(.recent-posts) { @@ -9180,7 +10496,7 @@ a.extend.prev { } .post .layout > div:first-child:not(.recent-posts) { - border-radius: 12px 12px 0px 0px; + border-radius: 12px 12px 0 0; } .post .layout#content-inner { @@ -9194,7 +10510,7 @@ a.extend.prev { #aside-content { z-index: 2; background: var(--heo-background); - padding: 0px 1rem; + padding: 0 1rem; display: flex; flex-direction: column; width: 100%; @@ -9205,15 +10521,28 @@ a.extend.prev { max-width: 1400px; } +/* 隐藏主页头图 */ .full_page #post-cover { display: none; } +/* @keyframes postheadimg { + from { + backdrop-filter: blur(0px); + background-color: rgba(0,0,0,0.2); + } + + to { + backdrop-filter: blur(300px); + background-color: rgba(0,0,0,0.2); + } */ + +/* 文章头部 */ #page-header #post-info { - top: 0px; + top: 0; position: absolute; - padding: 0px 3rem; - margin: 0px auto; + padding: 0 3rem; + margin: 0 auto; z-index: 10; color: var(--heo-white); max-width: 1400px; @@ -9226,25 +10555,38 @@ a.extend.prev { @media screen and (max-width: 768px) { #page-header #post-info { - padding: 18rem 6% 0px; + padding: 0 6%; justify-content: normal; + padding-top: 18rem; } } @media screen and (min-width: 1300px) { #page-header #post-info { height: calc(100% + 30px); - top: 0px; + top: 0; display: flex; justify-content: center; } } -#post-info #post-meta > .meta-secondline > span:first-child { - display: inline; - margin-right: 0.8rem; +/*#post-info #post-meta > .meta-secondline > span:first-child {*/ +/* margin-right: 0.8rem;*/ +/*}*/ + +.meta-secondline span { + display: flex; + align-items: center; + line-height: 1; } +@media screen and (max-width: 768px) { + .meta-secondline span { + line-height: 1.5; + } +} + +/* 文章时间分类信息 */ #post-firstinfo { text-align: left; display: flex; @@ -9264,11 +10606,11 @@ a.extend.prev { span.post-meta-categories { background-color: var(--heo-white-op); - padding: 0px 0.5rem; + padding: 0 0.5rem; border-radius: 8px; line-height: 32px; height: 32px; - transition: all 0.3s ease 0s; + transition: 0.3s; } span.post-meta-categories:not(:first-child) { @@ -9303,6 +10645,7 @@ span.post-meta-categories:hover a.post-meta-categories { } } +/* 文章作者信息和时间 */ .meta-avatar img { width: 30px; border-radius: 30px; @@ -9310,15 +10653,15 @@ span.post-meta-categories:hover a.post-meta-categories { } a.post-meta-original { - padding: 0px 0.5rem; + background: var(--heo-white-op) !important; + color: var(--heo-white) !important; + padding: 0 0.5rem; font-size: 0.7rem; margin: auto; border-radius: 8px; - font-weight: 700; + font-weight: bold; height: 32px; line-height: 32px; - background: var(--heo-white-op) !important; - color: var(--heo-white) !important; } a.post-meta-original:hover { @@ -9337,19 +10680,17 @@ a.post-meta-original:hover { } #post-info #post-meta { - display: flex; - margin: 0px auto; z-index: 1; } - #post-info::after { + #post-info:after { position: absolute; - content: ""; + content: ''; width: 100%; height: 100%; - bottom: 0px; - left: 0px; - box-shadow: 0 -214px 287px 45px var(--heo-main) inset; + bottom: 0; + left: 0; + box-shadow: 0px -214px 287px 45px var(--heo-main) inset; z-index: 0; } @@ -9371,13 +10712,14 @@ a.post-meta-original:hover { #post-firstinfo { white-space: nowrap; - margin: 0px auto; + margin: 0 auto; z-index: 1; } .meta-firstline .tag_share { display: none; } + } .post-meta__tag-list::-webkit-scrollbar { @@ -9385,13 +10727,13 @@ a.post-meta-original:hover { } .meta-share-time a:hover { - background: 0px 0px !important; + background: none !important; } .meta-share-time .meta-avatar-name { opacity: 1; - font-weight: 700; color: var(--heo-white) !important; + font-weight: bold; } .meta-share-time { @@ -9399,13 +10741,15 @@ a.post-meta-original:hover { } .meta-share-time .meta-info { - margin: 0px 0.5rem; + margin: 0 0.5rem; } .meta-secondline { - flex-flow: row wrap; + display: flex; + flex-direction: row; + flex-wrap: wrap; justify-content: flex-start; - display: flex !important; + align-items: center; } .meta-avatar { @@ -9413,21 +10757,30 @@ a.post-meta-original:hover { } .meta-avatar .meta-avatar-name { - margin: 0px 0.5rem; + margin: 0 0.5rem; } +/* 热度图标 */ #post-info #post-meta .fab { margin-bottom: 3px; font-size: 15px; } +/* 热度间隔 */ span.post-meta-pv-cv { margin-left: 0.8rem; } +/* 微信公众号同步 */ span.post-meta-wechat { margin-right: 0.8rem; opacity: 0.6; + transition: 0.3s; + cursor: pointer; +} + +.post-meta-wechat:hover { + opacity: 1; } span.post-meta-position { @@ -9435,19 +10788,23 @@ span.post-meta-position { opacity: 0.6; } +/* 隐藏信息文字 */ #post-info #post-meta .post-meta-label { display: none; } +/* 图标数字间距 */ #post-info #post-meta .post-meta-icon { margin-right: 0.4rem; } +/* 每组间距 */ #post-info #post-meta .post-meta-separator { margin: 0px 0.4rem; } -.post-meta-pv-cv #busuanzi_value_page_pv { +/* 文章信息数值 */ +.post-meta-pv-cv #visit { font-weight: 800; } @@ -9463,13 +10820,15 @@ span.post-meta-position { font-weight: 800; } +/* 文章信息透明度 */ .post-meta-wordcount { opacity: 0.6; + margin-right: 0.8rem } @media screen and (max-width: 768px) { .post-meta-wordcount { - margin-left: 0px; + margin-left: 0; } } @@ -9488,9 +10847,15 @@ span.post-meta-position { .post-meta-commentcount { opacity: 0.6; + cursor: pointer; + transition: 0.3s; } -#twikoo-count { +.post-meta-commentcount:hover { + opacity: 1; +} + +#comment-count { font-weight: 800; color: var(--heo-white); } @@ -9503,6 +10868,7 @@ span.post-meta-position { margin-right: 0.5rem; } +/* 文章内图片保持一行 */ .inline-image { display: flex; margin: 8px auto; @@ -9511,39 +10877,39 @@ span.post-meta-position { } .inline-image a:hover { - background: 0px 0px !important; + background: none !important; box-shadow: none !important; } .inline-image img { - margin-top: 0px; - margin-right: 0px; - margin-left: 0px; + margin: 0; display: inline-flex; - margin-bottom: 0px !important; + margin-bottom: 0 !important; } +/* 文章标题 */ #post-info .post-title { color: var(--heo-white); font-weight: 700; font-size: 2.3rem; line-height: 1.2; text-align: left; + margin: 1rem 0 1rem 0 !important; -webkit-line-clamp: 2; - padding: 0px; - margin: 1rem 0px !important; + padding: 0; } @media screen and (max-width: 768px) { #post-info .post-title { font-size: 1.2rem; -webkit-line-clamp: 3; + margin: 0.2rem auto !important; text-align: center; z-index: 1; - margin: 0.2rem auto !important; } } +/* 文章顶部其他信息 */ #post-meta > div { text-align: left; } @@ -9551,41 +10917,44 @@ span.post-meta-position { #post-info #post-meta { color: var(--heo-white); margin-top: 0.4rem; - height: 30px; - transition: all 0.3s ease 0s; + transition: 0.3s; + display: flex; } #post-info #post-meta a { text-decoration: none; color: var(--heo-fontcolor); - height: 30px; + line-height: 1; } #post-info #post-meta a:hover { text-decoration: none; color: var(--heo-blue); - border-radius: 12px; + border-radius: 12px } -#article-container h1::before, -#article-container h2::before, -#article-container h3::before, -#article-container h4::before, -#article-container h5::before, -#article-container h6::before { - top: calc(50% - 0.45rem); - content: ""; +/* 文章标题前图标 */ +#article-container h1:before, +#article-container h2:before, +#article-container h3:before, +#article-container h4:before, +#article-container h5:before, +#article-container h6:before { + top: calc(50% - .45rem); + content: ''; } -#article-container h1:hover::before, -#article-container h2:hover::before, -#article-container h3:hover::before, -#article-container h4:hover::before, -#article-container h5:hover::before, -#article-container h6:hover::before { +/* 文章标题前图标悬浮 */ +#article-container h1:hover:before, +#article-container h2:hover:before, +#article-container h3:hover:before, +#article-container h4:hover:before, +#article-container h5:hover:before, +#article-container h6:hover:before { color: var(--heo-lighttext); } +/* 标题悬浮效果 */ #article-container h1:hover, #article-container h2:hover, #article-container h3:hover, @@ -9595,100 +10964,153 @@ span.post-meta-position { padding-left: 1.3rem; } -#article-container ul > li:not(.tab)::before { +/* 文章tab样式 */ +#article-container ul > li:not(.tab):before { border: 0.21em solid var(--heo-lighttext); background: var(--heo-lighttext); } #article-container ol, #article-container ul { - padding: 0px; + padding: 0; } #article-container .tabs { + margin: 1rem 0 !important; border-radius: 12px; overflow: hidden; box-shadow: var(--heo-shadow-border); - margin: 1rem 0px !important; + padding: 8px; + background: var(--heo-card-bg); + border: var(--style-border); } #article-container .tabs .nav-tabs { - background: var(--heo-secondbg); + background: var(--heo-card-bg); + padding: 16px; + display: flex; + justify-content: center; + flex-wrap: wrap; + flex-direction: row; +} + +@media screen and (max-width: 768px) { + #article-container .tabs .nav-tabs { + padding: 0; + margin-bottom: 8px; + } } #article-container .tabs > .nav-tabs > .tab.active button { - border-top: 0 solid var(--heo-lighttext); - border-bottom: 3px solid var(--heo-lighttext); + border: var(--style-border-hover-always); background: var(--heo-background); -} - -#article-container .tabs > .nav-tabs > .tab:not(.active) button:hover { - border-bottom: 3px solid var(--heo-secondbg); - border-top: none !important; + border-radius: 8px; } #article-container .tabs > .nav-tabs > .tab button { + transition: all 0s; + -webkit-transition: all 0s; background: var(--heo-secondbg); - transition: all 0.3s ease 0s; - border-top: none; - border-bottom: 3px solid var(--heo-secondbg); + transition: 0.3s; + border: var(--style-border-always); + border-radius: 8px; + font-size: 14px; + padding: 8px 16px; + display: block; + line-height: 1; + width: 100%; + color: var(--heo-fontcolor); } #article-container .tabs > .nav-tabs > .tab:not(.active) button:hover { background: var(--heo-main); color: var(--heo-white); - transition: all 0.3s ease 0s; - border-top: 3px solid var(--heo-main); + transition: 0.3s; + border: var(--style-border-hover-always); } .tab-item-content { background: var(--heo-card-bg); } +/* tab边框 */ #article-container .tabs { border: 3px solid var(--heo-secondbg) !important; } + +/* 切换tab标签 */ #article-container .tabs > .tab-contents .tab-item-content.active { - animation: 0s ease 0s 1 normal none running tabshow; - padding: 1.2rem; + animation: tabshow 0s; + -webkit-animation: tabshow 0s; + padding: 1.2rem 1.2rem; + border-radius: 8px; } @media screen and (max-width: 768px) { #article-container .tabs > .tab-contents .tab-item-content.active { - padding: 0.5rem; + padding: 0.5rem 0.5rem; } } +.tab-contents { + border-radius: 8px; + overflow: hidden; +} + +/* 文章details折叠 */ details { + display: block; + position: relative; margin-bottom: 1rem; + min-height: 54px; + overflow: hidden; } details summary { + position: absolute; padding: 0.5rem 1rem; background: var(--heo-card-bg); border-radius: 12px; - margin: 0.2rem 0px; - transition: all 0.3s ease 0s; + margin: 0; + transition: 0.3s; border: var(--style-border); box-shadow: var(--heo-shadow-border); + position: absolute; + left: 0; + width: 100%; +} + +details > *:nth-child(2) { + margin-top: calc(54px + 1rem) !important; +} + +details[open] summary { + border-radius: 12px 12px 0 0; + background: var(--heo-main); + color: var(--heo-white); + border: var(--style-border-hover-always); } details summary:hover { cursor: pointer; background: var(--heo-main); color: var(--heo-white); - transition: all 0.3s ease 0s; + transition: 0.3s; box-shadow: var(--heo-shadow-main); } details summary:focus { - outline: 0px; + outline: none; } details summary::marker { color: var(--heo-main); - transition: all 0.3s ease 0s; + transition: 0.3s; +} + +details[open] summary::marker { + color: var(--heo-white); } details summary:hover::marker { @@ -9697,32 +11119,44 @@ details summary:hover::marker { details[open] { border-radius: 12px; - border: var(--style-border); - padding: 0px 1.5rem; + border: var(--style-border-hover-always); + padding: 0 1.5rem; background: var(--heo-card-bg); } +details summary:hover:after { + position: absolute; + content: '+'; + text-align: center; + top: calc(50% - 2px); + transform: translateY(-50%); + right: 16px; + line-height: 1; +} + +details[open] > summary:hover:after { + content: '-'; +} + @media screen and (max-width: 768px) { details[open] { - padding: 0px; + padding: 0; } } -details[open] summary { - display: none; -} - -#article-container ul > li:not(.tab):hover::before { +/* 文章点样式 */ +#article-container ul > li:not(.tab):hover:before { border-color: var(--heo-none); } +/* 文章中的超链接 */ #article-container a { text-decoration: none; border-bottom: 2px solid var(--heo-lighttext); color: var(--heo-fontcolor); - font-weight: 700; - padding: 0px 4px; - border-radius: 4px 4px 0px 0px; + font-weight: bold; + padding: 0 4px; + border-radius: 4px 4px 0 0; } #article-container a:not(.fancybox):hover { @@ -9735,8 +11169,8 @@ details[open] summary { } #article-container a.fancybox { - border-bottom: 0px; - padding: 0px; + border-bottom: 0; + padding: 0; margin: auto; display: contents; width: fit-content; @@ -9747,22 +11181,37 @@ details[open] summary { } .site-card-avatar a.fancybox { - padding: 0px !important; + padding: 0 !important; } #article-container p { - margin: 1rem 0px; + margin: 1rem 0; text-align: left; letter-spacing: 0.6px; } +/*#article-container code {*/ +/* color: var(--heo-white);*/ +/* padding: 0.2rem 0.4rem;*/ +/* border-radius: 4px;*/ +/* margin: 0px 4px;*/ +/* background: var(--heo-pink);*/ +/* line-height: 2;*/ +/* box-shadow: var(--heo-shadow-border);*/ +/*}*/ + +/*#article-container code::selection {*/ +/* background: var(--heo-main) !important;*/ +/*}*/ + +/* 文章表格间距 */ .table-wrap { margin: 1rem 0px; border-radius: 8px; } -table td, -table th { +table th, +table td { border: var(--style-border-always); } @@ -9770,11 +11219,13 @@ table thead { background: var(--heo-secondbg); } +/* 文章中的加粗文本颜色 */ b, strong { color: var(--heo-lighttext); } +/* 文章字号 */ #article-container p { font-size: 0.9rem; line-height: 1.7; @@ -9791,13 +11242,6 @@ strong { flex-direction: row-reverse; } -#article-container.post-content h1 strong, -#article-container.post-content h2 strong, -#article-container.post-content h3 strong, -#article-container.post-content h4 strong { - color: var(--text-highlight-color); -} - #article-container.post-content h1 { font-size: 1.5rem; line-height: 1.3; @@ -9816,7 +11260,7 @@ strong { } #article-container.post-content h4 { - font-size: 1rem; + font-size: 1.0rem; line-height: 1.3; } @@ -9826,6 +11270,8 @@ strong { } } +/* 外挂标签 */ + .note.warning:not(.no-icon):not(.modern)::before { display: flex; align-items: center; @@ -9838,16 +11284,19 @@ strong { border-width: 1px; border-color: var(--heo-yellow); box-shadow: var(--heo-shadow-border); + background: var(--card-bg); } +/* 链接外挂标签 */ #article-container .tag-Link { background: var(--heo-secondbg); + border-radius: 8px !important; display: flex; + border: var(--style-border); flex-direction: column; padding: 0.5rem 1rem; - margin-top: 1rem; - border-radius: 8px !important; border-width: 1px !important; + margin-top: 1rem; } #article-container .tag-Link:hover { @@ -9859,7 +11308,7 @@ strong { padding-bottom: 4px; font-size: 0.6rem; color: var(--heo-gray); - font-weight: 400; + font-weight: normal; pointer-events: none; } @@ -9879,9 +11328,10 @@ strong { width: 60px; min-width: 60px; height: 60px; - border-radius: 60px; - pointer-events: none; background-size: cover !important; + border-radius: 60px; + background: var(--heo-card-bg); + pointer-events: none; } #article-container .tag-Link .tag-link-bottom .tag-link-right { @@ -9898,7 +11348,7 @@ strong { #article-container .tag-Link .tag-link-bottom .tag-link-right .tag-link-sitename { font-size: 0.7rem; color: var(--heo-gray); - font-weight: 400; + font-weight: normal; margin-top: 4px; pointer-events: none; } @@ -9913,6 +11363,7 @@ strong { pointer-events: none; } +/* 文章标题 */ h1, h2, h3, @@ -9920,65 +11371,148 @@ h4, h5, h6 { margin-top: 1rem; - padding-top: 0px; - padding-left: 0px !important; + padding-top: 0; + padding-left: 0 !important; + font-weight: weight; } #post h2 { margin-top: 1.5rem; } -#article-container > h1:nth-child(1), -#article-container > h2:nth-child(1) { - margin: 0px; +#article-container > h2:nth-child(1), +#article-container > h1:nth-child(1) { + margin: 0; } -#aside-content #card-toc .toc-content::before { +/* 隐藏阅读进度 */ +#aside-content #card-toc .toc-content:before { display: none; } +/* 文章引用 */ blockquote { border: var(--style-border-always); background-color: var(--heo-secondbg); color: var(--heo-secondtext); border-radius: 8px; - margin: 1rem 0px; + margin: 1rem 0; padding: 0.5rem 0.8rem; } blockquote p { - padding: 0px; + padding: 0; } +/* readmore插件 */ +/* +[data-theme=dark] #read-more-mask{ + background: -webkit-gradient(linear, 0 0%, 0 100%, from(rgba(29, 30, 31, 0)), to(rgb(29, 30, 31)))!important; +} + +#read-more-btn{ + background: var(--heo-blue)!important; + border: 0px solid var(--heo-white) !important; + color: var(--heo-white) !important; + text-decoration: none!important; + font-weight:bold!important; + border-radius: 8px!important; +} + +#read-more-btn:hover{ + background: var(--heo-white) !important; + color: var(--heo-blue)!important; +} + +#btw-modal { + background: rgb(29, 30, 31)!important; +} + +#btw-modal img { + border: 8px solid rgb(0, 0, 0)!important; + border-radius: 8px!important; +} + +#btw-modal-header{ + margin-top: 0!important; + color: #fff !important; + margin: 2rem 0 1rem 0!important; +} + +#btw-modal-header strong{ + color: var(--heo-lighttext)!important; +} + +#btw-modal-input-code{ + background: rgb(29, 30, 31)!important; + margin-bottom: 50px; +} + +#btw-submit-btn{ + background: rgb(66, 123, 238)!important; + border-radius: 8px!important; + color: #fff !important; + font-weight:bold!important; +} + +#btw-submit-btn:hover{ + background: #fff !important; + color: rgb(66, 123, 238)!important; +} + +#btw-modal-input{ + color: #fff!important; + border-radius: 8px!important; + background: rgb(29, 30, 31)!important; +} + +#btw-modal-close-btn{ + color: rgb(129, 132, 136)!important; +} + +#btw-footer{ + display: none; +} + +#btw-mask{ + backdrop-filter: blur(3px); +} */ + +/* 文章内标题 */ #article-container .headerlink::before { - content: ""; + content: "\f0c1"; font-family: "Font Awesome 5 Free"; } #article-container .headerlink { float: right; opacity: 0.08; + border-bottom-style: none; + border-bottom: none; position: relative; padding: 0px; border: none; + border-radius: 8px !important; line-height: 1; font-size: 1rem; - border-radius: 8px !important; } #article-container .headerlink:hover { + background: none !important; opacity: 1; - text-decoration: none; - background: 0px 0px !important; border-bottom: none !important; box-shadow: none !important; + background: var(--heo-none); color: var(--heo-lighttext) !important; + text-decoration: none; } +/* 文章边栏 */ #sidebar { background: var(--heo-maskbg); } +/* 文章图片 */ #article-container img { border-radius: 12px; margin-bottom: 0.5rem; @@ -9989,21 +11523,32 @@ blockquote p { content: url(../images/404.gif); } +/* 文章视频 */ .doge-inner-player { border-radius: 12px !important; } -#article-container ol li::before, -#article-container ul li::before { +/* 文章数字头 */ +#article-container ol li:before, +#article-container ul li:before { background: var(--heo-theme); cursor: default; } -#article-container ol li:hover::before, -#article-container ul li:hover::before { +#article-container ol li:hover:before, +#article-container ul li:hover:before { transform: rotate(0deg); } +/* 文章代码框 */ +/*figure {*/ +/* margin-top: 0.5rem !important;*/ +/*}*/ + +/*#article-container figure.highlight .highlight-tools {*/ +/* background: var(--heo-secondbg) !important;*/ +/*}*/ + #article-container .gutter { opacity: 0.6; } @@ -10012,44 +11557,72 @@ blockquote p { margin-left: 6px; } -#article-container .highlight-tools .code-lang { - text-transform: capitalize; - left: 1.9rem; -} +/*#article-container .highlight-tools .code-lang {*/ +/* text-transform: capitalize;*/ +/* left: 1.9rem;*/ +/*}*/ +/*#article-container figure.highlight table::-webkit-scrollbar {*/ +/* color: var(--heo-blue);*/ +/* background: var(--heo-secondbg);*/ +/* height: 8px;*/ +/*}*/ + +/*#article-container figure.highlight table::-webkit-scrollbar-thumb {*/ +/* background: var(--heo-gray);*/ +/*}*/ + +/*#article-container figure.highlight table::-webkit-scrollbar-thumb:hover {*/ +/* background: var(--heo-main);*/ +/*}*/ + +/* 代码展开图标 */ #article-container .code-expand-btn i { + color: var(--heo-fontcolor); font-size: 1rem; - color: var(--heo-white) !important; } #article-container .code-expand-btn { + background-color: var(--heo-mask); background: var(--heo-secondbg); - transition: all 0.3s ease 0s; + transition: 0.3s; backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } #article-container .code-expand-btn:hover { background: var(--heo-main); } +#article-container .code-expand-btn:hover i { + color: var(--heo-white); +} + +/* 结尾寄语 */ #readmore-talk { text-align: center; color: var(--heo-lighttext); padding: 8px; border-radius: 12px; - background: rgba(242, 185, 75, 0.047); + background: #f2b94b0c; } +/* 相关推荐 */ +/* .relatedPosts>.relatedPosts-list>div { + border-radius: 12px; +} */ + .relatedPosts > .relatedPosts-list .cover::after { - content: " "; + content: ' '; display: block; position: absolute; z-index: 0; - top: 0px; - left: 0px; + top: 0; + left: 0; width: 100%; height: 100%; - background: url(../images/404.gif) 0% 0% / 100% 100%; + background: url(../images/404.gif) 50%; + background-size: cover; } .relatedPosts > .relatedPosts-list a { @@ -10060,7 +11633,7 @@ blockquote p { @media screen and (min-width: 768px) { #post > div.relatedPosts > div.relatedPosts-list > div { - -webkit-mask-image: -webkit-radial-gradient(center center, rgb(255, 255, 255), rgb(0, 0, 0)); + -webkit-mask-image: -webkit-radial-gradient(center, rgb(255, 255, 255), rgb(0, 0, 0)); } #post > div.relatedPosts > div.relatedPosts-list > div { @@ -10083,16 +11656,18 @@ blockquote p { } .relatedPosts > .headline { - font-size: 1.2em; margin-bottom: 0.8rem !important; + font-size: 1.2em; } + +/* 文章标签 */ #post .tag_share .post-meta__tags { background: var(--heo-card-bg); border: var(--style-border-always); color: var(--heo-fontcolor); border-radius: 8px; - margin: 0px; + margin: 0; display: flex; align-items: center; white-space: nowrap; @@ -10100,7 +11675,7 @@ blockquote p { } #post .tag_share .post-meta__tags:not(:last-child) { - margin: 0px 0.5rem 0px 0px; + margin: 0 0.5rem 0 0; } #post .tag_share .post-meta__tags:hover { @@ -10120,22 +11695,24 @@ blockquote p { } } +/* 版权信息 */ +/* 背景 */ #post .post-copyright { background: var(--heo-card-bg); padding: 1rem 1.3rem; overflow: hidden; - border-width: 1px; border: var(--style-border); - transition: all 0.3s ease 0s; + border-width: 1px; + transition: 0.3s; } -#post .post-copyright::after { +#post .post-copyright:after { position: absolute; right: 22px; top: -77px; - content: ""; + content: '\f25e'; font-size: 180px; - font-family: "Font Awesome 5 Brands"; + font-family: 'Font Awesome 5 Brands'; color: var(--heo-fontcolor); opacity: 0.4; filter: blur(7px); @@ -10159,7 +11736,7 @@ blockquote p { font-size: 0.7rem; border-radius: 8px; margin-right: 0.5rem; - font-weight: 700; + font-weight: bold; line-height: 1.5; white-space: nowrap; } @@ -10182,31 +11759,33 @@ blockquote p { display: none; } - #post .post-copyright::after { + #post .post-copyright:after { display: none; } } +/* 复制按钮 */ .post-copyright-copybtn { margin-left: 0.5rem; color: var(--heo-fontcolor); opacity: 0.4; - transition: all 0.3s ease 0s; + transition: 0.3s; } .post-copyright-copybtn:hover { opacity: 1; - transition: all 0.3s ease 0s; + transition: 0.3s; } +/* 作者名 */ #post .post-copyright .post-copyright-info a { - padding: 0px; + padding: 0; color: var(--heo-fontcolor); - font-weight: 700; + font-weight: bold; } #post .post-copyright .post-copyright__notice .post-copyright-info a { - padding: 0px 4px; + padding: 0 4px; } #post .post-copyright .post-copyright-info a:hover { @@ -10214,7 +11793,7 @@ blockquote p { } #post .post-copyright .post-copyright-info { - padding-left: 0px; + padding-left: 0; color: var(--heo-fontcolor); overflow: hidden; display: -webkit-box; @@ -10223,14 +11802,14 @@ blockquote p { } #post .post-copyright .post-copyright-title { - padding-left: 0px; + padding-left: 0; color: var(--heo-fontcolor); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; font-size: 1rem; - font-weight: 700; + font-weight: bold; } #post .post-copyright .post-copyright-title:hover { @@ -10238,9 +11817,9 @@ blockquote p { } #post > div.post-copyright > div.post-copyright__author > span > span { - padding: 0px; + padding: 0; color: var(--heo-fontcolor); - font-weight: 700; + font-weight: bold; font-size: 1rem; line-height: 1.38; overflow: hidden; @@ -10264,6 +11843,7 @@ blockquote p { } } +/* 链接 */ #post > div.post-copyright > div.post-copyright__type { line-height: 16px; display: flex; @@ -10278,7 +11858,7 @@ blockquote p { #post > div.post-copyright > div.post-copyright__type > span > a:hover { opacity: 1; - background: 0px 0px; + background: none; } #post-copyright-url a { @@ -10288,20 +11868,23 @@ blockquote p { -webkit-box-orient: vertical; } +/* 提示 */ #post > div.post-copyright > div.post-copyright__notice { font-size: 0.7rem; line-height: 1rem; - margin: 0.5rem 0px; + margin: 0.5rem 0; } -#post .post-copyright::before { +/* 装饰圈 */ +#post .post-copyright:before { display: none; } +/* 赞赏作者按钮 */ .post-reward .reward-button { background: var(--heo-red); color: var(--heo-white); - padding: 0px; + padding: 0; width: 133px; height: 40px; line-height: 39px; @@ -10314,7 +11897,7 @@ blockquote p { box-shadow: none; } -.share-button .fa-qrcode::before { +.share-button .fa-qrcode:before { font-size: 1rem; } @@ -10325,7 +11908,7 @@ blockquote p { } .post-reward .reward-main .reward-all .reward-item .post-qr-code-desc { - padding-top: 0px; + padding-top: 0rem; margin-top: -8px; margin-bottom: 8px; } @@ -10341,22 +11924,26 @@ blockquote p { align-items: center; } +/* 赞赏描述 */ .reward-dec { font-size: 0.6rem; } +/* 赞赏名单 */ + .reward-text { - margin-bottom: 0px; - font-weight: 700; + margin-bottom: 0rem; + font-weight: bold; } +/* 赞赏名单按钮 */ a.reward-main-btn { background: var(--heo-secondbg); color: var(--heo-fontcolor); display: flex; flex-direction: column; border-radius: 12px; - padding: 4px 0px; + padding: 4px 0; border: var(--style-border-always); margin: 8px; width: 100%; @@ -10364,19 +11951,20 @@ a.reward-main-btn { a.reward-main-btn:hover { color: var(--heo-white); + background: var(--heo-red); background-image: url(../images/404.gif); box-shadow: var(--heo-shadow-red); } .reward-title { - font-weight: 700; + font-weight: bold; color: var(--heo-red); } .reward-link.mode { background: var(--heo-green); color: var(--heo-white); - padding: 0px; + padding: 0; width: 173px; height: 40px; line-height: 39px; @@ -10384,7 +11972,7 @@ a.reward-main-btn:hover { border-radius: 8px; margin-left: 0.5rem; text-align: center; - transition: all 0.3s ease 0s; + transition: 0.3s; } @media screen and (min-width: 1300px) { @@ -10397,6 +11985,7 @@ a.reward-main-btn:hover { } } + .reward-link.mode a { color: var(--heo-white); } @@ -10410,31 +11999,36 @@ a.reward-main-btn:hover { box-shadow: none; } +/* 赞赏背景 */ + #quit-box { position: fixed; width: 100vw; height: 100vh; - background: rgba(0, 0, 0, 0.4); - top: 0px; - left: 0px; + background: rgba(0, 0, 0, .4); + top: 0; + left: 0; display: none; z-index: 101; - margin: 0px !important; + margin: 0 !important; } .post-tools-left #quit-box { display: none; } -#pagination .next-post, -#pagination .prev-post, + +/* 接下来下一篇 */ .next-post.pull-right, -.prev-post.pull-left { +.prev-post.pull-left, +#pagination .prev-post, +#pagination .next-post { background: var(--heo-secondbg); } @media screen and (min-width: 768px) { #pagination .next-post a { + border-left: var(--heo-card-bg); border-left-width: 3px; border-left-style: solid; display: flex; @@ -10447,15 +12041,16 @@ a.reward-main-btn:hover { } #pagination .prev-post a { + border-right: var(--heo-card-bg); border-right-width: 3px; border-right-style: solid; } #pagination .pagination-info { - padding: 1rem 1.5rem; + padding: 1rem 1.5rem 1rem 1.5rem; position: relative; display: flex; - top: 0px; + top: 0; transform: none; flex-direction: column; justify-content: center; @@ -10463,53 +12058,55 @@ a.reward-main-btn:hover { height: 100%; } - #pagination .next-post a:hover, - #pagination .prev-post a:hover { + #pagination .prev-post a:hover, + #pagination .next-post a:hover { background: var(--heo-main); } - #pagination .next-post a:hover div, - #pagination .prev-post a:hover div { + #pagination .prev-post a:hover div, + #pagination .next-post a:hover div { color: var(--heo-white) !important; } } @media screen and (max-width: 768px) { - #pagination .next-post a:hover, - #pagination .prev-post a:hover { + #pagination .prev-post a:hover, + #pagination .next-post a:hover { background: var(--heo-none); } + } -#pagination img.next-cover, -#pagination img.prev-cover { + +#pagination img.prev-cover, +#pagination img.next-cover { opacity: 0.15; transform: scale(1.03); - transition: all 0.3s ease 0s; + transition: 0.3s; filter: blur(0px); - backface-visibility: hidden; - transform-style: preserve-3d; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; } -#pagination .next-post:hover img.next-cover, +#pagination .prev-post:hover img.prev-cover, #pagination .next-post:hover img.prev-cover, #pagination .prev-post:hover img.next-cover, -#pagination .prev-post:hover img.prev-cover { +#pagination .next-post:hover img.next-cover { opacity: 0.25; transform: scale(1.03); filter: blur(5px); } -#pagination .next-post .label, -#post #pagination .prev-post .label { +#post #pagination .prev-post .label, +#pagination .next-post .label { color: var(--heo-fontcolor); } -#pagination .next_info, -#post #pagination .prev_info { +#post #pagination .prev_info, +#pagination .next_info { color: var(--heo-fontcolor); - font-weight: 700; + font-weight: bold; -webkit-line-clamp: 2; white-space: normal; line-height: 1.3; @@ -10533,8 +12130,9 @@ a.reward-main-btn:hover { width: 300px; bottom: -100px; right: 20px; + z-index: 1000; height: fit-content; - transition: all 0.3s cubic-bezier(0.42, 0, 0.3, 1.11) 0s; + transition: cubic-bezier(0.42, 0, 0.3, 1.11) 0.3s; border: var(--style-border); border-radius: 12px; overflow: hidden; @@ -10555,17 +12153,17 @@ a.reward-main-btn:hover { #pagination .next-post a { border: none; height: fit-content; - padding: 0.5rem 0px; + padding: 0.5rem 0; } #pagination.pagination-post { - border-radius: 0px; + border-radius: 0; } - #pagination .next_info, - #post #pagination .prev_info { + #post #pagination .prev_info, + #pagination .next_info { font-size: 14px; - font-weight: 400; + font-weight: normal; } #pagination .pagination-info { @@ -10574,14 +12172,15 @@ a.reward-main-btn:hover { } #post #pagination { - background: 0px 0px; + background: none; } - #pagination .next-post, - #pagination .prev-post, .next-post.pull-right, - .prev-post.pull-left { + .prev-post.pull-left, + #pagination .prev-post, + #pagination .next-post { background: var(--heo-maskbgdeep); + -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); } @@ -10598,10 +12197,10 @@ a.reward-main-btn:hover { position: relative; } - #pagination .next-post .label, - #post #pagination .prev-post .label { + #post #pagination .prev-post .label, + #pagination .next-post .label { color: var(--heo-fontcolor); - font-weight: 700; + font-weight: bold; font-size: 12px; margin-bottom: 0.5rem; border-bottom: var(--style-border); @@ -10621,24 +12220,25 @@ a.reward-main-btn:hover { box-shadow: var(--heo-shadow-border); } - #pagination .next-post .label, - #post #pagination .prev-post .label { + #post #pagination .prev-post .label, + #pagination .next-post .label { text-align: left; } - #pagination .next_info, - #post #pagination .prev_info { + #post #pagination .prev_info, + #pagination .next_info { text-align: left; } - #pagination .next-post, - #pagination .prev-post, .next-post.pull-right, - .prev-post.pull-left { + .prev-post.pull-left, + #pagination .prev-post, + #pagination .next-post { background: var(--heo-card-bg); } } +/* 翻页 */ @media screen and (max-width: 768px) { #pagination .page-number { display: none; @@ -10651,7 +12251,7 @@ a.reward-main-btn:hover { #pagination .pagination .extend { width: 100%; height: 2.5rem; - margin: 0.2rem 1rem 1rem; + margin: 0.2rem 1rem 1rem 1rem; border-radius: 12px; line-height: 2.5rem; background: var(--heo-card-bg); @@ -10670,7 +12270,7 @@ a.reward-main-btn:hover { #pagination .pagination { background: var(--heo-background); - transition: all 0.3s ease 0s; + transition: 0.3s; display: flex; } } @@ -10681,11 +12281,11 @@ a.reward-main-btn:hover { background: var(--heo-card-bg); height: 2rem; line-height: calc(2rem - 2px); - margin: 0px 0.3rem; + border-radius: 8px !important; + margin: 0 0.3rem; box-shadow: var(--heo-shadow-border); border: var(--style-border); - transition: all 0.3s ease 0s; - border-radius: 8px !important; + transition: 0.3s; } #pagination .page-number.current { @@ -10707,6 +12307,7 @@ a.reward-main-btn:hover { transform: scale(1.03); } + #pagination a.extend.next:hover, #pagination a.extend.prev:hover { color: var(--heo-theme); @@ -10715,11 +12316,13 @@ a.reward-main-btn:hover { transform: scale(1.03); } + @media screen and (min-width: 1300px) { #pagination .page-number:hover { transform: scale(1.03); } + #pagination a.extend.next:hover, #pagination a.extend.prev:hover { transform: scale(1.03); @@ -10733,10 +12336,11 @@ a.reward-main-btn:hover { #pagination a.extend.prev:active { transform: scale(0.97); } + } #pagination span.space { - margin: 0px 0.3rem; + margin: 0 0.3rem; } #pagination a.extend.next, @@ -10744,6 +12348,7 @@ a.reward-main-btn:hover { width: 4rem; height: 2rem; line-height: 1.9rem; + border-radius: 8px !important; background: var(--heo-card-bg); box-shadow: var(--heo-shadow-border); position: absolute; @@ -10752,13 +12357,12 @@ a.reward-main-btn:hover { align-items: center; justify-content: center; overflow: hidden; - transition: all 0.3s ease 0s; - border-radius: 8px !important; + transition: 0.3s; } #pagination a.extend.next i, #pagination a.extend.prev i { - transition: all 0.3s ease 0s; + transition: 0.3s; } #pagination a.extend.next { @@ -10767,7 +12371,7 @@ a.reward-main-btn:hover { #pagination a.extend.next .pagination_tips_next { margin-left: -32px; - transition: all 0.3s ease 0s; + transition: 0.3s; opacity: 0; } @@ -10779,7 +12383,7 @@ a.reward-main-btn:hover { #pagination a.extend.prev .pagination_tips_prev { margin-right: -32px; - transition: all 0.3s ease 0s; + transition: 0.3s; opacity: 0; } @@ -10800,6 +12404,7 @@ a.reward-main-btn:hover { } } +/* 相关推荐 */ .relatedPosts-list { display: flex; flex-wrap: wrap; @@ -10808,7 +12413,7 @@ a.reward-main-btn:hover { .relatedPosts > .relatedPosts-list > div { background: var(--heo-background); - transition: all 0.3s ease 0s; + transition: 0.3s; cursor: pointer; overflow: hidden; } @@ -10839,7 +12444,7 @@ a.reward-main-btn:hover { .relatedPosts > .relatedPosts-list .content .title { color: var(--heo-fontcolor); - font-weight: 700; + font-weight: bold; line-height: 1.5; -webkit-line-clamp: 4; font-size: 0.9rem; @@ -10851,10 +12456,12 @@ a.reward-main-btn:hover { display: none; } +/* 分割线 */ #post > hr { display: none; } +/* 文章tips */ .post-tips { color: var(--heo-gray); font-size: 14px; @@ -10878,6 +12485,12 @@ a.reward-main-btn:hover { } } +/* 评论 */ +/* ---------------------------------------------------------------- */ +/* ---------------------------------------------------------------- */ +/* ---------------------------------------------------------------- */ +/* ---------------------------------------------------------------- */ +/* ---------------------------------------------------------------- */ div#post-comment { margin-top: 2rem; } @@ -10891,6 +12504,7 @@ div#post-comment { #post-comment .comment-tips { background-color: rgba(103, 194, 58, 0.13); + border: var(--style-border-always); border-color: var(--heo-green); color: var(--heo-green); border-radius: 8px; @@ -10899,14 +12513,16 @@ div#post-comment { display: none; } + #post-comment .comment-tips.show { display: flex; } +/* 头像 */ .tk-avatar { - box-shadow: var(--heo-shadow-border); width: 32px !important; height: 32px !important; + box-shadow: var(--heo-shadow-border); } .tk-avatar.tk-has-avatar { @@ -10935,26 +12551,29 @@ img.tk-avatar-img { margin-right: 0.5rem !important; } -.el-input.el-input--small.el-input-group.el-input-group--prepend:nth-child(1)::before { - content: "输入QQ号会自动获取昵称和头像"; +/* 评论输入框提示 */ +/* 设置文字内容 :nth-child(1)的作用是选择第几个 */ +.el-input.el-input--small.el-input-group.el-input-group--prepend:nth-child(1):before { + content: '输入QQ号会自动获取昵称和头像'; } -.el-input.el-input--small.el-input-group.el-input-group--prepend:nth-child(2)::before { - content: "收到回复将会发送到你的邮箱"; +.el-input.el-input--small.el-input-group.el-input-group--prepend:nth-child(2):before { + content: '收到回复将会发送到你的邮箱'; } -.el-input.el-input--small.el-input-group.el-input-group--prepend:nth-child(3)::before { - content: "可以通过昵称访问你的网站"; +.el-input.el-input--small.el-input-group.el-input-group--prepend:nth-child(3):before { + content: '可以通过昵称访问你的网站'; } +/* 当用户点击输入框时显示 */ .el-input.el-input--small.el-input-group.el-input-group--prepend:focus-within::before { display: block; - animation: 0.3s ease 0s 1 normal none running commonTipsIn; + animation: commonTipsIn 0.3s; } .el-input.el-input--small.el-input-group.el-input-group--prepend:focus-within::after { display: block; - animation: 0.3s ease 0s 1 normal none running commonTriangleIn; + animation: commonTriangleIn 0.3s; } @keyframes commonTipsIn { @@ -10981,37 +12600,49 @@ img.tk-avatar-img { } } +/* 主内容区 */ .el-input.el-input--small.el-input-group.el-input-group--prepend::before { + /* 先隐藏起来 */ display: none; + /* 绝对定位 */ position: absolute; + /* 向上移动60像素 */ top: -60px; + /* 文字强制不换行,防止left:50%导致的文字换行 */ white-space: nowrap; + /* 圆角 */ border-radius: 10px; + /* 距离左边50% */ left: 50%; + /* 然后再向左边挪动自身的一半,即可实现居中 */ transform: translate(-50%); + /* 填充 */ padding: 14px 18px; - background: rgb(68, 68, 68); - color: rgb(255, 255, 255); + background: #444; + color: #fff; z-index: 100; } +/* 小角标 */ .el-input.el-input--small.el-input-group.el-input-group--prepend::after { display: none; - content: ""; + content: ''; position: absolute; - border-width: 12px; - border-style: solid; - border-color: rgb(68, 68, 68) transparent transparent; - border-image: initial; + /* 内容大小(宽高)为0且边框大小不为0的情况下,每一条边(4个边)都是一个三角形,组成一个正方形。 + 我们先将所有边框透明,再给其中的一条边添加颜色就可以实现小三角图标 */ + border: 12px solid transparent; + border-top-color: #444; left: 50%; transform: translate(-50%, -46px); } +/* 昵称 */ .tk-nick { - line-height: 32px; font-size: 1rem !important; + line-height: 32px; } +/* 填写项标题 */ .el-input-group__append, .el-input-group__prepend { background-color: var(--heo-card-bg) !important; @@ -11019,6 +12650,7 @@ img.tk-avatar-img { border-color: var(--heo-card-border) !important; } +/* 输入框 */ .el-input__inner { background: var(--heo-background) !important; border: 1px solid var(--heo-card-border) !important; @@ -11033,12 +12665,13 @@ img.tk-avatar-img { border: 1px solid var(--heo-main) !important; } +/* 评论输入框 */ .el-textarea__inner { background: var(--heo-background) !important; color: var(--heo-fontcolor) !important; border-radius: 12px !important; min-height: 100px !important; - padding: 16px 16px 40px !important; + padding: 16px 16px 40px 16px !important; border: var(--style-border-always) !important; } @@ -11050,13 +12683,13 @@ img.tk-avatar-img { } #page .el-textarea__inner { - box-shadow: var(--heo-shadow-border); background: var(--heo-card-bg) !important; + box-shadow: var(--heo-shadow-border); } .el-textarea__inner:focus { - box-shadow: var(--heo-shadow-main); border: var(--style-border-hover-always) !important; + box-shadow: var(--heo-shadow-main); } #page .tk-meta-input .el-input { @@ -11067,50 +12700,58 @@ img.tk-avatar-img { flex-direction: column-reverse !important; } +/* 评论数量字号 */ #twikoo > div.tk-comments > div.tk-comments-container > div.tk-comments-title > span:nth-child(1) { display: none !important; } +/* 加载时背景颜色 */ .el-loading-mask { + background-color: none !important; } +/* 所有标签 */ .tk-tag { transform: translateY(-2px); } +/* 评论博主标签圆角 */ .tk-tag-green { border-radius: 4px !important; - border: 0px solid rgb(225, 243, 216) !important; + border: 0px solid #e1f3d8 !important; font-size: 0.5rem !important; } -[data-theme="dark"] .tk-tag-green { - background-color: rgba(103, 194, 58, 0.13) !important; +[data-theme=dark] .tk-tag-green { + background-color: #67c23a21 !important; } +/* 审核中的评论 */ .tk-tag-yellow { border-radius: 4px !important; - border: 0px solid rgb(225, 243, 216) !important; + border: 0px solid #e1f3d8 !important; font-size: 0.5rem !important; } -[data-theme="dark"] .tk-tag-green { - background-color: rgba(192, 194, 58, 0.13) !important; +[data-theme=dark] .tk-tag-green { + background-color: #c0c23a21 !important; } +/* 评论置顶 */ .tk-tag-red { border-radius: 4px !important; - border: 0px solid rgb(243, 216, 216) !important; + border: 0px solid #f3d8d8 !important; font-size: 0.5rem !important; } -[data-theme="dark"] .tk-tag-red { - background-color: rgba(194, 58, 58, 0.13) !important; +[data-theme=dark] .tk-tag-red { + background-color: #c23a3a21 !important; } +/* 预览按钮 */ .el-button { background-color: var(--heo-fontcolor) !important; - border: 0 solid var(--heo-main) !important; + border: 0px solid var(--heo-main) !important; color: var(--heo-background) !important; border-radius: 8px !important; } @@ -11132,10 +12773,12 @@ img.tk-avatar-img { z-index: 102; } +/* 魔改教程入口 */ .twikoo-info { color: var(--heo-secondtext); } +/* 点赞和评论 */ .tk-action-link { color: var(--heo-lighttext) !important; } @@ -11144,6 +12787,7 @@ img.tk-avatar-img { fill: var(--heo-lighttext) !important; } +/* 取消按钮 */ button.el-button.tk-cancel.el-button--default.el-button--small { background: var(--heo-secondbg) !important; border-radius: 8px !important; @@ -11154,20 +12798,22 @@ button.el-button.tk-cancel.el-button--default.el-button--small { display: none; } +/* 发送按钮正常状态 */ .tk-comments .el-button--primary { + border-color: var(--heo-fontcolor) !important; + color: var(--heo-card-bg) !important; + border-radius: 4px !important; box-shadow: var(--heo-shadow-black); - transition: all 0.3s ease 0s; + transition: 0.3s; width: 5rem; position: absolute; top: -53px; right: 0px; - height: 32px; - border-color: var(--heo-fontcolor) !important; - color: var(--heo-card-bg) !important; - border-radius: 4px !important; margin-left: 0.5rem !important; + height: 32px; } +/* 发送按钮禁用状态 */ .tk-comments .el-button--primary.is-disabled, .tk-comments .el-button--primary.is-disabled:active, .tk-comments .el-button--primary.is-disabled:focus, @@ -11195,8 +12841,8 @@ button.el-button.tk-cancel.el-button--default.el-button--small { .tk-comments-title { position: absolute; - bottom: 0px; - left: 0px; + bottom: 0; + left: 0; } .tk-extras { @@ -11209,7 +12855,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .tk-icon.__comments { - margin-left: 0px !important; + margin-left: 0 !important; } .tk-row.actions { @@ -11220,24 +12866,27 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .tk-meta-input { + position: relative !important; margin-top: 0.8rem; width: calc(100% - 5.5rem); - position: relative !important; } +/* 内容 */ #post-comment blockquote { background: var(--heo-secondbg); border: var(--style-border); box-shadow: none; - margin: 0px 0px 0.5rem; + margin: 0; + margin-bottom: 0.5rem; font-size: 0.6rem; color: var(--heo-secondtext); border-radius: 8px; } +/* 表情 */ .tk-content .tk-owo-emotion { width: 3em; - margin: 0px 2px; + margin: 0px 2px 0px 2px; } .OwO .OwO-body .OwO-bar .OwO-packages li { @@ -11258,9 +12907,9 @@ button.el-button.tk-cancel.el-button--default.el-button--small { border-radius: 10px; z-index: 9999; display: none; - transform: translate(0px, -105%); + transform: translate(0, -105%); overflow: hidden; - animation: 0.3s cubic-bezier(0.42, 0, 0.3, 1.11) 0s 1 normal none running owoIn; + animation: owoIn 0.3s cubic-bezier(0.42, 0, 0.3, 1.11); padding: 1rem; } @@ -11275,12 +12924,12 @@ button.el-button.tk-cancel.el-button--default.el-button--small { @keyframes owoIn { 0% { - transform: translate(0px, -95%); + transform: translate(0, -95%); opacity: 0; } 100% { - transform: translate(0px, -105%); + transform: translate(0, -105%); opacity: 1; } } @@ -11296,23 +12945,29 @@ button.el-button.tk-cancel.el-button--default.el-button--small { border: var(--style-border-always); padding: 1px 5px 1px 2px; border-radius: 8px; - font-size: 0.5rem; margin-right: 4px !important; color: var(--heo-secondtext) !important; display: inline !important; margin-top: 6px !important; + font-size: 0.5rem; } .tk-extra .tk-icon { display: none; } +/* 更多评论 */ +/* [data-theme=dark] .tk-expand{ + background: linear-gradient(rgba(29, 31, 32,0), rgba(29, 31, 32,1))!important; + color: var(--heo-fontcolor); +} */ + .tk-expand { + background: var(--heo-card-bg) !important; + color: var(--heo-fontcolor) !important; border: var(--style-border-always); box-shadow: var(--heo-shadow-border); border-radius: 12px; - background: var(--heo-card-bg) !important; - color: var(--heo-fontcolor) !important; } .tk-expand:hover { @@ -11320,28 +12975,30 @@ button.el-button.tk-cancel.el-button--default.el-button--small { color: var(--heo-white) !important; } +/* 评论时间 */ .tk-time { + color: var(--heo-secondtext) !important; font-size: 0.8rem; margin-left: 0.5rem; - color: var(--heo-secondtext) !important; } +/* 评论之间的间距 */ .tk-comments-container > .tk-comment { - background: var(--heo-card-bg); - transition: all 0.3s ease 0s; - border-radius: 12px; - padding: 0.5rem 0px 0px; - border-right: none; - border-bottom: none; - border-left: none; - border-image: initial; - border-top: var(--style-border-dashed); - margin-top: 0px !important; + margin-top: 0rem !important; margin-bottom: 0.5rem !important; + background: var(--heo-card-bg); + transition: 0.3s; + border-radius: 12px; + padding: 0rem; + padding-top: 0.5rem; + border: none; + border-top: var(--style-border-dashed); } #page .tk-comments-container > .tk-comment { - padding: 1rem 1rem 1.5rem; + padding: 1rem; + padding-bottom: 1.5rem; + border: var(--style-border); border-top: var(--style-border); box-shadow: var(--heo-shadow-border); } @@ -11362,27 +13019,31 @@ button.el-button.tk-cancel.el-button--default.el-button--small { position: absolute; } +/* 评论功能模块标题字号 */ #post-comment .comment-head { - margin-bottom: 0.5rem; font-size: 0.8em !important; + margin-bottom: 0.5rem; } +/* 隐藏没有评论 */ .tk-comments-no { display: none !important; } .tk-comments-container { + min-height: 0rem !important; margin-top: 0.5rem; - min-height: 0px !important; } + .tk-replies > .tk-comment { background: var(--heo-card-bg); border-top: var(--style-border-dashed); border-radius: 12px; - padding: 1rem 0px 0px; - transition: all 0.3s ease 0s; - margin-top: 0px; + padding: 0; + transition: 0.3s; + padding-top: 1rem; + margin-top: 0; } .tk-content p { @@ -11394,21 +13055,24 @@ button.el-button.tk-cancel.el-button--default.el-button--small { color: var(--heo-secondtext); } +/* 图片描述 */ .img-alt { font-size: 12px; - margin: 0px; + margin: 0; color: var(--heo-secondtext); } +/* 文章长图 */ .long-img .img-alt { display: none; } .long-img img { - border-radius: 0px !important; - margin: 0px !important; + border-radius: 0 !important; + margin: 0 !important; } +/* 文章底部推荐 */ .relatedPosts > .relatedPosts-list > div:hover .cover { transform: scale(1); opacity: 0; @@ -11427,8 +13091,8 @@ button.el-button.tk-cancel.el-button--default.el-button--small { @media screen and (min-width: 1300px) { #pagination.pagination-post { - border-radius: 0px; - margin-top: 0px; + border-radius: 0; + margin-top: 0; } } @@ -11441,7 +13105,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .post-reward { - margin-top: 0px; + margin-top: 0rem; display: flex; justify-content: center; } @@ -11456,22 +13120,22 @@ button.el-button.tk-cancel.el-button--default.el-button--small { @media screen and (min-width: 768px) { .post-reward:hover > .reward-main { - justify-content: left; display: flex !important; + justify-content: left; } } @media screen and (max-width: 768px) { .post-reward .reward-main { + justify-content: center !important; position: fixed; - bottom: 0px; - left: 0px; - right: 0px; + bottom: 0; + left: 0; + right: 0; z-index: 102; width: 100%; margin: auto; - padding: 0px; - justify-content: center !important; + padding: 0; } .post-reward .reward-main .reward-all { @@ -11479,12 +13143,12 @@ button.el-button.tk-cancel.el-button--default.el-button--small { display: flex; flex-wrap: wrap; justify-content: space-around; - padding: 30px 0px 60px; - border-radius: 12px 12px 0px 0px; + padding: 30px 0 60px 0; + border-radius: 12px 12px 0 0; } #post .tag_share .post-meta__tags { - margin: 0px 0.5rem 0px 0px; + margin: 0 0.5rem 0 0; } a.reward-main-btn { @@ -11492,7 +13156,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .tk-meta-input .el-input .el-input-group__prepend { - padding: 0px 0.3rem !important; + padding: 0 0.3rem !important; } .tk-meta-input { @@ -11503,17 +13167,18 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .tk-meta-input .el-input { - margin-bottom: 8px; margin-left: 0px !important; width: 100% !important; + margin-bottom: 8px; } .tk-icon { position: absolute; - right: 0px; + right: 0; } } +/* 捐助工具栏 */ .post-tools-left { white-space: nowrap; display: flex; @@ -11523,7 +13188,8 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .post-tools-right { - overflow: overlay scroll; + overflow: scroll; + overflow-x: overlay; padding-right: 0px; display: flex; align-items: center; @@ -11531,6 +13197,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } @media screen and (max-width: 768px) { + .post-tools-left > div { margin: 8px; } @@ -11551,7 +13218,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } } -.post-reward .reward-main .reward-all::after { +.post-reward .reward-main .reward-all:after { display: none; } @@ -11581,7 +13248,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { color: var(--heo-fontcolor); border-radius: 8px; cursor: pointer; - transition: all 0.3s ease 0s; + transition: 0.3s; width: 56px; height: 40px; } @@ -11621,7 +13288,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { background: var(--heo-theme); border-color: var(--heo-theme); color: var(--heo-white); - transition: all 0.3s ease 0s; + transition: 0.3s; box-shadow: var(--heo-shadow-blue); } @@ -11650,7 +13317,7 @@ button.el-button.tk-cancel.el-button--default.el-button--small { padding: 12px; border-radius: 12px; background: var(--heo-background); - animation: 0.3s ease 0.1s 1 normal both running donate_effcet; + animation: donate_effcet 0.3s 0.1s ease both; flex-direction: column; border: var(--style-border-always); } @@ -11688,12 +13355,53 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } } +/* 代码高亮 */ +/*#article-container figure.highlight {*/ +/* border-radius: 8px 8px 4px 4px;*/ +/*}*/ + +/*#article-container figure.highlight,*/ +/*#article-container pre {*/ +/* color: #f8f8f2;*/ +/* background: #696969*/ +/*}*/ + +/*#article-container figure.highlight .highlight-tools {*/ +/* background: #3f3f3f;*/ +/* color: var(--heo-fontcolor);*/ +/*}*/ + +/*#article-container figure.highlight .gutter pre {*/ +/* color: #d3d3d3 !important;*/ +/* background: grey;*/ +/* border-right: var(--style-border-always);*/ +/*}*/ + +/*#article-container figure.highlight figcaption a {*/ +/* color: #a9a9a9 !important*/ +/*}*/ + +/*#article-container pre,*/ +/*#article-container .highlight:not(.js-file-line-container) {*/ +/* background-color: var(--heo-card-bg) !important;*/ +/* color: var(--heo-fontcolor);*/ +/* box-shadow: var(--heo-shadow-border);*/ +/* border: var(--style-border-always);*/ +/*}*/ + +/*#article-container figure.highlight pre span::selection {*/ +/* background: var(--heo-main) !important;*/ +/* color: var(--heo-white) !important;*/ +/*}*/ + +/* 表情窗口owo */ .OwO .OwO-body { - overflow: hidden; - backdrop-filter: saturate(180%) blur(10px); border: var(--style-border-always) !important; border-radius: 8px !important; + overflow: hidden; background-color: var(--heo-maskbg) !important; + backdrop-filter: saturate(180%) blur(10px); + -webkit-backdrop-filter: blur(10px); } .OwO .OwO-body .OwO-bar { @@ -11701,8 +13409,8 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .OwO .OwO-body .OwO-items .OwO-item:hover { - border-radius: 8px; box-shadow: var(--heo-shadow-lightblack) !important; + border-radius: 8px; } #twikoo > div.tk-comments > div.tk-submit > div.tk-row.actions > div > div.tk-action-icon.OwO.OwO-open > div.OwO-body > div > ul > li > span { @@ -11711,14 +13419,14 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .OwO .OwO-body .OwO-bar .OwO-packages li { + margin-right: 0px !important; width: 50px; height: 48px; - transition: all 0.3s ease 0s; - margin-right: 0px !important; + transition: 0.3s; } .OwO .OwO-body .OwO-bar .OwO-packages li:hover { - transition: all 0.3s ease 0s; + transition: 0.3s; } .OwO-packages { @@ -11731,10 +13439,13 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } .OwO .OwO-body .OwO-items-show { - min-height: 197px; margin: 12px 8px !important; + min-height: 197px; } +/* 文章列表页 */ +/* ---------------------------------------------------------------- */ +/* 标题 */ #page .category-lists .category-title { display: none; } @@ -11751,17 +13462,19 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } #page { - background: 0px 0px; + background: none; border: none; - padding: 0px; + padding: 0; } +/* 图片 */ + .article-sort .article-sort-item .article-sort-item-img { border-radius: 12px; min-width: 151px; min-height: 80px; background: var(--heo-secondbg); - -webkit-mask-image: -webkit-radial-gradient(center center, rgb(255, 255, 255), rgb(0, 0, 0)); + -webkit-mask-image: -webkit-radial-gradient(center, rgb(255, 255, 255), rgb(0, 0, 0)); } @media screen and (max-width: 768px) { @@ -11770,6 +13483,8 @@ button.el-button.tk-cancel.el-button--default.el-button--small { } } +/* 标签列表页 */ + #post .tag_share .post-meta__tag-list { display: flex; } @@ -11779,35 +13494,35 @@ button.el-button.tk-cancel.el-button--default.el-button--small { display: flex; overflow: scroll; position: absolute; - left: 0px; - padding: 0px 20px; + left: 0; + padding: 0 20px 0 20px; width: 100%; } } #page .tag-cloud-list a { - padding: 0.2em 0.5em; - background: var(--heo-secondbg); - margin: 0.5em; - border-radius: 12px; - backface-visibility: hidden; - transform-style: preserve-3d; - border: var(--style-border-always); - box-shadow: var(--heo-shadow-border); color: var(--heo-fontcolor) !important; font-size: 1.4em !important; + padding: 0.2em .5em; + background: var(--heo-secondbg); + margin: .5em .5em; + border-radius: 12px; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; + border: var(--style-border-always); + box-shadow: var(--heo-shadow-border); } #page .tag-cloud-list a:hover { - box-shadow: var(--heo-shadow-blue); - border: var(--style-border-hover); background: var(--heo-blue) !important; + box-shadow: var(--heo-shadow-blue); color: var(--heo-white) !important; + border: var(--style-border-hover); } span.tagsPageCount { background: var(--heo-card-bg); - padding: 4px; + padding: 4px 4px; border-radius: 8px; color: var(--heo-secondtext); line-height: 1; @@ -11821,8 +13536,8 @@ span.tagsPageCount { color: var(--heo-lighttext); } -#post .tag_share .post-meta__tags span.tagsPageCount, -#tag-page-tags .tagsPageCount { +#tag-page-tags .tagsPageCount, +#post .tag_share .post-meta__tags span.tagsPageCount { padding: 2px 4px; background: var(--heo-secondbg); border: var(--style-border-always); @@ -11835,8 +13550,8 @@ span.tagsPageCount { margin-left: 4px; } -#post .tag_share .post-meta__tags:hover span.tagsPageCount, -#tag #tag-page-tags a:hover .tagsPageCount { +#tag #tag-page-tags a:hover .tagsPageCount, +#post .tag_share .post-meta__tags:hover span.tagsPageCount { background: var(--heo-card-bg); color: var(--heo-lighttext); } @@ -11850,16 +13565,22 @@ span.tags-punctuation { opacity: 0.4; } +/* page标题 */ #article-container h1 { - padding-left: 0px; + padding-left: 0rem; } -#article-container h1::before { +#article-container h1:before { display: none; } #article-container h1:hover { - padding-left: 0px; + padding-left: 0rem; +} + +/* 分类页 */ +#article-container > div > figure > figcaption > p { + margin: 0; } #page .category-lists ul li::before { @@ -11867,13 +13588,16 @@ span.tags-punctuation { } #page .category-lists ul li { - margin: 0px 8px 8px 0px; + margin: 0; + margin-right: 8px; + margin-bottom: 8px; } #page .category-lists ul { display: flex; - padding: 0px; - flex-flow: row wrap; + padding: 0; + flex-wrap: wrap; + flex-direction: row; } #page .category-lists ul li { @@ -11884,52 +13608,66 @@ span.tags-punctuation { border: var(--style-border-always); } +/* 分类圆角 */ +figure.gallery-group { + border-radius: 12px; +} + +/* 分类分割线隐藏 */ +figure.gallery-group:hover .gallery-group-name::after { + display: none; +} + +/* 标签详情页标题 */ .tag-cloud-title { display: none; } .tk-replies .tk-content { - margin-top: 0px !important; + margin-top: 0rem !important; } #tag #tag-page-tags { display: flex; - flex-flow: row wrap; - margin: 0px -0.75rem 0.5rem; + flex-direction: row; + flex-wrap: wrap; + margin: 0 -0.75rem; + margin-bottom: 0.5rem; } #tag #tag-page-tags a { padding: 0.1rem 0.5rem; - margin: 0.25rem; + margin: 0.25rem 0.25rem; line-height: 1.6; border-radius: 8px; + color: var(--heo-fontcolor) !important; border: var(--style-border-always); display: flex; align-items: center; - color: var(--heo-fontcolor) !important; } #tag #tag-page-tags a.select { + color: var(--heo-white) !important; background: var(--heo-theme); box-shadow: var(--heo-shadow-theme); - color: var(--heo-white) !important; } #tag #tag-page-tags a:hover { + color: var(--heo-white) !important; background: var(--heo-theme); box-shadow: var(--heo-shadow-theme); - color: var(--heo-white) !important; } -.article-sort-item::before { +/* 时间线 */ +.article-sort-item:before { display: none; } -.article-sort-title::before { +.article-sort-title:before { display: none; } -.article-sort-title::after { +.article-sort-title:after { display: none; } @@ -11938,18 +13676,18 @@ span.tags-punctuation { } .article-sort { - margin-left: 0px; - padding-left: 0px; + margin-left: 0; + padding-left: 0; } .article-sort-title { - margin-left: 0px; - padding-bottom: 0px; - padding-left: 0px; + margin-left: 0; + padding-bottom: 0; + padding-left: 0; } .article-sort-item { - margin: 0px 0px 1rem; + margin: 0 0 1rem 0rem; overflow: hidden; border-radius: 12px; } @@ -11971,12 +13709,13 @@ span.tags-punctuation { } .article-sort-title { - font-weight: 700; + font-weight: bold; font-size: 2em; } +/* 文章列表 */ .article-sort-item-info { - padding: 0px 0.8rem; + padding: 0 0.8rem; display: flex; flex-direction: column; } @@ -11989,7 +13728,7 @@ span.tags-punctuation { .article-sort-item-title { order: 0; - font-weight: 700; + font-weight: bold; } .article-sort-item-title:hover { @@ -11997,6 +13736,9 @@ span.tags-punctuation { color: var(--heo-hovertext); } +/* 友情链接页面 */ +/* ---------------------------------------------------------------- */ +/* 随机文章 */ #random-post { min-height: 32px; background: var(--card-bg); @@ -12012,7 +13754,7 @@ span.tags-punctuation { border-bottom: 2px solid var(--heo-lighttext); color: var(--heo-fontcolor); font-weight: 700; - padding: 0px 4px; + padding: 0 4px; } .random-friends-post:hover { @@ -12032,19 +13774,21 @@ span.tags-punctuation { color: var(--heo-hovertext); } +/* 炙焰友链间距 */ .flink#article-container .flink-list { - padding: 0px; - margin: 1rem -6px 0px; + padding: 0; + margin: 1rem -6px 0 -6px; overflow-x: hidden; } .flink#article-container .flink-desc { - margin: 0px; + margin: 0; } +/* 友情描述 */ .flink#article-container .flink-list > .flink-list-item a .flink-item-desc { white-space: normal; - padding: 5px 10px 16px 0px; + padding: 5px 10px 16px 0; color: var(--heo-fontcolor); text-align: left; height: 40px; @@ -12060,6 +13804,7 @@ span.tags-punctuation { color: var(--heo-white); } +/* 友链标题 */ .flink-list-item .flink-item-info { max-width: 136px; overflow: hidden; @@ -12085,41 +13830,47 @@ span.tags-punctuation { } .flink#article-container .flink-list > .flink-list-item a:hover { - background: 0px 0px; + background: none; } +/* 友链头像 */ .flink#article-container .flink-list > .flink-list-item a img { border-radius: 32px; margin: 15px 20px 15px 15px; - transition: all 0.3s ease 0s; + transition: 0.3s; background: var(--heo-background); min-width: 60px; min-height: 60px; } +/* 悬浮状态头像 */ .flink#article-container .flink-list > .flink-list-item:hover a img { - transition: all 0.6s ease 0s; - width: 0px; - height: 0px; + transition: 0.6s; + width: 0; + height: 0; opacity: 0; margin: 0.5rem; min-width: 0px; min-height: 0px; } +/* 标题和描述 */ .flink#article-container .flink-list > .flink-list-item a span { - transition: all 0.3s ease 0s; + transition: 0.3s; } +/* 友链描述 */ .flink#article-container .flink-list > .flink-list-item:hover a .flink-item-desc { overflow: inherit; width: 100%; } +/* 修改初始动画 */ .flink#article-container .flink-list > .flink-list-item { - margin: 6px; - transition: all 0.3s ease-in-out 0s; + margin: 6px 6px; + transition: 0.3s; border-radius: 12px; + transition-timing-function: ease-in-out; position: relative; width: calc(20% - 12px); border: var(--style-border); @@ -12127,6 +13878,7 @@ span.tags-punctuation { background: var(--heo-card-bg); } + .flink#article-container .flink-list > .flink-list-item:hover { transform: scale(1); background: var(--heo-theme); @@ -12148,6 +13900,10 @@ span.tags-punctuation { line-height: 1.5 !important; } +/* 超级博主友链 */ + +/* 超级博主标题 */ + .flink#article-container .site-card .info .title { color: var(--heo-fontcolor); text-align: left; @@ -12168,11 +13924,13 @@ span.tags-punctuation { align-items: flex-start; } + +/* 超级博主描述 */ .flink#article-container .site-card .info .desc { font-size: 0.7rem; color: var(--heo-fontcolor); opacity: 0.7; - transition: all 0.3s ease 0s; + transition: 0.3s; text-align: left; } @@ -12181,23 +13939,25 @@ span.tags-punctuation { } .flink#article-container .site-card:hover .info .desc { - transition: all 0.3s ease 0s; + transition: 0.3s; color: var(--heo-white); - width: 100%; + width: 100% } .flink#article-container .site-card:hover .info { background: var(--heo-theme); } +/* 背景 */ .flink#article-container .site-card { border: var(--style-border); border-radius: 12px; - transition: all 0.3s ease-in-out 0s; + transition: 0.3s; + transition-timing-function: ease-in-out; overflow: hidden; height: 200px; position: relative; - width: calc(14.2857% - 16px); + width: calc(100% / 7 - 16px); background: var(--heo-card-bg); box-shadow: var(--heo-shadow-border); } @@ -12208,25 +13968,32 @@ span.tags-punctuation { } .flink#article-container .site-card:active { + transition: 0.95; } } .site-card-tag { position: absolute; - top: 0px; - left: 0px; + top: 0; + left: 0; padding: 4px 8px; background-color: var(--heo-main); box-shadow: var(--heo-shadow-main); color: var(--heo-white); z-index: 1; - border-radius: 12px 0px; - transition: all 0.3s ease 0s; + border-radius: 12px 0 12px 0; + transition: 0.3s; font-size: 0.6rem; } .site-card-tag.vip { - background: linear-gradient(38deg, rgb(229, 176, 133) 0px, rgb(212, 143, 22) 100%); + /*! Edit and share this gradient: https://html5kit.com/gradient-editor/?preset=d48f16,100;e5b085,0 */ + background: -moz-linear-gradient(38deg, rgba(229, 176, 133, 1) 0%, rgba(212, 143, 22, 1) 100%); + /* FF3.6+ */ + background: -webkit-linear-gradient(38deg, rgba(229, 176, 133, 1) 0%, rgba(212, 143, 22, 1) 100%); + /* Chrome10-25, Safari5.1-6 */ + background: linear-gradient(38deg, rgba(229, 176, 133, 1) 0%, rgba(212, 143, 22, 1) 100%); + /* W3C, IE10+, Firefox16+, Chrome26+, Opera12+, Safari7+ */ overflow: hidden; box-shadow: var(--heo-shadow-yellow); } @@ -12234,21 +14001,31 @@ span.tags-punctuation { .light { cursor: pointer; position: absolute; - top: 0px; + top: 0; width: 100px; height: 50px; + background-image: -moz-linear-gradient(0deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0)); background-image: -webkit-linear-gradient(0deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0)); - animation: 4s ease 0s infinite normal both running light_tag; + -webkit-animation: light_tag 4s both infinite; + -moz-animation: light_tag 4s both infinite; + -ms-animation: light_tag 4s both infinite; + animation: light_tag 4s both infinite; } @keyframes light_tag { 0% { - transform: skewX(0deg); + transform: skewx(0deg); + -o-transform: skewx(0deg); + -moz-transform: skewx(0deg); + -webkit-transform: skewx(0deg); left: -150px; } 99% { - transform: skewX(-25deg); + transform: skewx(-25deg); + -o-transform: skewx(-25deg); + -moz-transform: skewx(-25deg); + -webkit-transform: skewx(-25deg); left: 50px; } } @@ -12262,6 +14039,7 @@ span.tags-punctuation { left: -50px; } + .flink-list-item:hover .site-card-tag { left: -50px; } @@ -12272,14 +14050,15 @@ span.tags-punctuation { padding: 0.5rem; width: 100%; height: 90px; - margin: 0px; - border-radius: 0px 0px 12px 12px; + margin: 0; + border-radius: 0 0 12px 12px; } +/* 修复图片圆角 */ .flink#article-container .site-card .img img { - border-radius: 12px 12px 0px 0px; + border-radius: 12px 12px 0 0; transform: scale(1.03); - transition: all 0.3s ease 0s; + transition: 0.3s; } @media screen and (min-width: 769px) { @@ -12293,37 +14072,42 @@ span.tags-punctuation { } } + .flink#article-container .site-card .img { - -webkit-mask-image: -webkit-radial-gradient(center center, rgb(255, 255, 255), rgb(0, 0, 0)); - border-radius: 12px 12px 0px 0px; + -webkit-mask-image: -webkit-radial-gradient(center, rgb(255, 255, 255), rgb(0, 0, 0)); + border-radius: 12px 12px 0 0; height: 120px; width: 100%; display: flex; border: none; - padding: 0px !important; + padding: 0 !important; } + +/* 头像 */ .flink#article-container .site-card .info img { border-radius: 32px; - margin: 2px 8px 0px 0px; + transition: 0.3s !important; + margin: 2px 8px 0 0; width: 20px; height: 20px; min-width: 20px; min-height: 20px; background: var(--heo-secondbg); - transition: all 0.3s ease 0s !important; } + +/* 边距 */ .flink#article-container .site-card-group { - padding: 20px 0px; + padding: 20px 0; } .flink#article-container .site-card:hover .info img { - width: 0px; - height: 0px; + width: 0; + height: 0; opacity: 0; - min-width: 0px; - min-height: 0px; + min-width: 0; + min-height: 0; } .flink#article-container .site-card:hover { @@ -12331,12 +14115,15 @@ span.tags-punctuation { box-shadow: var(--heo-shadow-main); } +/* 友链文章 */ .article-sort-item-info a { margin-right: auto; overflow: hidden; text-overflow: ellipsis; } +/* 新页脚 */ + @media screen and (max-width: 768px) { #letlink { flex-direction: column !important; @@ -12354,30 +14141,31 @@ span.tags-punctuation { .footer-banner-right { display: flex; - flex-flow: row wrap; + flex-direction: row; + flex-wrap: wrap; } #footer-wrap { display: flex; flex-wrap: wrap; justify-content: space-around; - padding: 20px 50px 0px; + padding: 20px 50px 0px 50px; + text-align: left !important; max-width: 1200px; margin: 0px auto; - text-align: left !important; } #footer-wrap h1 { font-size: 1.5rem; - margin: 0px; + margin: 0; } #footer-wrap h3 { - padding: 0px 12px; + padding: 0 12px; } #footer-wrap p { - margin: 0px 0px 0px 0.2rem; + margin: 0 0 0 0.2rem; font-size: 0.8rem; opacity: 0.8; } @@ -12392,8 +14180,9 @@ span.tags-punctuation { #footer-wrap #letlogo { display: flex; flex-direction: column; + margin-right: 60px; align-self: center; - margin: auto 0px; + margin: auto 0; max-width: 200px; } @@ -12408,7 +14197,7 @@ span.tags-punctuation { display: flex; flex-direction: row; justify-content: space-around; - margin: 0px 0px 1rem; + margin: 0 0 1rem 0; } #weblogo i { @@ -12417,19 +14206,16 @@ span.tags-punctuation { letter-spacing: -10px; } -#footer::before { - z-index: -1; +/* 页脚底层背景 */ +#footer:before { position: absolute !important; width: 100% !important; height: 100% !important; - content: "" !important; -} - -.weixin:hover::after { - transform: scale(1); - opacity: 1; + content: '' !important; + z-index: -1; } +/* 404页面 */ #error-wrap { top: 40%; } @@ -12439,14 +14225,15 @@ span.tags-punctuation { } #error-wrap .error-content { - border-radius: 12px; box-shadow: none !important; + border-radius: 12px; background: var(--heo-card-bg) !important; } #body-wrap.error .aside-list { display: flex; - flex-flow: row nowrap; + flex-direction: row; + flex-wrap: nowrap; bottom: 0px; position: absolute; padding: 1rem; @@ -12456,9 +14243,10 @@ span.tags-punctuation { #body-wrap.error .aside-list .aside-list-group { display: flex; - flex-flow: row nowrap; + flex-direction: row; + flex-wrap: nowrap; max-width: 1200px; - margin: 0px auto; + margin: 0 auto; } #body-wrap.error .aside-list .aside-list-item { @@ -12485,8 +14273,9 @@ span.tags-punctuation { display: -webkit-box; -webkit-box-orient: vertical; line-height: 1.5; - place-content: center; + justify-content: center; align-items: flex-end; + align-content: center; padding-top: 0.5rem; } @@ -12494,25 +14283,354 @@ span.tags-punctuation { display: none; } +/* 瞬间 */ +#comment .timeline #waterfall { + opacity: 0; + transition: 0.3s; +} + +#comment .timeline #waterfall.show { + opacity: 1; +} + +#comment .timeline ul li.item { + position: relative; + width: 32%; + border: var(--style-border-always); + border-radius: 12px; + padding: 1rem; + padding-bottom: 0.5rem; + transition: 0.3s; + display: flex; + flex-direction: column; + flex-wrap: nowrap; + justify-content: space-between; + align-items: flex-start; + background: var(--heo-card-bg); + box-shadow: var(--heo-shadow-border); + margin-right: 2%; +} + +#comment .timeline ul li.item hr { + display: flex; + position: relative; + margin: 8px 0; + border: 1px dashed var(--heo-theme-op); + width: 100%; +} + +@media screen and (max-width: 768px) { + #comment .timeline ul li.item { + padding: 0; + } +} + +#comment .timeline ul li.item:hover { + border: var(--style-border-hover); +} + +#comment ul.list { + display: flex; + flex-direction: row; + flex-wrap: wrap; + justify-content: space-between; +} + +#comment li.item { + display: flex; + flex-direction: column; + flex-wrap: nowrap; + align-items: flex-start; +} + + +@media screen and (max-width: 1300px) { + #comment .timeline ul li.item { + width: 49%; + margin-right: 1%; + } +} + + +@media screen and (max-width: 768px) { + #comment .timeline ul li.item { + width: 100%; + margin-right: 0; + } + + #comment .timeline ul li.item { + padding: 16px 20px; + } +} + +.timeline ul .list { + display: flex; + flex-direction: row; + flex-wrap: wrap; + justify-content: space-between; +} + +/* 标题 */ +.bb-info { + display: inline; + float: right; + line-height: 1; + color: var(--heo-secondtext); + margin-left: auto; + margin-bottom: 1rem; + margin-right: 0.5rem; +} + +.bb-info:hover { + color: var(--heo-hovertext); +} + +#comment { + margin-top: 1rem; + width: 100%; +} + +/* 每条动态 */ +#comment div.bber-content { + display: flex; + flex-direction: initial; + flex-wrap: wrap; + border-radius: 12px; + width: 100%; + height: 100%; +} + +#comment > section > ul > li.item { + margin-bottom: 1rem; +} + +#comment .bber-info { + display: flex; + align-items: center; +} + +#comment .bber-info .fa-rectangles-mixed { + margin-right: 8px; +} + +#comment .bber-content-link { + display: flex; + margin-left: 0.5rem; + color: var(--heo-secondtext); + font-size: 0.7rem; + align-items: center; + background-color: rgba(245, 108, 108, 0.13); + color: #f56c6c; + padding: 0 8px; + border-radius: 20px; +} + +#comment .bber-content-link:hover { + background-color: var(--heo-main); + color: var(--heo-white); +} + +#comment .bber-content-link i { + margin-right: 3px; +} + +#comment .bber-reply { + cursor: pointer; + padding: 0 4px; +} + +#comment .bber-bottom { + display: flex; + justify-content: space-between; + width: 100%; +} + +#comment .count { + color: var(--heo-secondtext); + font-size: 0.8rem; +} + +#comment p { + margin: 0; +} + +#comment .datafrom i { + margin-right: 4px; +} + +/* 音乐 */ +#comment .bber-music { + width: 100%; + height: 90px; + margin: 0.5rem 0; + border-radius: 8px; + overflow: hidden; + border: var(--style-border-always); + background: var(--heo-secondbg); +} + +#comment .aplayer { + margin: 0; +} + +#comment .aplayer .aplayer-info .aplayer-music .aplayer-title { + font-size: 0.8rem; + font-weight: bold; + margin: 0; + color: var(--heo-black); +} + +#comment .aplayer.aplayer-withlrc .aplayer-pic { + height: 82px; + width: 82px; + margin: 4px; + border-radius: 4px; +} + +#comment .aplayer .aplayer-info .aplayer-music { + height: 23px; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap { + padding: 0; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar { + background: var(--heo-gray); + height: 8px; + border-radius: 12px; + transition: 0.3s; + overflow: hidden; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap:hover .aplayer-bar { + height: 12px; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-played { + height: 100%; + border-radius: 12px; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-loaded { + height: 100%; + border-radius: 12px; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-bar-wrap .aplayer-bar .aplayer-played .aplayer-thumb { + display: none; +} + +#comment .aplayer .aplayer-info .aplayer-controller { + align-items: center; +} + +#comment .aplayer .aplayer-info .aplayer-controller .aplayer-time { + position: initial; +} + +#comment .bber-music .aplayer-lrc { + display: none; +} + +/* 只能展示30条的提示 */ +#comment-tips { + font-size: 14px; + display: flex; + justify-content: center; + margin-top: 1rem; +} + +/* 图片 */ + +#comment .bber-content-img img { + object-fit: cover; + max-height: 100%; + border-radius: 12px; +} + +#comment .bber-content-img { + height: 100px; + margin: auto; + margin-top: 0.2rem; + margin-bottom: 0.3rem; + margin-left: 0; + border-radius: 12px; + overflow: hidden; + display: flex; + position: relative; +} + +/* 时间 */ + +#comment > section > ul > li > div .bber-info-time { + color: var(--heo-fontcolor); + font-size: 0.7rem; + background-color: var(--heo-gray-op); + padding: 0 8px; + border-radius: 20px; + cursor: default; + display: flex; + align-items: center; +} + +#comment > section > ul > li > div .bber-info-time i { + margin-right: 8px; +} + +/* 内容 */ +#comment .bber-content .datacont { + order: 0; + font-size: 0.8rem; + font-weight: bold; + color: var(--heo-fontcolor); + width: 100%; + line-height: 1.38; + border-radius: 12px; + margin-bottom: 0.5rem; + display: flex; + flex-direction: column; + text-align: justify; +} + +/* 设备 */ +#comment > section > ul > li > div .datafrom { + order: 2; + color: var(--heo-secondtext); + font-size: 0.7rem; + margin-left: 8px; +} + +#comment > section > ul > li > div .datafrom small { + font-size: 0.7rem; +} + +/* 加载更多 */ .load-btn.button-load { background: var(--heo-card-btn-bg); color: var(--heo-fontcolor); - padding: 12px; - margin: 1.5rem 0px 0px; + padding: 12px 12px; + margin: 1.5rem 0 0 0; width: 100%; text-align: center; border-radius: 12px; - transition: all 0.3s ease 0s; - font-weight: 700; + transition: 0.3s; + font-weight: bold; } .load-btn.button-load:hover { background: var(--heo-blue); color: var(--heo-white); - transition: all 0.3s ease 0s; + transition: 0.3s; box-shadow: var(--heo-shadow-blue); } +/* 友链朋友圈 */ + +#hexo-circle-of-friends-root { + margin: 0 -8px; +} + .moments-list { display: flex; flex-direction: column; @@ -12542,12 +14660,12 @@ span.tags-punctuation { border-radius: 32px; overflow: hidden; background: var(--heo-secondbg); - padding: 0px !important; + padding: 0 !important; } .friendlink-avatar:hover { - background: var(--heo-secondbg); border-radius: 32px !important; + background: var(--heo-secondbg); } .moments-list .article-sort-item-info .article-sort-item-title { @@ -12558,24 +14676,44 @@ span.tags-punctuation { color: var(--heo-hovertext); } +a.bb-link { + margin-left: 8px; + color: var(--heo-secondtext) !important; + display: inline; + border: none !important; +} + +a.bb-link-info { + display: inline; + float: right; + border: none !important; + color: var(--heo-secondtext) !important; + line-height: 2.7rem; +} + +a.bb-link-info:hover { + color: var(--heo-fontcolor) !important; + background: none !important; +} + #friend_link_moments { border: none !important; } .moments-article-img { height: 100%; - margin: 0px !important; + margin: 0 !important; } .tab-item-content #moments_container .moments-item a { border-bottom: none; - padding: 0px; + padding: 0; margin-right: auto; width: auto; } .tab-item-content #moments_container .moments-item a:hover { - background: 0px 0px; + background: none; color: var(--heo-lighttext); box-shadow: none; } @@ -12584,8 +14722,10 @@ span.tags-punctuation { display: none; } +/* 朋友圈页面 */ + #friend_moments_list .moments-sort-item { - margin: 1rem 0px; + margin: 1rem 0; } .moments-sort-item-img { @@ -12599,12 +14739,12 @@ span.tags-punctuation { .moments-sort-item-title { color: var(--heo-lighttext); border-bottom: none !important; - padding: 0px !important; + padding: 0 !important; } .moments-sort-item-title:hover { color: var(--heo-hovertext) !important; - background: 0px 0px !important; + background: none !important; box-shadow: none !important; } @@ -12613,21 +14753,21 @@ span.tags-punctuation { } .moments_load_button { - transition: all 0.3s ease 0s; - width: 100%; - margin-top: 1rem; - margin-bottom: 1rem; color: var(--heo-fontcolor) !important; background: var(--heo-card-btn-bg) !important; padding: 12px 16px !important; border-radius: 12px !important; - border: 0px !important; + transition: 0.3s; + width: 100%; + margin-top: 1rem; + margin-bottom: 1rem; + border: 0 !important; } .moments_load_button:hover { - transition: all 0.3s ease 0s; color: var(--heo-white) !important; background: var(--heo-main) !important; + transition: 0.3s; } .moments-item-title { @@ -12635,10 +14775,10 @@ span.tags-punctuation { font-size: 1rem; order: 0; width: 100%; - font-weight: 700; + font-weight: bold; + -webkit-line-clamp: 1 !important; overflow: hidden; -webkit-box-orient: vertical; - -webkit-line-clamp: 1 !important; } .moments-item-info { @@ -12656,32 +14796,32 @@ span.tags-punctuation { .chart { align-items: flex-start; - flex: 1 1 0%; + flex: 1; width: 100px; height: 60px; margin: 20px; } .moments-item-title { - font-weight: 700; + font-weight: bold; } .moments_post_info_number { - float: right; + float: right } @media screen and (max-width: 500px) { #info_user_pool { padding: 10px; flex-direction: column; - max-height: 200px; + max-height: 200px } .chart { - flex: 0 1 0%; + flex: 0; width: 100%; height: 160px; - margin: 0px; + margin: 0; } } @@ -12699,26 +14839,28 @@ span.tags-punctuation { #info_user_pool { background: var(--heo-secondbg); - margin-top: 1rem; border-radius: 12px !important; + margin-top: 1rem; box-shadow: none !important; } .moments-item { - margin-left: 0px !important; + margin-left: 0 !important; box-shadow: none !important; } +/* 豆瓣 */ .hexo-douban-item { + border-bottom: none !important; background: var(--heo-card-bg); + border: var(--style-border); box-shadow: var(--heo-shadow-border); border-radius: 12px; - margin: 8px 0px; + margin: 8px 0; height: 160px; + min-height: 160px !important; width: 49%; overflow: hidden; - border-bottom: none !important; - min-height: 160px !important; } @media screen and (min-width: 1300px) { @@ -12729,12 +14871,13 @@ span.tags-punctuation { #hexo-douban-item3 { display: flex; - flex-flow: row wrap; + flex-direction: row; + flex-wrap: wrap; justify-content: space-between; } .hexo-douban-item .hexo-douban-picture a { - padding: 0px !important; + padding: 0 !important; } .hexo-douban-item .hexo-douban-picture img { @@ -12770,7 +14913,7 @@ span.tags-punctuation { } span.hexo-douban-pagenum { - margin: 0px 0.5rem; + margin: 0 0.5rem; } .hexo-douban-title { @@ -12779,36 +14922,36 @@ span.hexo-douban-pagenum { } .hexo-douban-title a { - padding: 0px !important; + padding: 0 !important; } .hexo-douban-info { - margin-right: 0.5rem; padding-left: 130px !important; + margin-right: 0.5rem; } .hexo-douban-meta { + font-size: 0.7rem !important; color: var(--heo-secondtext); margin-top: 0.3rem; line-height: 1.05; - font-size: 0.7rem !important; } .hexo-douban-comments { line-height: 1.2; margin-top: 0.5rem; + font-size: 0.8rem !important; -webkit-line-clamp: 3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-box-orient: vertical; - font-size: 0.8rem !important; } .hexo-douban-picture { height: 100%; - padding: 10px 0px 10px 10px; - top: 0px !important; + top: 0 !important; + padding: 10px 0 10px 10px; } .hexo-douban-picture a img { @@ -12819,17 +14962,21 @@ span.hexo-douban-pagenum { width: 4rem; height: 2rem; line-height: 1.9rem; + border-radius: 8px !important; background: var(--heo-card-bg); box-shadow: var(--heo-shadow-lightblack); - margin: 0px 0.2rem; - border-radius: 8px !important; + border: var(--style-border); + margin: 0 0.2rem; border-bottom: var(--style-border) !important; } +/* 标签页 */ +/* 隐藏时间 */ .article-sort-item-time { display: none; } +/* 标签 */ .article-sort-item-tags { margin-top: 8px; white-space: nowrap; @@ -12842,14 +14989,15 @@ span.hexo-douban-pagenum { .article-sort-item-tags a { color: var(--heo-fontcolor); - transition: all 0.3s ease 0s; + transition: 0.3s; } .article-sort-item-tags a:hover { color: var(--heo-theme); - transition: all 0.3s ease 0s; + transition: 0.3s; } +/* v3footer */ #heo-footer .footer-links { display: flex; flex-direction: column; @@ -12857,19 +15005,26 @@ span.hexo-douban-pagenum { #heo-footer { display: flex; - flex-flow: row wrap; + flex-direction: row; width: 100%; max-width: 1200px; - margin: 1rem auto 3rem; + margin: 1rem auto; justify-content: space-between; - padding: 0px 1rem; + flex-wrap: wrap; + margin-bottom: 3rem; + padding: 0 1rem; } #heo-footer .footer-item { font-size: 0.8rem; line-height: 0.8rem; - margin: 0.38rem auto 0.38rem 0px; + margin: 0.38rem 0; color: var(--heo-fontcolor); + margin-right: auto; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; + max-width: 120px; } #heo-footer .footer-item:hover { @@ -12880,6 +15035,36 @@ span.hexo-douban-pagenum { min-width: 120px; } +#heo-footer .footer-title-group { + display: flex; + align-items: center; + margin: 1rem 0 0.7rem 0; +} + +#heo-footer .footer-title-group a { + margin-left: 8px; +} + +#heo-footer .footer-title-group i { + line-height: 1; + color: var(--heo-secondtext); + transition: 0.3s; + font-size: 12px; +} + + +#heo-footer .footer-title-group a:hover i { + color: var(--heo-main); +} + +#heo-footer .footer-title-group .footer-title { + margin: 0; +} + +#heo-footer .random-friends-btn { + display: flex; +} + #heo-footer .footer-title { color: var(--heo-secondtext); font-size: 0.8rem; @@ -12893,10 +15078,10 @@ span.hexo-douban-pagenum { display: flex; overflow: hidden; z-index: 1002; - transition: all 0.3s ease 0s; + transition: 0.3s; } -[data-theme="dark"] #footer-banner { +[data-theme=dark] #footer-banner { background: var(--heo-secondbg); } @@ -12905,7 +15090,7 @@ span.hexo-douban-pagenum { justify-content: space-between; max-width: 1400px; width: 100%; - margin: 0px auto; + margin: 0 auto; flex-wrap: wrap; align-items: center; } @@ -12920,12 +15105,12 @@ span.hexo-douban-pagenum { margin-right: 1rem; color: var(--heo-fontcolor); font-size: 0.8rem; - font-weight: 700; + font-weight: bold; white-space: nowrap; } #footer-banner .footer-banner-link.cc { - margin-right: 0px; + margin-right: 0rem; } #footer-banner .footer-banner-link.cc i { @@ -12950,10 +15135,12 @@ span.hexo-douban-pagenum { height: 0.9rem; } +/* about关于页 */ .la-widget.la-data-widget__container { border-radius: 12px; - box-shadow: var(--heo-shadow-border); border: var(--style-border) !important; + box-shadow: var(--heo-shadow-border); + border-color: var(--heo-card-border); } #about-page { @@ -12966,15 +15153,51 @@ span.hexo-douban-pagenum { #about-page .author-img { margin: auto; border-radius: 50%; - overflow: hidden; width: 180px; height: 180px; + position: relative; } +#about-page .author-img img { + border-radius: 200px; +} + +#about-page .author-img::before { + content: ''; + -webkit-transition: 1s; + -moz-transition: 1s; + -o-transition: 1s; + -ms-transition: 1s; + transition: 1s; + width: 30px; + height: 30px; + background: var(--heo-green); + position: absolute; + border-radius: 50%; + border: 5px solid var(--heo-background); + bottom: 5px; + right: 10px; + z-index: 2; +} + +@media screen and (max-width: 768px) { + #about-page .author-img { + width: 120px; + height: 120px; + } + + #about-page .author-img::before { + bottom: -5px; + right: -5px; + } +} + + #about-page .author-title { font-size: 2rem; - font-weight: 700; - margin-top: 1rem; + font-weight: bold; + margin: 1rem 0; + line-height: 1; } .page-title { @@ -12990,6 +15213,8 @@ span.hexo-douban-pagenum { white-space: nowrap; } +/* 一行内容 */ + .author-content { display: flex; flex-wrap: wrap; @@ -12998,6 +15223,8 @@ span.hexo-douban-pagenum { margin-top: 1rem; } +/* 一行内容,纵向组件 */ + .author-content-item-group.column { display: flex; flex-direction: column; @@ -13005,6 +15232,8 @@ span.hexo-douban-pagenum { justify-content: space-between; } +/* 一行内容,横向组件 */ + .author-content-item { width: 49%; border-radius: 24px; @@ -13022,7 +15251,7 @@ span.hexo-douban-pagenum { .author-content-item .author-content-item-title { font-size: 36px; - font-weight: 700; + font-weight: bold; line-height: 1; } @@ -13034,9 +15263,9 @@ span.hexo-douban-pagenum { @media screen and (max-width: 768px) { .author-content-item { + width: 100% !important; margin-top: 1rem; padding: 1rem; - width: 100% !important; } .author-content-item-group.column { @@ -13044,7 +15273,7 @@ span.hexo-douban-pagenum { } .author-content { - margin-top: 0px; + margin-top: 0rem; } } @@ -13052,20 +15281,69 @@ span.hexo-douban-pagenum { font-size: 12rem; opacity: 0.2; position: absolute; - right: 0px; + right: 0; bottom: -40%; transform: rotate(30deg); - transition: all 2s ease-in-out 0s; + transition: 2s ease-in-out; } .author-content-item:hover .card-background-icon { transform: rotate(20deg); } +/* 关于页面打招呼信息 */ + +#about-page .myInfoAndSayHello { + display: flex; + flex-direction: column; + justify-content: center; + color: var(--heo-white); + background: linear-gradient(120deg, rgba(91, 39, 255, 1) 0%, rgba(0, 212, 255, 1) 100%); + background-size: 200%; + animation: gradient 15s ease infinite; + width: 59%; +} + +#about-page .myInfoAndSayHello .title1 { + opacity: 0.8; + line-height: 1.3; +} + +#about-page .myInfoAndSayHello .title2 { + font-size: 36px; + font-weight: bold; + line-height: 1.1; + margin: 0.5rem 0; +} + +.author-content-item-group.column.mapAndInfo { + width: 59%; +} + +/* 关于页面地图 */ + +.author-content-item.map { + background: url(../images/404.gif) no-repeat center; + min-height: 160px; + max-height: 400px; + position: relative; + overflow: hidden; + margin-bottom: 0.5rem; + height: 60%; + background-size: 100%; + transition: 1s ease-in-out; +} + +[data-theme=dark] .author-content-item.map { + background: url(../images/404.gif) no-repeat center; + background-size: 100%; +} + .author-content-item.map:hover { background-size: 120%; - transition: all 4s ease-in-out 0s; - background-position: 0px 36%; + transition: 4s ease-in-out; + background-position-x: 0; + background-position-y: 36%; } .author-content-item.map .map-title { @@ -13076,7 +15354,8 @@ span.hexo-douban-pagenum { background: var(--heo-maskbg); padding: 0.5rem 2rem; backdrop-filter: saturate(180%) blur(20px); - transition: all 1s ease-in-out 0s; + -webkit-backdrop-filter: blur(20px); + transition: 1s ease-in-out; font-size: 20px; } @@ -13085,7 +15364,7 @@ span.hexo-douban-pagenum { } .author-content-item.map .map-title b { - color: var(--font-color); + color: var(--heo-fontcolor); } @media screen and (max-width: 768px) { @@ -13098,6 +15377,8 @@ span.hexo-douban-pagenum { } } +/* 关于页面自我信息 */ + .author-content-item.selfInfo { display: flex; min-height: 100px; @@ -13105,6 +15386,7 @@ span.hexo-douban-pagenum { justify-content: space-between; align-items: center; flex-wrap: wrap; + height: -webkit-fill-available; height: 40%; } @@ -13117,7 +15399,7 @@ span.hexo-douban-pagenum { .author-content-item.selfInfo div { display: flex; flex-direction: column; - margin: 0.5rem 2rem 0.5rem 0px; + margin: 0.5rem 2rem 0.5rem 0; } .author-content-item.selfInfo .selfInfo-title { @@ -13128,11 +15410,13 @@ span.hexo-douban-pagenum { } .author-content-item.selfInfo .selfInfo-content { - font-weight: 700; + font-weight: bold; font-size: 34px; line-height: 1; } +/* 关于页面我的照片 */ + .author-content-item.myphoto { height: 60%; min-height: 240px; @@ -13149,12 +15433,12 @@ span.hexo-douban-pagenum { height: 100%; min-width: 100%; object-fit: cover; - transition: all 0.6s ease 0s; + transition: 0.6s; } .author-content-item.myphoto:hover img { min-width: 105%; - transition: all 2s ease 0s; + transition: 2s; } .author-content-item.myphoto .myphoto-title { @@ -13165,18 +15449,20 @@ span.hexo-douban-pagenum { background: var(--heo-maskbgdeep); padding: 0.5rem 2rem; backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } +/* 关于页面我的生涯图片 */ .author-content-item.careers { min-height: 400px; } .author-content-item.careers img { position: absolute; - left: 0px; + left: 0; bottom: 20px; width: 100%; - transition: all 0.6s ease 0s; + transition: 0.6s; } .author-content-item.careers .careers-group { @@ -13199,6 +15485,8 @@ span.hexo-douban-pagenum { color: var(--heo-secondtext); } +/* 关于页面我的性格 */ + .author-content-item.personalities { overflow: hidden; position: relative; @@ -13207,7 +15495,7 @@ span.hexo-douban-pagenum { .author-content-item.personalities .title2 { font-size: 36px; - font-weight: 700; + font-weight: bold; line-height: 1.1; } @@ -13215,7 +15503,7 @@ span.hexo-douban-pagenum { position: absolute; right: -40px; bottom: -10rem; - transition: transform 2s cubic-bezier(0.13, 0.45, 0.21, 1.02) 0s; + transition: transform 2s cubic-bezier(0.13, 0.45, 0.21, 1.02); } .author-content-item.personalities:hover .image { @@ -13232,9 +15520,11 @@ span.hexo-douban-pagenum { } } +/* 关于页面座右铭 */ + .author-content-item.maxim { font-size: 36px; - font-weight: 700; + font-weight: bold; line-height: 1.1; display: flex; align-items: flex-start; @@ -13254,17 +15544,21 @@ span.hexo-douban-pagenum { margin-bottom: 0.5rem; } +/* 关于页面特长 */ + .author-content-item.buff { + height: 200px; font-size: 36px; - font-weight: 700; + font-weight: bold; line-height: 1.1; display: flex; align-items: flex-start; flex-direction: column; justify-content: center; - background: linear-gradient(120deg, rgb(255, 39, 232) 0px, rgb(255, 128, 0) 100%) 0% 0% / 200%; + background: linear-gradient(120deg, rgba(255, 39, 232, 1) 0%, rgba(255, 128, 0, 1) 100%); color: var(--heo-white); - animation: 15s ease 0s infinite normal none running gradient; + background-size: 200%; + animation: gradient 15s ease infinite; min-height: 200px; height: fit-content; width: 59%; @@ -13287,26 +15581,27 @@ span.hexo-douban-pagenum { margin-bottom: 0.5rem; } +/* 关于页面我的技能 */ .author-content-item.skills { display: flex; justify-content: center; align-items: flex-start; flex-direction: column; - width: 50%; + width: 49%; min-height: 450px; } .author-content-item.skills .tags-group-all { display: flex; transform: rotate(0deg); - transition: all 0.3s ease 0s; + transition: 0.3s; } .author-content-item.skills .tags-group-wrapper { margin-top: 40px; display: flex; flex-wrap: nowrap; - animation: 60s linear 0s infinite normal none running rowup; + animation: rowup 60s linear infinite; } .author-content-item.skills .skills-style-group { @@ -13316,12 +15611,13 @@ span.hexo-douban-pagenum { .author-content-item.skills .skills-list { display: flex; opacity: 0; - transition: all 0.3s ease 0s; + transition: 0.3s; position: absolute; width: 100%; - top: 0px; - left: 0px; - flex-flow: row wrap; + top: 0; + left: 0; + flex-wrap: wrap; + flex-direction: row; margin-top: 10px; } @@ -13366,9 +15662,11 @@ span.hexo-douban-pagenum { } .author-content-item.skills .skill-name { - font-weight: 700; + font-weight: bold; } +/* 关于页面滚动 */ + .author-content-item.aboutsiteTips { display: flex; justify-content: center; @@ -13383,8 +15681,8 @@ span.hexo-douban-pagenum { font-family: Helvetica; line-height: 1.06; letter-spacing: -0.02em; - color: var(--font-color); - margin-top: 0px; + color: var(--heo-fontcolor); + margin-top: 0; } .aboutsiteTips .mask { @@ -13401,6 +15699,7 @@ span.hexo-douban-pagenum { top: 36px; padding-bottom: var(--offset); background-size: 100% 100%; + -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; background-repeat: no-repeat; @@ -13408,51 +15707,56 @@ span.hexo-douban-pagenum { .aboutsiteTips .mask span[data-show] { transform: translateY(-100%); - transition: transform 0.5s ease-in-out 0s; + transition: .5s transform ease-in-out; } .aboutsiteTips .mask span[data-up] { transform: translateY(-200%); - transition: transform 0.5s ease-in-out 0s; + transition: .5s transform ease-in-out; } .aboutsiteTips .mask span:nth-child(1) { - background-image: linear-gradient(45deg, rgb(14, 207, 254) 50%, rgb(7, 166, 241)); + background-image: linear-gradient(45deg, #0ecffe 50%, #07a6f1); } .aboutsiteTips .mask span:nth-child(2) { - background-image: linear-gradient(45deg, rgb(24, 225, 152) 50%, rgb(14, 193, 93)); + background-image: linear-gradient(45deg, #18e198 50%, #0ec15d); } .aboutsiteTips .mask span:nth-child(3) { - background-image: linear-gradient(45deg, rgb(138, 124, 251) 50%, rgb(99, 62, 156)); + background-image: linear-gradient(45deg, #8a7cfb 50%, #633e9c); } .aboutsiteTips .mask span:nth-child(4) { - background-image: linear-gradient(45deg, rgb(250, 118, 113) 50%, rgb(244, 95, 127)); + background-image: linear-gradient(45deg, #fa7671 50%, #f45f7f); } @media screen and (max-width: 768px) { + .author-content-item.map { - margin-bottom: 0px; + margin-bottom: 0; } } +/* 关于51la页面统计 */ + #about-page .about-statistic { min-height: 380px; width: 39%; + background: url(../images/404.gif) no-repeat top; + background-size: cover; color: var(--heo-white); overflow: hidden; } #about-page .about-statistic::after { - box-shadow: rgb(15, 17, 20) 0px -159px 173px 71px inset; + box-shadow: 0 -159px 173px 71px #0f1114 inset; position: absolute; - content: ""; + content: ''; width: 100%; height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; } #statistic { @@ -13462,7 +15766,8 @@ span.hexo-douban-pagenum { color: var(--heo-white); display: flex; justify-content: space-between; - flex-flow: row wrap; + flex-direction: row; + flex-wrap: wrap; margin-top: 1rem; margin-bottom: 2rem; } @@ -13481,45 +15786,51 @@ span.hexo-douban-pagenum { } #statistic div span:last-child { - font-weight: 700; + font-weight: bold; font-size: 34px; line-height: 1; white-space: nowrap; } .author-content-item.about-statistic .card-content .banner-button-group .banner-button:hover { - background: rgb(153, 140, 90); + background: #998c5a; color: var(--heo-white); } +/* 关于页面赞赏 */ + .author-content-item.single.reward .author-content-item .author-content-item-title { color: var(--heo-red); } .author-content-item.single.reward .reward-list-all { display: flex; - flex-flow: row wrap; - margin: 1rem -0.25rem 0.5rem; + flex-wrap: wrap; + flex-direction: row; + margin-top: 1rem; + margin-bottom: 0.5rem; + margin-left: -0.25rem; + margin-right: -0.25rem; } .author-content-item.single.reward .reward-list-all .reward-list-item { padding: 1rem; border-radius: 12px; border: var(--style-border-always); - width: calc(16.6667% - 0.5rem); - margin: 0px 0.25rem 0.5rem; + width: calc((100% / 6) - 0.5rem); + margin: 0rem 0.25rem 0.5rem 0.25rem; box-shadow: var(--heo-shadow-border); } @media screen and (max-width: 1200px) { .author-content-item.single.reward .reward-list-all .reward-list-item { - width: calc(25% - 0.5rem); + width: calc((100% / 4) - 0.5rem); } } @media screen and (max-width: 900px) { .author-content-item.single.reward .reward-list-all .reward-list-item { - width: calc(50% - 0.5rem); + width: calc((100% / 2) - 0.5rem); } } @@ -13536,7 +15847,7 @@ span.hexo-douban-pagenum { .author-content-item.single.reward .reward-list-all .reward-list-item .reward-list-item-name { font-size: 1rem; - font-weight: 700; + font-weight: bold; line-height: 1; margin-bottom: 0.5rem; } @@ -13549,7 +15860,7 @@ span.hexo-douban-pagenum { .author-content-item.single.reward .reward-list-all .reward-list-item .reward-list-item-money { padding: 4px; - background: var(--font-color); + background: var(--heo-fontcolor); color: var(--card-bg); font-size: 12px; line-height: 1; @@ -13583,7 +15894,7 @@ span.hexo-douban-pagenum { display: flex; align-items: center; z-index: 1; - transition: all 0.3s ease 0s; + transition: .3s; cursor: pointer; box-shadow: none; width: fit-content; @@ -13603,7 +15914,10 @@ span.hexo-douban-pagenum { } .author-content-item.single.reward .post-reward .reward-main { - inset: 60px 0px auto auto; + top: 60px; + right: 0; + left: auto; + bottom: auto; width: fit-content; box-shadow: var(--heo-shadow-border); } @@ -13617,12 +15931,22 @@ span.hexo-douban-pagenum { display: none; } +/* 喜欢的游戏 lol */ +.author-content-item.game-lol { + background: url(../images/404.gif) no-repeat top; + background-size: cover; + min-height: 300px; + overflow: hidden; + color: var(--heo-white); + width: 59%; +} + .author-content-item .card-content { position: absolute; width: 100%; height: 100%; - top: 0px; - left: 0px; + top: 0; + left: 0; z-index: 2; display: flex; flex-direction: column; @@ -13635,6 +15959,16 @@ span.hexo-douban-pagenum { } } +.author-content-item.game-lol::after { + box-shadow: 0 -69px 203px 11px #04120f inset; + position: absolute; + content: ''; + width: 100%; + height: 100%; + top: 0; + left: 0; +} + .author-content-item .content-bottom { margin-top: auto; display: flex; @@ -13653,6 +15987,61 @@ span.hexo-douban-pagenum { margin-right: 0.5rem; } +.icon-pos-sup { + background: url(../images/404.gif); +} + +.icon-pos-mid { + background: url(../images/404.gif); +} + +/* 喜欢的游戏 狼人杀 */ +.author-content-item.game-wolf { + width: 39%; + background: url(../images/404.gif) no-repeat top; + background-size: cover; + min-height: 300px; + overflow: hidden; + color: var(--heo-white); +} + +.author-content-item.game-wolf::after { + box-shadow: 0 -69px 203px 11px #415dc9 inset; + position: absolute; + content: ''; + width: 100%; + height: 100%; + top: 0; + left: 0; +} + +/* 关注领域 */ +.author-content-item.like-technology { + background: url(../images/404.gif) no-repeat; + background-size: cover; + min-height: 230px; + color: var(--heo-white); +} + +/* 喜欢音乐 */ +.author-content-item.like-music { + background: url(../images/404.gif) no-repeat top; + background-size: cover; + min-height: 400px; + color: var(--heo-white); + overflow: hidden; +} + +.author-content-item.like-music::after { + box-shadow: 0 -69px 203px 11px #736896 inset; + position: absolute; + content: ''; + width: 100%; + height: 100%; + top: 0; + left: 0; +} + .author-content-item .card-content .author-content-item-title { margin-bottom: 0.5rem; } @@ -13673,9 +16062,10 @@ span.hexo-douban-pagenum { display: flex; align-items: center; z-index: 1; - transition: all 0.3s ease 0s; + transition: .3s; cursor: pointer; backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } .author-content-item .card-content .banner-button-group .banner-button:hover { @@ -13695,14 +16085,14 @@ span.hexo-douban-pagenum { } .author-content-item .card-content .banner-button-group .banner-button { - background: 0px 0px; + background: none; color: var(--heo-white); - padding: 0px; + padding: 0; width: fit-content; } .author-content-item .card-content .banner-button-group .banner-button i { - margin-right: 0px; + margin-right: 0; font-size: 1.5rem; } @@ -13711,17 +16101,112 @@ span.hexo-douban-pagenum { } } +/* 豆瓣电影页面 */ +.author-content-item.single.like-movie { + height: 19rem; + background: url(../images/404.gif) no-repeat top; + background-size: cover; + color: var(--heo-white); + overflow: hidden; +} + +.author-content-item.single.like-movie::after { + box-shadow: 0 21px 133px 81px #1c1c1c inset; + position: absolute; + content: ''; + width: 100%; + height: 100%; + top: 0; + left: 0; +} + +#article-container .author-content-item.single.like-movie .banner-button-group .banner-button { + padding: 8px 12px; + background: var(--heo-white); + border-radius: 12px; + color: var(--heo-black); + display: flex; + align-items: center; + z-index: 1; + transition: 0.3s; + cursor: pointer; + border: none; +} + +#article-container .author-content-item.single.like-movie .banner-button-group .banner-button:hover { + background: #d0b247; + color: var(--heo-white); +} + +#article-container .author-content-item.single.like-movie .banner-button-group .banner-button i { + margin-right: 8px; + font-size: 1rem; +} + +@media screen and (max-width: 768px) { + #article-container .author-content-item.single.like-movie .banner-button-group { + right: 1rem; + bottom: 1rem; + } + + #article-container .author-content-item.single.like-movie .banner-button-group .banner-button { + background: none; + color: var(--heo-white); + padding: 0; + } + + #article-container .author-content-item.single.like-movie .banner-button-group .banner-button i { + margin-right: 0; + font-size: 1.5rem; + } + + #article-container .author-content-item.single.like-movie .banner-button-group .banner-button-text { + display: none; + } +} + +/* 工具推荐 */ +.author-content.author-content-item.toolPage { + height: 19rem; + background: url(../images/404.gif) no-repeat top; + background-size: cover; + color: var(--heo-white); + overflow: hidden; + margin-top: 0; +} + +/* 友链鱼塘 */ +.author-content.author-content-item.momentsPage { + height: 19rem; + background: url(../images/404.gif) no-repeat top; + background-size: cover; + color: var(--heo-white); + overflow: hidden; + margin-top: 0; +} + +/* 即刻短文 */ +.author-content.author-content-item.essayPage { + height: 19rem; + background: url(../images/404.gif) no-repeat center; + background-size: cover; + color: var(--heo-white); + overflow: hidden; + margin-top: 0; +} + +/* 中控台 */ #console { display: flex; position: fixed; width: 100vw; height: 100vh; - top: 0px; - left: 0px; + top: 0; + left: 0; z-index: 9999; justify-content: center; opacity: 0; - transition: all 0.3s ease-out 0s; + transition: 0.3s ease-out; flex-direction: column; align-items: center; pointer-events: none; @@ -13736,15 +16221,49 @@ span.hexo-douban-pagenum { display: flex; justify-content: space-between; align-items: center; - margin: 0px 30px; + margin: 0 30px; max-width: 2000px; + transform: translateY(20px); + transition: 0.3s; + opacity: 0; +} + +#console.show .console-card-group { + transform: translateY(0px); + opacity: 1; + transition-delay: 0.1s; +} + + +#console .console-card-group-left { + margin-right: 0.5rem; + width: 40%; + height: 100%; +} + +#console .console-card-group-right { + display: flex; + flex-direction: column; + justify-content: center; + height: 100%; + width: 60%; + overflow: hidden; } @media screen and (max-width: 1300px) { #console .console-card-group { + justify-content: center; + } + + #console .console-card-group-left { display: none; } + #console .console-card-group-right { + width: 100%; + margin: 0; + } + #consoleMusic { display: none; } @@ -13754,6 +16273,16 @@ span.hexo-douban-pagenum { } } +@media screen and (max-width: 768px) { + #console .console-card-group { + display: none; + } + + #consoleHideAside { + display: none; + } +} + @media screen and (max-height: 800px) { #console .console-card-group { display: none; @@ -13781,37 +16310,25 @@ span.hexo-douban-pagenum { height: calc(100% - 172px); } -#console .console-card-group-left { - margin-right: 0.5rem; - width: 40%; - height: 100%; -} - -#console .console-card-group-right { - display: flex; - flex-direction: column; - justify-content: center; - height: 100%; - width: 60%; - overflow: hidden; -} #console .console-mask { background: var(--heo-maskbgdeep); backdrop-filter: saturate(100%) blur(0px); + -webkit-backdrop-filter: blur(0px); width: 100vw; height: 100vh; - top: 0px; - left: 0px; + top: 0; + left: 0; position: absolute; z-index: -1; - transition: all 0.3s ease 0s; - backface-visibility: hidden; - transform-style: preserve-3d; + transition: 0.3s; + -webkit-backface-visibility: hidden; + -webkit-transform-style: preserve-3d; } #console.show .console-mask { backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); } #card-newest-comments .aside-list-item .thumbnail img { @@ -13843,9 +16360,9 @@ span.hexo-douban-pagenum { } #console .author-content-item-tips { - opacity: 0.8; - font-size: 0.6rem; - margin-bottom: 0.5rem; + opacity: .8; + font-size: .6rem; + margin-bottom: .5rem; } #console .author-content-item-title { @@ -13884,14 +16401,15 @@ span.hexo-douban-pagenum { #console .aside-list { display: flex; - flex-flow: row wrap; + flex-wrap: wrap; + flex-direction: row; justify-content: space-between; margin-top: 1.5rem; } #console .button-group { display: flex; - margin: 1rem auto 0px; + margin: 1rem auto 0 auto; justify-content: center; width: fit-content; } @@ -13899,7 +16417,7 @@ span.hexo-douban-pagenum { #console .button-group .console-btn-item { width: 60px; height: 60px; - transition: all 0.3s ease 0s; + transition: 0.3s; cursor: pointer; } @@ -13920,13 +16438,13 @@ span.hexo-douban-pagenum { display: flex; align-items: center; justify-content: center; - color: var(--font-color); + color: var(--heo-fontcolor); } #console .button-group .console-btn-item.on a { background: var(--heo-orange); color: var(--heo-white); - transition: all 0.3s ease 0s; + transition: 0.3s; } #console .button-group .console-btn-item a:hover { @@ -13944,14 +16462,14 @@ span.hexo-douban-pagenum { } .console-card.tags .card-tag-cloud a { + color: var(--heo-fontcolor) !important; margin: 6px 4px; padding: 2px 8px; border-radius: 8px; background: var(--heo-secondbg); border: var(--style-border); - font-weight: 700; - color: var(--font-color) !important; font-size: 14px !important; + font-weight: bold; } .console-card.tags .card-tag-cloud a:hover { @@ -13964,15 +16482,16 @@ span.hexo-douban-pagenum { } #console .close-btn { - width: 60px; - height: 60px; - position: absolute; - right: 40px; - top: 40px; - font-size: 40px; - color: var(--font-color); + width: 35px; + height: 35px; + position: fixed; + right: 100px; + top: 50px; + font-size: 35px; + color: var(--heo-fontcolor); cursor: pointer; - transition: all 0.3s ease 0s; + transition: 0.3s; + display: flex; } #console .close-btn:hover { @@ -13981,10 +16500,11 @@ span.hexo-douban-pagenum { #console .console-card.history { margin-top: 8px; - padding: 0px; - background: 0px 0px; + padding: 0; + background: none; box-shadow: none; border: none; + overflow: hidden; } #console .console-card.history .item-headline { @@ -13993,8 +16513,9 @@ span.hexo-douban-pagenum { #console .console-card.history .card-archive-list { display: flex; - flex-flow: row wrap; + flex-direction: row; justify-content: space-between; + flex-wrap: wrap; } #console .console-card.history .card-archive-list li.card-archive-list-item { @@ -14003,13 +16524,13 @@ span.hexo-douban-pagenum { #console .console-card.history .card-archive-list .card-archive-list-link { border-radius: 8px; - margin: 4px 0px; + margin: 4px 0; display: flex; flex-direction: column; align-content: space-between; border: var(--style-border); background: var(--card-bg); - padding: 8px; + padding: 8px 16px; } #console .console-card.history .card-archive-list .card-archive-list-link:hover { @@ -14025,6 +16546,7 @@ span.hexo-douban-pagenum { font-size: 1rem; } +/* 快捷键窗口 */ #keyboard-tips { position: fixed; top: 80px; @@ -14037,15 +16559,16 @@ span.hexo-douban-pagenum { display: flex; flex-direction: column; backdrop-filter: saturate(180%) blur(20px); + -webkit-backdrop-filter: blur(20px); pointer-events: none; box-shadow: var(--heo-shadow-border); opacity: 0; - transition: all 0.3s ease 0s; + transition: 0.3s; } #keyboard-tips.show { opacity: 1; - transition: all 0.1s ease 0s; + transition: 0.1s; } #keyboard-tips .keybordList { @@ -14072,71 +16595,21 @@ span.hexo-douban-pagenum { } #keyboard-tips .keyGroup .key { - padding: 0.2em 0.4em; + padding: .2em .4em; font-family: inherit; background-color: var(--card-bg); - color: var(--font-color); + color: var(--heo-fontcolor); + border: var(--style-border); + border-color: var(--heo-secondtext); border-bottom: 2px solid var(--heo-secondtext); box-shadow: var(--heo-shadow-border); - border-radius: 0.25rem; + border-radius: .25rem; overflow-wrap: break-word; overflow-x: auto; font-weight: 500; - font-size: 0.875em; + font-size: .875em; margin-right: 4px; vertical-align: baseline; line-height: 1; height: 24px; -} - -:root { - --heo-main: var(--heo-theme) !important; -} - -:root { - --heo-main-op: var(--heo-theme-op) !important; -} - -:root { - --heo-main-op-deep: var(--heo-theme-op-deep) !important; -} - -:root { - --heo-main-none: var(--heo-theme-none) !important; -} - -:root { - --heo-main: #000000 !important; -} - -:root { - --heo-main-op: #00000023 !important; -} - -:root { - --heo-main-op-deep: #000000dd !important; -} - -:root { - --heo-main-none: #00000000 !important; -} - -:root { - --heo-main: var(--heo-theme) !important; -} - -:root { - --heo-main-op: var(--heo-theme-op) !important; -} - -:root { - --heo-main-op-deep: var(--heo-theme-op-deep) !important; -} - -:root { - --heo-main-none: var(--heo-theme-none) !important; -} - -:root { - --heo-snackbar-time: 3000ms !important; } \ No newline at end of file diff --git a/templates/index.html b/templates/index.html index dd572ef2..b99a7295 100644 --- a/templates/index.html +++ b/templates/index.html @@ -11,7 +11,7 @@
-
+
diff --git a/templates/modules/footer.html b/templates/modules/footer.html index 888d2c42..a9a6889b 100644 --- a/templates/modules/footer.html +++ b/templates/modules/footer.html @@ -60,15 +60,15 @@ - - - - - - - - - +
+
协议提醒助手
+
+ 查看本站为你的个人隐私做出的努力 + + + +
+
\ No newline at end of file diff --git a/templates/modules/head.html b/templates/modules/head.html index 16a4581e..0999f170 100644 --- a/templates/modules/head.html +++ b/templates/modules/head.html @@ -126,6 +126,10 @@ + + + + diff --git a/templates/modules/layouts/layout.html b/templates/modules/layouts/layout.html index 9fad4d89..28ec2732 100644 --- a/templates/modules/layouts/layout.html +++ b/templates/modules/layouts/layout.html @@ -11,6 +11,12 @@ // 页面类型 index,page,post,tag,category htmlType: [[${htmlType}]], postTitle: [[${htmlType == 'post' ? post.spec.title : ''}]], + isanchor: true, + isPost: [[${htmlType == 'post'}]], + isHome: [[${htmlType == 'index'}]], + isHighlightShrink: false, + isToc: [[${htmlType == 'post'}]] && document.getElementById("card-toc"), + postUpdate: '2022-11-04 20:08:15', Snackbar: { chs_to_cht: "你已切换为繁体", cht_to_chs: "你已切换为简体", @@ -37,9 +43,23 @@
+
+ + +
+
+ + + +
+
+ + +
+
@@ -59,14 +79,13 @@ - - - - + + +
@@ -79,7 +98,6 @@ // 移除加载动画 removeLoading(); } - addRightMenuClickEvent(); navTitle(); heo.topPostScroll(); heo.topCategoriesBarScroll(); diff --git a/templates/modules/moment.html b/templates/modules/moment.html new file mode 100644 index 00000000..264057fb --- /dev/null +++ b/templates/modules/moment.html @@ -0,0 +1,14 @@ + + +
+ + +
+
+
这里需要后面适配瞬间的插件
+
后面再适配吧!
+
+
+ +
+ \ No newline at end of file diff --git a/templates/modules/post-list.html b/templates/modules/post-list.html index 28220a6d..33ce45f5 100644 --- a/templates/modules/post-list.html +++ b/templates/modules/post-list.html @@ -2,8 +2,7 @@ + th:with="postItems=${posts.items}">
- +