From e6abae4d5c9a6df6d9a990c78b5f8ab611dcd1b9 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Mon, 22 Jul 2024 22:23:52 +0800 Subject: [PATCH 01/42] :tada: Upgrade to develop 4.7.0 --- VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 7962f0f..f6cdf40 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -4.6.3 \ No newline at end of file +4.7.0 From 569b733e2a35980ff6ff57421412abec946d88a8 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Mon, 22 Jul 2024 23:35:01 +0800 Subject: [PATCH 02/42] :wrench: Upgrade the data VERSION to 4.7.0. --- data/config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data/config.yaml b/data/config.yaml index 9e2a348..b07ece9 100644 --- a/data/config.yaml +++ b/data/config.yaml @@ -1,5 +1,5 @@ # Hugo NexT theme's custom config -version: 4.6.2 +version: 4.7.0 -domain: hugo-next.eu.org \ No newline at end of file +domain: hugo-next.eu.org From b8ac0c8f95dc917a2c682ec37d5f168840d28e70 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Tue, 23 Jul 2024 09:14:01 +0800 Subject: [PATCH 03/42] :pencil: Update the gitter link. --- README.md | 2 +- README.zh.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0ff2f94..b36ecc9 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ > All page designs & configuration compatibility with Hexo NexT, it's very easy migrate your site from Hexo to Hugo and enjoy yourself. -[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square&label=Gitter)](https://gitter.im/hugo-next/community) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.89.0-red?style=flat-square&logo=hugo&color=%23FF4088&&label=Hugo%20Extended)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&logo=GitHub&label=Github%20Pages)](https://github.com/hugo-next/hugo-theme-next) [![Contributors](https://img.shields.io/github/contributors/hugo-next/hugo-theme-next?style=flat-square&color=%235E0D73&logo=contributorcovenant&label=Contributors)](https://github.com/hugo-next/hugo-theme-next/graphs/contributors) [![Latest Release](https://img.shields.io/github/v/release/hugo-next/hugo-theme-next?include_prereleases&style=flat-square&color=%23DD2C00&logo=semanticrelease&label=Latest%20Release)](https://github.com/hugo-next/hugo-theme-next/releases) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files&label=Repo%20Size)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square&label=License)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE) +[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square&label=Gitter)](https://app.gitter.im/#/room/#hugo-next_community:gitter.im) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.89.0-red?style=flat-square&logo=hugo&color=%23FF4088&&label=Hugo%20Extended)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&logo=GitHub&label=Github%20Pages)](https://github.com/hugo-next/hugo-theme-next) [![Contributors](https://img.shields.io/github/contributors/hugo-next/hugo-theme-next?style=flat-square&color=%235E0D73&logo=contributorcovenant&label=Contributors)](https://github.com/hugo-next/hugo-theme-next/graphs/contributors) [![Latest Release](https://img.shields.io/github/v/release/hugo-next/hugo-theme-next?include_prereleases&style=flat-square&color=%23DD2C00&logo=semanticrelease&label=Latest%20Release)](https://github.com/hugo-next/hugo-theme-next/releases) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files&label=Repo%20Size)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square&label=License)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE) ![Screenshot](images/screenshot.png) diff --git a/README.zh.md b/README.zh.md index b7172fc..2e4ce92 100644 --- a/README.zh.md +++ b/README.zh.md @@ -10,7 +10,7 @@ > 本主题的所有页面设计和配置项都与原来 `Hexo` 引擎的 `NexT` 主题保持了良好的兼容性,可以非常平滑的从 `Hexo` 迁移至 `Hugo` 引擎,欢迎大家使用并反馈。 -[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square&label=Gitter)](https://gitter.im/hugo-next/community) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.89.0-red?style=flat-square&logo=hugo&color=%23FF4088&&label=Hugo%20Extended)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&logo=GitHub&label=Github%20Pages)](https://github.com/hugo-next/hugo-theme-next) [![Contributors](https://img.shields.io/github/contributors/hugo-next/hugo-theme-next?style=flat-square&color=%235E0D73&logo=contributorcovenant&label=Contributors)](https://github.com/hugo-next/hugo-theme-next/graphs/contributors) [![Latest Release](https://img.shields.io/github/v/release/hugo-next/hugo-theme-next?include_prereleases&style=flat-square&color=%23DD2C00&logo=semanticrelease&label=Latest%20Release)](https://github.com/hugo-next/hugo-theme-next/releases) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files&label=Repo%20Size)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square&label=License)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE) +[![Gitter](https://img.shields.io/gitter/room/hugo-next/hugo-them-next?logo=gitter&style=flat-square&label=Gitter)](https://app.gitter.im/#/room/#hugo-next_community:gitter.im) [![Build Hugo Version](https://img.shields.io/badge/Hugo-%3E=0.89.0-red?style=flat-square&logo=hugo&color=%23FF4088&&label=Hugo%20Extended)](https://github.com/gohugoio/hugo/releases/latest) [![GitHub deployments](https://img.shields.io/github/deployments/hugo-next/hugo-next.github.io/github-pages?style=flat-square&logo=GitHub&label=Github%20Pages)](https://github.com/hugo-next/hugo-theme-next) [![Contributors](https://img.shields.io/github/contributors/hugo-next/hugo-theme-next?style=flat-square&color=%235E0D73&logo=contributorcovenant&label=Contributors)](https://github.com/hugo-next/hugo-theme-next/graphs/contributors) [![Latest Release](https://img.shields.io/github/v/release/hugo-next/hugo-theme-next?include_prereleases&style=flat-square&color=%23DD2C00&logo=semanticrelease&label=Latest%20Release)](https://github.com/hugo-next/hugo-theme-next/releases) [![Repos Size](https://img.shields.io/github/repo-size/hugo-next/hugo-theme-next?style=flat-square&color=%23FFBF3B&logo=Files&label=Repo%20Size)](https://github.com/hugo-next/hugo-theme-next/find/main) [![GitHub](https://img.shields.io/github/license/hugo-next/hugo-theme-next?logo=webauthn&style=flat-square&label=License)](https://github.com/hugo-next/hugo-theme-next/blob/main/LICENSE) ![截图](images/screenshot.png) From 1076ba9282166b1d9654e1ae875f1b8ea7da3d7f Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Fri, 26 Jul 2024 21:06:50 +0800 Subject: [PATCH 04/42] :lipstick: Set the footer icon min width pixes. --- assets/css/_common/outline/footer/index.scss | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/assets/css/_common/outline/footer/index.scss b/assets/css/_common/outline/footer/index.scss index 83e6762..c07848a 100644 --- a/assets/css/_common/outline/footer/index.scss +++ b/assets/css/_common/outline/footer/index.scss @@ -47,14 +47,17 @@ img { display: inline-block; - max-width: 50px; - filter: var(--highlight-img-fill); + max-width: 48px; + min-width: 14px; + max-height: 16px; + @include mobile() { max-width: 40px; } - - &:last-child { - max-height: 18px; + + // Only work for svg image + &[src$=".svg"] { + filter: var(--highlight-img-fill); } } From 27ca39f39e74b512fa9ac9aa66439f92e40cfcb5 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Sat, 3 Aug 2024 18:56:01 +0800 Subject: [PATCH 05/42] :sparkles::tada: Add waline3 comment plugin. --- assets/js/third-party/comments/waline.js | 4 - assets/js/third-party/comments/waline3.js | 59 ++++++++++++++ assets/js/third-party/others/counter.js | 67 ++++++++++++---- assets/js/utils.js | 76 ++++++++++--------- data/resources.yaml | 26 +++++++ exampleSite/config.yaml | 29 +++++-- .../partials/_thirdparty/comment/waline3.html | 1 + layouts/partials/head/config.html | 23 ++++-- layouts/partials/init.html | 9 +++ layouts/partials/post/header_meta/views.html | 4 +- layouts/partials/scripts/global.html | 10 ++- static/3rd/waline/3.3.0/comment.min.js | 1 + static/3rd/waline/3.3.0/pageview.min.js | 1 + static/3rd/waline/3.3.0/waline.min.css | 1 + static/3rd/waline/3.3.0/waline.min.js | 56 ++++++++++++++ static/3rd/waline/3.3.0/waline.umd.min.js | 56 ++++++++++++++ 16 files changed, 351 insertions(+), 72 deletions(-) create mode 100644 assets/js/third-party/comments/waline3.js create mode 100644 layouts/partials/_thirdparty/comment/waline3.html create mode 100644 static/3rd/waline/3.3.0/comment.min.js create mode 100644 static/3rd/waline/3.3.0/pageview.min.js create mode 100644 static/3rd/waline/3.3.0/waline.min.css create mode 100644 static/3rd/waline/3.3.0/waline.min.js create mode 100644 static/3rd/waline/3.3.0/waline.umd.min.js diff --git a/assets/js/third-party/comments/waline.js b/assets/js/third-party/comments/waline.js index 8c3b191..5855941 100644 --- a/assets/js/third-party/comments/waline.js +++ b/assets/js/third-party/comments/waline.js @@ -5,10 +5,8 @@ NexT.plugins.comments.waline = function() { || !NexT.utils.checkDOMExist(element)) return; const { - comment, emoji, imguploader, - pageview, placeholder, sofa, requiredmeta, @@ -39,8 +37,6 @@ NexT.plugins.comments.waline = function() { Waline.init({ locale, el : element, - pageview : pageview, - comment : comment, emoji : emoji, imageUploader : imguploader, wordLimit : wordlimit, diff --git a/assets/js/third-party/comments/waline3.js b/assets/js/third-party/comments/waline3.js new file mode 100644 index 0000000..82ab556 --- /dev/null +++ b/assets/js/third-party/comments/waline3.js @@ -0,0 +1,59 @@ +/* Waline3 comment plugin */ +NexT.plugins.comments.waline3 = function () { + const element = '.waline3-container'; + if (!NexT.CONFIG.waline3 + || !NexT.utils.checkDOMExist(element)) return; + + const { + emoji, + search, + imguploader, + placeholder, + sofa, + requiredmeta, + serverurl, + wordlimit, + reaction, + reactiontext, + reactiontitle + } = NexT.CONFIG.waline3.cfg; + + const waline_js = NexT.utils.getCDNResource(NexT.CONFIG.waline3.js); + + NexT.utils.lazyLoadComponent(element, () => { + + const waline_css = NexT.utils.getCDNResource(NexT.CONFIG.waline3.css); + NexT.utils.getStyle(waline_css, 'before'); + + let waline_script = ` + let locale = { + placeholder : '${placeholder}', + sofa : '${sofa}', + reactionTitle : '${reactiontitle}' + }; + + let recatt = ${JSON.stringify(reactiontext)} + recatt.forEach(function(value, index){ + locale['reaction'+index] = value; + }); + + import('${waline_js}').then((Waline) => { + Waline.init({ + locale, + el : '${element}', + emoji : ${emoji}, + search : ${search}, + imageUploader : ${imguploader}, + wordLimit : ${wordlimit}, + requiredMeta : ${JSON.stringify(requiredmeta)}, + reaction : ${reaction}, + serverURL : '${serverurl}', + }); + + NexT.utils.hiddeLodingCmp('${element}'); + }); + `; + + NexT.utils.getScript(null, { module: true, textContent: waline_script }); + }); +} \ No newline at end of file diff --git a/assets/js/third-party/others/counter.js b/assets/js/third-party/others/counter.js index 8cb9098..45f5c3e 100644 --- a/assets/js/third-party/others/counter.js +++ b/assets/js/third-party/others/counter.js @@ -1,31 +1,66 @@ /* Page's view & comment counter plugin */ -NexT.plugins.others.counter = function() { - let pageview_js = undefined; - let comment_js = undefined; +NexT.plugins.others.counter = function () { + let pageview_js = undefined; + let comment_js = undefined; - const post_meta = NexT.CONFIG.postmeta; + const post_meta = NexT.CONFIG.postmeta; - const views = post_meta.views; - if(views != undefined && views.enable) { - if (views.plugin == 'waline') { - pageview_js = NexT.utils.getCDNResource(NexT.CONFIG.page.waline.js[0]); - NexT.utils.getScript(pageview_js, function(){ + const views = post_meta.views; + if (views != undefined && views.enable) { + let pageview_el = '#pageview-count'; + + switch (views.plugin) { + case 'waline': + pageview_js = NexT.utils.getCDNResource(NexT.CONFIG.page.waline.pagecnt); + NexT.utils.getScript(pageview_js, function () { Waline.pageviewCount({ + selector : pageview_el, serverURL: NexT.CONFIG.waline.cfg.serverurl }); }); - } + break; + case 'waline3': + pageview_js = NexT.utils.getCDNResource(NexT.CONFIG.page.waline3.pagecnt); + + let pageview_script = ` + import('${pageview_js}').then((Waline) => { + Waline.pageviewCount({ + selector : '${pageview_el}', + serverURL: '${NexT.CONFIG.waline3.cfg.serverurl}' + }) + }); + `; + NexT.utils.getScript(null, { module: true, textContent: pageview_script }); + break; } - const comments = post_meta.comments; - if (comments != undefined && comments.enable) { - if (comments.plugin == 'waline') { - comment_js = NexT.utils.getCDNResource(NexT.CONFIG.page.waline.js[1]); - NexT.utils.getScript(comment_js, function(){ + } + + const comments = post_meta.comments; + if (comments != undefined && comments.enable) { + let comments_el = '#comments-count'; + switch (comments.plugin) { + case 'waline': + comment_js = NexT.utils.getCDNResource(NexT.CONFIG.page.waline.commentcnt); + NexT.utils.getScript(comment_js, function () { Waline.commentCount({ + selector : comments_el, serverURL: NexT.CONFIG.waline.cfg.serverurl }); }); - } + break; + case 'waline3': + comment_js = NexT.utils.getCDNResource(NexT.CONFIG.page.waline3.commentcnt); + let comment_script = ` + import('${comment_js}').then((Waline) => { + Waline.commentCount({ + selector : '${comments_el}', + serverURL: '${NexT.CONFIG.waline3.cfg.serverurl}' + }) + }); + `; + NexT.utils.getScript(null, { module: true, textContent: comment_script }); + break; } + } } \ No newline at end of file diff --git a/assets/js/utils.js b/assets/js/utils.js index 0cdd6bf..5da1bad 100644 --- a/assets/js/utils.js +++ b/assets/js/utils.js @@ -7,15 +7,15 @@ HTMLElement.prototype.wrap = function (wrapper) { }; NexT.utils = { - registerMenuClick: function() { + registerMenuClick: function () { const pMenus = document.querySelectorAll('.main-menu > li > a.menus-parent'); - pMenus.forEach(function(item) { + pMenus.forEach(function (item) { const icon = item.querySelector('span > i'); - var ul = item.nextElementSibling; - - item.addEventListener('click', function(e) { + var ul = item.nextElementSibling; + + item.addEventListener('click', function (e) { e.preventDefault(); - + ul.classList.toggle('expand'); if (ul.classList.contains('expand')) { icon.className = 'fa fa-angle-down'; @@ -30,9 +30,9 @@ NexT.utils = { } }); }, - registerImageLoadEvent: function() { + registerImageLoadEvent: function () { const images = document.querySelectorAll('.sidebar img, .post-block img, .vendors-list img'); - + const callback = (entries) => { entries.forEach(item => { if (item.intersectionRatio > 0) { @@ -40,7 +40,7 @@ NexT.utils = { let imgSrc = ele.getAttribute('data-src'); if (imgSrc) { let img = new Image(); - img.addEventListener('load', function() { + img.addEventListener('load', function () { ele.src = imgSrc; }, false); ele.src = imgSrc; @@ -50,23 +50,23 @@ NexT.utils = { } }) }; - + const observer = new IntersectionObserver(callback); images.forEach(img => { observer.observe(img); }); }, - registerImageViewer: function() { + registerImageViewer: function () { const post_body = document.querySelector('.post-body'); if (post_body) { - new Viewer(post_body,{ navbar:2, toolbar:2 }); + new Viewer(post_body, { navbar: 2, toolbar: 2 }); } }, registerToolButtons: function () { const buttons = document.querySelector('.tool-buttons'); - + const scrollbar_buttons = buttons.querySelectorAll('div:not(#toggle-theme)'); scrollbar_buttons.forEach(button => { let targetId = button.id; @@ -86,12 +86,12 @@ NexT.utils = { slidScrollBarAnime: function (targetId, easing = 'linear', duration = 500) { const targetObj = document.getElementById(targetId); - + window.anime({ targets: document.scrollingElement, duration: duration, easing: easing, - scrollTop: targetId == '' || !targetObj ? 0 : targetObj.getBoundingClientRect().top + window.scrollY + scrollTop: targetId == '' || !targetObj ? 0 : targetObj.getBoundingClientRect().top + window.scrollY }); }, @@ -147,8 +147,8 @@ NexT.utils = { } }, - fmtLaWidget: function(){ - setTimeout(function(){ + fmtLaWidget: function () { + setTimeout(function () { const laWidget = document.querySelectorAll('#la-siteinfo-widget span'); if (laWidget.length > 0) { const valIds = [0, 2, 4, 6]; @@ -162,8 +162,8 @@ NexT.utils = { }, fmtBusuanzi: function () { - setTimeout(function(){ - const bszUV = document.getElementById('busuanzi_value_site_uv'); + setTimeout(function () { + const bszUV = document.getElementById('busuanzi_value_site_uv'); if (bszUV) { bszUV.innerText = NexT.utils.numberFormat(bszUV.innerText); } @@ -171,7 +171,7 @@ NexT.utils = { if (bszPV) { bszPV.innerText = NexT.utils.numberFormat(bszPV.innerText); } - }, 800); + }, 800); }, numberFormat: function (number) { @@ -244,14 +244,14 @@ NexT.utils = { let router = NexT.CONFIG.vendor.router; let { name, version, file, alias, alias_name } = res; - + let res_src = ''; - + switch (router.type) { case "modern": if (alias_name) name = alias_name; let alias_file = file.replace(/^(dist|lib|source|\/js|)\/(browser\/|)/, ''); - if (alias_file.indexOf('min') == -1) { + if (alias_file.indexOf('min') == -1) { alias_file = alias_file.replace(/\.js$/, '.min.js'); } res_src = `${router.url}/${name}/${version}/${alias_file}`; @@ -512,7 +512,7 @@ NexT.utils = { hideComments: function () { let postComments = document.querySelector('.post-comments'); if (postComments !== null) { - postComments.style.display = 'none'; + postComments.style.display = 'none'; } }, @@ -587,7 +587,7 @@ NexT.utils = { }); }, - getStyle: function (src, position='after', parent) { + getStyle: function (src, position = 'after', parent) { const link = document.createElement('link'); link.setAttribute('rel', 'stylesheet'); link.setAttribute('type', 'text/css'); @@ -607,8 +607,11 @@ NexT.utils = { condition: legacyCondition }).then(options); } + const { condition = false, + module = false, + textContent = undefined, attributes: { id = '', async = false, @@ -628,6 +631,8 @@ NexT.utils = { if (id) script.id = id; if (crossOrigin) script.crossOrigin = crossOrigin; + if (module) script.type = 'module'; + if (textContent != undefined) script.textContent = textContent; script.async = async; script.defer = defer; Object.assign(script.dataset, dataset); @@ -638,22 +643,25 @@ NexT.utils = { script.onload = resolve; script.onerror = reject; - if (typeof src === 'object') { - const { url, integrity } = src; - script.src = url; - if (integrity) { - script.integrity = integrity; - script.crossOrigin = 'anonymous'; + if (src != null && src != undefined) { + if (typeof src === 'object') { + const { url, integrity } = src; + script.src = url; + if (integrity) { + script.integrity = integrity; + script.crossOrigin = 'anonymous'; + } + } else { + script.src = src; } - } else { - script.src = src; } + (parentNode || document.head).appendChild(script); } }); }, - lazyLoadComponent: function(selector, legacyCallback) { + lazyLoadComponent: function (selector, legacyCallback) { if (legacyCallback) { return this.lazyLoadComponent(selector).then(legacyCallback); } diff --git a/data/resources.yaml b/data/resources.yaml index c0aa4c7..2da1d7e 100644 --- a/data/resources.yaml +++ b/data/resources.yaml @@ -108,6 +108,19 @@ waline: file: dist/waline.css alias: "@waline/client" +waline3: + js: + name: waline + version: 3.3.0 + file: dist/waline.js + alias: "@waline/client" + + css: + name: waline + version: 3.3.0 + file: dist/waline.min.css + alias: "@waline/client" + artalk: js: name: artalk @@ -186,4 +199,17 @@ plugins: alias_name: waline version: 2.15.8 file: dist/comment.js + alias: "@waline/client" + waline3: + js: + - name: pageview + alias_name: waline + version: 3.3.0 + file: dist/pageview.js + alias: "@waline/client" + + - name: comment + alias_name: waline + version: 3.3.0 + file: dist/comment.js alias: "@waline/client" \ No newline at end of file diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 2c8805c..ba291c9 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -485,14 +485,14 @@ params: # 是否开启评论数显示 comments: enable: true - # 评论统计插件,暂只支持waline - # Comment counter plugin, only support waline + # 评论统计插件,暂只支持waline和waline3 + # Comment counter plugin, only support waline and waline3 plugin: waline # 是否开启页面访问数显示 views: enable: true - # 页面访问统计插件,支持busuanzi, waline, leancloud - # Page views counter plugin, support: busuanzi, waline, leancloud + # 页面访问统计插件,支持busuanzi, waline, waline3 + # Page views counter plugin, support: busuanzi, waline, waline3 plugin: busuanzi # 文章底部的设置 @@ -809,7 +809,7 @@ params: # Lazyload all comment systems. # lazyload: false # 设置你要显示的2个评论插件,`weight` 数字越小越靠前 - # `name` 参数名可选值:livere | waline | utterances | artalk | giscus + # `name` 参数名可选值:livere | waline | waline3 | utterances | artalk | giscus # Modify texts or order for any naves, here are some examples. nav: - name: waline @@ -836,6 +836,19 @@ params: reactionText: [ '点赞', '踩一下', '得意', '不屑', '尴尬', '睡觉'] reactionTitle: "你认为这篇文章怎么样?" serverURL: # + # Waline(2) 与 Waline3 无法兼容只能是二选一 + # Waline3 采用的是ES模块开发,需要更高版本的浏览器才能支持,如考虑兼容性建议可优先选用Waline2 + # waline3: + # placeholder: "请文明发言哟 ヾ(≧▽≦*)o" + # sofa: "快来发表你的意见吧 (≧∀≦)ゞ" + # emoji: false + # imgUploader: false + # wordLimit: 200 + # requiredMeta: ['nick', 'mail'] + # reaction: true + # reactionText: [ '点赞', '踩一下', '得意', '不屑', '尴尬', '睡觉'] + # reactionTitle: "你认为这篇文章怎么样?" + # serverURL: # # Artalk 评论插件 # 更多配置信息请参考:https://artalk.js.org @@ -921,11 +934,11 @@ params: id: # color: "#fc6423" - # AddThis文章分享功能 + # AddThis文章分享功能(服务商已下线,不推荐使用) # 更多信息及配置请参考:https://www.addthis.com - # AddThis Share. + # AddThis Share (The service provider has been offline, not recommended for use) # See: https://www.addthis.com - addThisId: # + # addThisId: # # --------------------------------------------------------------- diff --git a/layouts/partials/_thirdparty/comment/waline3.html b/layouts/partials/_thirdparty/comment/waline3.html new file mode 100644 index 0000000..3a397f8 --- /dev/null +++ b/layouts/partials/_thirdparty/comment/waline3.html @@ -0,0 +1 @@ +
\ No newline at end of file diff --git a/layouts/partials/head/config.html b/layouts/partials/head/config.html index 777f8a4..574d57b 100644 --- a/layouts/partials/head/config.html +++ b/layouts/partials/head/config.html @@ -8,11 +8,24 @@ }} {{/* Append waline pageview & comment plugin */}} -{{ if or (eq .Site.Params.postMeta.views.plugin "waline") (eq .Site.Params.postMeta.comments.plugin "waline") }} -{{ $counter := dict - "js" .Site.Data.resources.plugins.waline.js -}} -{{ $pageCfg = merge $pageCfg (dict "waline" $counter) }} +{{ with .Site.Params.postMeta.views }} + {{ if and .enable (ne .plugin "busuanzi") }} + {{ $plugin := .plugin }} + {{ $counter := dict + "pagecnt" (index ($.Site.Data.resources.plugins) $plugin "js" 0) + }} + {{ $pageCfg = merge $pageCfg (dict $plugin $counter) }} + {{ end }} +{{ end }} + +{{ with .Site.Params.postMeta.comments }} + {{ if .enable }} + {{ $plugin := .plugin }} + {{ $counter := dict + "commentcnt" (index ($.Site.Data.resources.plugins) $plugin "js" 1) + }} + {{ $pageCfg = merge $pageCfg (dict $plugin $counter) }} + {{ end }} {{ end }} {{/* Append mermaid plugin */}} diff --git a/layouts/partials/init.html b/layouts/partials/init.html index 6cf25e3..5b16e82 100644 --- a/layouts/partials/init.html +++ b/layouts/partials/init.html @@ -100,6 +100,15 @@ {{ $config = merge $config (dict "waline" $waline) }} {{ end }} +{{ with .Site.Params.waline3 }} +{{ $waline := dict + "js" $.Site.Data.resources.waline3.js + "css" $.Site.Data.resources.waline3.css + "cfg" . +}} +{{ $config = merge $config (dict "waline3" $waline) }} +{{ end }} + {{ with .Site.Params.giscus }} {{ $giscus := dict "js" $.Site.Data.resources.giscus.js diff --git a/layouts/partials/post/header_meta/views.html b/layouts/partials/post/header_meta/views.html index 5c5d974..64a16c4 100644 --- a/layouts/partials/post/header_meta/views.html +++ b/layouts/partials/post/header_meta/views.html @@ -1,5 +1,5 @@ {{ if .Site.Params.postMeta.views.enable }} -{{ $pageViewId := "" }} +{{ $pageViewId := "pageview-count" }} {{ if eq .Site.Params.postMeta.views.plugin "leancloud" }} {{ $pageViewId = "leancloud-visitors-count" }} {{ else if eq .Site.Params.postMeta.views.plugin "busuanzi" }} @@ -12,7 +12,7 @@ - + diff --git a/layouts/partials/scripts/global.html b/layouts/partials/scripts/global.html index 62826ed..d017f2b 100644 --- a/layouts/partials/scripts/global.html +++ b/layouts/partials/scripts/global.html @@ -47,12 +47,16 @@ {{/* Comments scripts */}} {{ if isset .Site.Params "waline" }} -{{ $walinejs := resources.Get "js/third-party/comments/waline.js" }} -{{ $nextjs = $nextjs | append $walinejs }} + {{ $walinejs := resources.Get "js/third-party/comments/waline.js" }} + {{ $nextjs = $nextjs | append $walinejs }} +{{ end }} +{{ if isset .Site.Params "waline3" }} + {{ $walinejs3 := resources.Get "js/third-party/comments/waline3.js" }} + {{ $nextjs = $nextjs | append $walinejs3 }} +{{ end }} {{ if or .Site.Params.postMeta.views.enable .Site.Params.postMeta.comments.enable }} {{ $counterjs := resources.Get "js/third-party/others/counter.js" }} {{ $nextjs = $nextjs | append $counterjs }} - {{ end }} {{ end }} {{ if isset .Site.Params "giscus" }} {{ $giscusjs := resources.Get "js/third-party/comments/giscus.js" }} diff --git a/static/3rd/waline/3.3.0/comment.min.js b/static/3rd/waline/3.3.0/comment.min.js new file mode 100644 index 0000000..f8e6527 --- /dev/null +++ b/static/3rd/waline/3.3.0/comment.min.js @@ -0,0 +1 @@ +const h=e=>e.replace(/\/?$/,"/")+"api/",i=(e,t="")=>{if("object"==typeof e&&e.errno)throw new TypeError(`${t} failed with ${e.errno}: `+e.errmsg);return e},g=({serverURL:e,lang:t,paths:n,signal:r})=>fetch(`${h(e)}comment?type=count&url=${encodeURIComponent(n.join(","))}&lang=`+t,{signal:r}).then(e=>e.json()).then(e=>i(e,"Get comment count").data),p=e=>{try{e=decodeURI(e)}catch{}return e},m=(e="")=>e.replace(/\/$/u,""),u=e=>/^(https?:)?\/\//.test(e),d=e=>{e=m(e);return u(e)?e:"https://"+e},$=e=>{"AbortError"!==e.name&&console.error(e.message)},f=e=>{e=e.dataset.path;return null!=e&&e.length?e:null},v=({serverURL:e,path:t=window.location.pathname,selector:n=".waline-comment-count",lang:r=navigator.language})=>{const o=new AbortController,a=document.querySelectorAll(n);return a.length&&g({serverURL:d(e),paths:Array.from(a).map(e=>p(f(e)??t)),lang:r,signal:o.signal}).then(n=>{a.forEach((e,t)=>{e.innerText=n[t].toString()})}).catch($),o.abort.bind(o)},w="3.3.0";export{v as commentCount,w as version}; \ No newline at end of file diff --git a/static/3rd/waline/3.3.0/pageview.min.js b/static/3rd/waline/3.3.0/pageview.min.js new file mode 100644 index 0000000..ce12ff9 --- /dev/null +++ b/static/3rd/waline/3.3.0/pageview.min.js @@ -0,0 +1 @@ +const v="3.3.0",$={"Content-Type":"application/json"},h=e=>e.replace(/\/?$/,"/")+"api/",u=(e,t="")=>{if("object"==typeof e&&e.errno)throw new TypeError(`${t} failed with ${e.errno}: `+e.errmsg);return e},f=({serverURL:e,lang:t,paths:n,type:r,signal:a})=>fetch(`${h(e)}article?path=${encodeURIComponent(n.join(","))}&type=${encodeURIComponent(r.join(","))}&lang=`+t,{signal:a}).then(e=>e.json()).then(e=>u(e,"Get counter").data),U=({serverURL:e,lang:t,path:n,type:r,action:a})=>fetch(h(e)+"article?lang="+t,{method:"POST",headers:$,body:JSON.stringify({path:n,type:r,action:a})}).then(e=>e.json()).then(e=>u(e,"Update counter").data),R=({serverURL:e,lang:t,paths:n,signal:r})=>f({serverURL:e,lang:t,paths:n,type:["time"],signal:r}),w=e=>U({...e,type:"time",action:"inc"}),L=(e="")=>e.replace(/\/$/u,""),b=e=>/^(https?:)?\/\//.test(e),d=e=>{e=L(e);return b(e)?e:"https://"+e},j=e=>{"AbortError"!==e.name&&console.error(e.message)},m=e=>{e=e.dataset.path;return null!=e&&e.length?e:null},y=(r,e)=>{e.forEach((e,t)=>{const n=r[t].time;"number"==typeof n&&(e.innerText=n.toString())})},S=({serverURL:e,path:n=window.location.pathname,selector:t=".waline-pageview-count",update:r=!0,lang:a=navigator.language})=>{const o=new AbortController,l=Array.from(document.querySelectorAll(t)),s=e=>{e=m(e);return null!==e&&n!==e},i=t=>R({serverURL:d(e),paths:t.map(e=>m(e)??n),lang:a,signal:o.signal}).then(e=>y(e,t)).catch(j);if(r){const p=l.filter(e=>!s(e)),h=l.filter(s);w({serverURL:d(e),path:n,lang:a}).then(e=>y(e,p)),h.length&&i(h)}else i(l);return o.abort.bind(o)};export{S as pageviewCount,v as version}; \ No newline at end of file diff --git a/static/3rd/waline/3.3.0/waline.min.css b/static/3rd/waline/3.3.0/waline.min.css new file mode 100644 index 0000000..b7939ad --- /dev/null +++ b/static/3rd/waline/3.3.0/waline.min.css @@ -0,0 +1 @@ +:root{--waline-font-size:1rem;--waline-white:#fff;--waline-light-grey:#999;--waline-dark-grey:#666;--waline-theme-color:#27ae60;--waline-active-color:#2ecc71;--waline-color:#444;--waline-bg-color:#fff;--waline-bg-color-light:#f8f8f8;--waline-bg-color-hover:#f0f0f0;--waline-border-color:#ddd;--waline-disable-bg-color:#f8f8f8;--waline-disable-color:#000;--waline-code-bg-color:#282c34;--waline-bq-color:#f0f0f0;--waline-avatar-size:3.25rem;--waline-m-avatar-size:calc(var(--waline-avatar-size) * 9 / 13);--waline-badge-color:#3498db;--waline-badge-font-size:0.75em;--waline-info-bg-color:#f8f8f8;--waline-info-color:#999;--waline-info-font-size:0.625em;--waline-border:1px solid var(--waline-border-color);--waline-avatar-radius:50%;--waline-box-shadow:none}[data-waline]{font-size:var(--waline-font-size);text-align:start}[dir=rtl] [data-waline]{direction:rtl}[data-waline] *{box-sizing:content-box;line-height:1.75}[data-waline] p{color:var(--waline-color)}[data-waline] a{position:relative;display:inline-block;color:var(--waline-theme-color);text-decoration:none;word-break:break-word;cursor:pointer}[data-waline] a:hover{color:var(--waline-active-color)}[data-waline] img{max-width:100%;max-height:400px;border:none}[data-waline] hr{margin:.825em 0;border-style:dashed;border-color:var(--waline-bg-color-light)}[data-waline] code,[data-waline] pre{margin:0;padding:.2em .4em;border-radius:3px;background:var(--waline-bg-color-light);font-size:85%}[data-waline] pre{overflow:auto;padding:10px;line-height:1.45}[data-waline] pre::-webkit-scrollbar{width:6px;height:6px}[data-waline] pre::-webkit-scrollbar-track-piece:horizontal{-webkit-border-radius:6px;border-radius:6px;background:rgba(0,0,0,.1)}[data-waline] pre::-webkit-scrollbar-thumb:horizontal{width:6px;-webkit-border-radius:6px;border-radius:6px;background:var(--waline-theme-color)}[data-waline] pre code{padding:0;background:rgba(0,0,0,0);color:var(--waline-color);white-space:pre-wrap;word-break:keep-all}[data-waline] blockquote{margin:.5em 0;padding:.5em 0 .5em 1em;border-inline-start:8px solid var(--waline-bq-color);color:var(--waline-dark-grey)}[data-waline] blockquote>p{margin:0}[data-waline] ol,[data-waline] ul{margin-inline-start:1.25em;padding:0}[data-waline] input[type=checkbox],[data-waline] input[type=radio]{display:inline-block;vertical-align:middle;margin-top:-2px}.wl-btn{display:inline-block;vertical-align:middle;min-width:2.5em;margin-bottom:0;padding:.5em 1em;border:1px solid var(--waline-border-color);border-radius:.5em;background:rgba(0,0,0,0);color:var(--waline-color);font-weight:400;font-size:.75em;line-height:1.5;text-align:center;white-space:nowrap;cursor:pointer;user-select:none;transition-duration:.4s;touch-action:manipulation}.wl-btn:active,.wl-btn:hover{border-color:var(--waline-theme-color);color:var(--waline-theme-color)}.wl-btn:disabled{border-color:var(--waline-border-color);background:var(--waline-disable-bg-color);color:var(--waline-disable-color);cursor:not-allowed}.wl-btn.primary{border-color:var(--waline-theme-color);background:var(--waline-theme-color);color:var(--waline-white)}.wl-btn.primary:active,.wl-btn.primary:hover{border-color:var(--waline-active-color);background:var(--waline-active-color);color:var(--waline-white)}.wl-btn.primary:disabled{border-color:var(--waline-border-color);background:var(--waline-disable-bg-color);color:var(--waline-disable-color);cursor:not-allowed}.wl-loading{text-align:center}.wl-loading svg{margin:0 auto}.wl-comment{position:relative;display:flex;margin-bottom:.75em}.wl-close{position:absolute;top:-4px;inset-inline-end:-4px;padding:0;border:none;background:rgba(0,0,0,0);line-height:1;cursor:pointer}.wl-login-info{max-width:80px;margin-top:.75em;text-align:center}.wl-logout-btn{position:absolute;top:-10px;inset-inline-end:-10px;padding:3px;border:none;background:rgba(0,0,0,0);line-height:0;cursor:pointer}.wl-avatar{position:relative;width:var(--waline-avatar-size);height:var(--waline-avatar-size);margin:0 auto;border:var(--waline-border);border-radius:var(--waline-avatar-radius)}@media(max-width:720px){.wl-avatar{width:var(--waline-m-avatar-size);height:var(--waline-m-avatar-size)}}.wl-avatar img{width:100%;height:100%;border-radius:var(--waline-avatar-radius)}.wl-login-nick{display:block;color:var(--waline-theme-color);font-size:.75em;word-break:break-all}.wl-panel{position:relative;flex-shrink:1;width:100%;margin:.5em;border:var(--waline-border);border-radius:.75em;background:var(--waline-bg-color);box-shadow:var(--waline-box-shadow)}.wl-header{display:flex;overflow:hidden;padding:0 4px;border-bottom:2px dashed var(--waline-border-color);border-top-left-radius:.75em;border-top-right-radius:.75em}@media(max-width:580px){.wl-header{display:block}}.wl-header label{min-width:40px;padding:.75em .5em;color:var(--waline-color);font-size:.75em;text-align:center}.wl-header input{flex:1;width:0;padding:.5em;background:rgba(0,0,0,0);font-size:.625em;resize:none}.wl-header-item{display:flex;flex:1}@media(max-width:580px){.wl-header-item:not(:last-child){border-bottom:2px dashed var(--waline-border-color)}}.wl-header-1 .wl-header-item{width:100%}.wl-header-2 .wl-header-item{width:50%}@media(max-width:580px){.wl-header-2 .wl-header-item{flex:0;width:100%}}.wl-header-3 .wl-header-item{width:33.33%}@media(max-width:580px){.wl-header-3 .wl-header-item{width:100%}}.wl-editor{position:relative;width:calc(100% - 1em);min-height:8.75em;margin:.75em .5em;border-radius:.5em;background:rgba(0,0,0,0);font-size:.875em;resize:vertical}.wl-editor,.wl-input{max-width:100%;border:none;color:var(--waline-color);outline:0;transition:all .25s ease}.wl-editor:focus,.wl-input:focus{background:var(--waline-bg-color-light)}.wl-preview{padding:0 .5em .5em}.wl-preview h4{margin:.25em;font-weight:700;font-size:.9375em}.wl-preview .wl-content{min-height:1.25em;padding:.25em;word-break:break-word;hyphens:auto}.wl-preview .wl-content>:first-child{margin-top:0}.wl-preview .wl-content>:last-child{margin-bottom:0}.wl-footer{position:relative;display:flex;flex-wrap:wrap;margin:.5em .75em}.wl-actions{display:flex;flex:2;align-items:center}.wl-action{display:inline-flex;align-items:center;justify-content:center;width:1.5em;height:1.5em;margin:2px;padding:0;border:none;background:rgba(0,0,0,0);color:var(--waline-color);font-size:16px;cursor:pointer}.wl-action:hover{color:var(--waline-theme-color)}.wl-action.active{color:var(--waline-active-color)}#wl-image-upload{display:none}#wl-image-upload:focus+label{color:var(--waline-color)}#wl-image-upload:focus-visible+label{outline:-webkit-focus-ring-color auto 1px}.wl-info{display:flex;flex:3;align-items:center;justify-content:flex-end}.wl-info .wl-text-number{color:var(--waline-info-color);font-size:.75em}.wl-info .wl-text-number .illegal{color:red}.wl-info button{margin-inline-start:.75em}.wl-info button svg{display:block;margin:0 auto;line-height:18px}.wl-emoji-popup{position:absolute;top:100%;inset-inline-start:1.25em;z-index:10;display:none;width:100%;max-width:526px;border:var(--waline-border);border-radius:6px;background:var(--waline-bg-color);box-shadow:var(--waline-box-shadow)}.wl-emoji-popup.display{display:block}.wl-emoji-popup button{display:inline-block;vertical-align:middle;width:2em;margin:.125em;padding:0;border-width:0;background:rgba(0,0,0,0);font-size:inherit;line-height:2;text-align:center;cursor:pointer}.wl-emoji-popup button:hover{background:var(--waline-bg-color-hover)}.wl-emoji-popup .wl-emoji{display:inline-block;vertical-align:middle;max-width:1.5em;max-height:1.5em}.wl-emoji-popup .wl-tab-wrapper{overflow-y:auto;max-height:145px;padding:.5em}.wl-emoji-popup .wl-tab-wrapper::-webkit-scrollbar{width:6px;height:6px}.wl-emoji-popup .wl-tab-wrapper::-webkit-scrollbar-track-piece:vertical{-webkit-border-radius:6px;border-radius:6px;background:rgba(0,0,0,.1)}.wl-emoji-popup .wl-tab-wrapper::-webkit-scrollbar-thumb:vertical{width:6px;-webkit-border-radius:6px;border-radius:6px;background:var(--waline-theme-color)}.wl-emoji-popup .wl-tabs{position:relative;overflow-x:auto;padding:0 6px;white-space:nowrap}.wl-emoji-popup .wl-tabs::before{content:" ";position:absolute;top:0;right:0;left:0;z-index:2;height:1px;background:var(--waline-border-color)}.wl-emoji-popup .wl-tabs::-webkit-scrollbar{width:6px;height:6px}.wl-emoji-popup .wl-tabs::-webkit-scrollbar-track-piece:horizontal{-webkit-border-radius:6px;border-radius:6px;background:rgba(0,0,0,.1)}.wl-emoji-popup .wl-tabs::-webkit-scrollbar-thumb:horizontal{height:6px;-webkit-border-radius:6px;border-radius:6px;background:var(--waline-theme-color)}.wl-emoji-popup .wl-tab{position:relative;margin:0;padding:0 .5em}.wl-emoji-popup .wl-tab.active{z-index:3;border:1px solid var(--waline-border-color);border-top-width:0;border-bottom-right-radius:6px;border-bottom-left-radius:6px;background:var(--waline-bg-color)}.wl-gif-popup{position:absolute;top:100%;inset-inline-start:1.25em;z-index:10;width:calc(100% - 3em);padding:.75em .75em .25em;border:var(--waline-border);border-radius:6px;background:var(--waline-bg-color);box-shadow:var(--waline-box-shadow);opacity:0;visibility:hidden;transition:transform .2s ease-out,opacity .2s ease-out;transform:scale(.9,.9);transform-origin:0 0}.wl-gif-popup.display{opacity:1;visibility:visible;transform:none}.wl-gif-popup input{box-sizing:border-box;width:100%;margin-bottom:10px;padding:3px 5px;border:var(--waline-border)}.wl-gif-popup img{display:block;box-sizing:border-box;width:100%;border-width:2px;border-style:solid;border-color:#fff;cursor:pointer}.wl-gif-popup img:hover{border-color:var(--waline-theme-color);border-radius:2px}.wl-gallery{display:flex;overflow-y:auto;max-height:80vh}.wl-gallery-column{display:flex;flex:1;flex-direction:column;height:-webkit-max-content;height:-moz-max-content;height:max-content}.wl-cards .wl-user{--avatar-size:var(--waline-avatar-size);position:relative;margin-inline-end:.75em}@media(max-width:720px){.wl-cards .wl-user{--avatar-size:var(--waline-m-avatar-size)}}.wl-cards .wl-user .wl-user-avatar{width:var(--avatar-size);height:var(--avatar-size);border-radius:var(--waline-avatar-radius);box-shadow:var(--waline-box-shadow)}.wl-cards .wl-user .verified-icon{position:absolute;top:calc(var(--avatar-size)*3/4);inset-inline-start:calc(var(--avatar-size)*3/4);border-radius:50%;background:var(--waline-bg-color);box-shadow:var(--waline-box-shadow)}.wl-card-item{position:relative;display:flex;padding:.5em}.wl-card-item .wl-card-item{padding-inline-end:0}.wl-card{flex:1;width:0;padding-bottom:.5em;border-bottom:1px dashed var(--waline-border-color)}.wl-card:first-child{margin-inline-start:1em}.wl-card-item:last-child>.wl-card{border-bottom:none}.wl-card .wl-nick svg{position:relative;bottom:-.125em;line-height:1}.wl-card .wl-head{overflow:hidden;line-height:1.5}.wl-card .wl-head .wl-nick{position:relative;display:inline-block;margin-inline-end:.5em;font-weight:700;font-size:.875em;line-height:1;text-decoration:none}.wl-card span.wl-nick{color:var(--waline-dark-grey)}.wl-card .wl-badge{display:inline-block;margin-inline-end:1em;padding:0 .3em;border:1px solid var(--waline-badge-color);border-radius:4px;color:var(--waline-badge-color);font-size:var(--waline-badge-font-size)}.wl-card .wl-time{margin-inline-end:.875em;color:var(--waline-info-color);font-size:.75em}.wl-card .wl-meta{position:relative;line-height:1}.wl-card .wl-meta>span{display:inline-block;margin-inline-end:.25em;padding:2px 4px;border-radius:.2em;background:var(--waline-info-bg-color);color:var(--waline-info-color);font-size:var(--waline-info-font-size);line-height:1.5}.wl-card .wl-meta>span:empty{display:none}.wl-card .wl-comment-actions{float:right;line-height:1}[dir=rtl] .wl-card .wl-comment-actions{float:left}.wl-card .wl-delete,.wl-card .wl-edit,.wl-card .wl-like,.wl-card .wl-reply{display:inline-flex;align-items:center;border:none;background:rgba(0,0,0,0);color:var(--waline-color);line-height:1;cursor:pointer;transition:color .2s ease}.wl-card .wl-delete:hover,.wl-card .wl-edit:hover,.wl-card .wl-like:hover,.wl-card .wl-reply:hover{color:var(--waline-theme-color)}.wl-card .wl-delete.active,.wl-card .wl-edit.active,.wl-card .wl-like.active,.wl-card .wl-reply.active{color:var(--waline-active-color)}.wl-card .wl-content{position:relative;margin-bottom:.75em;padding-top:.625em;font-size:.875em;line-height:2;word-wrap:break-word}.wl-card .wl-content.expand{overflow:hidden;max-height:8em;cursor:pointer}.wl-card .wl-content.expand::before{content:"";position:absolute;top:0;bottom:3.15em;inset-inline-start:0;z-index:999;display:block;width:100%;background:linear-gradient(180deg,#000,rgba(255,255,255,.9))}.wl-card .wl-content.expand::after{content:attr(data-expand);position:absolute;bottom:0;inset-inline-start:0;z-index:999;display:block;width:100%;height:3.15em;background:rgba(255,255,255,.9);color:#828586;line-height:3.15em;text-align:center}.wl-card .wl-content>:first-child{margin-top:0}.wl-card .wl-content>:last-child{margin-bottom:0}.wl-card .wl-admin-actions{margin:8px 0;font-size:12px;text-align:right}.wl-card .wl-comment-status{margin:0 8px}.wl-card .wl-comment-status .wl-btn{border-radius:0}.wl-card .wl-comment-status .wl-btn:first-child{border-inline-end:0;border-radius:.5em 0 0 .5em}.wl-card .wl-comment-status .wl-btn:last-child{border-inline-start:0;border-radius:0 .5em .5em 0}.wl-card .wl-quote{border-inline-start:1px dashed rgba(237,237,237,.5)}.wl-card .wl-quote .wl-user{--avatar-size:var(--waline-m-avatar-size)}.wl-close-icon{color:var(--waline-border-color)}.wl-content .vemoji,.wl-content .wl-emoji{display:inline-block;vertical-align:baseline;height:1.25em;margin:-.125em .25em}.wl-content .wl-tex{background:var(--waline-info-bg-color);color:var(--waline-info-color)}.wl-content span.wl-tex{display:inline-block;margin-inline-end:.25em;padding:2px 4px;border-radius:.2em;font-size:var(--waline-info-font-size);line-height:1.5}.wl-content p.wl-tex{text-align:center}.wl-content .katex-display{overflow:auto hidden;-webkit-overflow-scrolling:touch;padding-top:.2em;padding-bottom:.2em}.wl-content .katex-display::-webkit-scrollbar{height:3px}.wl-content .katex-error{color:red}.wl-count{flex:1;font-weight:700;font-size:1.25em}.wl-empty{overflow:auto;padding:1.25em;color:var(--waline-color);text-align:center}.wl-operation{text-align:center}.wl-operation button{margin:1em 0}.wl-power{padding:.5em 0;color:var(--waline-light-grey);font-size:var(--waline-info-font-size);text-align:end}.wl-meta-head{display:flex;flex-direction:row;align-items:center;padding:.375em}.wl-sort{margin:0;list-style-type:none}.wl-sort li{display:inline-block;color:var(--waline-info-color);font-size:.75em;cursor:pointer}.wl-sort li.active{color:var(--waline-theme-color)}.wl-sort li+li{margin-inline-start:1em}.wl-reaction{overflow:auto hidden;margin-bottom:1.75em;text-align:center}.wl-reaction img{width:100%;height:100%;transition:all 250ms ease-in-out}.wl-reaction-title{margin:16px auto;font-weight:700;font-size:18px}.wl-reaction-list{display:flex;flex-direction:row;gap:16px;justify-content:center;margin:0;padding:8px;list-style-type:none}@media(max-width:580px){.wl-reaction-list{gap:12px}}[data-waline] .wl-reaction-list{margin-inline-start:0}.wl-reaction-item{display:flex;flex-direction:column;align-items:center;cursor:pointer}.wl-reaction-item.active img,.wl-reaction-item:hover img{transform:scale(1.15)}.wl-reaction-img{position:relative;width:42px;height:42px}@media(max-width:580px){.wl-reaction-img{width:32px;height:32px}}.wl-reaction-loading{position:absolute;top:-4px;inset-inline-end:-5px;width:18px;height:18px;color:var(--waline-theme-color)}.wl-reaction-votes{position:absolute;top:-9px;inset-inline-end:-9px;min-width:1em;padding:2px;border:1px solid var(--waline-theme-color);border-radius:1em;background:var(--waline-bg-color);color:var(--waline-theme-color);font-weight:700;font-size:.75em;line-height:1}.wl-reaction-item.active .wl-reaction-votes{background:var(--waline-theme-color);color:var(--waline-bg-color)}.wl-reaction-text{font-size:.875em}.wl-reaction-item.active .wl-reaction-text{color:var(--waline-theme-color)}.wl-content pre,.wl-content pre[class*=language-]{overflow:auto;margin:.75rem 0;padding:1rem 1.25rem;border-radius:6px;background:var(--waline-code-bg-color);line-height:1.4}.wl-content pre code,.wl-content pre[class*=language-] code{padding:0;border-radius:0;background:rgba(0,0,0,0)!important;color:#bbb;direction:ltr}.wl-content code[class*=language-],.wl-content pre[class*=language-]{background:0 0;color:#ccc;font-size:1em;font-family:Consolas,Monaco,"Andale Mono","Ubuntu Mono",monospace;text-align:left;white-space:pre;word-spacing:normal;word-wrap:normal;word-break:normal;tab-size:4;hyphens:none}.wl-content pre[class*=language-]{overflow:auto}.wl-content :not(pre)>code[class*=language-],.wl-content pre[class*=language-]{background:#2d2d2d}.wl-content :not(pre)>code[class*=language-]{padding:.1em;border-radius:.3em;white-space:normal}.wl-content .token.block-comment,.wl-content .token.cdata,.wl-content .token.comment,.wl-content .token.doctype,.wl-content .token.prolog{color:#999}.wl-content .token.punctuation{color:#ccc}.wl-content .token.attr-name,.wl-content .token.deleted,.wl-content .token.namespace,.wl-content .token.tag{color:#e2777a}.wl-content .token.function-name{color:#6196cc}.wl-content .token.boolean,.wl-content .token.function,.wl-content .token.number{color:#f08d49}.wl-content .token.class-name,.wl-content .token.constant,.wl-content .token.property,.wl-content .token.symbol{color:#f8c555}.wl-content .token.atrule,.wl-content .token.builtin,.wl-content .token.important,.wl-content .token.keyword,.wl-content .token.selector{color:#cc99cd}.wl-content .token.attr-value,.wl-content .token.char,.wl-content .token.regex,.wl-content .token.string,.wl-content .token.variable{color:#7ec699}.wl-content .token.entity,.wl-content .token.operator,.wl-content .token.url{color:#67cdcc}.wl-content .token.bold,.wl-content .token.important{font-weight:700}.wl-content .token.italic{font-style:italic}.wl-content .token.entity{cursor:help}.wl-content .token.inserted{color:green}.wl-recent-item p{display:inline}.wl-user-list{padding:0;list-style:none}.wl-user-list a,.wl-user-list a:hover,.wl-user-list a:visited{color:var(--waline-color);text-decoration:none}.wl-user-list .wl-user-avatar{position:relative;display:inline-block;overflow:hidden;margin-inline-end:10px;border-radius:4px;line-height:0}.wl-user-list .wl-user-avatar>img{width:var(--waline-user-avatar-size,48px);height:var(--waline-user-avatar-size,48px)}.wl-user-list .wl-user-badge{position:absolute;bottom:0;inset-inline-end:0;min-width:.7em;height:1.5em;padding:0 .4em;border-radius:4px;background:var(--waline-info-bg-color);color:var(--waline-info-color);font-weight:700;font-size:10px;line-height:1.5em;text-align:center}.wl-user-list .wl-user-item{margin:10px 0}.wl-user-list .wl-user-item:nth-child(1) .wl-user-badge{background:var(--waline-rank-gold-bg-color,#fa3939);color:var(--waline-white);font-weight:700}.wl-user-list .wl-user-item:nth-child(2) .wl-user-badge{background:var(--waline-rank-silver-bg-color,#fb811c);color:var(--waline-white);font-weight:700}.wl-user-list .wl-user-item:nth-child(3) .wl-user-badge{background:var(--waline-rank-copper-bg-color,#feb207);color:var(--waline-white)}.wl-user-list .wl-user-meta{display:inline-block;vertical-align:top}.wl-user-list .wl-badge{display:inline-block;vertical-align:text-top;margin-inline-start:.5em;padding:0 .3em;border:1px solid var(--waline-badge-color);border-radius:4px;color:var(--waline-badge-color);font-size:var(--waline-badge-font-size)}.wl-user-wall{padding:0;list-style:none}.wl-user-wall .wl-user-badge,.wl-user-wall .wl-user-meta{display:none}.wl-user-wall .wl-user-item{position:relative;display:inline-block;transition:transform ease-in-out .2s}.wl-user-wall .wl-user-item::after,.wl-user-wall .wl-user-item::before{position:absolute;bottom:100%;left:50%;z-index:10;opacity:0;pointer-events:none;transition:all .18s ease-out .18s;transform:translate(-50%,4px);transform-origin:top}.wl-user-wall .wl-user-item::before{content:"";width:0;height:0;border:5px solid transparent;border-top-color:rgba(16,16,16,.95)}.wl-user-wall .wl-user-item::after{content:attr(aria-label);margin-bottom:10px;padding:.5em 1em;border-radius:2px;background:rgba(16,16,16,.95);color:#fff;font-size:12px;white-space:nowrap}.wl-user-wall .wl-user-item:hover{transform:scale(1.1)}.wl-user-wall .wl-user-item:hover::after,.wl-user-wall .wl-user-item:hover::before{opacity:1;pointer-events:none;transform:translate(-50%,0)}.wl-user-wall .wl-user-item img{width:var(--waline-user-avatar-size,48px);height:var(--waline-user-avatar-size,48px)} \ No newline at end of file diff --git a/static/3rd/waline/3.3.0/waline.min.js b/static/3rd/waline/3.3.0/waline.min.js new file mode 100644 index 0000000..87454f5 --- /dev/null +++ b/static/3rd/waline/3.3.0/waline.min.js @@ -0,0 +1,56 @@ +var xn,kr,bi,wl,bl=Object.defineProperty,yl=(e,t,n)=>t in e?bl(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Oe=(e,t,n)=>(yl(e,"symbol"!=typeof t?t+"":t,n),n),_l=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},_i=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},En=(e,t,n)=>(_l(e,t,"access private method"),n);const Sr={"Content-Type":"application/json"},Ge=e=>e.replace(/\/?$/,"/")+"api/",vt=(e,t="")=>{if("object"==typeof e&&e.errno)throw new TypeError(`${t} failed with ${e.errno}: `+e.errmsg);return e},ki=({serverURL:e,lang:t,paths:n,type:r,signal:i})=>fetch(`${Ge(e)}article?path=${encodeURIComponent(n.join(","))}&type=${encodeURIComponent(r.join(","))}&lang=`+t,{signal:i}).then(e=>e.json()).then(e=>vt(e,"Get counter").data),Sn=({serverURL:e,lang:t,path:n,type:r,action:i})=>fetch(Ge(e)+"article?lang="+t,{method:"POST",headers:Sr,body:JSON.stringify({path:n,type:r,action:i})}).then(e=>e.json()).then(e=>vt(e,"Update counter").data),Ir=({serverURL:e,lang:t,path:n,page:r,pageSize:i,sortBy:l,signal:o,token:s})=>{const a={};return s&&(a.Authorization="Bearer "+s),fetch(`${Ge(e)}comment?path=${encodeURIComponent(n)}&pageSize=${i}&page=${r}&lang=${t}&sortBy=`+l,{signal:o,headers:a}).then(e=>e.json()).then(e=>vt(e,"Get comment data").data)},Rr=({serverURL:e,lang:t,token:n,comment:r})=>{const i={"Content-Type":"application/json"};return n&&(i.Authorization="Bearer "+n),fetch(Ge(e)+"comment?lang="+t,{method:"POST",headers:i,body:JSON.stringify(r)}).then(e=>e.json())},Tr=({serverURL:e,lang:t,token:n,objectId:r})=>fetch(Ge(e)+`comment/${r}?lang=`+t,{method:"DELETE",headers:{Authorization:"Bearer "+n}}).then(e=>e.json()).then(e=>vt(e,"Delete comment")),qt=({serverURL:e,lang:t,token:n,objectId:r,comment:i})=>fetch(Ge(e)+`comment/${r}?lang=`+t,{method:"PUT",headers:{...Sr,Authorization:"Bearer "+n},body:JSON.stringify(i)}).then(e=>e.json()).then(e=>vt(e,"Update comment")),Lr=({serverURL:e,lang:t,paths:n,signal:r})=>fetch(`${Ge(e)}comment?type=count&url=${encodeURIComponent(n.join(","))}&lang=`+t,{signal:r}).then(e=>e.json()).then(e=>vt(e,"Get comment count").data),Ar=({lang:e,serverURL:t})=>{const n=(window.innerWidth-450)/2,r=(window.innerHeight-450)/2,i=window.open(t.replace(/\/$/,"")+"/ui/login?lng="+encodeURIComponent(e),"_blank",`width=450,height=450,left=${n},top=${r},scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no`);return null!=i&&i.postMessage({type:"TOKEN",data:null},"*"),new Promise(t=>{const n=({data:e})=>{e&&"object"==typeof e&&"userInfo"===e.type&&e.data.token&&(null!=i&&i.close(),window.removeEventListener("message",n),t(e.data))};window.addEventListener("message",n)})},Mr=({serverURL:e,lang:t,paths:n,signal:r})=>ki({serverURL:e,lang:t,paths:n,type:["time"],signal:r}),$r=e=>Sn({...e,type:"time",action:"inc"}),Or=({serverURL:e,lang:t,count:n,signal:r,token:i})=>{const l={};return i&&(l.Authorization="Bearer "+i),fetch(Ge(e)+`comment?type=recent&count=${n}&lang=`+t,{signal:r,headers:l}).then(e=>e.json())},jr=({serverURL:e,signal:t,pageSize:n,lang:r})=>fetch(Ge(e)+`user?pageSize=${n}&lang=`+r,{signal:t}).then(e=>e.json()).then(e=>vt(e,"user list")).then(e=>e.data),kl=["nick","mail","link"],zr=e=>e.filter(e=>kl.includes(e)),Pr=["//unpkg.com/@waline/emojis@1.1.0/weibo"],xl=["//unpkg.com/@waline/emojis/tieba/tieba_agree.png","//unpkg.com/@waline/emojis/tieba/tieba_look_down.png","//unpkg.com/@waline/emojis/tieba/tieba_sunglasses.png","//unpkg.com/@waline/emojis/tieba/tieba_pick_nose.png","//unpkg.com/@waline/emojis/tieba/tieba_awkward.png","//unpkg.com/@waline/emojis/tieba/tieba_sleep.png"],Cl=r=>new Promise((t,e)=>{if(128e3{var e;return t((null==(e=n.result)?void 0:e.toString())??"")},n.onerror=e}),El=e=>!0===e?'

TeX is not available in preview

':'TeX is not available in preview',Sl=n=>{const r=async(e,t={})=>fetch(`https://api.giphy.com/v1/gifs/${e}?`+new URLSearchParams({lang:n,limit:"20",rating:"g",api_key:"6CIMLkNMMOhRcXPoMCPkFy4Ybk2XUiMp",...t}).toString()).then(e=>e.json()).then(({data:e})=>e.map(e=>({title:e.title,src:e.images.downsized_medium.url})));return{search:e=>r("search",{q:e,offset:"0"}),default:()=>r("trending",{}),more:(e,t=0)=>r("search",{q:e,offset:t.toString()})}},Il=/[\u4E00-\u9FFF\u3400-\u4dbf\uf900-\ufaff\u3040-\u309f\uac00-\ud7af\u0400-\u04FF]+|\w+/,Rl=/{let i=0;return e.replace(Al,(e,t,n)=>{if(n)return`${n}`;if("<"===t)return"<";let r;xi[t]?r=xi[t]:(r=Fr[i],xi[t]=r);n=`${t}`;return i=++i%Fr.length,n})},$l=["nick","nickError","mail","mailError","link","optional","placeholder","sofa","submit","like","cancelLike","reply","cancelReply","comment","refresh","more","preview","emoji","uploadImage","seconds","minutes","hours","days","now","uploading","login","logout","admin","sticky","word","wordHint","anonymous","level0","level1","level2","level3","level4","level5","gif","gifSearchPlaceholder","profile","approved","waiting","spam","unsticky","oldest","latest","hottest","reactionTitle"],Ze=e=>Object.fromEntries(e.map((e,t)=>[$l[t],e]));var Ur=Ze(["NickName","NickName cannot be less than 3 bytes.","E-Mail","Please confirm your email address.","Website","Optional","Comment here...","No comment yet.","Submit","Like","Cancel like","Reply","Cancel reply","Comments","Refresh","Load More...","Preview","Emoji","Upload Image","seconds ago","minutes ago","hours ago","days ago","just now","Uploading","Login","logout","Admin","Sticky","Words",`Please input comments between $0 and $1 words! + Current word number: $2`,"Anonymous","Dwarves","Hobbits","Ents","Wizards","Elves","Maiar","GIF","Search GIF","Profile","Approved","Waiting","Spam","Unsticky","Oldest","Latest","Hottest","What do you think?"]),Nr=Ze(["Pseudo","Le pseudo ne peut pas faire moins de 3 octets.","E-mail","Veuillez confirmer votre adresse e-mail.","Site Web","Optionnel","Commentez ici...","Aucun commentaire pour l'instant.","Envoyer","J'aime","Annuler le j'aime","Répondre","Annuler la réponse","Commentaires","Actualiser","Charger plus...","Aperçu","Emoji","Télécharger une image","Il y a quelques secondes","Il y a quelques minutes","Il y a quelques heures","Il y a quelques jours","À l'instant","Téléchargement en cours","Connexion","Déconnexion","Admin","Épinglé","Mots",`Veuillez saisir des commentaires entre $0 et $1 mots ! + Nombre actuel de mots : $2`,"Anonyme","Nains","Hobbits","Ents","Mages","Elfes","Maïar","GIF","Rechercher un GIF","Profil","Approuvé","En attente","Indésirable","Détacher","Le plus ancien","Dernier","Le plus populaire","Qu'en pensez-vous ?"]),Hr=Ze(["ニックネーム","3バイト以上のニックネームをご入力ください.","メールアドレス","メールアドレスをご確認ください.","サイト","オプション","ここにコメント","コメントしましょう~","提出する","Like","Cancel like","返信する","キャンセル","コメント","更新","さらに読み込む","プレビュー","絵文字","画像をアップロード","秒前","分前","時間前","日前","たっだ今","アップロード","ログインする","ログアウト","管理者","トップに置く","ワード",`コメントは $0 から $1 ワードの間でなければなりません! + 現在の単語番号: $2`,"匿名","うえにん","なかにん","しもおし","特にしもおし","かげ","なぬし","GIF","探す GIF","個人情報","承認済み","待っている","スパム","べたつかない","逆順","正順","人気順","どう思いますか?"]),Ol=Ze(["Apelido","Apelido não pode ser menor que 3 bytes.","E-Mail","Por favor, confirme seu endereço de e-mail.","Website","Opcional","Comente aqui...","Nenhum comentário, ainda.","Enviar","Like","Cancel like","Responder","Cancelar resposta","Comentários","Refrescar","Carregar Mais...","Visualizar","Emoji","Enviar Imagem","segundos atrás","minutos atrás","horas atrás","dias atrás","agora mesmo","Enviando","Entrar","Sair","Admin","Sticky","Palavras",`Favor enviar comentário com $0 a $1 palavras! + Número de palavras atuais: $2`,"Anônimo","Dwarves","Hobbits","Ents","Wizards","Elves","Maiar","GIF","Pesquisar GIF","informação pessoal","Aprovado","Espera","Spam","Unsticky","Mais velho","Mais recentes","Mais quente","O que você acha?"]),Dr=Ze(["Псевдоним","Никнейм не может быть меньше 3 байт.","Эл. адрес","Пожалуйста, подтвердите адрес вашей электронной почты.","Веб-сайт","Необязательный","Комментарий здесь...","Пока нет комментариев.","Отправить","Like","Cancel like","Отвечать","Отменить ответ","Комментарии","Обновить","Загрузи больше...","Превью","эмодзи","Загрузить изображение","секунд назад","несколько минут назад","несколько часов назад","дней назад","прямо сейчас","Загрузка","Авторизоваться","Выход из системы","Админ","Липкий","Слова",`Пожалуйста, введите комментарии от $0 до $1 слов! +Номер текущего слова: $2`,"Анонимный","Dwarves","Hobbits","Ents","Wizards","Elves","Maiar","GIF","Поиск GIF","Персональные данные","Одобренный","Ожидающий","Спам","Нелипкий","самый старый","последний","самый горячий","Что вы думаете?"]),Vr=Ze(["Tên","Tên không được nhỏ hơn 3 ký tự.","E-Mail","Vui lòng xác nhập địa chỉ email của bạn.","Website","Tùy chọn","Hãy bình luận có văn hoá!","Chưa có bình luận","Gửi","Thích","Bỏ thích","Trả lời","Hủy bỏ","bình luận","Làm mới","Tải thêm...","Xem trước","Emoji","Tải lên hình ảnh","giây trước","phút trước","giờ trước","ngày trước","Vừa xong","Đang tải lên","Đăng nhập","đăng xuất","Quản trị viên","Dính","từ",`Bình luận phải có độ dài giữa $0 và $1 từ! + Số từ hiện tại: $2`,"Vô danh","Người lùn","Người tí hon","Thần rừng","Pháp sư","Tiên tộc","Maiar","Ảnh GIF","Tìm kiếm ảnh GIF","thông tin cá nhân","Đã được phê duyệt","Đang chờ đợi","Thư rác","Không dính","lâu đời nhất","muộn nhất","nóng nhất","What do you think?"]),Br=Ze(["昵称","昵称不能少于3个字符","邮箱","请填写正确的邮件地址","网址","可选","欢迎评论","来发评论吧~","提交","喜欢","取消喜欢","回复","取消回复","评论","刷新","加载更多...","预览","表情","上传图片","秒前","分钟前","小时前","天前","刚刚","正在上传","登录","退出","博主","置顶","字",`评论字数应在 $0 到 $1 字之间! +当前字数:$2`,"匿名","潜水","冒泡","吐槽","活跃","话痨","传说","表情包","搜索表情包","个人资料","通过","待审核","垃圾","取消置顶","按倒序","按正序","按热度","你认为这篇文章怎么样?"]),jl=Ze(["暱稱","暱稱不能少於3個字元","郵箱","請填寫正確的郵件地址","網址","可選","歡迎留言","來發留言吧~","送出","喜歡","取消喜歡","回覆","取消回覆","留言","重整","載入更多...","預覽","表情","上傳圖片","秒前","分鐘前","小時前","天前","剛剛","正在上傳","登入","登出","管理者","置頂","字",`留言字數應在 $0 到 $1 字之間! +目前字數:$2`,"匿名","潛水","冒泡","吐槽","活躍","多話","傳說","表情包","搜尋表情包","個人資料","通過","待審核","垃圾","取消置頂","最早","最新","熱門","你認為這篇文章怎麼樣?"]),zl=Ze(["Benutzername","Der Benutzername darf nicht weniger als 3 Bytes umfassen.","E-Mail","Bitte bestätigen Sie Ihre E-Mail-Adresse.","Webseite","Optional","Kommentieren Sie hier...","Noch keine Kommentare.","Senden","Gefällt mir","Gefällt mir nicht mehr","Antworten","Antwort abbrechen","Kommentare","Aktualisieren","Mehr laden...","Vorschau","Emoji","Ein Bild hochladen","Vor einigen Sekunden","Vor einigen Minuten","Vor einigen Stunden","Vor einigen Tagen","Gerade eben","Hochladen läuft","Anmelden","Abmelden","Admin","Angeheftet","Wörter","Bitte geben Sie Kommentare zwischen $0 und $1 Wörtern ein! Aktuelle Anzahl der Wörter: $2","Anonym","Zwerge","Hobbits","Ents","Magier","Elfen","Maïar","GIF","Nach einem GIF suchen","Profil","Genehmigt","Ausstehend","Spam","Lösen","Älteste","Neueste","Am beliebtesten","Was denken Sie?"]);const Wr="en-US",In={zh:Br,"zh-cn":Br,"zh-tw":jl,en:Ur,"en-us":Ur,fr:Nr,"fr-fr":Nr,jp:Hr,"jp-jp":Hr,"pt-br":Ol,ru:Dr,"ru-ru":Dr,vi:Vr,"vi-vn":Vr,de:zl},qr=e=>In[e.toLowerCase()]||In[Wr.toLowerCase()],Kr=e=>Object.keys(In).includes(e.toLowerCase())?e:Wr,Gr=e=>{try{e=decodeURI(e)}catch{}return e},Zr=(e="")=>e.replace(/\/$/u,""),Qr=e=>/^(https?:)?\/\//.test(e),Rn=e=>{e=Zr(e);return Qr(e)?e:"https://"+e},Pl=e=>Array.isArray(e)?e:!!e&&[0,e],Ci=(e,t)=>"function"==typeof e?e:!1!==e&&t,Fl=({serverURL:e,path:t=location.pathname,lang:n="u"({serverURL:Rn(e),path:Gr(t),lang:Kr(n),locale:{...qr(Kr(n)),..."object"==typeof r?r:{}},wordLimit:Pl(c),meta:zr(l),requiredMeta:zr(o),imageUploader:Ci(u,Cl),highlighter:Ci(p,Ml),texRenderer:Ci(d,El),dark:s,emoji:"boolean"==typeof i?i?Pr:[]:i,pageSize:a,login:f,copyright:h,search:!1!==g&&("object"==typeof g?g:Sl(n)),recaptchaV3Key:v,turnstileKey:y,reaction:Array.isArray(m)?m:!0===m?xl:[],commentSorting:w,...b}),$t=e=>"string"==typeof e,Ei="{--waline-white:#000;--waline-light-grey:#666;--waline-dark-grey:#999;--waline-color:#888;--waline-bg-color:#1e1e1e;--waline-bg-color-light:#272727;--waline-bg-color-hover: #444;--waline-border-color:#333;--waline-disable-bg-color:#444;--waline-disable-color:#272727;--waline-bq-color:#272727;--waline-info-bg-color:#272727;--waline-info-color:#666}",Ul=e=>$t(e)?"auto"===e?`@media(prefers-color-scheme:dark){body${Ei}}`:""+e+Ei:!0===e?":root"+Ei:"",Si=(e,t)=>{let n=e.toString();for(;n.length{var t=Si(e.getDate(),2),n=Si(e.getMonth()+1,2);return Si(e.getFullYear(),2)+`-${n}-`+t},Hl=(e,t,n)=>{if(!e)return"";const r=$t(e)?new Date(-1!==e.indexOf(" ")?e.replace(/-/g,"/"):e):e,i=t.getTime()-r.getTime(),l=Math.floor(i/864e5);var o;return 0===l?(e=i%864e5,0===(t=Math.floor(e/36e5))?(e=e%36e5,0===(o=Math.floor(e/6e4))?Math.round(e%6e4/1e3)+" "+n.seconds:o+" "+n.minutes):t+" "+n.hours):l<0?n.now:l<8?l+" "+n.days:Nl(r)},Dl=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Vl=e=>Dl.test(e);function Ii(e,t){const n=new Set(e.split(","));return e=>n.has(e)}const se={},Ot=[],Qe=()=>{},Bl=()=>!1,Tn=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&(122e.startsWith("onUpdate:"),be=Object.assign,Jr=(e,t)=>{t=e.indexOf(t);-1Wl.call(e,t),N=Array.isArray,jt=e=>"[object Map]"===Kt(e),zt=e=>"[object Set]"===Kt(e),Yr=e=>"[object Date]"===Kt(e),ee=e=>"function"==typeof e,ve=e=>"string"==typeof e,Je=e=>"symbol"==typeof e,ce=e=>null!==e&&"object"==typeof e,Xr=e=>(ce(e)||ee(e))&&ee(e.then)&&ee(e.catch),eo=Object.prototype.toString,Kt=e=>eo.call(e),ql=e=>Kt(e).slice(8,-1),to=e=>"[object Object]"===Kt(e),Ti=e=>ve(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,Gt=Ii(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Ln=t=>{const n=Object.create(null);return e=>n[e]||(n[e]=t(e))},Kl=/-(\w)/g,Ve=Ln(e=>e.replace(Kl,(e,t)=>t?t.toUpperCase():"")),Gl=/\B([A-Z])/g,Pt=Ln(e=>e.replace(Gl,"-$1").toLowerCase()),An=Ln(e=>e.charAt(0).toUpperCase()+e.slice(1)),Li=Ln(e=>e?"on"+An(e):""),lt=(e,t)=>!Object.is(e,t),Mn=(t,n)=>{for(let e=0;e{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},$n=e=>{var t=parseFloat(e);return isNaN(t)?e:t};let io;const Ai=()=>io=io||(typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Zt(t){if(N(t)){const i={};for(let e=0;e{if(e){const t=e.split(Ql);1wt(e,t))}const Q=e=>ve(e)?e:null==e?"":N(e)||ce(e)&&(e.toString===eo||!ee(e.toString))?JSON.stringify(e,oo,2):String(e),oo=(e,t)=>t&&t.__v_isRef?oo(e,t.value):jt(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[$i(t,r)+" =>"]=n,e),{})}:zt(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>$i(e))}:Je(t)?$i(t):!ce(t)||N(t)||to(t)?t:String(t),$i=(e,t="")=>{var n;return Je(e)?`Symbol(${null!=(n=e.description)?n:t})`:e};let Me;class na{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Me,!e&&Me&&(this.index=(Me.scopes||(Me.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){var t=Me;try{return Me=this,e()}finally{Me=t}}}on(){Me=this}off(){Me=this.parent}stop(n){if(this._active){let e,t;for(e=0,t=this.effects.length;et._depsLength){for(let e=t._depsLength;e{const n=new Map;return n.cleanup=e,n.computed=t,n},Ui=new WeakMap,kt=Symbol(""),Ni=Symbol("");function Ie(n,e,r){if(at&&bt){let e=Ui.get(n),t=(e||Ui.set(n,e=new Map),e.get(r));t||e.set(r,t=po(()=>e.delete(r))),fo(bt,t)}}function Ye(e,t,r,i,n,l){const o=Ui.get(e);if(o){let n=[];if("clear"===t)n=[...o.values()];else if("length"===r&&N(e)){const s=Number(i);o.forEach((e,t)=>{("length"===t||!Je(t)&&t>=s)&&n.push(e)})}else switch(void 0!==r&&n.push(o.get(r)),t){case"add":N(e)?Ti(r)&&n.push(o.get("length")):(n.push(o.get(kt)),jt(e)&&n.push(o.get(Ni)));break;case"delete":N(e)||(n.push(o.get(kt)),jt(e)&&n.push(o.get(Ni)));break;case"set":jt(e)&&n.push(o.get(kt))}zi();for(const a of n)a&&ho(a,4);Pi()}}const oa=Ii("__proto__,__v_isRef,__isVue"),go=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>"arguments"!==e&&"caller"!==e).map(e=>Symbol[e]).filter(Je)),mo=sa();function sa(){const e={};return["includes","indexOf","lastIndexOf"].forEach(r=>{e[r]=function(...e){const n=J(this);for(let e=0,t=this.length;e{e[t]=function(...e){yt(),zi();e=J(this)[t].apply(this,e);return Pi(),_t(),e}}),e}function la(e){Je(e)||(e=String(e));const t=J(this);return Ie(t,"has",e),t.hasOwnProperty(e)}class vo{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){var r=this._isReadonly,i=this._isShallow;if("__v_isReactive"===t)return!r;if("__v_isReadonly"===t)return r;if("__v_isShallow"===t)return i;if("__v_raw"===t)return n===(r?i?ya:Eo:i?Co:xo).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;var l=N(e);if(!r){if(l&&G(mo,t))return Reflect.get(mo,t,n);if("hasOwnProperty"===t)return la}n=Reflect.get(e,t,n);return(Je(t)?go.has(t):oa(t))||(r||Ie(e,"get",t),i)?n:Re(n)?l&&Ti(t)?n:n.value:ce(n)?(r?Jt:Qt)(n):n}}class wo extends vo{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t];if(!this._isShallow){var l=Xt(i);if(Nn(n)||Xt(n)||(i=J(i),n=J(n)),!N(e)&&Re(i)&&!Re(n))return!l&&(i.value=n,!0)}var l=N(e)&&Ti(t)?Number(t)e,On=e=>Reflect.getPrototypeOf(e);function jn(e,t,n=!1,r=!1){var i=J(e=e.__v_raw),l=J(t);n||(lt(t,l)&&Ie(i,"get",t),Ie(i,"get",l));const o=On(i)["has"],s=r?Hi:n?Bi:en;return o.call(i,t)?s(e.get(t)):o.call(i,l)?s(e.get(l)):void(e!==i&&e.get(t))}function zn(e,t=!1){const n=this.__v_raw,r=J(n),i=J(e);return t||(lt(e,i)&&Ie(r,"has",e),Ie(r,"has",i)),e===i?n.has(e):n.has(e)||n.has(i)}function Pn(e,t=!1){return e=e.__v_raw,t||Ie(J(e),"iterate",kt),Reflect.get(e,"size",e)}function bo(e){e=J(e);const t=J(this);return On(t).has.call(t,e)||(t.add(e),Ye(t,"add",e,e)),this}function yo(e,t){t=J(t);const n=J(this),{has:r,get:i}=On(n);let l=r.call(n,e);l||(e=J(e),l=r.call(n,e));var o=i.call(n,e);return n.set(e,t),l?lt(t,o)&&Ye(n,"set",e,t):Ye(n,"add",e,t),this}function _o(e){const t=J(this),{has:n,get:r}=On(t);let i=n.call(t,e);i||(e=J(e),i=n.call(t,e)),r&&r.call(t,e);var l=t.delete(e);return i&&Ye(t,"delete",e,void 0),l}function ko(){const e=J(this),t=0!==e.size,n=e.clear();return t&&Ye(e,"clear",void 0,void 0),n}function Fn(o,s){return function(n,r){const i=this,e=i.__v_raw,t=J(e),l=s?Hi:o?Bi:en;return o||Ie(t,"iterate",kt),e.forEach((e,t)=>n.call(r,l(e),l(t),i))}}function Un(a,c,u){return function(...e){const t=this.__v_raw,n=J(t),r=jt(n),i="entries"===a||a===Symbol.iterator&&r,l="keys"===a&&r,o=t[a](...e),s=u?Hi:c?Bi:en;return c||Ie(n,"iterate",l?Ni:kt),{next(){var{value:e,done:t}=o.next();return t?{value:e,done:t}:{value:i?[s(e[0]),s(e[1])]:s(e),done:t}},[Symbol.iterator](){return this}}}}function ct(e){return function(){return"delete"!==e&&("clear"===e?void 0:this)}}function da(){const t={get(e){return jn(this,e)},get size(){return Pn(this)},has:zn,add:bo,set:yo,delete:_o,clear:ko,forEach:Fn(!1,!1)},n={get(e){return jn(this,e,!1,!0)},get size(){return Pn(this)},has:zn,add:bo,set:yo,delete:_o,clear:ko,forEach:Fn(!1,!0)},r={get(e){return jn(this,e,!0)},get size(){return Pn(this,!0)},has(e){return zn.call(this,e,!0)},add:ct("add"),set:ct("set"),delete:ct("delete"),clear:ct("clear"),forEach:Fn(!0,!1)},i={get(e){return jn(this,e,!0,!0)},get size(){return Pn(this,!0)},has(e){return zn.call(this,e,!0)},add:ct("add"),set:ct("set"),delete:ct("delete"),clear:ct("clear"),forEach:Fn(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(e=>{t[e]=Un(e,!1,!1),r[e]=Un(e,!0,!1),n[e]=Un(e,!1,!0),i[e]=Un(e,!0,!0)}),[t,r,n,i]}const[ha,pa,ga,ma]=da();function Di(r,e){const i=e?r?ma:ga:r?pa:ha;return(e,t,n)=>"__v_isReactive"===t?!r:"__v_isReadonly"===t?r:"__v_raw"===t?e:Reflect.get(G(i,t)&&t in e?i:e,t,n)}const va={get:Di(!1,!1)},wa={get:Di(!1,!0)},ba={get:Di(!0,!1)},xo=new WeakMap,Co=new WeakMap,Eo=new WeakMap,ya=new WeakMap;function _a(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function ka(e){return e.__v_skip||!Object.isExtensible(e)?0:_a(ql(e))}function Qt(e){return Xt(e)?e:Vi(e,!1,ca,va,xo)}function xa(e){return Vi(e,!1,fa,wa,Co)}function Jt(e){return Vi(e,!0,ua,ba,Eo)}function Vi(e,t,n,r,i){if(!ce(e)||e.__v_raw&&(!t||!e.__v_isReactive))return e;t=i.get(e);if(t)return t;t=ka(e);if(0===t)return e;t=new Proxy(e,2===t?r:n);return i.set(e,t),t}function Yt(e){return Xt(e)?Yt(e.__v_raw):!(!e||!e.__v_isReactive)}function Xt(e){return!(!e||!e.__v_isReadonly)}function Nn(e){return!(!e||!e.__v_isShallow)}function So(e){return!!e&&!!e.__v_raw}function J(e){var t=e&&e.__v_raw;return t?J(t):e}function Ca(e){return Object.isExtensible(e)&&no(e,"__v_skip",!0),e}const en=e=>ce(e)?Qt(e):e,Bi=e=>ce(e)?Jt(e):e;class Io{constructor(e,t,n,r){this.getter=e,this._setter=t,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new Oi(()=>e(this._value),()=>Hn(this,2===this.effect._dirtyLevel?2:3)),(this.effect.computed=this).effect.active=this._cacheable=!r,this.__v_isReadonly=n}get value(){const e=J(this);return e._cacheable&&!e.effect.dirty||!lt(e._value,e._value=e.effect.run())||Hn(e,4),Ro(e),2<=e.effect._dirtyLevel&&Hn(e,2),e._value}set value(e){this._setter(e)}get _dirty(){return this.effect.dirty}set _dirty(e){this.effect.dirty=e}}function Ea(e,t,n=!1){let r,i;var l=ee(e);return i=l?(r=e,Qe):(r=e.get,e.set),new Io(r,i,l||!i,n)}function Ro(e){var t;at&&bt&&(e=J(e),fo(bt,null!=(t=e.dep)?t:e.dep=po(()=>e.dep=void 0,e instanceof Io?e:void 0)))}function Hn(e,t=4,n){e=(e=J(e)).dep;e&&ho(e,t)}function Re(e){return!(!e||!0!==e.__v_isRef)}function W(e){return To(e,!1)}function Sa(e){return To(e,!0)}function To(e,t){return Re(e)?e:new Ia(e,t)}class Ia{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!0,this._rawValue=t?e:J(e),this._value=t?e:en(e)}get value(){return Ro(this),this._value}set value(e){var t=this.__v_isShallow||Nn(e)||Xt(e);e=t?e:J(e),lt(e,this._rawValue)&&(this._rawValue=e,this._value=t?e:en(e),Hn(this,4))}}function Lo(e){return Re(e)?e.value:e}const Ra={get:(e,t,n)=>Lo(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const i=e[t];return Re(i)&&!Re(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function Ao(e){return Yt(e)?e:new Proxy(e,Ra)}function ut(e,t,n,r){try{return r?e(...r):e()}catch(e){Dn(e,t,n)}}function Be(t,n,r,i){if(ee(t)){const e=ut(t,n,r,i);return e&&Xr(e)&&e.catch(e=>{Dn(e,n,r)}),e}if(N(t)){const l=[];for(let e=0;e>>1,i=ye[r],l=nn(i);lWe&&ye.splice(e,1)}function Ma(e){N(e)?Ft.push(...e):ft&&ft.includes(e,e.allowRecurse?xt+1:xt)||Ft.push(e),$o()}function Oo(e,t,n=tn?We+1:0){for(;nnn(e)-nn(t));if(Ft.length=0,ft)ft.push(...t);else{for(ft=t,xt=0;xtnull==e.id?1/0:e.id,$a=(e,t)=>{var n=nn(e)-nn(t);if(0==n){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function zo(e){Wi=!1,tn=!0,ye.sort($a);try{for(We=0;Weve(e)?e.trim():e)),a&&(e=l.map($n)));let t,n=o[t=Li(i)]||o[t=Li(Ve(i))];(n=!n&&s?o[t=Li(Pt(i))]:n)&&Be(n,r,6,e);var c=o[t+"Once"];if(c){if(r.emitted){if(r.emitted[t])return}else r.emitted={};r.emitted[t]=!0,Be(c,r,6,e)}}}function ja(e,t,n=0){const r=t.emitsCache,i=r.get(e);if(void 0!==i)return i;const l=e.emits;let o={};return l?(N(l)?l.forEach(e=>o[e]=null):be(o,l),ce(e)&&r.set(e,o),o):(ce(e)&&r.set(e,null),null)}function Vn(e,t){return!(!e||!Tn(t))&&(t=t.slice(2).replace(/Once$/,""),G(e,t[0].toLowerCase()+t.slice(1))||G(e,Pt(t))||G(e,t))}let xe=null,Po=null;function Bn(e){var t=xe;return xe=e,Po=e&&e.type.__scopeId||null,t}function za(r,i=xe,e){if(!i||r._n)return r;const l=(...e)=>{l._d&&ss(-1);var t=Bn(i);let n;try{n=r(...e)}finally{Bn(t),l._d&&ss(1)}return n};return l._n=!0,l._c=!0,l._d=!0,l}function Gi(t){const{type:e,vnode:n,proxy:r,withProxy:i,propsOptions:[l],slots:o,attrs:s,emit:a,render:c,renderCache:u,props:p,data:d,setupState:h,ctx:f,inheritAttrs:g}=t,m=Bn(t);let v,y;try{if(4&n.shapeFlag){var w=i||r,b=w;v=qe(c.call(b,w,u,p,h,d,f)),y=s}else{const x=e;v=qe(1{let t;for(const n in e)"class"!==n&&"style"!==n&&!Tn(n)||((t=t||{})[n]=e[n]);return t},Fa=(e,t)=>{const n={};for(const r in e)Ri(r)&&r.slice(9)in t||(n[r]=e[r]);return n};function Ua(e,t,n){var{props:r,children:e,component:i}=e,{props:l,children:o,patchFlag:s}=t,a=i.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&0<=s))return!(!e&&!o||o&&o.$stable)||r!==l&&(r?!l||Fo(r,l,a):!!l);if(1024&s)return!0;if(16&s)return r?Fo(r,l,a):!!l;if(8&s){var c=t.dynamicProps;for(let e=0;ee.__isSuspense;function qa(e,t){t&&t.pendingBranch?N(e)?t.effects.push(...e):t.effects.push(e):Ma(e)}const Ka=Symbol.for("v-scx"),Ga=()=>Zn(Ka);function No(e,t){return Ho(e,null,t)}const Wn={};function je(e,t,n){return Ho(e,t,n)}function Ho(e,t,{immediate:n,deep:r,flush:i,once:l}=se){if(t&&l){const b=t;t=(...e)=>{b(...e),w()}}const o=Ee,s=e=>!0===r?e:Ct(e,!1===r?1:void 0);let a,c=!1,u=!1;if(Re(e)?(a=()=>e.value,c=Nn(e)):Yt(e)?(a=()=>s(e),c=!0):a=N(e)?(u=!0,c=e.some(e=>Yt(e)||Nn(e)),()=>e.map(e=>Re(e)?e.value:Yt(e)?s(e):ee(e)?ut(e,o,2):void 0)):ee(e)?t?()=>ut(e,o,2):()=>(p&&p(),Be(e,o,3,[d])):Qe,t&&r){const k=a;a=()=>Ct(k())}let p,d=e=>{p=v.onStop=()=>{ut(e,o,4),p=v.onStop=void 0}},h;if(Xn){if(d=Qe,t?n&&Be(t,o,3,[a(),u?[]:void 0,d]):a(),"sync"!==i)return Qe;{const x=Ga();h=x.__watcherHandles||(x.__watcherHandles=[])}}let f=u?new Array(e.length).fill(Wn):Wn;const g=()=>{if(v.active&&v.dirty)if(t){const e=v.run();(r||c||(u?e.some((e,t)=>lt(e,f[t])):lt(e,f)))&&(p&&p(),Be(t,o,3,[e,f===Wn?void 0:u&&f[0]===Wn?[]:f,d]),f=e)}else v.run()};g.allowRecurse=!!t;let m;m="sync"===i?g:"post"===i?()=>Te(g,o&&o.suspense):(g.pre=!0,o&&(g.id=o.uid),()=>Ki(g));const v=new Oi(a,Qe,m),y=so(),w=()=>{v.stop(),y&&Jr(y.effects,v)};return t?n?g():f=v.run():"post"===i?Te(v.run.bind(v),o&&o.suspense):v.run(),h&&h.push(w),w}function Ct(t,n=1/0,r){if(n<=0||!ce(t)||t.__v_skip||(r=r||new Set).has(t))return t;if(r.add(t),n--,Re(t))Ct(t.value,n,r);else if(N(t))for(let e=0;e{Ct(e,n,r)});else if(to(t))for(const e in t)Ct(t[e],n,r);return t}function qn(e,l){if(null===xe)return e;const o=ei(xe)||xe.proxy,s=e.dirs||(e.dirs=[]);for(let i=0;i!!e.type.__asyncLoader,Za=e=>e.type.__isKeepAlive;function Qa(r,i,l=Ee,e=!1){if(l){const t=l[r]||(l[r]=[]),n=i.__weh||(i.__weh=(...e)=>{if(!l.isUnmounted){yt();const t=lr(l),n=Be(i,l,r,e);return t(),_t(),n}});return e?t.unshift(n):t.push(n),n}}const Zi=n=>(t,e=Ee)=>(!Xn||"sp"===n)&&Qa(n,(...e)=>t(...e),e),on=Zi("m"),Ja=Zi("bum"),Qi=Zi("um");function ze(n,r,e,t){let i;const l=e;if(N(n)||ve(n)){i=new Array(n.length);for(let e=0,t=n.length;er(e,t,void 0,l));else{var o=Object.keys(n);i=new Array(o.length);for(let e=0,t=o.length;ee?us(e)?ei(e)||e.proxy:Ji(e.parent):null,sn=be(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Ji(e.parent),$root:e=>Ji(e.root),$emit:e=>e.emit,$options:e=>e.type,$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,Ki(e.update)}),$nextTick:e=>e.n||(e.n=Ut.bind(e.proxy)),$watch:e=>Qe}),Yi=(e,t)=>e!==se&&!e.__isScriptSetup&&G(e,t),Ya={get({_:e},t){if("__v_skip"===t)return!0;const{ctx:n,setupState:r,data:i,props:l,accessCache:o,type:s,appContext:a}=e;if("$"!==t[0]){var c=o[t];if(void 0!==c)switch(c){case 1:return r[t];case 2:return i[t];case 4:return n[t];case 3:return l[t]}else{if(Yi(r,t))return o[t]=1,r[t];if(i!==se&&G(i,t))return o[t]=2,i[t];if((c=e.propsOptions[0])&&G(c,t))return o[t]=3,l[t];if(n!==se&&G(n,t))return o[t]=4,n[t];o[t]=0}}const u=sn[t];let p,d;return u?("$attrs"===t&&Ie(e.attrs,"get",""),u(e)):(p=s.__cssModules)&&(p=p[t])?p:n!==se&&G(n,t)?(o[t]=4,n[t]):(d=a.config.globalProperties,G(d,t)?d[t]:void 0)},set({_:e},t,n){const{data:r,setupState:i,ctx:l}=e;return Yi(i,t)?(i[t]=n,!0):r!==se&&G(r,t)?(r[t]=n,!0):!(G(e.props,t)||"$"===t[0]&&t.slice(1)in e)&&(l[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,propsOptions:l}},o){return!!n[o]||e!==se&&G(e,o)||Yi(t,o)||(n=l[0])&&G(n,o)||G(r,o)||G(sn,o)||G(i.config.globalProperties,o)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:G(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Do(e){return N(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}function Xa(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:l,config:{optionMergeStrategies:o}}=e.appContext,s=l.get(t);let a;return s?a=s:i.length||n||r?(a={},i.length&&i.forEach(e=>Gn(a,e,o,!0)),Gn(a,t,o)):a=t,ce(t)&&l.set(t,a),a}function Gn(t,e,n,r=!1){const{mixins:i,extends:l}=e;l&&Gn(t,l,n,!0),i&&i.forEach(e=>Gn(t,e,n,!0));for(const o in e)if(!r||"expose"!==o){const s=ec[o]||n&&n[o];t[o]=s?s(t[o],e[o]):e[o]}return t}const ec={data:Vo,props:Wo,emits:Wo,methods:ln,computed:ln,beforeCreate:Ce,created:Ce,beforeMount:Ce,mounted:Ce,beforeUpdate:Ce,updated:Ce,beforeDestroy:Ce,beforeUnmount:Ce,destroyed:Ce,unmounted:Ce,activated:Ce,deactivated:Ce,errorCaptured:Ce,serverPrefetch:Ce,components:ln,directives:ln,watch:nc,provide:Vo,inject:tc};function Vo(e,t){return t?e?function(){return be(ee(e)?e.call(this,this):e,ee(t)?t.call(this,this):t)}:t:e}function tc(e,t){return ln(Bo(e),Bo(t))}function Bo(t){if(N(t)){const n={};for(let e=0;eObject.create(Ko),Zo=e=>Object.getPrototypeOf(e)===Ko;function sc(e,t,n,r=!1){const i={},l=Go();e.propsDefaults=Object.create(null),Qo(e,t,i,l);for(const o in e.propsOptions[0])o in i||(i[o]=void 0);n?e.props=r?i:xa(i):e.type.props?e.props=i:e.props=l,e.attrs=l}function lc(t,n,r,e){const{props:i,attrs:l,vnode:{patchFlag:o}}=t,s=J(i),[a]=t.propsOptions;let c=!1;if(!(e||0Xo(e,t)):ee(e)&&Xo(e,t)?0:-1}const ts=e=>"_"===e[0]||"$stable"===e,er=e=>N(e)?e.map(qe):[qe(e)],cc=(e,t,n)=>{if(t._n)return t;const r=za((...e)=>er(t(...e)),n);return r._c=!1,r},ns=(e,t,n)=>{var r=e._ctx;for(const l in e)if(!ts(l)){var i=e[l];if(ee(i))t[l]=cc(l,i,r);else if(null!=i){const o=er(i);t[l]=()=>o}}},is=(e,t)=>{const n=er(t);e.slots.default=()=>n},uc=(e,t)=>{var n,r=e.slots=Go();32&e.vnode.shapeFlag?(n=t._)?(be(r,t),no(r,"_",n,!0)):ns(t,r):t&&is(e,t)},fc=(e,t,n)=>{const{vnode:r,slots:i}=e;let l=!0,o=se;var s;if(32&r.shapeFlag?((s=t._)?n&&1===s?l=!1:(be(i,t),n||1!==s||delete i._):(l=!t.$stable,ns(t,i)),o=t):t&&(is(e,t),o={default:1}),l)for(const a in i)ts(a)||null!=o[a]||delete i[a]};function tr(t,n,r,i,l=!1){if(N(t))t.forEach((e,t)=>tr(e,n&&(N(n)?n[t]:n),r,i,l));else if(!Kn(i)||l){const o=4&i.shapeFlag?ei(i.component)||i.component.proxy:i.el,s=l?null:o,{i:a,r:c}=t,u=n&&n.r,p=a.refs===se?a.refs={}:a.refs,d=a.setupState;if(null!=u&&u!==c&&(ve(u)?(p[u]=null,G(d,u)&&(d[u]=null)):Re(u)&&(u.value=null)),ee(c))ut(c,a,12,[s,p]);else{const h=ve(c),f=Re(c);var e;(h||f)&&(e=()=>{if(t.f){const e=h?(G(d,c)?d:p)[c]:c.value;l?N(e)&&Jr(e,o):N(e)?e.includes(o)||e.push(o):h?(p[c]=[o],G(d,c)&&(d[c]=p[c])):(c.value=[o],t.k&&(p[t.k]=c.value))}else h?(p[c]=s,G(d,c)&&(d[c]=s)):f&&(c.value=s,t.k&&(p[t.k]=s))},s?(e.id=-1,Te(e,r)):e())}}}function dc(){"boolean"!=typeof __VUE_PROD_HYDRATION_MISMATCH_DETAILS__&&(Ai().__VUE_PROD_HYDRATION_MISMATCH_DETAILS__=!1)}const Te=qa;function hc(e){return pc(e)}function pc(e,o){dc();const t=Ai(),{insert:O,remove:g,patchProp:y,createElement:m,createText:P,createComment:i,setText:N,setElementText:S,parentNode:b,nextSibling:k,setScopeId:l=Qe,insertStaticContent:U}=(t.__VUE__=!0,e),E=(r,i,l,o=null,s=null,a=null,c=void 0,u=null,p=!!i.dynamicChildren)=>{if(r!==i){r&&!fn(r,i)&&(o=q(r),Z(r,s,a,!0),r=null),-2===i.patchFlag&&(p=!1,i.dynamicChildren=null);const{type:A,ref:$,shapeFlag:M}=i;switch(A){case Qn:var e=r,t=i,n=l,d=o;if(e==null)O(t.el=P(t.children),n,d);else{const T=t.el=e.el;t.children!==e.children&&N(T,t.children)}break;case It:V(r,i,l,o);break;case ir:null==r&&(n=i,d=l,e=o,t=c,[n.el,n.anchor]=U(n.children,d,e,t,n.el,n.anchor));break;case oe:{var h=r;var f=i;var g=l;var m=o;var v=s;var y=a;var w=c;var b=u;var k=p;const z=f.el=h?h.el:P(""),j=f.anchor=h?h.anchor:P("");let{patchFlag:e,dynamicChildren:t,slotScopeIds:n}=f;n&&(b=b?b.concat(n):n),h==null?(O(z,g,m),O(j,g,m),F(f.children||[],g,j,v,y,w,b,k)):e>0&&e&64&&t&&h.dynamicChildren?(D(h.dynamicChildren,t,g,v,y,w,b),(f.key!=null||v&&f===v.subTree)&&rs(h,f,!0)):G(h,f,g,j,v,y,w,b,k)}break;default:1&M?(m=r,h=l,f=o,g=s,v=a,y=c,w=u,b=p,"svg"===(k=i).type?y="svg":"math"===k.type&&(y="mathml"),null==m?W(k,h,f,g,v,y,w,b):H(m,k,g,v,y,w,b)):6&M?(x=r,S=l,C=o,L=s,R=a,I=c,E=p,(_=i).slotScopeIds=u,null==x?512&_.shapeFlag?L.ctx.activate(_,S,C,I,E):B(_,S,C,L,R,I,E):J(x,_,E)):(64&M||128&M)&&A.process(r,i,l,o,s,a,c,u,p,Q)}var x,_,S,C,L,R,I,E;null!=$&&s&&tr($,r&&r.ref,a,i||r,!i)}},V=(e,t,n,r)=>{null==e?O(t.el=i(t.children||""),n,r):t.el=e.el},W=(e,t,n,r,i,l,o,s)=>{let a,c;const{props:u,shapeFlag:p,transition:d,dirs:h}=e;if(a=e.el=m(e.type,l,u&&u.is,u),8&p?S(a,e.children):16&p&&F(e.children,a,null,r,i,nr(e,l),o,s),h&&Et(e,null,r,"created"),v(a,e,e.scopeId,o,r),u){for(const g in u)"value"===g||Gt(g)||y(a,g,null,u[g],l,e.children,r,i,L);"value"in u&&y(a,"value",null,u.value,l),(c=u.onVnodeBeforeMount)&&Ke(c,r,e)}h&&Et(e,null,r,"beforeMount");const f=gc(i,d);f&&d.beforeEnter(a),O(a,t,n),((c=u&&u.onVnodeMounted)||f||h)&&Te(()=>{c&&Ke(c,r,e),f&&d.enter(a),h&&Et(e,null,r,"mounted")},i)},v=(t,e,n,r,i)=>{if(n&&l(t,n),r)for(let e=0;e{for(let e=c;e{var s=e.el=t.el;let{patchFlag:a,dynamicChildren:c,dirs:u}=e;a|=16&t.patchFlag;var p=t.props||se,d=e.props||se;let h;if(n&&St(n,!1),(h=d.onVnodeBeforeUpdate)&&Ke(h,n,e,t),u&&Et(e,t,n,"beforeUpdate"),n&&St(n,!0),c?D(t.dynamicChildren,c,s,n,r,nr(e,i),l):o||G(t,e,s,null,n,r,nr(e,i),l,!1),0{h&&Ke(h,n,e,t),u&&Et(e,t,n,"updated")},r)},D=(t,n,r,i,l,o,s)=>{for(let e=0;e{if(n!==r){if(n!==se)for(const c in n)Gt(c)||c in r||y(e,c,n[c],null,o,t.children,i,l,L);for(const u in r){var s,a;Gt(u)||(s=r[u])!==(a=n[u])&&"value"!==u&&y(e,u,a,s,o,t.children,i,l,L)}"value"in r&&y(e,"value",n.value,r.value,o)}},B=(e,t,n,r,i,l,o)=>{const s=e.component=Cc(e,r,i);Za(e)&&(s.ctx.renderer=Q),Sc(s),s.asyncDep?(i&&i.registerDep(s,a),e.el||(r=s.subTree=ie(It),V(null,r,t,n))):a(s,e,t,n,i,l,o)},J=(e,t,n)=>{const r=t.component=e.component;Ua(e,t,n)?r.asyncDep&&!r.asyncResolved?x(r,t,n):(r.next=t,Aa(r.update),r.effect.dirty=!0,r.update()):(t.el=e.el,r.vnode=t)},a=(d,h,f,g,m,v,y)=>{const w=()=>{if(d.isMounted){let{next:e,bu:t,u:n,parent:r,vnode:i}=d;{const c=os(d);if(c)return e&&(e.el=i.el,x(d,e,y)),void c.asyncDep.then(()=>{d.isUnmounted||w()})}let l=e,o;St(d,!1),e?(e.el=i.el,x(d,e,y)):e=i,t&&Mn(t),(o=e.props&&e.props.onVnodeBeforeUpdate)&&Ke(o,r,e,i),St(d,!0);var s=Gi(d),a=d.subTree;d.subTree=s,E(a,s,b(a.el),q(a),d,m,v),e.el=s.el,null===l&&Na(d,s.el),n&&Te(n,m),(o=e.props&&e.props.onVnodeUpdated)&&Te(()=>Ke(o,r,e,i),m)}else{let e;const{el:t,props:n}=h,{bm:r,m:i,parent:l}=d,o=Kn(h);if(St(d,!1),r&&Mn(r),!o&&(e=n&&n.onVnodeBeforeMount)&&Ke(e,l,h),St(d,!0),t&&R){const u=()=>{d.subTree=Gi(d),R(t,d.subTree,d,m,null)};o?h.type.__asyncLoader().then(()=>!d.isUnmounted&&u()):u()}else{a=d.subTree=Gi(d);E(null,a,f,g,d,m,v),h.el=a.el}if(i&&Te(i,m),!o&&(e=n&&n.onVnodeMounted)){const p=h;Te(()=>Ke(e,l,p),m)}(256&h.shapeFlag||l&&Kn(l.vnode)&&256&l.vnode.shapeFlag)&&d.a&&Te(d.a,m),d.isMounted=!0,h=f=g=null}},e=d.effect=new Oi(w,Qe,()=>Ki(t),d.scope),t=d.update=()=>{e.dirty&&e.run()};t.id=d.uid,St(d,!0),t()},x=(e,t,n)=>{var r=(t.component=e).vnode.props;e.vnode=t,e.next=null,lc(e,t.props,r,n),fc(e,t.children,n),yt(),Oo(e),_t()},G=(e,t,n,r,i,l,o,s,a=!1)=>{var c=e&&e.children,e=e?e.shapeFlag:0,u=t.children,{patchFlag:t,shapeFlag:p}=t;if(0k?L(d,g,m,!0,!1,x):F(h,f,t,g,m,v,y,w,x)}return}}8&p?(16&e&&L(c,i,l),u!==c&&S(n,u)):16&e?16&p?C(c,u,n,r,i,l,o,s,a):L(c,i,l,!0):(8&e&&S(n,""),16&p&&F(u,n,r,i,l,o,s,a))},C=(e,l,o,s,a,c,u,p,d)=>{let h=0;var f=l.length;let g=e.length-1,m=f-1;for(;h<=g&&h<=m;){var t=e[h],n=l[h]=(d?dt:qe)(l[h]);if(!fn(t,n))break;E(t,n,o,null,a,c,u,p,d),h++}for(;h<=g&&h<=m;){var r=e[g],i=l[m]=(d?dt:qe)(l[m]);if(!fn(r,i))break;E(r,i,o,null,a,c,u,p,d),g--,m--}if(h>g){if(h<=m)for(var v=m+1,y=vm)for(;h<=g;)Z(e[h],a,c,!0),h++;else{const C=h,L=h,R=new Map;for(h=L;h<=m;h++){var w=l[h]=(d?dt:qe)(l[h]);null!=w.key&&R.set(w.key,h)}let t,n=0;var b=m-L+1;let r=!1,i=0;const I=new Array(b);for(h=0;h=b)Z(k,a,c,!0);else{let e;if(null!=k.key)e=R.get(k.key);else for(t=L;t<=m;t++)if(0===I[t-L]&&fn(k,l[t])){e=t;break}void 0===e?Z(k,a,c,!0):(I[e-L]=h+1,e>=i?i=e:r=!0,E(k,l[e],o,null,a,c,u,p,d),n++)}}var x=r?mc(I):Ot;for(t=x.length-1,h=b-1;0<=h;h--){var _=L+h,S=l[_],_=_+1{const{el:l,type:o,transition:s,children:a,shapeFlag:c}=e;if(6&c)A(e.component.subTree,t,n,r);else if(128&c)e.suspense.move(t,n,r);else if(64&c)o.move(e,t,n,Q);else if(o===oe){O(l,t,n);for(let e=0;es.enter(l),i);else{const{leave:g,delayLeave:m,afterLeave:v}=s,y=()=>O(l,t,n),w=()=>{g(l,()=>{y(),v&&v()})};m?m(l,y,w):w()}else O(l,t,n)},Z=(t,n,r,i=!1,l=!1)=>{var{type:o,props:s,ref:e,children:a,dynamicChildren:c,shapeFlag:u,patchFlag:p,dirs:d}=t;if(null!=e&&tr(e,null,r,t,!0),256&u)n.ctx.deactivate(t);else{const h=1&u&&d,f=!Kn(t);let e;if(f&&(e=s&&s.onVnodeBeforeUnmount)&&Ke(e,n,t),6&u)I(t.component,r,i);else{if(128&u)return void t.suspense.unmount(r,i);h&&Et(t,null,n,"beforeUnmount"),64&u?t.type.remove(t,n,r,l,Q,i):c&&(o!==oe||0{e&&Ke(e,n,t),h&&Et(t,null,n,"unmounted")},r)}},_=e=>{const{type:t,el:n,anchor:r,transition:i}=e;if(t===oe){for(var l,o=n,s=r;o!==s;)l=k(o),g(o),o=l;g(s)}else if(t===ir){for(var a,{el:c,anchor:u}=[e][0];c&&c!==u;)a=k(c),g(c),c=a;g(u)}else{const p=()=>{g(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(1&e.shapeFlag&&i&&!i.persisted){const{leave:d,delayLeave:h}=i,f=()=>d(n,p);h?h(e.el,p,f):f()}else p()}},I=(e,t,n)=>{const{bum:r,scope:i,update:l,subTree:o,um:s}=e;r&&Mn(r),i.stop(),l&&(l.active=!1,Z(o,e,t,n)),s&&Te(s,t),Te(()=>{e.isUnmounted=!0},t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},L=(t,n,r,i=!1,l=!1,o=0)=>{for(let e=o;e6&e.shapeFlag?q(e.component.subTree):128&e.shapeFlag?e.suspense.next():k(e.anchor||e.el);let r=!1;const n=(e,t,n)=>{null==e?t._vnode&&Z(t._vnode,null,null,!0):E(t._vnode||null,e,t,null,null,null,n),r||(r=!0,Oo(),jo(),r=!1),t._vnode=e},Q={p:E,um:Z,m:A,r:_,mt:B,mc:F,pc:G,pbc:D,n:q,o:e};let R;return{render:n,hydrate:void 0,createApp:rc(n,void 0)}}function nr({type:e,props:t},n){return"svg"===n&&"foreignObject"===e||"mathml"===n&&"annotation-xml"===e&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function St({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function gc(e,t){return(!e||!e.pendingBranch)&&t&&!t.persisted}function rs(e,t,n=!1){const r=e.children,i=t.children;if(N(r)&&N(i))for(let t=0;t>1,e[n[s]]e.__isTeleport,oe=Symbol.for("v-fgt"),Qn=Symbol.for("v-txt"),It=Symbol.for("v-cmt"),ir=Symbol.for("v-stc"),cn=[];let He=null;function S(e=!1){cn.push(He=e?null:[])}function wc(){cn.pop(),He=cn[cn.length-1]||null}let un=1;function ss(e){un+=e}function ls(e){return e.dynamicChildren=0e??null,Jn=({ref:e,ref_key:t,ref_for:n})=>null!=(e="number"==typeof e?""+e:e)?ve(e)||Re(e)||ee(e)?{i:xe,r:e,k:t,f:!!n}:e:null;function M(e,t=null,n=null,r=0,i=null,l=e===oe?0:1,o=!1,s=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&as(t),ref:t&&Jn(t),scopeId:Po,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:l,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:xe};return s?(or(a,n),128&l&&e.normalize(a)):n&&(a.shapeFlag|=ve(n)?8:16),0Ee||xe;let Yn,sr;{const JD=Ai(),KD=(e,t)=>{let n;return(n=(n=JD[e])?n:JD[e]=[]).push(t),t=>{1e(t)):n[0](t)}};Yn=KD("__VUE_INSTANCE_SETTERS__",e=>Ee=e),sr=KD("__VUE_SSR_SETTERS__",e=>Xn=e)}const lr=e=>{const t=Ee;return Yn(e),e.scope.on(),()=>{e.scope.off(),Yn(t)}},cs=()=>{Ee&&Ee.scope.off(),Yn(null)};function us(e){return 4&e.vnode.shapeFlag}let Xn=!1;function Sc(e,t=!1){t&&sr(t);var{props:n,children:r}=e.vnode,i=us(e),n=(sc(e,n,i,t),uc(e,r),i?Ic(e,t):void 0);return t&&sr(!1),n}function Ic(t,n){var e=t.type,e=(t.accessCache=Object.create(null),t.proxy=new Proxy(t.ctx,Ya),e)["setup"];if(e){const r=t.setupContext=1{fs(t,e,n)}).catch(e=>{Dn(e,t,0)});t.asyncDep=l}else fs(t,l,n)}else hs(t,n)}function fs(e,t,n){ee(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ce(t)&&(e.setupState=Ao(t)),hs(e,n)}let ds;function hs(e,t,n){const r=e.type;var i,l,o,s;e.render||(t||!ds||r.render||(t=r.template||Xa(e).template)&&({isCustomElement:s,compilerOptions:i}=e.appContext.config,{delimiters:l,compilerOptions:o}=r,s=be(be({isCustomElement:s,delimiters:l},i),o),r.render=ds(t,s)),e.render=r.render||Qe)}const Rc={get(e,t){return Ie(e,"get",""),e[t]}};function Tc(t){return{attrs:new Proxy(t.attrs,Rc),slots:t.slots,emit:t.emit,expose:e=>{t.exposed=e||{}}}}function ei(n){if(n.exposed)return n.exposeProxy||(n.exposeProxy=new Proxy(Ao(Ca(n.exposed)),{get(e,t){return t in e?e[t]:t in sn?sn[t](n):void 0},has(e,t){return t in e||t in sn}}))}function Lc(e,t=!0){return ee(e)?e.displayName||e.name:e.name||t&&e.__name}function Ac(e){return ee(e)&&"__vccOpts"in e}const we=(e,t)=>Ea(e,t,Xn);function Y(e,t,n){var r=arguments.length;return 2===r?ce(t)&&!N(t)?rr(t)?ie(e,null,[t]):ie(e,t):ie(e,null,t):(3{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const i="svg"===t?ht.createElementNS($c,e):"mathml"===t?ht.createElementNS(Oc,e):ht.createElement(e,n?{is:n}:void 0);return"select"===e&&r&&null!=r.multiple&&i.setAttribute("multiple",r.multiple),i},createText:e=>ht.createTextNode(e),createComment:e=>ht.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>ht.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,i,l){var o=n?n.previousSibling:t.lastChild;if(i&&(i===l||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==l&&(i=i.nextSibling););else{ps.innerHTML="svg"===r?`${e}`:"mathml"===r?`${e}`:e;const a=ps.content;if("svg"===r||"mathml"===r){for(var s=a.firstChild;s.firstChild;)a.appendChild(s.firstChild);a.removeChild(s)}t.insertBefore(a,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},zc=Symbol("_vtc");function Pc(e,t,n){var r=e[zc];null==(t=r?(t?[t,...r]:[...r]).join(" "):t)?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const ti=Symbol("_vod"),gs=Symbol("_vsh"),ms={beforeMount(e,{value:t},{transition:n}){e[ti]="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):dn(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),dn(e,!0),r.enter(e)):r.leave(e,()=>{dn(e,!1)}):dn(e,t))},beforeUnmount(e,{value:t}){dn(e,t)}};function dn(e,t){e.style.display=t?e[ti]:"none",e[gs]=!t}const Fc=Symbol(""),Uc=/(^|;)\s*display\s*:/;function Nc(e,t,n){const r=e.style,i=ve(n);let l=!1;if(n&&!i){if(t)if(ve(t))for(const a of t.split(";")){var o=a.slice(0,a.indexOf(":")).trim();null==n[o]&&ni(r,o,"")}else for(const c in t)null==n[c]&&ni(r,c,"");for(const u in n)"display"===u&&(l=!0),ni(r,u,n[u])}else{var s;i?t!==n&&((s=r[Fc])&&(n+=";"+s),r.cssText=n,l=Uc.test(n)):t&&e.removeAttribute("style")}ti in e&&(e[ti]=l?r.display:"",e[gs]&&(r.display="none"))}const vs=/\s*!important$/;function ni(t,n,e){var r;N(e)?e.forEach(e=>ni(t,n,e)):(null==e&&(e=""),n.startsWith("--")?t.setProperty(n,e):(r=Hc(t,n),vs.test(e)?t.setProperty(Pt(r),e.replace(vs,""),"important"):t[r]=e))}const ws=["Webkit","Moz","ms"],ar={};function Hc(t,n){var e=ar[n];if(e)return e;let r=Ve(n);if("filter"!==r&&r in t)return ar[n]=r;r=An(r);for(let e=0;ecr||(Kc.then(()=>cr=0),cr=Date.now());function Zc(e,t){const n=e=>{if(e._vts){if(e._vts<=n.attached)return}else e._vts=Date.now();Be(Qc(e,n.value),t,5,[e])};return n.value=e,n.attached=Gc(),n}function Qc(e,t){if(N(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(t=>e=>!e._stopped&&t&&t(e))}return t}const ks=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&96{i="svg"===i;"class"===t?Pc(e,r,i):"style"===t?Nc(e,n,r):Tn(t)?Ri(t)||Wc(e,t,n,r,o):("."===t[0]?(t=t.slice(1),1):"^"===t[0]?(t=t.slice(1),0):Yc(e,t,r,i))?Vc(e,t,r,l,o,s,a):("true-value"===t?e._trueValue=r:"false-value"===t&&(e._falseValue=r),Dc(e,t,r,i))};function Yc(e,t,n,r){if(r)return!!("innerHTML"===t||"textContent"===t||t in e&&ks(t)&&ee(n));if("spellcheck"===t||"draggable"===t||"translate"===t||"form"===t||"list"===t&&"INPUT"===e.tagName||"type"===t&&"TEXTAREA"===e.tagName)return!1;if("width"===t||"height"===t){r=e.tagName;if("IMG"===r||"VIDEO"===r||"CANVAS"===r||"SOURCE"===r)return!1}return(!ks(t)||!ve(n))&&t in e}const pt=e=>{const t=e.props["onUpdate:modelValue"]||!1;return N(t)?e=>Mn(t,e):t};function Xc(e){e.target.composing=!0}function xs(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Pe=Symbol("_assign"),ur={created(t,{modifiers:{lazy:e,trim:n,number:r}},i){t[Pe]=pt(i);const l=r||i.props&&"number"===i.props.type;tt(t,e?"change":"input",e=>{if(!e.target.composing){let e=t.value;n&&(e=e.trim()),l&&(e=$n(e)),t[Pe](e)}}),n&&tt(t,"change",()=>{t.value=t.value.trim()}),e||(tt(t,"compositionstart",Xc),tt(t,"compositionend",xs),tt(t,"change",xs))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:r,number:i}},l){e[Pe]=pt(l),e.composing||(l=t??"",(!i&&"number"!==e.type||/^0\d/.test(e.value)?e.value:$n(e.value))===l||document.activeElement===e&&"range"!==e.type&&(n||r&&e.value.trim()===l)||(e.value=l))}},eu={deep:!0,created(a,e,t){a[Pe]=pt(t),tt(a,"change",()=>{const e=a._modelValue,t=Ht(a),n=a.checked,r=a[Pe];if(N(e)){var i=Mi(e,t),l=-1!==i;if(n&&!l)r(e.concat(t));else if(!n&&l){const o=[...e];o.splice(i,1),r(o)}}else if(zt(e)){const s=new Set(e);n?s.add(t):s.delete(t),r(s)}else r(Ss(a,n))})},mounted:Cs,beforeUpdate(e,t,n){e[Pe]=pt(n),Cs(e,t,n)}};function Cs(e,{value:t,oldValue:n},r){e._modelValue=t,N(t)?e.checked=-1{e[Pe](Ht(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[Pe]=pt(r),t!==n&&(e.checked=wt(t,r.props.value))}},nu={deep:!0,created(t,{value:e,modifiers:{number:n}},r){const i=zt(e);tt(t,"change",()=>{var e=Array.prototype.filter.call(t.options,e=>e.selected).map(e=>n?$n(Ht(e)):Ht(e));t[Pe](t.multiple?i?new Set(e):e:e[0]),t._assigning=!0,Ut(()=>{t._assigning=!1})}),t[Pe]=pt(r)},mounted(e,{value:t,modifiers:{}}){Es(e,t)},beforeUpdate(e,t,n){e[Pe]=pt(n)},updated(e,{value:t,modifiers:{}}){e._assigning||Es(e,t)}};function Es(n,r,e){var i,l=n.multiple,o=N(r);if(!l||o||zt(r)){for(let e=0,t=n.options.length;eString(e)===String(a)):-1{const r=su().createApp(...e),i=r["mount"];return r.mount=e=>{const t=cu(e);if(t){const n=r._component;ee(n)||n.render||n.template||(n.template=t.innerHTML),t.innerHTML="";e=i(t,!1,au(t));return t instanceof Element&&(t.removeAttribute("v-cloak"),t.setAttribute("data-v-app","")),e}},r};function au(e){return e instanceof SVGElement?"svg":"function"==typeof MathMLElement&&e instanceof MathMLElement?"mathml":void 0}function cu(e){return ve(e)?document.querySelector(e):e}function hn(e){return!!so()&&(ra(e),!0)}function nt(e){return"function"==typeof e?e():Lo(e)}const ri=typeof window<"u"&&typeof document<"u",uu=Object.prototype.toString,fu=e=>"[object Object]"===uu.call(e),oi=()=>{};function Rs(r,i){return function(...n){return new Promise((e,t)=>{Promise.resolve(r(()=>i.apply(this,n),{fn:i,thisArg:this,args:n})).then(e).catch(t)})}}const Ts=e=>e();function du(e,l={}){let o,s,a=oi;const c=e=>{clearTimeout(e),a(),a=oi};return n=>{const r=nt(e),i=nt(l.maxWait);return o&&c(o),r<=0||void 0!==i&&i<=0?(s&&(c(s),s=null),Promise.resolve(n())):new Promise((e,t)=>{a=l.rejectOnCancel?t:e,i&&!s&&(s=setTimeout(()=>{o&&c(o),s=null,e(n())},i)),o=setTimeout(()=>{s&&c(s),s=null,e(n())},r)})}}function hu(t=Ts){const n=W(!0);return{isActive:Jt(n),pause:function(){n.value=!1},resume:function(){n.value=!0},eventFilter:(...e)=>{n.value&&t(...e)}}}function Ls(e){return Ec()}function pu(e,t=200,n={}){return Rs(du(t,n),e)}function gu(e,t,n={}){const{eventFilter:r=Ts,...i}=n;return je(e,Rs(r,t),i)}function mu(e,t,n={}){const{eventFilter:r,...i}=n,{eventFilter:l,pause:o,resume:s,isActive:a}=hu(r);return{stop:gu(e,t,{...i,eventFilter:l}),pause:o,resume:s,isActive:a}}function fr(e,t=!0,n){Ls()?on(e,n):t?e():Ut(e)}function vu(e,t){Ls()&&Qi(e,t)}function wu(t,n=1e3,e={}){const{immediate:r=!0,immediateCallback:i=!1}=e;let l=null;const o=W(!1);function s(){l&&(clearInterval(l),l=null)}function a(){o.value=!1,s()}function c(){var e=nt(n);e<=0||(o.value=!0,i&&t(),s(),l=setInterval(t,e))}return r&&ri&&c(),!Re(n)&&"function"!=typeof n||hn(je(n,()=>{o.value&&ri&&c()})),hn(a),{isActive:o,pause:a,resume:c}}function bu(e){var t,e=nt(e);return null!=(t=null==e?void 0:e.$el)?t:e}const si=ri?window:void 0,As=ri?window.document:void 0;function li(...e){let t,i,l,n;if("string"==typeof e[0]||Array.isArray(e[0])?([i,l,n]=e,t=si):[t,i,l,n]=e,!t)return oi;Array.isArray(i)||(i=[i]),Array.isArray(l)||(l=[l]);const o=[],s=()=>{o.forEach(e=>e()),o.length=0},r=je(()=>[bu(t),nt(n)],([n,e])=>{if(s(),n){const r=fu(e)?{...e}:e;o.push(...i.flatMap(t=>l.map(e=>((e,t,n,r)=>(e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)))(n,t,e,r))))}},{immediate:!0,flush:"post"}),a=()=>{r(),s()};return hn(a),a}function yu(n,e={}){const{immediate:t=!0,fpsLimit:r=void 0,window:i=si}=e,l=W(!1),o=r?1e3/r:null;let s=0,a=null;function c(e){var t;l.value&&i&&(t=e-(s=s||e),a=(o&&t"true"===e,write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Ms="vueuse-storage";function Dt(r,e,i,t={}){const{flush:n="pre",deep:l=!0,listenToStorageChanges:o=!0,writeDefaults:s=!0,mergeDefaults:a=!1,shallow:c,window:u=si,eventFilter:p,onError:d=e=>{console.error(e)},initOnMounted:h}=t,f=(c?Sa:W)("function"==typeof e?e():e);if(!i)try{i=xu("getDefaultStorage",()=>{var e;return null==(e=si)?void 0:e.localStorage})()}catch(e){d(e)}if(!i)return f;const g=nt(e),m=Cu(g),v=null!=(e=t.serializer)?e:Eu[m],{pause:y,resume:w}=mu(f,()=>{var e=f.value;try{var t,n=i.getItem(r);null==e?(b(n,null),i.removeItem(r)):(t=v.write(e),n!==t&&(i.setItem(r,t),b(n,t)))}catch(e){d(e)}},{flush:n,deep:l,eventFilter:p});function b(e,t){u&&u.dispatchEvent(new CustomEvent(Ms,{detail:{key:r,oldValue:e,newValue:t,storageArea:i}}))}function k(e){if(!e||e.storageArea===i)if(e&&null==e.key)f.value=g;else if(!e||e.key===r){y();try{(null==e?void 0:e.newValue)!==v.write(f.value)&&(f.value=null==(n=(t=e)?t.newValue:i.getItem(r))?(s&&null!=g&&i.setItem(r,v.write(g)),g):!t&&a?(t=v.read(n),"function"==typeof a?a(t,g):"object"!==m||Array.isArray(t)?t:{...g,...t}):"string"!=typeof n?n:v.read(n))}catch(e){d(e)}finally{e?Ut(w):w()}}var t,n}function x(e){k(e.detail)}return u&&o&&fr(()=>{li(u,"storage",k),li(u,Ms,x),h&&k()}),h||k(),f}function Su(e={}){const{controls:t=!1,interval:n="requestAnimationFrame"}=e,r=W(new Date),i=()=>r.value=new Date,l="requestAnimationFrame"===n?yu(i,{immediate:!0}):wu(i,n,{immediate:!0});return t?{now:r,...l}:r}function Iu(o,s=oi,e={}){const{immediate:t=!0,manual:n=!1,type:a="text/javascript",async:c=!0,crossOrigin:u,referrerPolicy:p,noModule:d,defer:h,document:f=As,attrs:g={}}=e,m=W(null);let r=null;const i=(e=!0)=>r=r||(l=>new Promise((t,r)=>{const i=e=>(m.value=e,t(e),e);if(f){let e=!1,n=f.querySelector(`script[src="${nt(o)}"]`);n?n.hasAttribute("data-loaded")&&i(n):((n=f.createElement("script")).type=a,n.async=c,n.src=nt(o),h&&(n.defer=h),u&&(n.crossOrigin=u),d&&(n.noModule=d),p&&(n.referrerPolicy=p),Object.entries(g).forEach(([e,t])=>null==n?void 0:n.setAttribute(e,t)),e=!0),n.addEventListener("error",e=>r(e)),n.addEventListener("abort",e=>r(e)),n.addEventListener("load",()=>{n.setAttribute("data-loaded","true"),s(n),i(n)}),e&&(n=f.head.appendChild(n)),l||i(n)}else t(!1)}))(e),l=()=>{var e;f&&(r=null,m.value&&(m.value=null),(e=f.querySelector(`script[src="${nt(o)}"]`))&&f.head.removeChild(e))};return t&&!n&&fr(i),n||vu(l),{scriptTag:m,load:i,unload:l}}let Ru=0;function Tu(e,n={}){const r=W(!1),{document:i=As,immediate:t=!0,manual:l=!1,id:o="vueuse_styletag_"+ ++Ru}=n,s=W(e);let a=()=>{};var e=()=>{if(i){const t=i.getElementById(o)||i.createElement("style");t.isConnected||(t.id=o,n.media&&(t.media=n.media),i.head.appendChild(t)),r.value||(a=je(s,e=>{t.textContent=e},{immediate:!0}),r.value=!0)}},c=()=>{i&&r.value&&(a(),i.head.removeChild(i.getElementById(o)),r.value=!1)};return t&&!l&&fr(e),l||hn(c),{id:o,css:s,unload:c,load:e,isLoaded:Jt(r)}}const Lu=e=>!!/@[0-9]+\.[0-9]+\.[0-9]+/.test(e),Au=t=>{const n=Dt("WALINE_EMOJI",{}),r=Lu(t);if(r){var e=n.value[t];if(e)return Promise.resolve(e)}return fetch(t+"/info.json").then(e=>e.json()).then(e=>{e={folder:t,...e};return r&&(n.value[t]=e),e})},$s=(e,t="",n="",r="")=>(t?t+"/":"")+n+e+(r?"."+r:""),Mu=e=>Promise.all(e.map(e=>$t(e)?Au(Zr(e)):Promise.resolve(e))).then(e=>{const s={tabs:[],map:{}};return e.forEach(e=>{const{name:t,folder:n,icon:r,prefix:i="",type:l,items:o}=e;s.tabs.push({name:t,icon:$s(r,n,i,l),items:o.map(e=>{var t=""+i+e;return s.map[t]=$s(e,n,i,l),t})})}),s}),Os=e=>{"AbortError"!==e.name&&console.error(e.message)},dr=e=>e instanceof HTMLElement?e:$t(e)?document.querySelector(e):null,$u=e=>e.type.includes("image"),js=e=>{const t=Array.from(e).find($u);return t?t.getAsFile():null};function hr(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let Rt=hr();function zs(e){Rt=e}const Ps=/[&<>"']/,Ou=new RegExp(Ps.source,"g"),Fs=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,ju=new RegExp(Fs.source,"g"),zu={"&":"&","<":"<",">":">",'"':""","'":"'"},Us=e=>zu[e];function $e(e,t){if(t){if(Ps.test(e))return e.replace(Ou,Us)}else if(Fs.test(e))return e.replace(ju,Us);return e}const Pu=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function Fu(e){return e.replace(Pu,(e,t)=>"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):"")}const Uu=/(^|[^\[])\^/g;function re(e,t){let r="string"==typeof e?e:e.source;t=t||"";const i={replace:(e,t)=>{let n="string"==typeof t?t:t.source;return n=n.replace(Uu,"$1"),r=r.replace(e,n),i},getRegex:()=>new RegExp(r,t)};return i}function Ns(e){try{e=encodeURI(e).replace(/%25/g,"%")}catch{return null}return e}const pn={exec:()=>null};function Hs(e,t){const n=e.replace(/\|/g,(e,t,n)=>{let r=!1,i=t;for(;0<=--i&&"\\"===n[i];)r=!r;return r?"|":" |"}),r=n.split(/ \|/);let i=0;if(r[0].trim()||r.shift(),0t)r.splice(t);else for(;r.length{var t=e.match(/^\s+/);if(null===t)return e;var[t]=t;return t.length>=n.length?e.slice(n.length):e}).join(` +`)}class fi{options;rules;lexer;constructor(e){this.options=e||Rt}space(e){e=this.rules.block.newline.exec(e);if(e&&0[ \t]?/gm,""),` +`);var t=this.lexer.state.top,r=(this.lexer.state.top=!0,this.lexer.blockTokens(e));return this.lexer.state.top=t,{type:"blockquote",raw:n[0],tokens:r,text:e}}}list(u){let p=this.rules.block.list.exec(u);if(p){let e=p[1].trim();const t=1" ".repeat(3*e.length)),n=u.split(` +`,1)[0],r=0,i=(this.options.pedantic?(r=2,a=t.trimStart()):(r=4<(r=p[2].search(/[^ ]/))?1:r,a=t.slice(r),r+=p[1].length),!1);if(!t&&/^ *$/.test(n)&&(s+=n+` +`,u=u.substring(n.length+1),e=!0),!e){const g=new RegExp(`^ {0,${Math.min(3,r-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),m=new RegExp(`^ {0,${Math.min(3,r-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),v=new RegExp(`^ {0,${Math.min(3,r-1)}}(?:\`\`\`|~~~)`),y=new RegExp(`^ {0,${Math.min(3,r-1)}}#`);for(;u;){var d=u.split(` +`,1)[0];if(n=d,this.options.pedantic&&(n=n.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),v.test(n)||y.test(n)||g.test(n)||m.test(u))break;if(n.search(/[^ ]/)>=r||!n.trim())a+=` +`+n.slice(r);else{if(i||4<=t.search(/[^ ]/)||v.test(t)||y.test(t)||m.test(t))break;a+=` +`+n}i||n.trim()||(i=!0),s+=d+` +`,u=u.substring(d.length+1),t=n.slice(r)}}h.loose||(c?h.loose=!0:/\n *\n *$/.test(s)&&(c=!0));let l=null,o;this.options.gfm&&((l=/^\[[ xX]\] /.exec(a))&&(o="[ ] "!==l[0],a=a.replace(/^\[[ xX]\] +/,""))),h.items.push({type:"list_item",raw:s,task:!!l,checked:o,loose:!1,text:a,tokens:[]}),h.raw+=s}h.items[h.items.length-1].raw=s.trimEnd(),h.items[h.items.length-1].text=a.trimEnd(),h.raw=h.raw.trimEnd();for(let e=0;e"space"===e.type),r=0/\n.*\n/.test(e.raw));h.loose=r}if(h.loose)for(let e=0;e$/,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",r=t[3]&&t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"),{type:"def",tag:e,raw:t[0],href:n,title:r}}table(e){const t=this.rules.block.table.exec(e);if(t&&/[:|]/.test(t[2])){const n=Hs(t[1]),r=t[2].replace(/^\||\| *$/g,"").split("|"),i=t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split(` +`):[],l={type:"table",raw:t[0],header:[],align:[],rows:[]};if(n.length===r.length){for(const o of r)/^ *-+: *$/.test(o)?l.align.push("right"):/^ *:-+: *$/.test(o)?l.align.push("center"):/^ *:-+ *$/.test(o)?l.align.push("left"):l.align.push(null);for(const s of n)l.header.push({text:s,tokens:this.lexer.inline(s)});for(const a of i)l.rows.push(Hs(a,l.header.length).map(e=>({text:e,tokens:this.lexer.inline(e)})));return l}}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t)return e=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1],{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}text(e){e=this.rules.block.text.exec(e);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(e){e=this.rules.inline.escape.exec(e);if(e)return{type:"escape",raw:e[0],text:$e(e[1])}}tag(e){e=this.rules.inline.tag.exec(e);if(e)return!this.lexer.state.inLink&&/^/i.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(n){const r=this.rules.inline.link.exec(n);if(r){const l=r[2].trim();if(!this.options.pedantic&&/^$/.test(l))return;n=ui(l.slice(0,-1),"\\");if((l.length-n.length)%2==0)return}else{var i,n=Nu(r[2],"()");-1$/.test(l)?e.slice(1):e.slice(1,-1)),Ds(r,{href:e&&e.replace(this.rules.inline.anyPunctuation,"$1"),title:t&&t.replace(this.rules.inline.anyPunctuation,"$1")},r[0],this.lexer)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){const r=(n[2]||n[1]).replace(/\s+/g," "),i=t[r.toLowerCase()];return i?Ds(n,i,n[0],this.lexer):{type:"text",raw:e=n[0].charAt(0),text:e}}}emStrong(i,l,e=""){let o=this.rules.inline.emStrongLDelim.exec(i);if(!(!o||o[3]&&e.match(/[\p{L}\p{N}]/u))&&(!o[1]&&!o[2]||!e||this.rules.inline.punctuation.exec(e))){var s=[...o[0]].length-1;let e,t,n=s,r=0;const c="*"===o[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,l=l.slice(-1*i.length+s);null!=(o=c.exec(l));)if(e=o[1]||o[2]||o[3]||o[4]||o[5]||o[6])if(t=[...e].length,o[3]||o[4])n+=t;else if((o[5]||o[6])&&s%3&&!((s+t)%3))r+=t;else if(!(0<(n-=t))){t=Math.min(t,t+n+r);const u=[...o[0]][0].length,p=i.slice(0,s+o.index+u+t);if(Math.min(s,t)%2)return a=p.slice(1,-1),{type:"em",raw:p,text:a,tokens:this.lexer.inlineTokens(a)};var a=p.slice(2,-2);return{type:"strong",raw:p,text:a,tokens:this.lexer.inlineTokens(a)}}}}codespan(t){const n=this.rules.inline.code.exec(t);if(n){let e=n[2].replace(/\n/g," ");var t=/[^ ]/.test(e),r=/^ /.test(e)&&/ $/.test(e);return e=$e(e=t&&r?e.substring(1,e.length-1):e,!0),{type:"codespan",raw:n[0],text:e}}}br(e){e=this.rules.inline.br.exec(e);if(e)return{type:"br",raw:e[0]}}del(e){e=this.rules.inline.del.exec(e);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(n){n=this.rules.inline.autolink.exec(n);if(n){let e,t;return t="@"===n[2]?"mailto:"+(e=$e(n[1])):e=$e(n[1]),{type:"link",raw:n[0],text:e,href:t,tokens:[{type:"text",raw:e,text:e}]}}}url(e){var n,r;let i;if(i=this.rules.inline.url.exec(e)){let e,t;if("@"===i[2])e=$e(i[0]),t="mailto:"+e;else{for(;r=i[0],i[0]=(null==(n=this.rules.inline._backpedal.exec(i[0]))?void 0:n[0])??"",r!==i[0];);e=$e(i[0]),t="www."===i[1]?"http://"+i[0]:i[0]}return{type:"link",raw:i[0],text:e,href:t,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(t){t=this.rules.inline.text.exec(t);if(t){let e;return e=this.lexer.state.inRawBlock?t[0]:$e(t[0]),{type:"text",raw:t[0],text:e}}}}const Du=/^(?: *(?:\n|$))+/,Vu=/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,Bu=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,gn=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Wu=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Vs=/(?:[*+-]|\d{1,9}[.)])/,Bs=re(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g,Vs).replace(/blockCode/g,/ {4}/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).getRegex(),pr=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,qu=/^[^\n]+/,gr=/(?!\s*\])(?:\\.|[^\[\]\\])+/,Ku=re(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label",gr).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Gu=re(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Vs).getRegex(),di="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",mr=/|$))/,Zu=re("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))","i").replace("comment",mr).replace("tag",di).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),Ws=re(pr).replace("hr",gn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",di).getRegex(),Qu=re(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",Ws).getRegex(),vr={blockquote:Qu,code:Vu,def:Ku,fences:Bu,heading:Wu,hr:gn,html:Zu,lheading:Bs,list:Gu,newline:Du,paragraph:Ws,table:pn,text:qu},qs=re("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",gn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",di).getRegex(),Ju={...vr,table:qs,paragraph:re(pr).replace("hr",gn).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",qs).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",di).getRegex()},Yu={...vr,html:re(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",mr).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:pn,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:re(pr).replace("hr",gn).replace("heading",` *#{1,6} *[^ +]`).replace("lheading",Bs).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Ks=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Xu=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Gs=/^( {2,}|\\)\n(?!\s*$)/,ef=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\]*?>/g,rf=re(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/,"u").replace(/punct/g,mn).getRegex(),of=re("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])","gu").replace(/punct/g,mn).getRegex(),sf=re("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])","gu").replace(/punct/g,mn).getRegex(),lf=re(/\\([punct])/,"gu").replace(/punct/g,mn).getRegex(),af=re(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),cf=re(mr).replace("(?:--\x3e|$)","--\x3e").getRegex(),uf=re("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",cf).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),hi=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,ff=re(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",hi).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Zs=re(/^!?\[(label)\]\[(ref)\]/).replace("label",hi).replace("ref",gr).getRegex(),Qs=re(/^!?\[(ref)\](?:\[\])?/).replace("ref",gr).getRegex(),df=re("reflink|nolink(?!\\()","g").replace("reflink",Zs).replace("nolink",Qs).getRegex(),wr={_backpedal:pn,anyPunctuation:lf,autolink:af,blockSkip:nf,br:Gs,code:Xu,del:pn,emStrongLDelim:rf,emStrongRDelimAst:of,emStrongRDelimUnd:sf,escape:Ks,link:ff,nolink:Qs,punctuation:tf,reflink:Zs,reflinkSearch:df,tag:uf,text:ef,url:pn},hf={...wr,link:re(/^!?\[(label)\]\((.*?)\)/).replace("label",hi).getRegex(),reflink:re(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",hi).getRegex()},br={...wr,escape:re(Ks).replace("])","~|])").getRegex(),url:re(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\t+" ".repeat(n.length));let n,e,i,l;for(;r;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(e=>!!(n=e.call({lexer:this},r,t))&&(r=r.substring(n.raw.length),t.push(n),!0)))){if(n=this.tokenizer.space(r)){r=r.substring(n.raw.length),1===n.raw.length&&0{"number"==typeof(n=e.call({lexer:this},s))&&0<=n&&(t=Math.min(t,n))}),t<1/0&&0<=t&&(i=r.substring(0,t+1))}if(this.state.top&&(n=this.tokenizer.paragraph(i))){e=t[t.length-1],l&&"paragraph"===e.type?(e.raw+=` +`+n.raw,e.text+=` +`+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=e.text):t.push(n),l=i.length!==r.length,r=r.substring(n.raw.length);continue}if(n=this.tokenizer.text(r)){r=r.substring(n.raw.length),(e=t[t.length-1])&&"text"===e.type?(e.raw+=` +`+n.raw,e.text+=` +`+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=e.text):t.push(n);continue}if(r){var o="Infinite loop on byte: "+r.charCodeAt(0);if(this.options.silent){console.error(o);break}throw new Error(o)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(r,t=[]){let n,e,i,l=r,o,s,a;if(this.tokens.links){const u=Object.keys(this.tokens.links);if(0!!(n=e.call({lexer:this},r,t))&&(r=r.substring(n.raw.length),t.push(n),!0)))){if(n=this.tokenizer.escape(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.tag(r)){r=r.substring(n.raw.length),(e=t[t.length-1])&&"text"===n.type&&"text"===e.type?(e.raw+=n.raw,e.text+=n.text):t.push(n);continue}if(n=this.tokenizer.link(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.reflink(r,this.tokens.links)){r=r.substring(n.raw.length),(e=t[t.length-1])&&"text"===n.type&&"text"===e.type?(e.raw+=n.raw,e.text+=n.text):t.push(n);continue}if(n=this.tokenizer.emStrong(r,l,a)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.codespan(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.br(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.del(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.autolink(r)){r=r.substring(n.raw.length),t.push(n);continue}if(!this.state.inLink&&(n=this.tokenizer.url(r))){r=r.substring(n.raw.length),t.push(n);continue}if(i=r,this.options.extensions&&this.options.extensions.startInline){let t=1/0;const p=r.slice(1);let n;this.options.extensions.startInline.forEach(e=>{"number"==typeof(n=e.call({lexer:this},p))&&0<=n&&(t=Math.min(t,n))}),t<1/0&&0<=t&&(i=r.substring(0,t+1))}if(n=this.tokenizer.inlineText(i)){r=r.substring(n.raw.length),"_"!==n.raw.slice(-1)&&(a=n.raw.slice(-1)),s=!0,(e=t[t.length-1])&&"text"===e.type?(e.raw+=n.raw,e.text+=n.text):t.push(n);continue}if(r){var c="Infinite loop on byte: "+r.charCodeAt(0);if(this.options.silent){console.error(c);break}throw new Error(c)}}return t}}class gi{options;constructor(e){this.options=e||Rt}code(e,t,n){t=null==(t=(t||"").match(/^\S*/))?void 0:t[0];return e=e.replace(/\n$/,"")+` +`,t?'
'+(n?e:$e(e,!0))+`
+`:"
"+(n?e:$e(e,!0))+`
+`}blockquote(e){return`
+${e}
+`}html(e,t){return e}heading(e,t,n){return`${e} +`}hr(){return`
+`}list(e,t,n){var r=t?"ol":"ul";return"<"+r+(t&&1!==n?' start="'+n+'"':"")+`> +`+e+" +`}listitem(e,t,n){return`
  • ${e}
  • +`}checkbox(e){return"'}paragraph(e){return`

    ${e}

    +`}table(e,t){return` + +`+e+` +`+(t=t&&`${t}`)+`
    +`}tablerow(e){return` +${e} +`}tablecell(e,t){var n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+` +`}strong(e){return`${e}`}em(e){return`${e}`}codespan(e){return`${e}`}br(){return"
    "}del(e){return`${e}`}link(e,t,n){var r=Ns(e);if(null===r)return n;let i='
    "}image(e,t,n){var r=Ns(e);if(null===r)return n;let i=`${n}{e=c[e].flat(1/0);r=r.concat(this.walkTokens(e,t))}):c.tokens&&(r=r.concat(this.walkTokens(c.tokens,t)))}}return r}use(...e){const w=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{const t={...e};if(t.async=this.defaults.async||t.async||!1,e.extensions&&(e.extensions.forEach(n=>{if(!n.name)throw new Error("extension name required");if("renderer"in n){const r=w.renderers[n.name];r?w.renderers[n.name]=function(...e){let t=n.renderer.apply(this,e);return t=!1===t?r.apply(this,e):t}:w.renderers[n.name]=n.renderer}if("tokenizer"in n){if(!n.level||"block"!==n.level&&"inline"!==n.level)throw new Error("extension level must be 'block' or 'inline'");const e=w[n.level];e?e.unshift(n.tokenizer):w[n.level]=[n.tokenizer],n.start&&("block"===n.level?w.startBlock?w.startBlock.push(n.start):w.startBlock=[n.start]:"inline"===n.level&&(w.startInline?w.startInline.push(n.start):w.startInline=[n.start]))}"childTokens"in n&&n.childTokens&&(w.childTokens[n.name]=n.childTokens)}),t.extensions=w),e.renderer){const n=this.defaults.renderer||new gi(this.defaults);for(const r in e.renderer){if(!(r in n))throw new Error(`renderer '${r}' does not exist`);if("options"!==r){const i=r,l=e.renderer[i],o=n[i];n[i]=(...e)=>{let t=l.apply(n,e);return(t=!1===t?o.apply(n,e):t)||""}}}t.renderer=n}if(e.tokenizer){const s=this.defaults.tokenizer||new fi(this.defaults);for(const a in e.tokenizer){if(!(a in s))throw new Error(`tokenizer '${a}' does not exist`);if(!["options","rules","lexer"].includes(a)){const c=a,u=e.tokenizer[c],p=s[c];s[c]=(...e)=>{let t=u.apply(s,e);return t=!1===t?p.apply(s,e):t}}}t.tokenizer=s}if(e.hooks){const d=this.defaults.hooks||new wn;for(const h in e.hooks){if(!(h in d))throw new Error(`hook '${h}' does not exist`);if("options"!==h){const f=h,g=e.hooks[f],m=d[f];wn.passThroughHooks.has(h)?d[f]=e=>{if(this.defaults.async)return Promise.resolve(g.call(d,e)).then(e=>m.call(d,e));e=g.call(d,e);return m.call(d,e)}:d[f]=(...e)=>{let t=g.apply(d,e);return t=!1===t?m.apply(d,e):t}}}t.hooks=d}if(e.walkTokens){const v=this.defaults.walkTokens,y=e.walkTokens;t.walkTokens=function(e){let t=[];return t.push(y.call(this,e)),t=v?t.concat(v.call(this,e)):t}}this.defaults={...this.defaults,...t}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return it.lex(e,t??this.defaults)}parser(e,t){return rt.parse(e,t??this.defaults)}}xn=new WeakSet,kr=function(l,o){return(n,e)=>{const t={...e},r={...this.defaults,...t},i=(!0===this.defaults.async&&!1===t.async&&(r.silent||console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."),r.async=!0),En(this,bi,wl).call(this,!!r.silent,!!r.async));if("u"l(e,r)).then(e=>r.hooks?r.hooks.processAllTokens(e):e).then(e=>r.walkTokens?Promise.all(this.walkTokens(e,r.walkTokens)).then(()=>e):e).then(e=>o(e,r)).then(e=>r.hooks?r.hooks.postprocess(e):e).catch(i);try{r.hooks&&(n=r.hooks.preprocess(n));let e=l(n,r),t=(r.hooks&&(e=r.hooks.processAllTokens(e)),r.walkTokens&&this.walkTokens(e,r.walkTokens),o(e,r));return t=r.hooks?r.hooks.postprocess(t):t}catch(e){return i(e)}}},bi=new WeakSet,wl=function(n,r){return e=>{var t;if(e.message+=` +Please report this to https://github.com/markedjs/marked.`,n)return t="

    An error occurred:

    "+$e(e.message+"",!0)+"
    ",r?Promise.resolve(t):t;if(r)return Promise.reject(e);throw e}};const Tt=new Js;function ue(e,t){return Tt.parse(e,t)}function gf(r){if((r="function"==typeof r?{highlight:r}:r)&&"function"==typeof r.highlight)return"string"!=typeof r.langPrefix&&(r.langPrefix="language-"),{async:!!r.async,walkTokens(e){if("code"===e.type){var t=Ys(e.lang);if(r.async)return Promise.resolve(r.highlight(e.text,t,e.lang||"")).then(Xs(e));t=r.highlight(e.text,t,e.lang||"");if(t instanceof Promise)throw new Error("markedHighlight is not set to async but the highlight function is async. Set the async option to true on markedHighlight to await the async highlight function.");Xs(e)(t)}},renderer:{code(e,t,n){t=Ys(t),t=t?` class="${r.langPrefix}${il(t)}"`:"";return e=e.replace(/\n$/,""),`
    ${n?e:il(e,!0)}
    +
    `}}};throw new Error("Must provide highlight function")}function Ys(e){return(e||"").match(/\S*/)[0]}function Xs(t){return e=>{"string"==typeof e&&e!==t.text&&(t.escaped=!0,t.text=e)}}ue.options=ue.setOptions=function(e){return Tt.setOptions(e),ue.defaults=Tt.defaults,zs(ue.defaults),ue},ue.getDefaults=hr,ue.defaults=Rt,ue.use=function(...e){return Tt.use(...e),ue.defaults=Tt.defaults,zs(ue.defaults),ue},ue.walkTokens=function(e,t){return Tt.walkTokens(e,t)},ue.parseInline=Tt.parseInline,ue.Parser=rt,ue.parser=rt.parse,ue.Renderer=gi,ue.TextRenderer=yr,ue.Lexer=it,ue.lexer=it.lex,ue.Tokenizer=fi,ue.Hooks=wn,ue.parse=ue;const el=/[&<>"']/,mf=new RegExp(el.source,"g"),tl=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,vf=new RegExp(tl.source,"g"),wf={"&":"&","<":"<",">":">",'"':""","'":"'"},nl=e=>wf[e];function il(e,t){if(t){if(el.test(e))return e.replace(mf,nl)}else if(tl.test(e))return e.replace(vf,nl);return e}const bf=/\$.*?\$/,yf=/^\$(.*?)\$/,_f=/^(?:\s{0,3})\$\$((?:[^\n]|\n[^\n])+?)\n{0,1}\$\$/,kf=t=>[{name:"blockMath",level:"block",tokenizer(e){e=_f.exec(e);if(null!==e)return{type:"html",raw:e[0],text:t(!0,e[1])}}},{name:"inlineMath",level:"inline",start(e){var t=e.search(bf);return-1!==t?t:e.length},tokenizer(e){e=yf.exec(e);if(null!==e)return{type:"html",raw:e[0],text:t(!1,e[1])}}}],rl=(e="",n={})=>e.replace(/:(.+?):/g,(e,t)=>n[t]?`${t}`:e),xf=(e,{emojiMap:t,highlighter:n,texRenderer:r})=>{const i=new Js;return i.setOptions({breaks:!0}),n&&i.use(gf({highlight:n})),r&&(n=kf(r),i.use({extensions:n})),i.parse(rl(e,t))},_r=e=>{e=e.dataset.path;return null!=e&&e.length?e:null},Cf=e=>e.match(/[\w\d\s,.\u00C0-\u024F\u0400-\u04FF]+/giu),Ef=e=>e.match(/[\u4E00-\u9FD5]/gu),Sf=e=>{var t;return((null==(t=Cf(e))?void 0:t.reduce((e,t)=>e+(["",",","."].includes(t.trim())?0:t.trim().split(/\s+/u).length),0))??0)+((null==(t=Ef(e))?void 0:t.length)??0)},If=async()=>{if(!navigator)return"";const e=navigator["userAgentData"];let t=navigator.userAgent;if(!e||"Windows"!==e.platform)return t;const n=(await e.getHighEntropyValues(["platformVersion"]))["platformVersion"];return t=n&&13<=parseInt(n.split(".")[0])?t.replace("Windows NT 10.0","Windows NT 11.0"):t},ol=({serverURL:e,path:t=window.location.pathname,selector:n=".waline-comment-count",lang:r=navigator.language})=>{const i=new AbortController,l=document.querySelectorAll(n);return l.length&&Lr({serverURL:Rn(e),paths:Array.from(l).map(e=>Gr(_r(e)??t)),lang:r,signal:i.signal}).then(n=>{l.forEach((e,t)=>{e.innerText=n[t].toString()})}).catch(Os),i.abort.bind(i)},Rf=({size:e})=>Y("svg",{class:"wl-close-icon",viewBox:"0 0 1024 1024",width:e,height:e},[Y("path",{d:"M697.173 85.333h-369.92c-144.64 0-241.92 101.547-241.92 252.587v348.587c0 150.613 97.28 252.16 241.92 252.16h369.92c144.64 0 241.494-101.547 241.494-252.16V337.92c0-151.04-96.854-252.587-241.494-252.587z",fill:"currentColor"}),Y("path",{d:"m640.683 587.52-75.947-75.861 75.904-75.862a37.29 37.29 0 0 0 0-52.778 37.205 37.205 0 0 0-52.779 0l-75.946 75.818-75.862-75.946a37.419 37.419 0 0 0-52.821 0 37.419 37.419 0 0 0 0 52.821l75.947 75.947-75.776 75.733a37.29 37.29 0 1 0 52.778 52.821l75.776-75.776 75.947 75.947a37.376 37.376 0 0 0 52.779-52.821z",fill:"#888"})]),Tf=()=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},Y("path",{d:"m341.013 394.667 27.755 393.45h271.83l27.733-393.45h64.106l-28.01 397.952a64 64 0 0 1-63.83 59.498H368.768a64 64 0 0 1-63.83-59.52l-28.053-397.93h64.128zm139.307 19.818v298.667h-64V414.485h64zm117.013 0v298.667h-64V414.485h64zM181.333 288h640v64h-640v-64zm453.483-106.667v64h-256v-64h256z",fill:"red"})),Lf=()=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},Y("path",{d:"M563.2 463.3 677 540c1.7 1.2 3.7 1.8 5.8 1.8.7 0 1.4-.1 2-.2 2.7-.5 5.1-2.1 6.6-4.4l25.3-37.8c1.5-2.3 2.1-5.1 1.6-7.8s-2.1-5.1-4.4-6.6l-73.6-49.1 73.6-49.1c2.3-1.5 3.9-3.9 4.4-6.6.5-2.7 0-5.5-1.6-7.8l-25.3-37.8a10.1 10.1 0 0 0-6.6-4.4c-.7-.1-1.3-.2-2-.2-2.1 0-4.1.6-5.8 1.8l-113.8 76.6c-9.2 6.2-14.7 16.4-14.7 27.5.1 11 5.5 21.3 14.7 27.4zM387 348.8h-45.5c-5.7 0-10.4 4.7-10.4 10.4v153.3c0 5.7 4.7 10.4 10.4 10.4H387c5.7 0 10.4-4.7 10.4-10.4V359.2c0-5.7-4.7-10.4-10.4-10.4zm333.8 241.3-41-20a10.3 10.3 0 0 0-8.1-.5c-2.6.9-4.8 2.9-5.9 5.4-30.1 64.9-93.1 109.1-164.4 115.2-5.7.5-9.9 5.5-9.5 11.2l3.9 45.5c.5 5.3 5 9.5 10.3 9.5h.9c94.8-8 178.5-66.5 218.6-152.7 2.4-5 .3-11.2-4.8-13.6zm186-186.1c-11.9-42-30.5-81.4-55.2-117.1-24.1-34.9-53.5-65.6-87.5-91.2-33.9-25.6-71.5-45.5-111.6-59.2-41.2-14-84.1-21.1-127.8-21.1h-1.2c-75.4 0-148.8 21.4-212.5 61.7-63.7 40.3-114.3 97.6-146.5 165.8-32.2 68.1-44.3 143.6-35.1 218.4 9.3 74.8 39.4 145 87.3 203.3.1.2.3.3.4.5l36.2 38.4c1.1 1.2 2.5 2.1 3.9 2.6 73.3 66.7 168.2 103.5 267.5 103.5 73.3 0 145.2-20.3 207.7-58.7 37.3-22.9 70.3-51.5 98.1-85 27.1-32.7 48.7-69.5 64.2-109.1 15.5-39.7 24.4-81.3 26.6-123.8 2.4-43.6-2.5-87-14.5-129zm-60.5 181.1c-8.3 37-22.8 72-43 104-19.7 31.1-44.3 58.6-73.1 81.7-28.8 23.1-61 41-95.7 53.4-35.6 12.7-72.9 19.1-110.9 19.1-82.6 0-161.7-30.6-222.8-86.2l-34.1-35.8c-23.9-29.3-42.4-62.2-55.1-97.7-12.4-34.7-18.8-71-19.2-107.9-.4-36.9 5.4-73.3 17.1-108.2 12-35.8 30-69.2 53.4-99.1 31.7-40.4 71.1-72 117.2-94.1 44.5-21.3 94-32.6 143.4-32.6 49.3 0 97 10.8 141.8 32 34.3 16.3 65.3 38.1 92 64.8 26.1 26 47.5 56 63.6 89.2 16.2 33.2 26.6 68.5 31 105.1 4.6 37.5 2.7 75.3-5.6 112.3z",fill:"currentColor"})),Af=()=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},[Y("path",{d:"M784 112H240c-88 0-160 72-160 160v480c0 88 72 160 160 160h544c88 0 160-72 160-160V272c0-88-72-160-160-160zm96 640c0 52.8-43.2 96-96 96H240c-52.8 0-96-43.2-96-96V272c0-52.8 43.2-96 96-96h544c52.8 0 96 43.2 96 96v480z",fill:"currentColor"}),Y("path",{d:"M352 480c52.8 0 96-43.2 96-96s-43.2-96-96-96-96 43.2-96 96 43.2 96 96 96zm0-128c17.6 0 32 14.4 32 32s-14.4 32-32 32-32-14.4-32-32 14.4-32 32-32zm462.4 379.2-3.2-3.2-177.6-177.6c-25.6-25.6-65.6-25.6-91.2 0l-80 80-36.8-36.8c-25.6-25.6-65.6-25.6-91.2 0L200 728c-4.8 6.4-8 14.4-8 24 0 17.6 14.4 32 32 32 9.6 0 16-3.2 22.4-9.6L380.8 640l134.4 134.4c6.4 6.4 14.4 9.6 24 9.6 17.6 0 32-14.4 32-32 0-9.6-4.8-17.6-9.6-24l-52.8-52.8 80-80L769.6 776c6.4 4.8 12.8 8 20.8 8 17.6 0 32-14.4 32-32 0-8-3.2-16-8-20.8z",fill:"currentColor"})]),Mf=({active:e=!1})=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},[Y("path",{d:"M850.654 323.804c-11.042-25.625-26.862-48.532-46.885-68.225-20.022-19.61-43.258-34.936-69.213-45.73-26.78-11.124-55.124-16.727-84.375-16.727-40.622 0-80.256 11.123-114.698 32.135A214.79 214.79 0 0 0 512 241.819a214.79 214.79 0 0 0-23.483-16.562c-34.442-21.012-74.076-32.135-114.698-32.135-29.25 0-57.595 5.603-84.375 16.727-25.872 10.711-49.19 26.12-69.213 45.73-20.105 19.693-35.843 42.6-46.885 68.225-11.453 26.615-17.303 54.877-17.303 83.963 0 27.439 5.603 56.03 16.727 85.117 9.31 24.307 22.659 49.52 39.715 74.981 27.027 40.293 64.188 82.316 110.33 124.915 76.465 70.615 152.189 119.394 155.402 121.371l19.528 12.525c8.652 5.52 19.776 5.52 28.427 0l19.529-12.525c3.213-2.06 78.854-50.756 155.401-121.371 46.143-42.6 83.304-84.622 110.33-124.915 17.057-25.46 30.487-50.674 39.716-74.981 11.124-29.087 16.727-57.678 16.727-85.117.082-29.086-5.768-57.348-17.221-83.963z"+(e?"":"M512 761.5S218.665 573.55 218.665 407.767c0-83.963 69.461-152.023 155.154-152.023 60.233 0 112.473 33.618 138.181 82.727 25.708-49.109 77.948-82.727 138.18-82.727 85.694 0 155.155 68.06 155.155 152.023C805.335 573.551 512 761.5 512 761.5z"),fill:e?"red":"currentColor"})]),$f=()=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},[Y("path",{d:"M710.816 654.301c70.323-96.639 61.084-230.578-23.705-314.843-46.098-46.098-107.183-71.109-172.28-71.109-65.008 0-126.092 25.444-172.28 71.109-45.227 46.098-70.756 107.183-70.756 172.106 0 64.923 25.444 126.007 71.194 172.106 46.099 46.098 107.184 71.109 172.28 71.109 51.414 0 100.648-16.212 142.824-47.404l126.53 126.006c7.058 7.06 16.297 10.979 26.406 10.979 10.105 0 19.343-3.919 26.402-10.979 14.467-14.467 14.467-38.172 0-52.723L710.816 654.301zm-315.107-23.265c-65.88-65.88-65.88-172.54 0-238.42 32.069-32.07 74.245-49.149 119.471-49.149 45.227 0 87.407 17.603 119.472 49.149 65.88 65.879 65.88 172.539 0 238.42-63.612 63.178-175.242 63.178-238.943 0zm0 0",fill:"currentColor"}),Y("path",{d:"M703.319 121.603H321.03c-109.8 0-199.469 89.146-199.469 199.38v382.034c0 109.796 89.236 199.38 199.469 199.38h207.397c20.653 0 37.384-16.645 37.384-37.299 0-20.649-16.731-37.296-37.384-37.296H321.03c-68.582 0-124.352-55.77-124.352-124.267V321.421c0-68.496 55.77-124.267 124.352-124.267h382.289c68.582 0 124.352 55.771 124.352 124.267V524.72c0 20.654 16.736 37.299 37.385 37.299 20.654 0 37.384-16.645 37.384-37.299V320.549c-.085-109.8-89.321-198.946-199.121-198.946zm0 0",fill:"currentColor"})]),Of=()=>Y("svg",{width:"16",height:"16",ariaHidden:"true"},Y("path",{d:"M14.85 3H1.15C.52 3 0 3.52 0 4.15v7.69C0 12.48.52 13 1.15 13h13.69c.64 0 1.15-.52 1.15-1.15v-7.7C16 3.52 15.48 3 14.85 3zM9 11H7V8L5.5 9.92 4 8v3H2V5h2l1.5 2L7 5h2v6zm2.99.5L9.5 8H11V5h2v3h1.5l-2.51 3.5z",fill:"currentColor"})),jf=()=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},Y("path",{d:"M810.667 213.333a64 64 0 0 1 64 64V704a64 64 0 0 1-64 64H478.336l-146.645 96.107a21.333 21.333 0 0 1-33.024-17.856V768h-85.334a64 64 0 0 1-64-64V277.333a64 64 0 0 1 64-64h597.334zm0 64H213.333V704h149.334v63.296L459.243 704h351.424V277.333zm-271.36 213.334v64h-176.64v-64h176.64zm122.026-128v64H362.667v-64h298.666z",fill:"currentColor"})),zf=()=>Y("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},Y("path",{d:"M813.039 318.772L480.53 651.278H360.718V531.463L693.227 198.961C697.904 194.284 704.027 192 710.157 192C716.302 192 722.436 194.284 727.114 198.961L813.039 284.88C817.72 289.561 820 295.684 820 301.825C820 307.95 817.72 314.093 813.039 318.772ZM710.172 261.888L420.624 551.431V591.376H460.561L750.109 301.825L710.172 261.888ZM490.517 291.845H240.906V771.09H720.156V521.479C720.156 504.947 733.559 491.529 750.109 491.529C766.653 491.529 780.063 504.947 780.063 521.479V791.059C780.063 813.118 762.18 831 740.125 831H220.937C198.882 831 181 813.118 181 791.059V271.872C181 249.817 198.882 231.935 220.937 231.935H490.517C507.06 231.935 520.47 245.352 520.47 261.888C520.47 278.424 507.06 291.845 490.517 291.845Z",fill:"currentColor"})),Pf=()=>Y("svg",{class:"verified-icon",viewBox:"0 0 1024 1024",width:"14",height:"14"},Y("path",{d:"m894.4 461.56-54.4-63.2c-10.4-12-18.8-34.4-18.8-50.4v-68c0-42.4-34.8-77.2-77.2-77.2h-68c-15.6 0-38.4-8.4-50.4-18.8l-63.2-54.4c-27.6-23.6-72.8-23.6-100.8 0l-62.8 54.8c-12 10-34.8 18.4-50.4 18.4h-69.2c-42.4 0-77.2 34.8-77.2 77.2v68.4c0 15.6-8.4 38-18.4 50l-54 63.6c-23.2 27.6-23.2 72.4 0 100l54 63.6c10 12 18.4 34.4 18.4 50v68.4c0 42.4 34.8 77.2 77.2 77.2h69.2c15.6 0 38.4 8.4 50.4 18.8l63.2 54.4c27.6 23.6 72.8 23.6 100.8 0l63.2-54.4c12-10.4 34.4-18.8 50.4-18.8h68c42.4 0 77.2-34.8 77.2-77.2v-68c0-15.6 8.4-38.4 18.8-50.4l54.4-63.2c23.2-27.6 23.2-73.2-.4-100.8zm-216-25.2-193.2 193.2a30 30 0 0 1-42.4 0l-96.8-96.8a30.16 30.16 0 0 1 0-42.4c11.6-11.6 30.8-11.6 42.4 0l75.6 75.6 172-172c11.6-11.6 30.8-11.6 42.4 0 11.6 11.6 11.6 30.8 0 42.4z",fill:"#27ae60"})),mi=({size:e=100})=>Y("svg",{width:e,height:e,viewBox:"0 0 100 100",preserveAspectRatio:"xMidYMid"},Y("circle",{cx:50,cy:50,fill:"none",stroke:"currentColor",strokeWidth:"4",r:"40","stroke-dasharray":"85 30"},Y("animateTransform",{attributeName:"transform",type:"rotate",repeatCount:"indefinite",dur:"1s",values:"0 50 50;360 50 50",keyTimes:"0;1"}))),Ff=()=>Y("svg",{width:24,height:24,fill:"currentcolor",viewBox:"0 0 24 24"},[Y("path",{style:"transform: translateY(0.5px)",d:"M18.968 10.5H15.968V11.484H17.984V12.984H15.968V15H14.468V9H18.968V10.5V10.5ZM8.984 9C9.26533 9 9.49967 9.09367 9.687 9.281C9.87433 9.46833 9.968 9.70267 9.968 9.984V10.5H6.499V13.5H8.468V12H9.968V14.016C9.968 14.2973 9.87433 14.5317 9.687 14.719C9.49967 14.9063 9.26533 15 8.984 15H5.984C5.70267 15 5.46833 14.9063 5.281 14.719C5.09367 14.5317 5 14.2973 5 14.016V9.985C5 9.70367 5.09367 9.46933 5.281 9.282C5.46833 9.09467 5.70267 9.001 5.984 9.001H8.984V9ZM11.468 9H12.968V15H11.468V9V9Z"}),Y("path",{d:"M18.5 3H5.75C3.6875 3 2 4.6875 2 6.75V18C2 20.0625 3.6875 21.75 5.75 21.75H18.5C20.5625 21.75 22.25 20.0625 22.25 18V6.75C22.25 4.6875 20.5625 3 18.5 3ZM20.75 18C20.75 19.2375 19.7375 20.25 18.5 20.25H5.75C4.5125 20.25 3.5 19.2375 3.5 18V6.75C3.5 5.5125 4.5125 4.5 5.75 4.5H18.5C19.7375 4.5 20.75 5.5125 20.75 6.75V18Z"})]),Uf=()=>Dt("WALINE_USER_META",{nick:"",mail:"",link:""}),Nf=()=>Dt("WALINE_COMMENT_BOX_EDITOR",""),Hf="WALINE_LIKE";let sl=null;const ll=()=>sl=sl??Dt(Hf,[]),Df="WALINE_REACTION";let al=null;const Vf=()=>al=al??Dt(Df,{});var gt,vi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},cl={},Vt={},bn={},Bf=vi&&vi.__awaiter||function(e,o,s,a){return new(s=s||Promise)(function(n,t){function r(e){try{l(a.next(e))}catch(e){t(e)}}function i(e){try{l(a.throw(e))}catch(e){t(e)}}function l(e){var t;e.done?n(e.value):((t=e.value)instanceof s?t:new s(function(e){e(t)})).then(r,i)}l((a=a.apply(e,o||[])).next())})},Wf=vi&&vi.__generator||function(r,i){var l,o,s,a={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]},e={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(n){return function(e){var t=[n,e];if(l)throw new TypeError("Generator is already executing.");for(;a;)try{if(l=1,o&&(s=2&t[0]?o.return:t[0]?o.throw||((s=o.return)&&s.call(o),0):o.next)&&!(s=s.call(o,t[1])).done)return s;switch(o=0,(t=s?[2&t[0],s.value]:t)[0]){case 0:case 1:s=t;break;case 4:return a.label++,{value:t[1],done:!1};case 5:a.label++,o=t[1],t=[0];continue;case 7:t=a.ops.pop(),a.trys.pop();continue;default:if(!(s=0<(s=a.trys).length&&s[s.length-1])&&(6===t[0]||2===t[0])){a=0;continue}if(3===t[0]&&(!s||t[1]>s[0]&&t[1]{const n=fl[e]??(fl[e]=cl.load(e,{useRecaptchaNet:!0,autoHideBadge:!0}));return{execute:t=>n.then(e=>e.execute(t))}},Zf=r=>({execute:async t=>{const e=Iu("https://challenges.cloudflare.com/turnstile/v0/api.js",void 0,{async:!1})["load"],n=(await e(),null==window?void 0:window.turnstile);return new Promise(e=>{null!=n&&n.ready(()=>{null!=n&&n.render(".wl-captcha-container",{sitekey:r,action:t,size:"compact",callback:e})})})}}),Qf="WALINE_USER";let dl=null;const wi=()=>dl=dl??Dt(Qf,{});var Jf=rn({__name:"ArticleReaction",setup(e,{expose:t}){t();const l=Vf(),o=Zn("config"),s=W(-1),a=W([]),r=we(()=>o.value.locale),c=we(()=>0{const{reaction:e,path:n}=o.value;return e.map((e,t)=>({icon:e,desc:r.value["reaction"+t],active:l.value[n]===t}))});let u;const i=async()=>{if(c.value){const{serverURL:e,lang:t,path:n,reaction:r}=o.value,i=new AbortController,l=(u=i.abort.bind(i),await ki({serverURL:e,lang:t,paths:[n],type:r.map((e,t)=>"reaction"+t),signal:i.signal}));a.value=r.map((e,t)=>l[0]["reaction"+t])}};on(()=>{je(()=>[o.value.serverURL,o.value.path],()=>{i()},{immediate:!0})}),Qi(()=>null==u?void 0:u());t={reactionStorage:l,config:o,votingIndex:s,voteNumbers:a,locale:r,isReactionEnabled:c,reactionsInfo:n,get abort(){return u},set abort(e){u=e},fetchReaction:i,vote:async e=>{var t,n,r,i;-1===s.value&&({serverURL:t,lang:n,path:r}=o.value,i=l.value[r],s.value=e,void 0!==i&&(await Sn({serverURL:t,lang:n,path:r,type:"reaction"+i,action:"desc"}),a.value[i]=Math.max(a.value[i]-1,0)),i!==e&&(await Sn({serverURL:t,lang:n,path:r,type:"reaction"+e}),a.value[e]=(a.value[e]||0)+1),i===e?delete l.value[r]:l.value[r]=e,s.value=-1)},get LoadingIcon(){return mi}};return Object.defineProperty(t,"__isScriptSetup",{enumerable:!1,value:!0}),t}}),yn=(e,t)=>{const n=e.__vccOpts||e;for(var[r,i]of t)n[r]=i;return n};const Yf={key:0,class:"wl-reaction"},Xf=["textContent"],ed={class:"wl-reaction-list"},td=["onClick"],nd={class:"wl-reaction-img"},id=["src","alt"],rd=["textContent"],od=["textContent"];function sd(e,t,n,i,r,l){return i.reactionsInfo.length?(S(),L("div",Yf,[M("div",{class:"wl-reaction-title",textContent:Q(i.locale.reactionTitle)},null,8,Xf),M("ul",ed,[(S(!0),L(oe,null,ze(i.reactionsInfo,({active:e,icon:t,desc:n},r)=>(S(),L("li",{key:r,class:pe(["wl-reaction-item",{active:e}]),onClick:e=>i.vote(r)},[M("div",nd,[M("img",{src:t,alt:n},null,8,id),i.votingIndex===r?(S(),Xe(i.LoadingIcon,{key:0,class:"wl-reaction-loading"})):(S(),L("div",{key:1,class:"wl-reaction-votes",textContent:Q(i.voteNumbers[r]||0)},null,8,rd))]),M("div",{class:"wl-reaction-text",textContent:Q(n)},null,8,od)],10,td))),128))])])):Z("v-if",!0)}var ld=yn(Jf,[["render",sd],["__file","ArticleReaction.vue"]]),_n=new Map;function ad(e){e=_n.get(e);e&&e.destroy()}function cd(e){e=_n.get(e);e&&e.update()}var kn=null,hl=("u"parseFloat(s.maxHeight)?("hidden"===s.overflowY&&(l.style.overflow="scroll"),e=parseFloat(s.maxHeight)):"hidden"!==s.overflowY&&(l.style.overflow="hidden"),l.style.height=e+"px",n&&(l.style.textAlign=n),t&&t(),o!==e&&(l.dispatchEvent(new Event("autosize:resized",{bubbles:!0})),o=e),r===s.overflow||n)||(t=s.textAlign,"hidden"===s.overflow&&(l.style.textAlign="start"===t?"end":"start"),i({restoreTextAlign:t,testForHeightReduction:!0}))}function n(){i({testForHeightReduction:!0,restoreTextAlign:null})}var l,t,o,s,r,a;(l=e)&&l.nodeName&&"TEXTAREA"===l.nodeName&&!_n.has(l)&&(o=null,s=window.getComputedStyle(l),t=l.value,r=function(){i({testForHeightReduction:""===t||!l.value.startsWith(t),restoreTextAlign:null}),t=l.value},a=function(t){l.removeEventListener("autosize:destroy",a),l.removeEventListener("autosize:update",n),l.removeEventListener("input",r),window.removeEventListener("resize",n),Object.keys(t).forEach(function(e){return l.style[e]=t[e]}),_n.delete(l)}.bind(l,{height:l.style.height,resize:l.style.resize,textAlign:l.style.textAlign,overflowY:l.style.overflowY,overflowX:l.style.overflowX,wordWrap:l.style.wordWrap}),l.addEventListener("autosize:destroy",a),l.addEventListener("autosize:update",n),l.addEventListener("input",r),window.addEventListener("resize",n),l.style.overflowX="hidden",l.style.wordWrap="break-word",_n.set(l,{destroy:a,update:n}),n())}),e}).destroy=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],ad),e},kn.update=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],cd),e}),kn),ud=rn({__name:"ImageWall",props:{items:{default:()=>[]},columnWidth:{default:300},gap:{default:0}},emits:["insert"],setup(e,{expose:t}){const n=e;t();let r=null;const i=W(null),l=W({}),o=W([]),s=()=>{var e=Math.floor((i.value.getBoundingClientRect().width+n.gap)/(n.columnWidth+n.gap));return 0new Array(e).fill(null).map(()=>[]),c=async e=>{var t;e>=n.items.length||(await Ut(),t=Array.from((null==(t=i.value)?void 0:t.children)??[]).reduce((e,t)=>t.getBoundingClientRect().height{o.value.length===s()&&!e||(o.value=a(s()),e=window.scrollY,await c(0),window.scrollTo({top:e}))};on(()=>{u(!0),(r=new ResizeObserver(()=>{u()})).observe(i.value),je(()=>[n.items],()=>{l.value={},u(!0)}),je(()=>[n.columnWidth,n.gap],()=>{u()})}),Ja(()=>r.unobserve(i.value));e={props:n,get resizeObserver(){return r},set resizeObserver(e){r=e},wall:i,state:l,columns:o,getColumnCount:s,createColumns:a,fillColumns:c,redraw:u,imageLoad:e=>{l.value[e.target.src]=!0},get LoadingIcon(){return mi}};return Object.defineProperty(e,"__isScriptSetup",{enumerable:!1,value:!0}),e}});const fd=["data-index"],dd=["src","title","onClick"];function hd(n,e,r,i,t,l){return S(),L("div",{ref:"wall",class:"wl-gallery",style:Zt({gap:r.gap+"px"})},[(S(!0),L(oe,null,ze(i.columns,(e,t)=>(S(),L("div",{key:t,class:"wl-gallery-column","data-index":t,style:Zt({gap:r.gap+"px"})},[(S(!0),L(oe,null,ze(e,t=>(S(),L(oe,{key:t},[i.state[r.items[t].src]?Z("v-if",!0):(S(),Xe(i.LoadingIcon,{key:0,size:36,style:{margin:"20px auto"}})),M("img",{class:"wl-gallery-item",src:r.items[t].src,title:r.items[t].title,loading:"lazy",onLoad:i.imageLoad,onClick:e=>n.$emit("insert",`![](${r.items[t].src})`)},null,40,dd)],64))),128))],12,fd))),128))],4)}var pd=yn(ud,[["render",hd],["__file","ImageWall.vue"]]),gd=rn({__name:"CommentBox",props:{edit:{default:null},rootId:{default:""},replyId:{default:""},replyUser:{default:""}},emits:["log","cancelEdit","cancelReply","submit"],setup(e,{expose:t,emit:n}){t();const f=e,g=n,m=Zn("config"),v=Nf(),y=Uf(),w=wi(),b=W({}),k=W(null),r=W(null),i=W(null),l=W(null),o=W(null),s=W(null),a=W(null),x=W({tabs:[],map:{}}),c=W(0),u=W(!1),p=W(!1),O=W(!1),_=W(""),S=W(0),d=Qt({loading:!0,list:[]}),h=W(0),C=W(!1),L=W(""),R=W(!1),I=W(!1),E=we(()=>m.value.locale),P=we(()=>{var e;return!(null==(e=w.value)||!e.token)}),A=we(()=>!1!==m.value.imageUploader),$=e=>{const t=k.value,n=t.selectionStart,r=t.selectionEnd||0,i=t.scrollTop;v.value=t.value.substring(0,n)+e+t.value.substring(r,t.value.length),t.focus(),t.selectionStart=n+e.length,t.selectionEnd=n+e.length,t.scrollTop=i},M=t=>{const n=`![${m.value.locale.uploading} ${t.name}]()`;return $(n),R.value=!0,Promise.resolve().then(()=>m.value.imageUploader(t)).then(e=>{v.value=v.value.replace(n,`\r +![${t.name}](${e})`)}).catch(e=>{alert(e.message),v.value=v.value.replace(n,"")}).then(()=>{R.value=!1})},T=async()=>{var e,t,n;const{serverURL:r,lang:i,login:l,wordLimit:o,requiredMeta:s,recaptchaV3Key:a,turnstileKey:c}=m.value,u=await If(),p={comment:L.value,nick:y.value.nick,mail:y.value.mail,link:y.value.link,url:m.value.path,ua:u};if(!f.edit)if(null!=(e=w.value)&&e.token)p.nick=w.value.display_name,p.mail=w.value.email,p.link=w.value.url;else{if("force"===l)return;if(-1{var t;null!=(t=i.value)&&t.contains(e.target)||null!=(t=l.value)&&t.contains(e.target)||(u.value=!1),null!=(t=o.value)&&t.contains(e.target)||null!=(t=s.value)&&t.contains(e.target)||(p.value=!1)},j=async e=>{var t;const{scrollTop:n,clientHeight:r,scrollHeight:i}=e.target,l=(r+n)/i,o=m.value.search,s=(null==(t=a.value)?void 0:t.value)??"";l<.9||d.loading||I.value||(d.loading=!0,(o.more&&d.list.length?await o.more(s,d.list.length):await o.search(s)).length?d.list=[...d.list,...o.more&&d.list.length?await o.more(s,d.list.length):await o.search(s)]:I.value=!0,d.loading=!1,setTimeout(()=>{e.target.scrollTop=n},50))},N=pu(e=>{d.list=[],I.value=!1,j(e)},300);je([m,S],([e,t])=>{e=e.wordLimit;e?te[1]?(h.value=e[1],C.value=!1):(h.value=e[1],C.value=!0):(h.value=0,C.value=!0)},{immediate:!0}),li("click",z),li("message",({data:e})=>{e&&"profile"===e.type&&(w.value={...w.value,...e.data},[localStorage,sessionStorage].filter(e=>e.getItem("WALINE_USER")).forEach(e=>e.setItem("WALINE_USER",JSON.stringify(w))))}),je(p,async e=>{if(e){const t=m.value.search;a.value&&(a.value.value=""),d.loading=!0,d.list=await((null==(e=t.default)?void 0:e.call(t))??t.search("")),d.loading=!1}}),on(()=>{var e;null!=(e=f.edit)&&e.objectId&&(v.value=f.edit.orig),je(()=>v.value,e=>{var{highlighter:t,texRenderer:n}=m.value;L.value=e,_.value=xf(e,{emojiMap:x.value.map,highlighter:t,texRenderer:n}),S.value=Sf(e),e?hl(k.value):hl.destroy(k.value)},{immediate:!0}),je(()=>m.value.emoji,e=>Mu(e).then(e=>{x.value=e}),{immediate:!0})});t={props:f,emit:g,config:m,editor:v,userMeta:y,userInfo:w,inputRefs:b,editorRef:k,imageUploadRef:r,emojiButtonRef:i,emojiPopupRef:l,gifButtonRef:o,gifPopupRef:s,gifSearchInputRef:a,emoji:x,emojiTabIndex:c,showEmoji:u,showGif:p,showPreview:O,previewText:_,wordNumber:S,searchResults:d,wordLimit:h,isWordNumberLegal:C,content:L,isSubmitting:R,isImageListEnd:I,locale:E,isLogin:P,canUploadImage:A,insert:$,onKeyDown:e=>{var t=e.key;(e.ctrlKey||e.metaKey)&&"Enter"===t&&T()},uploadImage:M,onDrop:e=>{var t;null!=(t=e.dataTransfer)&&t.items&&(t=js(e.dataTransfer.items))&&A.value&&(M(t),e.preventDefault())},onPaste:e=>{e.clipboardData&&(e=js(e.clipboardData.items))&&A.value&&M(e)},onChange:()=>{const e=r.value;e.files&&A.value&&M(e.files[0]).then(()=>{e.value=""})},submitComment:T,onLogin:e=>{e.preventDefault();var{lang:e,serverURL:t}=m.value;Ar({serverURL:t,lang:e}).then(e=>{((w.value=e).remember?localStorage:sessionStorage).setItem("WALINE_USER",JSON.stringify(e)),g("log")})},onLogout:()=>{w.value={},localStorage.setItem("WALINE_USER","null"),sessionStorage.setItem("WALINE_USER","null"),g("log")},onProfile:e=>{e.preventDefault();const{lang:t,serverURL:n}=m.value,r=(window.innerWidth-800)/2,i=(window.innerHeight-800)/2,l=new URLSearchParams({lng:t,token:w.value.token}),o=window.open(n+"/ui/profile?"+l.toString(),"_blank",`width=800,height=800,left=${r},top=${i},scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no`);null!=o&&o.postMessage({type:"TOKEN",data:w.value.token},"*")},popupHandler:z,onImageWallScroll:j,onGifSearch:N,get CloseIcon(){return Rf},get EmojiIcon(){return Lf},get GifIcon(){return Ff},get ImageIcon(){return Af},get LoadingIcon(){return mi},get MarkdownIcon(){return Of},get PreviewIcon(){return $f},ImageWall:pd};return Object.defineProperty(t,"__isScriptSetup",{enumerable:!1,value:!0}),t}});const md={key:0,class:"wl-login-info"},vd={class:"wl-avatar"},wd=["title"],bd=["title"],yd=["src"],_d=["title","textContent"],kd={class:"wl-panel"},xd=["for","textContent"],Cd=["id","onUpdate:modelValue","name","type"],Ed=["placeholder"],Sd={class:"wl-preview"},Id=M("hr",null,null,-1),Rd=["innerHTML"],Td={class:"wl-footer"},Ld={class:"wl-actions"},Ad={href:"https://guides.github.com/features/mastering-markdown/",title:"Markdown Guide","aria-label":"Markdown is supported",class:"wl-action",target:"_blank",rel:"noopener noreferrer"},Md=["title"],$d=["title"],Od=["title"],jd=["title"],zd={class:"wl-info"},Pd=M("div",{class:"wl-captcha-container"},null,-1),Fd={class:"wl-text-number"},Ud={key:0},Nd=["textContent"],Hd=["textContent"],Dd=["disabled"],Vd=["placeholder"],Bd={key:1,class:"wl-loading"},Wd={key:0,class:"wl-tab-wrapper"},qd=["title","onClick"],Kd=["src","alt"],Gd={key:0,class:"wl-tabs"},Zd=["onClick"],Qd=["src","alt","title"],Jd=["title"];function Yd(e,t,n,r,i,l){var o;return S(),L("div",{key:r.userInfo.token,class:"wl-comment"},["disable"===r.config.login||!r.isLogin||null!=(o=n.edit)&&o.objectId?Z("v-if",!0):(S(),L("div",md,[M("div",vd,[M("button",{type:"submit",class:"wl-logout-btn",title:r.locale.logout,onClick:r.onLogout},[ie(r.CloseIcon,{size:14})],8,wd),M("a",{href:"#",class:"wl-login-nick","aria-label":"Profile",title:r.locale.profile,onClick:r.onProfile},[M("img",{src:r.userInfo.avatar,alt:"avatar"},null,8,yd)],8,bd)]),M("a",{href:"#",class:"wl-login-nick","aria-label":"Profile",title:r.locale.profile,onClick:r.onProfile,textContent:Q(r.userInfo.display_name)},null,8,_d)])),M("div",kd,["force"!==r.config.login&&r.config.meta.length&&!r.isLogin?(S(),L("div",{key:0,class:pe(["wl-header","item"+r.config.meta.length])},[(S(!0),L(oe,null,ze(r.config.meta,t=>(S(),L("div",{key:t,class:"wl-header-item"},[M("label",{for:"wl-"+t,textContent:Q(r.locale[t]+(r.config.requiredMeta.includes(t)||!r.config.requiredMeta.length?"":`(${r.locale.optional})`))},null,8,xd),qn(M("input",{id:"wl-"+t,ref_for:!0,ref:e=>{e&&(r.inputRefs[t]=e)},"onUpdate:modelValue":e=>r.userMeta[t]=e,class:pe(["wl-input","wl-"+t]),name:t,type:"mail"===t?"email":"text"},null,10,Cd),[[iu,r.userMeta[t]]])]))),128))],2)):Z("v-if",!0),qn(M("textarea",{id:"wl-edit",ref:"editorRef","onUpdate:modelValue":t[0]||(t[0]=e=>r.editor=e),class:"wl-editor",placeholder:n.replyUser?"@"+n.replyUser:r.locale.placeholder,onKeydown:r.onKeyDown,onDrop:r.onDrop,onPaste:r.onPaste},null,40,Ed),[[ur,r.editor]]),qn(M("div",Sd,[Id,M("h4",null,Q(r.locale.preview)+":",1),M("div",{class:"wl-content",innerHTML:r.previewText},null,8,Rd)],512),[[ms,r.showPreview]]),M("div",Td,[M("div",Ld,[M("a",Ad,[ie(r.MarkdownIcon)]),qn(M("button",{ref:"emojiButtonRef",type:"button",class:pe(["wl-action",{active:r.showEmoji}]),title:r.locale.emoji,onClick:t[1]||(t[1]=e=>r.showEmoji=!r.showEmoji)},[ie(r.EmojiIcon)],10,Md),[[ms,r.emoji.tabs.length]]),r.config.search?(S(),L("button",{key:0,ref:"gifButtonRef",type:"button",class:pe(["wl-action",{active:r.showGif}]),title:r.locale.gif,onClick:t[2]||(t[2]=e=>r.showGif=!r.showGif)},[ie(r.GifIcon)],10,$d)):Z("v-if",!0),M("input",{id:"wl-image-upload",ref:"imageUploadRef",class:"upload",type:"file",accept:".png,.jpg,.jpeg,.webp,.bmp,.gif",onChange:r.onChange},null,544),r.canUploadImage?(S(),L("label",{key:1,for:"wl-image-upload",class:"wl-action",title:r.locale.uploadImage},[ie(r.ImageIcon)],8,Od)):Z("v-if",!0),M("button",{type:"button",class:pe(["wl-action",{active:r.showPreview}]),title:r.locale.preview,onClick:t[3]||(t[3]=e=>r.showPreview=!r.showPreview)},[ie(r.PreviewIcon)],10,jd)]),M("div",zd,[Pd,M("div",Fd,[et(Q(r.wordNumber)+" ",1),r.config.wordLimit?(S(),L("span",Ud,[et("  /  "),M("span",{class:pe({illegal:!r.isWordNumberLegal}),textContent:Q(r.wordLimit)},null,10,Nd)])):Z("v-if",!0),et("  "+Q(r.locale.word),1)]),"disable"===r.config.login||r.isLogin?Z("v-if",!0):(S(),L("button",{key:0,type:"button",class:"wl-btn",onClick:r.onLogin,textContent:Q(r.locale.login)},null,8,Hd)),"force"!==r.config.login||r.isLogin?(S(),L("button",{key:1,type:"submit",class:"primary wl-btn",title:"Cmd|Ctrl + Enter",disabled:r.isSubmitting,onClick:r.submitComment},[r.isSubmitting?(S(),Xe(r.LoadingIcon,{key:0,size:16})):(S(),L(oe,{key:1},[et(Q(r.locale.submit),1)],64))],8,Dd)):Z("v-if",!0)]),M("div",{ref:"gifPopupRef",class:pe(["wl-gif-popup",{display:r.showGif}])},[M("input",{ref:"gifSearchInputRef",type:"text",placeholder:r.locale.gifSearchPlaceholder,onInput:t[4]||(t[4]=(...e)=>r.onGifSearch&&r.onGifSearch(...e))},null,40,Vd),r.searchResults.list.length?(S(),Xe(r.ImageWall,{key:0,items:r.searchResults.list,"column-width":200,gap:6,onInsert:t[5]||(t[5]=e=>r.insert(e)),onScroll:r.onImageWallScroll},null,8,["items"])):Z("v-if",!0),r.searchResults.loading?(S(),L("div",Bd,[ie(r.LoadingIcon,{size:30})])):Z("v-if",!0)],2),M("div",{ref:"emojiPopupRef",class:pe(["wl-emoji-popup",{display:r.showEmoji}])},[(S(!0),L(oe,null,ze(r.emoji.tabs,(e,t)=>(S(),L(oe,{key:e.name},[t===r.emojiTabIndex?(S(),L("div",Wd,[(S(!0),L(oe,null,ze(e.items,t=>(S(),L("button",{key:t,type:"button",title:t,onClick:e=>r.insert(`:${t}:`)},[r.showEmoji?(S(),L("img",{key:0,class:"wl-emoji",src:r.emoji.map[t],alt:t,loading:"lazy",referrerPolicy:"no-referrer"},null,8,Kd)):Z("v-if",!0)],8,qd))),128))])):Z("v-if",!0)],64))),128)),1(S(),L("button",{key:e.name,type:"button",class:pe(["wl-tab",{active:r.emojiTabIndex===t}]),onClick:e=>r.emojiTabIndex=t},[M("img",{class:"wl-emoji",src:e.icon,alt:e.name,title:e.name,loading:"lazy",referrerPolicy:"no-referrer"},null,8,Qd)],10,Zd))),128))])):Z("v-if",!0)],2)])]),n.replyId||null!=(o=n.edit)&&o.objectId?(S(),L("button",{key:1,type:"button",class:"wl-close",title:r.locale.cancelReply,onClick:t[6]||(t[6]=e=>n.replyId?r.emit("cancelReply"):r.emit("cancelEdit"))},[ie(r.CloseIcon,{size:24})],8,Jd)):Z("v-if",!0)])}var pl=yn(gd,[["render",Yd],["__file","CommentBox.vue"]]),Xd=rn({__name:"CommentCard",props:{comment:{},edit:{default:null},rootId:{},reply:{default:null}},emits:["log","submit","delete","edit","like","status","sticky","reply"],setup(e,{expose:t,emit:n}){t();const r=e,i=n,l=Zn("config"),o=ll(),s=Su(),a=wi(),c=we(()=>l.value.locale),u=we(()=>{var e=r.comment["link"];return e?Qr(e)?e:"https://"+e:""}),p=we(()=>o.value.includes(r.comment.objectId)),d=we(()=>Hl(new Date(r.comment.time),s.value,c.value)),h=we(()=>"administrator"===a.value.type),f=we(()=>r.comment.user_id&&a.value.objectId===r.comment.user_id),g=we(()=>{var e;return r.comment.objectId===(null==(e=r.reply)?void 0:e.objectId)}),m=we(()=>{var e;return r.comment.objectId===(null==(e=r.edit)?void 0:e.objectId)}),v={props:r,emit:i,commentStatus:["approved","waiting","spam"],config:l,likes:o,now:s,userInfo:a,locale:c,link:u,like:p,time:d,isAdmin:h,isOwner:f,isReplyingCurrent:g,isEditingCurrent:m,CommentBox:pl,get DeleteIcon(){return Tf},get EditIcon(){return zf},get LikeIcon(){return Mf},get ReplyIcon(){return jf},get VerifiedIcon(){return Pf}};return Object.defineProperty(v,"__isScriptSetup",{enumerable:!1,value:!0}),v}});const eh=["id"],th={class:"wl-user","aria-hidden":"true"},nh=["src"],ih={class:"wl-card"},rh={class:"wl-head"},oh=["href"],sh={key:1,class:"wl-nick"},lh=["textContent"],ah=["textContent"],ch=["textContent"],uh=["textContent"],fh=["textContent"],dh={class:"wl-comment-actions"},hh=["title"],ph=["title"],gh={class:"wl-meta","aria-hidden":"true"},mh=["data-value","textContent"],vh={key:0,class:"wl-content"},wh={key:0},bh=["href"],yh=M("span",null,": ",-1),_h=["innerHTML"],kh={key:1,class:"wl-admin-actions"},xh={class:"wl-comment-status"},Ch=["disabled","onClick","textContent"],Eh={key:3,class:"wl-quote"};function Sh(e,t,n,r,i,l){var o;const s=Da("CommentCard",!0);return S(),L("div",{id:n.comment.objectId,class:"wl-card-item"},[M("div",th,[n.comment.avatar?(S(),L("img",{key:0,class:"wl-user-avatar",src:n.comment.avatar},null,8,nh)):Z("v-if",!0),n.comment.type?(S(),Xe(r.VerifiedIcon,{key:1})):Z("v-if",!0)]),M("div",ih,[M("div",rh,[r.link?(S(),L("a",{key:0,class:"wl-nick",href:r.link,target:"_blank",rel:"nofollow noopener noreferrer"},Q(n.comment.nick),9,oh)):(S(),L("span",sh,Q(n.comment.nick),1)),"administrator"===n.comment.type?(S(),L("span",{key:2,class:"wl-badge",textContent:Q(r.locale.admin)},null,8,lh)):Z("v-if",!0),n.comment.label?(S(),L("span",{key:3,class:"wl-badge",textContent:Q(n.comment.label)},null,8,ah)):Z("v-if",!0),n.comment.sticky?(S(),L("span",{key:4,class:"wl-badge",textContent:Q(r.locale.sticky)},null,8,ch)):Z("v-if",!0),"number"==typeof n.comment.level?(S(),L("span",{key:5,class:pe("wl-badge level"+n.comment.level),textContent:Q(r.locale["level"+n.comment.level]||"Level "+n.comment.level)},null,10,uh)):Z("v-if",!0),M("span",{class:"wl-time",textContent:Q(r.time)},null,8,fh),M("div",dh,[r.isAdmin||r.isOwner?(S(),L(oe,{key:0},[M("button",{type:"button",class:"wl-edit",onClick:t[0]||(t[0]=e=>r.emit("edit",n.comment))},[ie(r.EditIcon)]),M("button",{type:"button",class:"wl-delete",onClick:t[1]||(t[1]=e=>r.emit("delete",n.comment))},[ie(r.DeleteIcon)])],64)):Z("v-if",!0),M("button",{type:"button",class:"wl-like",title:r.like?r.locale.cancelLike:r.locale.like,onClick:t[2]||(t[2]=e=>r.emit("like",n.comment))},[ie(r.LikeIcon,{active:r.like},null,8,["active"]),et(" "+Q("like"in n.comment?n.comment.like:""),1)],8,hh),M("button",{type:"button",class:pe(["wl-reply",{active:r.isReplyingCurrent}]),title:r.isReplyingCurrent?r.locale.cancelReply:r.locale.reply,onClick:t[3]||(t[3]=e=>r.emit("reply",r.isReplyingCurrent?null:n.comment))},[ie(r.ReplyIcon)],10,ph)])]),M("div",gh,[(S(),L(oe,null,ze(["addr","browser","os"],e=>(S(),L(oe,null,[n.comment[e]?(S(),L("span",{key:e,class:pe("wl-"+e),"data-value":n.comment[e],textContent:Q(n.comment[e])},null,10,mh)):Z("v-if",!0)],64))),64))]),r.isEditingCurrent?Z("v-if",!0):(S(),L("div",vh,[n.comment.reply_user?(S(),L("p",wh,[M("a",{href:"#"+n.comment.pid},"@"+Q(n.comment.reply_user.nick),9,bh),yh])):Z("v-if",!0),M("div",{innerHTML:n.comment.comment},null,8,_h)])),r.isAdmin&&!r.isEditingCurrent?(S(),L("div",kh,[M("span",xh,[(S(),L(oe,null,ze(r.commentStatus,t=>M("button",{key:t,type:"submit",class:pe("wl-btn wl-"+t),disabled:n.comment.status===t,onClick:e=>r.emit("status",{status:t,comment:n.comment}),textContent:Q(r.locale[t])},null,10,Ch)),64))]),!r.isAdmin||"rid"in n.comment?Z("v-if",!0):(S(),L("button",{key:0,type:"submit",class:"wl-btn wl-sticky",onClick:t[4]||(t[4]=e=>r.emit("sticky",n.comment))},Q(n.comment.sticky?r.locale.unsticky:r.locale.sticky),1))])):Z("v-if",!0),r.isReplyingCurrent||r.isEditingCurrent?(S(),L("div",{key:2,class:pe({"wl-reply-wrapper":r.isReplyingCurrent,"wl-edit-wrapper":r.isEditingCurrent})},[ie(r.CommentBox,{edit:n.edit,"reply-id":null==(o=n.reply)?void 0:o.objectId,"reply-user":n.comment.nick,"root-id":n.rootId,onLog:t[5]||(t[5]=e=>r.emit("log")),onCancelReply:t[6]||(t[6]=e=>r.emit("reply",null)),onCancelEdit:t[7]||(t[7]=e=>r.emit("edit",null)),onSubmit:t[8]||(t[8]=e=>r.emit("submit",e))},null,8,["edit","reply-id","reply-user","root-id"])],2)):Z("v-if",!0),"children"in n.comment?(S(),L("div",Eh,[(S(!0),L(oe,null,ze(n.comment.children,e=>(S(),Xe(s,{key:e.objectId,comment:e,reply:n.reply,edit:n.edit,"root-id":n.rootId,onLog:t[9]||(t[9]=e=>r.emit("log")),onDelete:t[10]||(t[10]=e=>r.emit("delete",e)),onEdit:t[11]||(t[11]=e=>r.emit("edit",e)),onLike:t[12]||(t[12]=e=>r.emit("like",e)),onReply:t[13]||(t[13]=e=>r.emit("reply",e)),onStatus:t[14]||(t[14]=e=>r.emit("status",e)),onSticky:t[15]||(t[15]=e=>r.emit("sticky",e)),onSubmit:t[16]||(t[16]=e=>r.emit("submit",e))},null,8,["comment","reply","edit","root-id"]))),128))])):Z("v-if",!0)])],8,eh)}var Ih=yn(Xd,[["render",Sh],["__file","CommentCard.vue"]]);const gl="3.3.0";var Rh=rn({__name:"WalineComment",props:["serverURL","path","meta","requiredMeta","dark","commentSorting","lang","locale","pageSize","wordLimit","emoji","login","highlighter","texRenderer","imageUploader","search","copyright","recaptchaV3Key","turnstileKey","reaction"],setup(e,{expose:t}){t();const n=e,o={latest:"insertedAt_desc",oldest:"insertedAt_asc",hottest:"like_desc"},r=Object.keys(o),s=wi(),a=ll(),c=W("loading"),u=W(0),p=W(1),d=W(0),h=we(()=>Fl(n)),f=W(h.value.commentSorting),g=W([]),i=W(null),l=W(null),m=we(()=>Ul(h.value.dark)),v=we(()=>h.value.locale);Tu(m,{id:"waline-darkmode"});let y;const w=t=>{var e;const{serverURL:n,path:r,pageSize:i}=h.value,l=new AbortController;c.value="loading",null!=y&&y(),Ir({serverURL:n,lang:h.value.lang,path:r,pageSize:i,sortBy:o[f.value],page:t,signal:l.signal,token:null==(e=s.value)?void 0:e.token}).then(e=>{c.value="success",u.value=e.count,g.value.push(...e.data),p.value=t,d.value=e.totalPages}).catch(e=>{"AbortError"!==e.name&&(console.error(e.message),c.value="error")}),y=l.abort.bind(l)},b=()=>{u.value=0,g.value=[],w(1)};oc("config",h),on(()=>{je(()=>[n.serverURL,n.path],()=>b(),{immediate:!0})}),Qi(()=>null==y?void 0:y());t={props:n,sortKeyMap:o,sortingMethods:r,userInfo:s,likeStorage:a,status:c,count:u,page:p,totalPages:d,config:h,commentSortingRef:f,data:g,reply:i,edit:l,darkmodeStyle:m,i18n:v,get abort(){return y},set abort(e){y=e},getCommentData:w,loadMore:()=>w(p.value+1),refresh:b,onSortByChange:e=>{f.value!==e&&(f.value=e,b())},onReply:e=>{i.value=e},onEdit:e=>{l.value=e},onSubmit:t=>{if(l.value)l.value.comment=t.comment,l.value.orig=t.orig;else if("rid"in t){const e=g.value.find(({objectId:e})=>e===t.rid);e&&(Array.isArray(e.children)||(e.children=[]),e.children.push(t))}else g.value.unshift(t),u.value+=1},onStatusChange:async({comment:e,status:t})=>{var n,r;e.status!==t&&({serverURL:n,lang:r}=h.value,await qt({serverURL:n,lang:r,token:null==(n=s.value)?void 0:n.token,objectId:e.objectId,comment:{status:t}}),e.status=t)},onSticky:async e=>{var t,n;"rid"in e||({serverURL:t,lang:n}=h.value,await qt({serverURL:t,lang:n,token:null==(t=s.value)?void 0:t.token,objectId:e.objectId,comment:{sticky:e.sticky?0:1}}),e.sticky=!e.sticky)},onDelete:async({objectId:i})=>{var e,t;confirm("Are you sure you want to delete this comment?")&&({serverURL:e,lang:t}=h.value,await Tr({serverURL:e,lang:t,token:null==(e=s.value)?void 0:e.token,objectId:i}),g.value.some((t,r)=>t.objectId===i?(g.value=g.value.filter((e,t)=>t!==r),!0):t.children.some((e,n)=>e.objectId===i&&(g.value[r].children=t.children.filter((e,t)=>t!==n),!0))))},onLike:async e=>{var t;const{serverURL:n,lang:r}=h.value,i=e["objectId"],l=a.value.includes(i);await qt({serverURL:n,lang:r,objectId:i,token:null==(t=s.value)?void 0:t.token,comment:{like:!l}}),l?a.value=a.value.filter(e=>e!==i):(a.value=[...a.value,i],50(S(),L("li",{key:t,class:pe([t===r.commentSortingRef?"active":""]),onClick:e=>r.onSortByChange(t)},Q(r.i18n[t]),11,Oh))),128))])]),M("div",jh,[(S(!0),L(oe,null,ze(r.data,e=>(S(),Xe(r.CommentCard,{key:e.objectId,"root-id":e.objectId,comment:e,reply:r.reply,edit:r.edit,onLog:r.refresh,onReply:r.onReply,onEdit:r.onEdit,onSubmit:r.onSubmit,onStatus:r.onStatusChange,onDelete:r.onDelete,onSticky:r.onSticky,onLike:r.onLike},null,8,["root-id","comment","reply","edit"]))),128))]),"error"===r.status?(S(),L("div",zh,[M("button",{type:"button",class:"wl-btn",onClick:r.refresh,textContent:Q(r.i18n.refresh)},null,8,Ph)])):"loading"===r.status?(S(),L("div",Fh,[ie(r.LoadingIcon,{size:30})])):r.data.length?r.page{e.forEach((e,t)=>{const n=r[t].time;"number"==typeof n&&(e.innerText=n.toString())})},vl=({serverURL:e,path:n=window.location.pathname,selector:t=".waline-pageview-count",update:r=!0,lang:i=navigator.language})=>{const l=new AbortController,o=Array.from(document.querySelectorAll(t)),s=e=>{e=_r(e);return null!==e&&n!==e},a=t=>Mr({serverURL:Rn(e),paths:t.map(e=>_r(e)??n),lang:i,signal:l.signal}).then(e=>ml(e,t)).catch(Os);if(r){const c=o.filter(e=>!s(e)),u=o.filter(s);$r({serverURL:Rn(e),path:n,lang:i}).then(e=>ml(e,c)),u.length&&a(u)}else a(o);return l.abort.bind(l)},qh=({el:e="#waline",path:t=window.location.pathname,comment:n=!1,pageview:r=!1,...i})=>{var l=e?dr(e):null;if(e&&!l)throw new Error("Option 'el' do not match any domElement!");if(!i.serverURL)throw new Error("Option 'serverURL' is missing!");const o=Qt({...i}),s=Qt({comment:n,pageview:r,path:t}),a=l?lu(()=>Y(Wh,{path:s.path,...o})):null,c=(a&&a.mount(l),No(()=>{s.comment&&ol({serverURL:o.serverURL,path:s.path,...$t(s.comment)?{selector:s.comment}:{}})})),u=No(()=>{s.pageview&&vl({serverURL:o.serverURL,path:s.path,...$t(s.pageview)?{selector:s.pageview}:{}})});return{el:l,update:({comment:e,pageview:t,path:n=window.location.pathname,...r}={})=>{Object.entries(r).forEach(([e,t])=>{o[e]=t}),s.path=n,void 0!==e&&(s.comment=e),void 0!==t&&(s.pageview=t)},destroy:()=>{null!=a&&a.unmount(),c(),u()}}},Kh=({el:e,serverURL:t,count:n,lang:r=navigator.language})=>{const i=wi(),l=dr(e),o=new AbortController;return Or({serverURL:t,count:n,lang:r,signal:o.signal,token:null==(e=i.value)?void 0:e.token}).then(e=>l&&e.length?(l.innerHTML=`
    `,{comments:e,destroy:()=>{o.abort(),l.innerHTML=""}}):{comments:e,destroy:()=>o.abort()})},Gh=({el:e,serverURL:t,count:n,locale:r,lang:i=navigator.language,mode:l="list"})=>{const o=dr(e),s=new AbortController;return jr({serverURL:t,pageSize:n,lang:i,signal:s.signal}).then(e=>o&&e.length?(r={...qr(i),..."object"==typeof r?r:{}},o.innerHTML=``,{users:e,destroy:()=>{s.abort(),o.innerHTML=""}}):{users:e,destroy:()=>s.abort()})};export{Kh as RecentComments,Gh as UserList,Rr as addComment,ol as commentCount,In as defaultLocales,Tr as deleteComment,Lr as fetchCommentCount,ki as getArticleCounter,Ir as getComment,Mr as getPageview,Or as getRecentComment,jr as getUserList,qh as init,Ar as login,vl as pageviewCount,Sn as updateArticleCounter,qt as updateComment,$r as updatePageview,gl as version}; \ No newline at end of file diff --git a/static/3rd/waline/3.3.0/waline.umd.min.js b/static/3rd/waline/3.3.0/waline.umd.min.js new file mode 100644 index 0000000..147ddb1 --- /dev/null +++ b/static/3rd/waline/3.3.0/waline.umd.min.js @@ -0,0 +1,56 @@ +var Wh=Object.defineProperty,qh=(e,t,n)=>t in e?Wh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ne=(e,t,n)=>(qh(e,"symbol"!=typeof t?t+"":t,n),n),Kh=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},xr=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},_i=(e,t,n)=>(Kh(e,t,"access private method"),n);!function(e,t){"object"==typeof exports&&typeof module<"u"?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=typeof globalThis<"u"?globalThis:e||self).Waline={})}(this,function(e){"use strict";var i,x,L,R;const I={"Content-Type":"application/json"},A=e=>e.replace(/\/?$/,"/")+"api/",$=(e,t="")=>{if("object"==typeof e&&e.errno)throw new TypeError(`${t} failed with ${e.errno}: `+e.errmsg);return e},M=({serverURL:e,lang:t,paths:n,type:r,signal:l})=>fetch(`${A(e)}article?path=${encodeURIComponent(n.join(","))}&type=${encodeURIComponent(r.join(","))}&lang=`+t,{signal:l}).then(e=>e.json()).then(e=>$(e,"Get counter").data),P=({serverURL:e,lang:t,path:n,type:r,action:l})=>fetch(A(e)+"article?lang="+t,{method:"POST",headers:I,body:JSON.stringify({path:n,type:r,action:l})}).then(e=>e.json()).then(e=>$(e,"Update counter").data),U=({serverURL:e,lang:t,path:n,page:r,pageSize:l,sortBy:i,signal:o,token:s})=>{const a={};return s&&(a.Authorization="Bearer "+s),fetch(`${A(e)}comment?path=${encodeURIComponent(n)}&pageSize=${l}&page=${r}&lang=${t}&sortBy=`+i,{signal:o,headers:a}).then(e=>e.json()).then(e=>$(e,"Get comment data").data)},V=({serverURL:e,lang:t,token:n,comment:r})=>{const l={"Content-Type":"application/json"};return n&&(l.Authorization="Bearer "+n),fetch(A(e)+"comment?lang="+t,{method:"POST",headers:l,body:JSON.stringify(r)}).then(e=>e.json())},D=({serverURL:e,lang:t,token:n,objectId:r})=>fetch(A(e)+`comment/${r}?lang=`+t,{method:"DELETE",headers:{Authorization:"Bearer "+n}}).then(e=>e.json()).then(e=>$(e,"Delete comment")),H=({serverURL:e,lang:t,token:n,objectId:r,comment:l})=>fetch(A(e)+`comment/${r}?lang=`+t,{method:"PUT",headers:{...I,Authorization:"Bearer "+n},body:JSON.stringify(l)}).then(e=>e.json()).then(e=>$(e,"Update comment")),B=({serverURL:e,lang:t,paths:n,signal:r})=>fetch(`${A(e)}comment?type=count&url=${encodeURIComponent(n.join(","))}&lang=`+t,{signal:r}).then(e=>e.json()).then(e=>$(e,"Get comment count").data),W=({lang:e,serverURL:t})=>{const n=(window.innerWidth-450)/2,r=(window.innerHeight-450)/2,l=window.open(t.replace(/\/$/,"")+"/ui/login?lng="+encodeURIComponent(e),"_blank",`width=450,height=450,left=${n},top=${r},scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no`);return null!=l&&l.postMessage({type:"TOKEN",data:null},"*"),new Promise(t=>{const n=({data:e})=>{e&&"object"==typeof e&&"userInfo"===e.type&&e.data.token&&(null!=l&&l.close(),window.removeEventListener("message",n),t(e.data))};window.addEventListener("message",n)})},q=({serverURL:e,lang:t,paths:n,signal:r})=>M({serverURL:e,lang:t,paths:n,type:["time"],signal:r}),G=e=>P({...e,type:"time",action:"inc"}),Z=({serverURL:e,lang:t,count:n,signal:r,token:l})=>{const i={};return l&&(i.Authorization="Bearer "+l),fetch(A(e)+`comment?type=recent&count=${n}&lang=`+t,{signal:r,headers:i}).then(e=>e.json())},K=({serverURL:e,signal:t,pageSize:n,lang:r})=>fetch(A(e)+`user?pageSize=${n}&lang=`+r,{signal:t}).then(e=>e.json()).then(e=>$(e,"user list")).then(e=>e.data),Q=["nick","mail","link"],ne=e=>e.filter(e=>Q.includes(e)),re=["//unpkg.com/@waline/emojis@1.1.0/weibo"],le=["//unpkg.com/@waline/emojis/tieba/tieba_agree.png","//unpkg.com/@waline/emojis/tieba/tieba_look_down.png","//unpkg.com/@waline/emojis/tieba/tieba_sunglasses.png","//unpkg.com/@waline/emojis/tieba/tieba_pick_nose.png","//unpkg.com/@waline/emojis/tieba/tieba_awkward.png","//unpkg.com/@waline/emojis/tieba/tieba_sleep.png"],ie=r=>new Promise((t,e)=>{if(128e3{var e;return t((null==(e=n.result)?void 0:e.toString())??"")},n.onerror=e}),oe=e=>!0===e?'

    TeX is not available in preview

    ':'TeX is not available in preview',se=new RegExp(`(${/[\u4E00-\u9FFF\u3400-\u4dbf\uf900-\ufaff\u3040-\u309f\uac00-\ud7af\u0400-\u04FF]+|\w+/.source}|${/{let l=0;return e.replace(se,(e,t,n)=>{if(n)return`${n}`;if("<"===t)return"<";let r;ce[t]?r=ce[t]:(r=ae[l],ce[t]=r);n=`${t}`;return l=++l%ae.length,n})},pe=["nick","nickError","mail","mailError","link","optional","placeholder","sofa","submit","like","cancelLike","reply","cancelReply","comment","refresh","more","preview","emoji","uploadImage","seconds","minutes","hours","days","now","uploading","login","logout","admin","sticky","word","wordHint","anonymous","level0","level1","level2","level3","level4","level5","gif","gifSearchPlaceholder","profile","approved","waiting","spam","unsticky","oldest","latest","hottest","reactionTitle"],de=e=>Object.fromEntries(e.map((e,t)=>[pe[t],e]));var he=de(["NickName","NickName cannot be less than 3 bytes.","E-Mail","Please confirm your email address.","Website","Optional","Comment here...","No comment yet.","Submit","Like","Cancel like","Reply","Cancel reply","Comments","Refresh","Load More...","Preview","Emoji","Upload Image","seconds ago","minutes ago","hours ago","days ago","just now","Uploading","Login","logout","Admin","Sticky","Words",`Please input comments between $0 and $1 words! + Current word number: $2`,"Anonymous","Dwarves","Hobbits","Ents","Wizards","Elves","Maiar","GIF","Search GIF","Profile","Approved","Waiting","Spam","Unsticky","Oldest","Latest","Hottest","What do you think?"]),fe=de(["Pseudo","Le pseudo ne peut pas faire moins de 3 octets.","E-mail","Veuillez confirmer votre adresse e-mail.","Site Web","Optionnel","Commentez ici...","Aucun commentaire pour l'instant.","Envoyer","J'aime","Annuler le j'aime","Répondre","Annuler la réponse","Commentaires","Actualiser","Charger plus...","Aperçu","Emoji","Télécharger une image","Il y a quelques secondes","Il y a quelques minutes","Il y a quelques heures","Il y a quelques jours","À l'instant","Téléchargement en cours","Connexion","Déconnexion","Admin","Épinglé","Mots",`Veuillez saisir des commentaires entre $0 et $1 mots ! + Nombre actuel de mots : $2`,"Anonyme","Nains","Hobbits","Ents","Mages","Elfes","Maïar","GIF","Rechercher un GIF","Profil","Approuvé","En attente","Indésirable","Détacher","Le plus ancien","Dernier","Le plus populaire","Qu'en pensez-vous ?"]),ge=de(["ニックネーム","3バイト以上のニックネームをご入力ください.","メールアドレス","メールアドレスをご確認ください.","サイト","オプション","ここにコメント","コメントしましょう~","提出する","Like","Cancel like","返信する","キャンセル","コメント","更新","さらに読み込む","プレビュー","絵文字","画像をアップロード","秒前","分前","時間前","日前","たっだ今","アップロード","ログインする","ログアウト","管理者","トップに置く","ワード",`コメントは $0 から $1 ワードの間でなければなりません! + 現在の単語番号: $2`,"匿名","うえにん","なかにん","しもおし","特にしもおし","かげ","なぬし","GIF","探す GIF","個人情報","承認済み","待っている","スパム","べたつかない","逆順","正順","人気順","どう思いますか?"]),me=de(["Apelido","Apelido não pode ser menor que 3 bytes.","E-Mail","Por favor, confirme seu endereço de e-mail.","Website","Opcional","Comente aqui...","Nenhum comentário, ainda.","Enviar","Like","Cancel like","Responder","Cancelar resposta","Comentários","Refrescar","Carregar Mais...","Visualizar","Emoji","Enviar Imagem","segundos atrás","minutos atrás","horas atrás","dias atrás","agora mesmo","Enviando","Entrar","Sair","Admin","Sticky","Palavras",`Favor enviar comentário com $0 a $1 palavras! + Número de palavras atuais: $2`,"Anônimo","Dwarves","Hobbits","Ents","Wizards","Elves","Maiar","GIF","Pesquisar GIF","informação pessoal","Aprovado","Espera","Spam","Unsticky","Mais velho","Mais recentes","Mais quente","O que você acha?"]),ve=de(["Псевдоним","Никнейм не может быть меньше 3 байт.","Эл. адрес","Пожалуйста, подтвердите адрес вашей электронной почты.","Веб-сайт","Необязательный","Комментарий здесь...","Пока нет комментариев.","Отправить","Like","Cancel like","Отвечать","Отменить ответ","Комментарии","Обновить","Загрузи больше...","Превью","эмодзи","Загрузить изображение","секунд назад","несколько минут назад","несколько часов назад","дней назад","прямо сейчас","Загрузка","Авторизоваться","Выход из системы","Админ","Липкий","Слова",`Пожалуйста, введите комментарии от $0 до $1 слов! +Номер текущего слова: $2`,"Анонимный","Dwarves","Hobbits","Ents","Wizards","Elves","Maiar","GIF","Поиск GIF","Персональные данные","Одобренный","Ожидающий","Спам","Нелипкий","самый старый","последний","самый горячий","Что вы думаете?"]),ye=de(["Tên","Tên không được nhỏ hơn 3 ký tự.","E-Mail","Vui lòng xác nhập địa chỉ email của bạn.","Website","Tùy chọn","Hãy bình luận có văn hoá!","Chưa có bình luận","Gửi","Thích","Bỏ thích","Trả lời","Hủy bỏ","bình luận","Làm mới","Tải thêm...","Xem trước","Emoji","Tải lên hình ảnh","giây trước","phút trước","giờ trước","ngày trước","Vừa xong","Đang tải lên","Đăng nhập","đăng xuất","Quản trị viên","Dính","từ",`Bình luận phải có độ dài giữa $0 và $1 từ! + Số từ hiện tại: $2`,"Vô danh","Người lùn","Người tí hon","Thần rừng","Pháp sư","Tiên tộc","Maiar","Ảnh GIF","Tìm kiếm ảnh GIF","thông tin cá nhân","Đã được phê duyệt","Đang chờ đợi","Thư rác","Không dính","lâu đời nhất","muộn nhất","nóng nhất","What do you think?"]),t=de(["昵称","昵称不能少于3个字符","邮箱","请填写正确的邮件地址","网址","可选","欢迎评论","来发评论吧~","提交","喜欢","取消喜欢","回复","取消回复","评论","刷新","加载更多...","预览","表情","上传图片","秒前","分钟前","小时前","天前","刚刚","正在上传","登录","退出","博主","置顶","字",`评论字数应在 $0 到 $1 字之间! +当前字数:$2`,"匿名","潜水","冒泡","吐槽","活跃","话痨","传说","表情包","搜索表情包","个人资料","通过","待审核","垃圾","取消置顶","按倒序","按正序","按热度","你认为这篇文章怎么样?"]),we=de(["暱稱","暱稱不能少於3個字元","郵箱","請填寫正確的郵件地址","網址","可選","歡迎留言","來發留言吧~","送出","喜歡","取消喜歡","回覆","取消回覆","留言","重整","載入更多...","預覽","表情","上傳圖片","秒前","分鐘前","小時前","天前","剛剛","正在上傳","登入","登出","管理者","置頂","字",`留言字數應在 $0 到 $1 字之間! +目前字數:$2`,"匿名","潛水","冒泡","吐槽","活躍","多話","傳說","表情包","搜尋表情包","個人資料","通過","待審核","垃圾","取消置頂","最早","最新","熱門","你認為這篇文章怎麼樣?"]),be=de(["Benutzername","Der Benutzername darf nicht weniger als 3 Bytes umfassen.","E-Mail","Bitte bestätigen Sie Ihre E-Mail-Adresse.","Webseite","Optional","Kommentieren Sie hier...","Noch keine Kommentare.","Senden","Gefällt mir","Gefällt mir nicht mehr","Antworten","Antwort abbrechen","Kommentare","Aktualisieren","Mehr laden...","Vorschau","Emoji","Ein Bild hochladen","Vor einigen Sekunden","Vor einigen Minuten","Vor einigen Stunden","Vor einigen Tagen","Gerade eben","Hochladen läuft","Anmelden","Abmelden","Admin","Angeheftet","Wörter","Bitte geben Sie Kommentare zwischen $0 und $1 Wörtern ein! Aktuelle Anzahl der Wörter: $2","Anonym","Zwerge","Hobbits","Ents","Magier","Elfen","Maïar","GIF","Nach einem GIF suchen","Profil","Genehmigt","Ausstehend","Spam","Lösen","Älteste","Neueste","Am beliebtesten","Was denken Sie?"]);const ke="en-US",xe={zh:t,"zh-cn":t,"zh-tw":we,en:he,"en-us":he,fr:fe,"fr-fr":fe,jp:ge,"jp-jp":ge,"pt-br":me,ru:ve,"ru-ru":ve,vi:ye,"vi-vn":ye,de:be},_e=e=>xe[e.toLowerCase()]||xe[ke.toLowerCase()],Ce=e=>Object.keys(xe).includes(e.toLowerCase())?e:ke,Se=e=>{try{e=decodeURI(e)}catch{}return e},Le=(e="")=>e.replace(/\/$/u,""),Re=e=>/^(https?:)?\/\//.test(e),Ie=e=>{e=Le(e);return Re(e)?e:"https://"+e},Ee=(e,t)=>"function"==typeof e?e:!1!==e&&t,Ae=({serverURL:e,path:t=location.pathname,lang:n="u"({serverURL:Ie(e),path:Se(t),lang:Ce(n),locale:{..._e(Ce(n)),..."object"==typeof r?r:{}},wordLimit:(e=>Array.isArray(e)?e:!!e&&[0,e])(c),meta:ne(i),requiredMeta:ne(o),imageUploader:Ee(u,ie),highlighter:Ee(p,ue),texRenderer:Ee(d,oe),dark:s,emoji:"boolean"==typeof l?l?re:[]:l,pageSize:a,login:f,copyright:h,search:!1!==g&&("object"==typeof g?g:(n=>{const r=async(e,t={})=>fetch(`https://api.giphy.com/v1/gifs/${e}?`+new URLSearchParams({lang:n,limit:"20",rating:"g",api_key:"6CIMLkNMMOhRcXPoMCPkFy4Ybk2XUiMp",...t}).toString()).then(e=>e.json()).then(({data:e})=>e.map(e=>({title:e.title,src:e.images.downsized_medium.url})));return{search:e=>r("search",{q:e,offset:"0"}),default:()=>r("trending",{}),more:(e,t=0)=>r("search",{q:e,offset:t.toString()})}})(n)),recaptchaV3Key:v,turnstileKey:y,reaction:Array.isArray(m)?m:!0===m?le:[],commentSorting:w,...b}),$e=e=>"string"==typeof e,Te="{--waline-white:#000;--waline-light-grey:#666;--waline-dark-grey:#999;--waline-color:#888;--waline-bg-color:#1e1e1e;--waline-bg-color-light:#272727;--waline-bg-color-hover: #444;--waline-border-color:#333;--waline-disable-bg-color:#444;--waline-disable-color:#272727;--waline-bq-color:#272727;--waline-info-bg-color:#272727;--waline-info-color:#666}",je=(e,t)=>{let n=e.toString();for(;n.length{if(!e)return"";const r=$e(e)?new Date(-1!==e.indexOf(" ")?e.replace(/-/g,"/"):e):e,l=t.getTime()-r.getTime(),i=Math.floor(l/864e5);var o;return 0===i?(e=l%864e5,0===(t=Math.floor(e/36e5))?(e=e%36e5,0===(o=Math.floor(e/6e4))?Math.round(e%6e4/1e3)+" "+n.seconds:o+" "+n.minutes):t+" "+n.hours):i<0?n.now:i<8?i+" "+n.days:(e=r,o=je(e.getDate(),2),t=je(e.getMonth()+1,2),je(e.getFullYear(),2)+`-${t}-`+o)},Oe=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;function Me(e){const t=new Set(e.split(","));return e=>t.has(e)}const _={},Pe=[],Ue=()=>{},Fe=()=>!1,Ve=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&(122e.startsWith("onUpdate:"),f=Object.assign,He=(e,t)=>{t=e.indexOf(t);-1Be.call(e,t),j=Array.isArray,We=e=>"[object Map]"===Xe(e),qe=e=>"[object Set]"===Xe(e),Ge=e=>"[object Date]"===Xe(e),z=e=>"function"==typeof e,O=e=>"string"==typeof e,Ze=e=>"symbol"==typeof e,X=e=>null!==e&&"object"==typeof e,Ke=e=>(X(e)||z(e))&&z(e.then)&&z(e.catch),Qe=Object.prototype.toString,Xe=e=>Qe.call(e),Je=e=>Xe(e).slice(8,-1),Ye=e=>"[object Object]"===Xe(e),et=e=>O(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,tt=Me(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),nt=t=>{const n=Object.create(null);return e=>n[e]||(n[e]=t(e))},rt=/-(\w)/g,lt=nt(e=>e.replace(rt,(e,t)=>t?t.toUpperCase():"")),it=/\B([A-Z])/g,ot=nt(e=>e.replace(it,"-$1").toLowerCase()),st=nt(e=>e.charAt(0).toUpperCase()+e.slice(1)),at=nt(e=>e?"on"+st(e):""),ct=(e,t)=>!Object.is(e,t),ut=(t,n)=>{for(let e=0;e{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},dt=e=>{var t=parseFloat(e);return isNaN(t)?e:t};let ht;const ft=()=>ht=ht||(typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function gt(t){if(j(t)){const l={};for(let e=0;e{if(e){const t=e.split(vt);1kt(e,t))}const a=e=>O(e)?e:null==e?"":j(e)||X(e)&&(e.toString===Qe||!z(e.toString))?JSON.stringify(e,_t,2):String(e),_t=(e,t)=>t&&t.__v_isRef?_t(e,t.value):We(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Ct(t,r)+" =>"]=n,e),{})}:qe(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Ct(e))}:Ze(t)?Ct(t):!X(t)||j(t)||Ye(t)?t:String(t),Ct=(e,t="")=>{var n;return Ze(e)?`Symbol(${null!=(n=e.description)?n:t})`:e};let C;class St{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=C,!e&&C&&(this.index=(C.scopes||(C.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){var t=C;try{return C=this,e()}finally{C=t}}}on(){C=this}off(){C=this.parent}stop(n){if(this._active){let e,t;for(e=0,t=this.effects.length;et._depsLength){for(let e=t._depsLength;e{const n=new Map;return n.cleanup=e,n.computed=t,n},Dt=new WeakMap,Ht=Symbol(""),Bt=Symbol("");function h(n,e,r){if($t&&Lt){let e=Dt.get(n),t=(e||Dt.set(n,e=new Map),e.get(r));t||e.set(r,t=Vt(()=>e.delete(r))),Ut(Lt,t)}}function Wt(e,t,r,l){const i=Dt.get(e);if(i){let n=[];if("clear"===t)n=[...i.values()];else if("length"===r&&j(e)){const o=Number(l);i.forEach((e,t)=>{("length"===t||!Ze(t)&&t>=o)&&n.push(e)})}else switch(void 0!==r&&n.push(i.get(r)),t){case"add":j(e)?et(r)&&n.push(i.get("length")):(n.push(i.get(Ht)),We(e)&&n.push(i.get(Bt)));break;case"delete":j(e)||(n.push(i.get(Ht)),We(e)&&n.push(i.get(Bt)));break;case"set":We(e)&&n.push(i.get(Ht))}Mt();for(const s of n)s&&Ft(s,4);Pt()}}const qt=Me("__proto__,__v_isRef,__isVue"),Gt=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>"arguments"!==e&&"caller"!==e).map(e=>Symbol[e]).filter(Ze)),Zt=function(){const e={};return["includes","indexOf","lastIndexOf"].forEach(r=>{e[r]=function(...e){const n=J(this);for(let e=0,t=this.length;e{e[t]=function(...e){zt(),Mt();e=J(this)[t].apply(this,e);return Pt(),Ot(),e}}),e}();function Kt(e){Ze(e)||(e=String(e));const t=J(this);return h(t,0,e),t.hasOwnProperty(e)}class Qt{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){var r=this._isReadonly,l=this._isShallow;if("__v_isReactive"===t)return!r;if("__v_isReadonly"===t)return r;if("__v_isShallow"===t)return l;if("__v_raw"===t)return n===(r?l?Sn:Cn:l?_n:xn).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;var i=j(e);if(!r){if(i&&T(Zt,t))return Reflect.get(Zt,t,n);if("hasOwnProperty"===t)return Kt}n=Reflect.get(e,t,n);return(Ze(t)?Gt.has(t):qt(t))||(r||h(e,0,t),l)?n:S(n)?i&&et(t)?n:n.value:X(n)?(r?Rn:Ln)(n):n}}class Xt extends Qt{constructor(e=!1){super(!1,e)}set(e,t,n,r){let l=e[t];if(!this._isShallow){var i=An(l);if($n(n)||An(n)||(l=J(l),n=J(n)),!j(e)&&S(l)&&!S(n))return!i&&(l.value=n,!0)}var i=j(e)&&et(t)?Number(t)e,nn=e=>Reflect.getPrototypeOf(e);function rn(e,t,n=!1,r=!1){var l=J(e=e.__v_raw),i=J(t);n||(ct(t,i)&&h(l,0,t),h(l,0,i));const o=nn(l)["has"],s=r?tn:n?zn:jn;return o.call(l,t)?s(e.get(t)):o.call(l,i)?s(e.get(i)):void(e!==l&&e.get(t))}function ln(e,t=!1){const n=this.__v_raw,r=J(n),l=J(e);return t||(ct(e,l)&&h(r,0,e),h(r,0,l)),e===l?n.has(e):n.has(e)||n.has(l)}function on(e,t=!1){return e=e.__v_raw,t||h(J(e),0,Ht),Reflect.get(e,"size",e)}function sn(e){e=J(e);const t=J(this);return nn(t).has.call(t,e)||(t.add(e),Wt(t,"add",e,e)),this}function an(e,t){t=J(t);const n=J(this),{has:r,get:l}=nn(n);let i=r.call(n,e);i||(e=J(e),i=r.call(n,e));var o=l.call(n,e);return n.set(e,t),i?ct(t,o)&&Wt(n,"set",e,t):Wt(n,"add",e,t),this}function cn(e){const t=J(this),{has:n,get:r}=nn(t);let l=n.call(t,e);l||(e=J(e),l=n.call(t,e)),r&&r.call(t,e);var i=t.delete(e);return l&&Wt(t,"delete",e,void 0),i}function un(){const e=J(this),t=0!==e.size,n=e.clear();return t&&Wt(e,"clear",void 0,void 0),n}function pn(o,s){return function(n,r){const l=this,e=l.__v_raw,t=J(e),i=s?tn:o?zn:jn;return o||h(t,0,Ht),e.forEach((e,t)=>n.call(r,i(e),i(t),l))}}function dn(a,c,u){return function(...e){const t=this.__v_raw,n=J(t),r=We(n),l="entries"===a||a===Symbol.iterator&&r,i="keys"===a&&r,o=t[a](...e),s=u?tn:c?zn:jn;return c||h(n,0,i?Bt:Ht),{next(){var{value:e,done:t}=o.next();return t?{value:e,done:t}:{value:l?[s(e[0]),s(e[1])]:s(e),done:t}},[Symbol.iterator](){return this}}}}function hn(e){return function(){return"delete"!==e&&("clear"===e?void 0:this)}}const[fn,gn,mn,vn]=function(){const t={get(e){return rn(this,e)},get size(){return on(this)},has:ln,add:sn,set:an,delete:cn,clear:un,forEach:pn(!1,!1)},n={get(e){return rn(this,e,!1,!0)},get size(){return on(this)},has:ln,add:sn,set:an,delete:cn,clear:un,forEach:pn(!1,!0)},r={get(e){return rn(this,e,!0)},get size(){return on(this,!0)},has(e){return ln.call(this,e,!0)},add:hn("add"),set:hn("set"),delete:hn("delete"),clear:hn("clear"),forEach:pn(!0,!1)},l={get(e){return rn(this,e,!0,!0)},get size(){return on(this,!0)},has(e){return ln.call(this,e,!0)},add:hn("add"),set:hn("set"),delete:hn("delete"),clear:hn("clear"),forEach:pn(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(e=>{t[e]=dn(e,!1,!1),r[e]=dn(e,!0,!1),n[e]=dn(e,!1,!0),l[e]=dn(e,!0,!0)}),[t,r,n,l]}();function yn(r,e){const l=e?r?vn:mn:r?gn:fn;return(e,t,n)=>"__v_isReactive"===t?!r:"__v_isReadonly"===t?r:"__v_raw"===t?e:Reflect.get(T(l,t)&&t in e?l:e,t,n)}const wn={get:yn(!1,!1)},bn={get:yn(!1,!0)},kn={get:yn(!0,!1)},xn=new WeakMap,_n=new WeakMap,Cn=new WeakMap,Sn=new WeakMap;function Ln(e){return An(e)?e:In(e,!1,Jt,wn,xn)}function Rn(e){return In(e,!0,Yt,kn,Cn)}function In(e,t,n,r,l){if(!X(e)||e.__v_raw&&(!t||!e.__v_isReactive))return e;t=l.get(e);if(t)return t;t=function(e){if(e.__v_skip||!Object.isExtensible(e))return 0;switch(Je(e)){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}(e);if(0===t)return e;t=new Proxy(e,2===t?r:n);return l.set(e,t),t}function En(e){return An(e)?En(e.__v_raw):!(!e||!e.__v_isReactive)}function An(e){return!(!e||!e.__v_isReadonly)}function $n(e){return!(!e||!e.__v_isShallow)}function Tn(e){return e&&e.__v_raw}function J(e){var t=e&&e.__v_raw;return t?J(t):e}const jn=e=>X(e)?Ln(e):e,zn=e=>X(e)?Rn(e):e;class On{constructor(e,t,n,r){this.getter=e,this._setter=t,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new Rt(()=>e(this._value),()=>Pn(this,2===this.effect._dirtyLevel?2:3)),(this.effect.computed=this).effect.active=this._cacheable=!r,this.__v_isReadonly=n}get value(){const e=J(this);return e._cacheable&&!e.effect.dirty||!ct(e._value,e._value=e.effect.run())||Pn(e,4),Mn(e),2<=e.effect._dirtyLevel&&Pn(e,2),e._value}set value(e){this._setter(e)}get _dirty(){return this.effect.dirty}set _dirty(e){this.effect.dirty=e}}function Mn(e){var t;$t&&Lt&&(e=J(e),Ut(Lt,null!=(t=e.dep)?t:e.dep=Vt(()=>e.dep=void 0,e instanceof On?e:void 0)))}function Pn(e,t=4){e=(e=J(e)).dep;e&&Ft(e,t)}function S(e){return!(!e||!0!==e.__v_isRef)}function N(e){return Nn(e,!1)}function Un(e){return Nn(e,!0)}function Nn(e,t){return S(e)?e:new Fn(e,t)}class Fn{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!0,this._rawValue=t?e:J(e),this._value=t?e:jn(e)}get value(){return Mn(this),this._value}set value(e){var t=this.__v_isShallow||$n(e)||An(e);e=t?e:J(e),ct(e,this._rawValue)&&(this._rawValue=e,this._value=t?e:jn(e),Pn(this,4))}}function Vn(e){return S(e)?e.value:e}const Dn={get:(e,t,n)=>Vn(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const l=e[t];return S(l)&&!S(n)?(l.value=n,!0):Reflect.set(e,t,n,r)}};function Hn(e){return En(e)?e:new Proxy(e,Dn)}function Bn(e,t,n,r){try{return r?e(...r):e()}catch(e){qn(e,t,n)}}function Wn(t,n,r,l){if(z(t)){const e=Bn(t,n,r,l);return e&&Ke(e)&&e.catch(e=>{qn(e,n,r)}),e}if(j(t)){const i=[];for(let e=0;e>>1,l=o[r],i=or(l);ior(e)-or(t));if(Qn.length=0,Xn)Xn.push(...e);else{for(Xn=e,Jn=0;Jnnull==e.id?1/0:e.id,sr=(e,t)=>{var n=or(e)-or(t);if(0==n){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function ar(e){Zn=!1,Gn=!0,o.sort(sr);try{for(Kn=0;Kn{let t;for(const n in e)"class"!==n&&"style"!==n&&!Ve(n)||((t=t||{})[n]=e[n]);return t},fr=(e,t)=>{const n={};for(const r in e)De(r)&&r.slice(9)in t||(n[r]=e[r]);return n};function gr(t,n,r){var l=Object.keys(n);if(l.length!==Object.keys(t).length)return!0;for(let e=0;eXr(br);function _r(e,t){return Lr(e,null,t)}const Cr={};function Sr(e,t,n){return Lr(e,t,n)}function Lr(e,t,{immediate:n,deep:r,flush:l,once:i}=_){if(t&&i){const b=t;t=(...e)=>{b(...e),w()}}const o=E,s=e=>!0===r?e:Rr(e,!1===r?1:void 0);let a,c=!1,u=!1;if(S(e)?(a=()=>e.value,c=$n(e)):En(e)?(a=()=>s(e),c=!0):a=j(e)?(u=!0,c=e.some(e=>En(e)||$n(e)),()=>e.map(e=>S(e)?e.value:En(e)?s(e):z(e)?Bn(e,o,2):void 0)):z(e)?t?()=>Bn(e,o,2):()=>(p&&p(),Wn(e,o,3,[d])):Ue,t&&r){const k=a;a=()=>Rr(k())}let p,d=e=>{p=v.onStop=()=>{Bn(e,o,4),p=v.onStop=void 0}},h;if(ql){if(d=Ue,t?n&&Wn(t,o,3,[a(),u?[]:void 0,d]):a(),"sync"!==l)return Ue;{const x=kr();h=x.__watcherHandles||(x.__watcherHandles=[])}}let f=u?new Array(e.length).fill(Cr):Cr;const g=()=>{if(v.active&&v.dirty)if(t){const e=v.run();(r||c||(u?e.some((e,t)=>ct(e,f[t])):ct(e,f)))&&(p&&p(),Wn(t,o,3,[e,f===Cr?void 0:u&&f[0]===Cr?[]:f,d]),f=e)}else v.run()};g.allowRecurse=!!t;let m;m="sync"===l?g:"post"===l?()=>Y(g,o&&o.suspense):(g.pre=!0,o&&(g.id=o.uid),()=>nr(g));const v=new Rt(a,Ue,m),y=C,w=()=>{v.stop(),y&&He(y.effects,v)};return t?n?g():f=v.run():"post"===l?Y(v.run.bind(v),o&&o.suspense):v.run(),h&&h.push(w),w}function Rr(t,n=1/0,r){if(n<=0||!X(t)||t.__v_skip||(r=r||new Set).has(t))return t;if(r.add(t),n--,S(t))Rr(t.value,n,r);else if(j(t))for(let e=0;e{Rr(e,n,r)});else if(Ye(t))for(const e in t)Rr(t[e],n,r);return t}function Ir(e,i){if(null===c)return e;const o=Xl(c)||c.proxy,s=e.dirs||(e.dirs=[]);for(let l=0;l!!e.type.__asyncLoader,Tr=e=>e.type.__isKeepAlive;const jr=n=>(t,e=E)=>(!ql||"sp"===n)&&function(r,l,i=E,e=!1){if(i){const t=i[r]||(i[r]=[]),n=l.__weh||(l.__weh=(...e)=>{if(!i.isUnmounted){zt();const t=Hl(i),n=Wn(l,i,r,e);return t(),Ot(),n}});return e?t.unshift(n):t.push(n),n}}(n,(...e)=>t(...e),e),zr=jr("m"),Or=jr("bum"),Mr=jr("um");function u(n,r,e){let l;const i=e;if(j(n)||O(n)){l=new Array(n.length);for(let e=0,t=n.length;er(e,t,void 0,i));else{var o=Object.keys(n);l=new Array(o.length);for(let e=0,t=o.length;ee?Wl(e)?Xl(e)||e.proxy:Pr(e.parent):null,Ur=f(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Pr(e.parent),$root:e=>Pr(e.root),$emit:e=>e.emit,$options:e=>e.type,$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,nr(e.update)}),$nextTick:e=>e.n||(e.n=tr.bind(e.proxy)),$watch:e=>Ue}),Nr=(e,t)=>e!==_&&!e.__isScriptSetup&&T(e,t),Fr={get({_:e},t){if("__v_skip"===t)return!0;const{ctx:n,setupState:r,data:l,props:i,accessCache:o,type:s,appContext:a}=e;if("$"!==t[0]){var c=o[t];if(void 0!==c)switch(c){case 1:return r[t];case 2:return l[t];case 4:return n[t];case 3:return i[t]}else{if(Nr(r,t))return o[t]=1,r[t];if(l!==_&&T(l,t))return o[t]=2,l[t];if((c=e.propsOptions[0])&&T(c,t))return o[t]=3,i[t];if(n!==_&&T(n,t))return o[t]=4,n[t];o[t]=0}}const u=Ur[t];let p,d;return u?("$attrs"===t&&h(e.attrs,0,""),u(e)):(p=s.__cssModules)&&(p=p[t])?p:n!==_&&T(n,t)?(o[t]=4,n[t]):(d=a.config.globalProperties,T(d,t)?d[t]:void 0)},set({_:e},t,n){const{data:r,setupState:l,ctx:i}=e;return Nr(l,t)?(l[t]=n,!0):r!==_&&T(r,t)?(r[t]=n,!0):!(T(e.props,t)||"$"===t[0]&&t.slice(1)in e)&&(i[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:l,propsOptions:i}},o){return!!n[o]||e!==_&&T(e,o)||Nr(t,o)||(n=i[0])&&T(n,o)||T(r,o)||T(Ur,o)||T(l.config.globalProperties,o)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:T(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Vr(e){return j(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}function Dr(t,e,n,r=!1){const{mixins:l,extends:i}=e;i&&Dr(t,i,n,!0),l&&l.forEach(e=>Dr(t,e,n,!0));for(const o in e)if(!r||"expose"!==o){const s=Hr[o]||n&&n[o];t[o]=s?s(t[o],e[o]):e[o]}return t}const Hr={data:Br,props:Gr,emits:Gr,methods:qr,computed:qr,beforeCreate:l,created:l,beforeMount:l,mounted:l,beforeUpdate:l,updated:l,beforeDestroy:l,beforeUnmount:l,destroyed:l,unmounted:l,activated:l,deactivated:l,errorCaptured:l,serverPrefetch:l,components:qr,directives:qr,watch:function(e,t){if(!e)return t;if(!t)return e;const n=f(Object.create(null),e);for(const r in t)n[r]=l(e[r],t[r]);return n},provide:Br,inject:function(e,t){return qr(Wr(e),Wr(t))}};function Br(e,t){return t?e?function(){return f(z(e)?e.call(this,this):e,z(t)?t.call(this,this):t)}:t:e}function Wr(t){if(j(t)){const n={};for(let e=0;eObject.create(Jr),el=e=>Object.getPrototypeOf(e)===Jr;function tl(e,t,n,r=!1){const l={},i=Yr();e.propsDefaults=Object.create(null),nl(e,t,l,i);for(const o in e.propsOptions[0])o in l||(l[o]=void 0);n?e.props=r?l:In(l,!1,en,bn,_n):e.type.props?e.props=l:e.props=i,e.attrs=i}function nl(t,n,r,l){const[i,o]=t.propsOptions;let s=!1,a;if(n)for(var c in n)if(!tt(c)){var u=n[c];let e;i&&T(i,e=lt(c))?o&&o.includes(e)?(a=a||{})[e]=u:r[e]=u:cr(t.emitsOptions,c)||c in l&&u===l[c]||(l[c]=u,s=!0)}if(o){var p=J(r),d=a||_;for(let e=0;eol(e,t)):z(e)&&ol(e,t)?0:-1}const al=e=>"_"===e[0]||"$stable"===e,cl=e=>j(e)?e.map(zl):[zl(e)],ul=(e,t,n)=>{if(t._n)return t;const r=function(r,l=c){if(!l||r._n)return r;const i=(...e)=>{i._d&&Sl(-1);var t=pr(l);let n;try{n=r(...e)}finally{pr(t),i._d&&Sl(1)}return n};return i._n=!0,i._c=!0,i._d=!0,i}((...e)=>cl(t(...e)),n);return r._c=!1,r},pl=(e,t,n)=>{var r=e._ctx;for(const i in e)if(!al(i)){var l=e[i];if(z(l))t[i]=ul(i,l,r);else if(null!=l){const o=cl(l);t[i]=()=>o}}},dl=(e,t)=>{const n=cl(t);e.slots.default=()=>n},hl=(e,t)=>{var n,r=e.slots=Yr();32&e.vnode.shapeFlag?(n=t._)?(f(r,t),pt(r,"_",n,!0)):pl(t,r):t&&dl(e,t)},fl=(e,t,n)=>{const{vnode:r,slots:l}=e;let i=!0,o=_;var s;if(32&r.shapeFlag?((s=t._)?n&&1===s?i=!1:(f(l,t),n||1!==s||delete l._):(i=!t.$stable,pl(t,l)),o=t):t&&(dl(e,t),o={default:1}),i)for(const a in l)al(a)||null!=o[a]||delete l[a]};function gl(t,n,r,l,i=!1){if(j(t))t.forEach((e,t)=>gl(e,n&&(j(n)?n[t]:n),r,l,i));else if(!$r(l)||i){const o=4&l.shapeFlag?Xl(l.component)||l.component.proxy:l.el,s=i?null:o,{i:a,r:c}=t,u=n&&n.r,p=a.refs===_?a.refs={}:a.refs,d=a.setupState;if(null!=u&&u!==c&&(O(u)?(p[u]=null,T(d,u)&&(d[u]=null)):S(u)&&(u.value=null)),z(c))Bn(c,a,12,[s,p]);else{const h=O(c),f=S(c);var e;(h||f)&&(e=()=>{if(t.f){const e=h?(T(d,c)?d:p)[c]:c.value;i?j(e)&&He(e,o):j(e)?e.includes(o)||e.push(o):h?(p[c]=[o],T(d,c)&&(d[c]=p[c])):(c.value=[o],t.k&&(p[t.k]=c.value))}else h?(p[c]=s,T(d,c)&&(d[c]=s)):f&&(c.value=s,t.k&&(p[t.k]=s))},s?(e.id=-1,Y(e,r)):e())}}}const Y=function(e,t){t&&t.pendingBranch?j(e)?t.effects.push(...e):t.effects.push(e):(t=e,j(t)?Qn.push(...t):Xn&&Xn.includes(t,t.allowRecurse?Jn+1:Jn)||Qn.push(t),rr())};function ml(e){{"boolean"!=typeof __VUE_PROD_HYDRATION_MISMATCH_DETAILS__&&(ft().__VUE_PROD_HYDRATION_MISMATCH_DETAILS__=!1);const t=ft(),{insert:M,remove:g,patchProp:y,createElement:m,createText:P,createComment:l,setText:U,setElementText:S,parentNode:L,nextSibling:b,setScopeId:i=Ue,insertStaticContent:N}=(t.__VUE__=!0,e),E=(r,l,i,o=null,s=null,a=null,c=void 0,u=null,p=!!l.dynamicChildren)=>{if(r!==l){r&&!El(r,l)&&(o=K(r),Z(r,s,a,!0),r=null),-2===l.patchFlag&&(p=!1,l.dynamicChildren=null);const{type:A,ref:$,shapeFlag:T}=l;switch(A){case bl:var e=r,t=l,n=i,d=o;if(e==null)M(t.el=P(t.children),n,d);else{const j=t.el=e.el;t.children!==e.children&&U(j,t.children)}break;case kl:F(r,l,i,o);break;case xl:null==r&&(n=l,d=i,e=o,t=c,[n.el,n.anchor]=N(n.children,d,e,t,n.el,n.anchor));break;case ee:{var h=r;var f=l;var g=i;var m=o;var v=s;var y=a;var w=c;var b=u;var k=p;const z=f.el=h?h.el:P(""),O=f.anchor=h?h.anchor:P("");let{patchFlag:e,dynamicChildren:t,slotScopeIds:n}=f;n&&(b=b?b.concat(n):n),h==null?(M(z,g,m),M(O,g,m),D(f.children||[],g,O,v,y,w,b,k)):e>0&&e&64&&t&&h.dynamicChildren?(B(h.dynamicChildren,t,g,v,y,w,b),(f.key!=null||v&&f===v.subTree)&&wl(h,f,!0)):G(h,f,g,O,v,y,w,b,k)}break;default:1&T?(m=r,h=i,f=o,g=s,v=a,y=c,w=u,b=p,"svg"===(k=l).type?y="svg":"math"===k.type&&(y="mathml"),null==m?V(k,h,f,g,v,y,w,b):H(m,k,g,v,y,w,b)):6&T?(x=r,C=i,S=o,L=s,R=a,I=c,E=p,(_=l).slotScopeIds=u,null==x?512&_.shapeFlag?L.ctx.activate(_,C,S,I,E):W(_,C,S,L,R,I,E):q(x,_,E)):(64&T||128&T)&&A.process(r,l,i,o,s,a,c,u,p,Q)}var x,_,C,S,L,R,I,E;null!=$&&s&&gl($,r&&r.ref,a,l||r,!l)}},F=(e,t,n,r)=>{null==e?M(t.el=l(t.children||""),n,r):t.el=e.el},V=(e,t,n,r,l,i,o,s)=>{let a,c;const{props:u,shapeFlag:p,transition:d,dirs:h}=e;if(a=e.el=m(e.type,i,u&&u.is,u),8&p?S(a,e.children):16&p&&D(e.children,a,null,r,l,vl(e,i),o,s),h&&Er(e,null,r,"created"),v(a,e,e.scopeId,o,r),u){for(const g in u)"value"===g||tt(g)||y(a,g,null,u[g],i,e.children,r,l,$);"value"in u&&y(a,"value",null,u.value,i),(c=u.onVnodeBeforeMount)&&Pl(c,r,e)}h&&Er(e,null,r,"beforeMount");s=l,o=d;const f=(!s||!s.pendingBranch)&&o&&!o.persisted;f&&d.beforeEnter(a),M(a,t,n),((c=u&&u.onVnodeMounted)||f||h)&&Y(()=>{c&&Pl(c,r,e),f&&d.enter(a),h&&Er(e,null,r,"mounted")},l)},v=(t,e,n,r,l)=>{if(n&&i(t,n),r)for(let e=0;e{for(let e=c;e{var s=e.el=t.el;let{patchFlag:a,dynamicChildren:c,dirs:u}=e;a|=16&t.patchFlag;var p=t.props||_,d=e.props||_;let h;if(n&&yl(n,!1),(h=d.onVnodeBeforeUpdate)&&Pl(h,n,e,t),u&&Er(e,t,n,"beforeUpdate"),n&&yl(n,!0),c?B(t.dynamicChildren,c,s,n,r,vl(e,l),i):o||G(t,e,s,null,n,r,vl(e,l),i,!1),0{h&&Pl(h,n,e,t),u&&Er(e,t,n,"updated")},r)},B=(t,n,r,l,i,o,s)=>{for(let e=0;e{if(n!==r){if(n!==_)for(const c in n)tt(c)||c in r||y(e,c,n[c],null,o,t.children,l,i,$);for(const u in r){var s,a;tt(u)||(s=r[u])!==(a=n[u])&&"value"!==u&&y(e,u,a,s,o,t.children,l,i,$)}"value"in r&&y(e,"value",n.value,r.value,o)}},W=(e,t,n,r,l,i,o)=>{const s=e.component=function(e,t,n){const r=e.type,l=(t||e).appContext||Ul,i={uid:Nl++,vnode:e,type:r,parent:t,appContext:l,root:null,next:null,subTree:null,effect:null,update:null,scope:new St(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(l.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:function(e,t){const n=t.propsCache,r=n.get(e);if(r)return r;const l=e.props,i={},o=[];if(!l)return X(e)&&n.set(e,Pe),Pe;if(j(l))for(let e=0;ei[e]=null):f(i,l),X(e)&&n.set(e,i),i):(X(e)&&n.set(e,null),null)}(r,l),emit:null,emitted:null,propsDefaults:_,inheritAttrs:r.inheritAttrs,ctx:_,data:_,props:_,attrs:_,slots:_,refs:_,setupState:_,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return i.ctx={_:i},i.root=t?t.root:i,i.emit=function(r,l,...i){if(!r.isUnmounted){var o=r.vnode.props||_;let e=i;var s=l.startsWith("update:"),a=s&&l.slice(7);a&&a in o&&({number:a,trim:c}=o[`${"modelValue"===a?"model":a}Modifiers`]||_,c&&(e=i.map(e=>O(e)?e.trim():e)),a&&(e=i.map(dt)));let t,n=o[t=at(l)]||o[t=at(lt(l))];(n=!n&&s?o[t=at(ot(l))]:n)&&Wn(n,r,6,e);var c=o[t+"Once"];if(c){if(r.emitted){if(r.emitted[t])return}else r.emitted={};r.emitted[t]=!0,Wn(c,r,6,e)}}}.bind(null,i),e.ce&&e.ce(i),i}(e,r,l);Tr(e)&&(s.ctx.renderer=Q);var[r,a=!1]=[s],{props:c,children:u}=(a&&Dl(a),r.vnode),p=Wl(r),c=(tl(r,c,p,a),hl(r,u),p?function(t,n){var e=t.type,e=(t.accessCache=Object.create(null),t.proxy=new Proxy(t.ctx,Fr),e)["setup"];if(e){const r=t.setupContext=1{t.exposed=e||{}}}}(t):null,l=Hl(t),i=(zt(),Bn(e,t,0,[t.props,r]));if(Ot(),l(),Ke(i)){if(i.then(Bl,Bl),n)return i.then(e=>{Gl(t,e,n)}).catch(e=>{qn(e,t,0)});t.asyncDep=i}else Gl(t,i,n)}else Kl(t,n)}(r,a):void 0);a&&Dl(!1),s.asyncDep?(l&&l.registerDep(s,d),e.el||(u=s.subTree=te(kl),F(null,u,t,n))):d(s,e,t,n,l,i,o)},q=(e,t,n)=>{const r=t.component=e.component;!function(e,t,n){var{props:r,children:e,component:l}=e,{props:i,children:o,patchFlag:s}=t,a=l.emitsOptions;if(t.dirs||t.transition)return 1;if(!(n&&0<=s))return!(!e&&!o||o&&o.$stable)||r!==i&&(r?!i||gr(r,i,a):i);if(1024&s)return 1;if(16&s)return r?gr(r,i,a):i;if(8&s){var c=t.dynamicProps;for(let e=0;eKn&&o.splice(e,1),r.effect.dirty=!0,r.update())},d=(m,v,y,w,b,k,x)=>{const _=()=>{if(m.isMounted){let{next:e,bu:t,u:n,parent:r,vnode:l}=m;{const d=function e(t){const n=t.subTree.component;if(n)return n.asyncDep&&!n.asyncResolved?n:e(n)}(m);if(d)return e&&(e.el=l.el,R(m,e,x)),void d.asyncDep.then(()=>{m.isUnmounted||_()})}let i=e,o;yl(m,!1),e?(e.el=l.el,R(m,e,x)):e=l,t&&ut(t),(o=e.props&&e.props.onVnodeBeforeUpdate)&&Pl(o,r,e,l),yl(m,!0);var s=dr(m),a=m.subTree;if(m.subTree=s,E(a,s,L(a.el),K(a),m,b,k),e.el=s.el,null===i){var[{vnode:c,parent:u},p]=[m,s.el];for(;u;){const h=u.subTree;if(h.suspense&&h.suspense.activeBranch===c&&(h.el=c.el),h!==c)break;(c=u.vnode).el=p,u=u.parent}}n&&Y(n,b),(o=e.props&&e.props.onVnodeUpdated)&&Y(()=>Pl(o,r,e,l),b)}else{let e;const{el:t,props:n}=v,{bm:r,m:l,parent:i}=m,o=$r(v);if(yl(m,!1),r&&ut(r),!o&&(e=n&&n.onVnodeBeforeMount)&&Pl(e,i,v),yl(m,!0),t&&C){const f=()=>{m.subTree=dr(m),C(t,m.subTree,m,b,null)};o?v.type.__asyncLoader().then(()=>!m.isUnmounted&&f()):f()}else{a=m.subTree=dr(m);E(null,a,y,w,m,b,k),v.el=a.el}if(l&&Y(l,b),!o&&(e=n&&n.onVnodeMounted)){const g=v;Y(()=>Pl(e,i,g),b)}(256&v.shapeFlag||i&&$r(i.vnode)&&256&i.vnode.shapeFlag)&&m.a&&Y(m.a,b),m.isMounted=!0,v=y=w=null}},e=m.effect=new Rt(_,Ue,()=>nr(t),m.scope),t=m.update=()=>{e.dirty&&e.run()};t.id=m.uid,yl(m,!0),t()},R=(e,n,r)=>{var l=(n.component=e).vnode.props;e.vnode=n,e.next=null;{var i=e,o=n.props,s=l;l=r;const{props:p,attrs:d,vnode:{patchFlag:h}}=i,f=J(p),[g]=i.propsOptions;let t=!1;if(!(l||0{var c=e&&e.children,e=e?e.shapeFlag:0,u=t.children,{patchFlag:t,shapeFlag:p}=t;if(0k?$(d,g,m,!0,!1,x):D(h,f,t,g,m,v,y,w,x)}return}}8&p?(16&e&&$(c,l,i),u!==c&&S(n,u)):16&e?16&p?I(c,u,n,r,l,i,o,s,a):$(c,l,i,!0):(8&e&&S(n,""),16&p&&D(u,n,r,l,i,o,s,a))},I=(e,i,o,s,a,c,u,p,d)=>{let h=0;var f=i.length;let g=e.length-1,m=f-1;for(;h<=g&&h<=m;){var t=e[h],n=i[h]=(d?Ol:zl)(i[h]);if(!El(t,n))break;E(t,n,o,null,a,c,u,p,d),h++}for(;h<=g&&h<=m;){var r=e[g],l=i[m]=(d?Ol:zl)(i[m]);if(!El(r,l))break;E(r,l,o,null,a,c,u,p,d),g--,m--}if(h>g){if(h<=m)for(var v=m+1,y=vm)for(;h<=g;)Z(e[h],a,c,!0),h++;else{const S=h,L=h,R=new Map;for(h=L;h<=m;h++){var w=i[h]=(d?Ol:zl)(i[h]);null!=w.key&&R.set(w.key,h)}let t,n=0;var b=m-L+1;let r=!1,l=0;const I=new Array(b);for(h=0;h=b)Z(k,a,c,!0);else{let e;if(null!=k.key)e=R.get(k.key);else for(t=L;t<=m;t++)if(0===I[t-L]&&El(k,i[t])){e=t;break}void 0===e?Z(k,a,c,!0):(I[e-L]=h+1,e>=l?l=e:r=!0,E(k,i[e],o,null,a,c,u,p,d),n++)}}var x=r?function(e){const t=e.slice(),n=[0];let r,l,i,o,s;var a=e.length;for(r=0;r>1,e[n[s]]{const{el:i,type:o,transition:s,children:a,shapeFlag:c}=e;if(6&c)A(e.component.subTree,t,n,r);else if(128&c)e.suspense.move(t,n,r);else if(64&c)o.move(e,t,n,Q);else if(o===ee){M(i,t,n);for(let e=0;es.enter(i),l);else{const{leave:g,delayLeave:m,afterLeave:v}=s,y=()=>M(i,t,n),w=()=>{g(i,()=>{y(),v&&v()})};m?m(i,y,w):w()}else M(i,t,n)},Z=(t,n,r,l=!1,i=!1)=>{var{type:o,props:s,ref:e,children:a,dynamicChildren:c,shapeFlag:u,patchFlag:p,dirs:d}=t;if(null!=e&&gl(e,null,r,t,!0),256&u)n.ctx.deactivate(t);else{const h=1&u&&d,f=!$r(t);let e;if(f&&(e=s&&s.onVnodeBeforeUnmount)&&Pl(e,n,t),6&u)x(t.component,r,l);else{if(128&u)return void t.suspense.unmount(r,l);h&&Er(t,null,n,"beforeUnmount"),64&u?t.type.remove(t,n,r,i,Q,l):c&&(o!==ee||0{e&&Pl(e,n,t),h&&Er(t,null,n,"unmounted")},r)}},k=e=>{const{type:t,el:n,anchor:r,transition:l}=e;if(t===ee){for(var i,o=n,s=r;o!==s;)i=b(o),g(o),o=i;g(s)}else if(t===xl){for(var a,{el:c,anchor:u}=[e][0];c&&c!==u;)a=b(c),g(c),c=a;g(u)}else{const p=()=>{g(n),l&&!l.persisted&&l.afterLeave&&l.afterLeave()};if(1&e.shapeFlag&&l&&!l.persisted){const{leave:d,delayLeave:h}=l,f=()=>d(n,p);h?h(e.el,p,f):f()}else p()}},x=(e,t,n)=>{const{bum:r,scope:l,update:i,subTree:o,um:s}=e;r&&ut(r),l.stop(),i&&(i.active=!1,Z(o,e,t,n)),s&&Y(s,t),Y(()=>{e.isUnmounted=!0},t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},$=(t,n,r,l=!1,i=!1,o=0)=>{for(let e=o;e6&e.shapeFlag?K(e.component.subTree):128&e.shapeFlag?e.suspense.next():b(e.anchor||e.el);let r=!1;const n=(e,t,n)=>{null==e?t._vnode&&Z(t._vnode,null,null,!0):E(t._vnode||null,e,t,null,null,null,n),r||(r=!0,lr(),ir(),r=!1),t._vnode=e},Q={p:E,um:Z,m:A,r:k,mt:W,mc:D,pc:G,pbc:B,n:K,o:e};let C;return{render:n,hydrate:void 0,createApp:function(c,u){return function(l,i=null){z(l)||(l=f({},l)),null==i||X(i)||(i=null);const o=Zr(),n=new WeakSet;let s=!1;const a=o.app={_uid:Kr++,_component:l,_props:i,_container:null,_context:o,_instance:null,version:Jl,get config(){return o.config},set config(e){},use(e,...t){return n.has(e)||(e&&z(e.install)?(n.add(e),e.install(a,...t)):z(e)&&(n.add(e),e(a,...t))),a},mixin(e){return a},component(e,t){return t?(o.components[e]=t,a):o.components[e]},directive(e,t){return t?(o.directives[e]=t,a):o.directives[e]},mount(e,t,n){if(!s){const r=te(l,i);return r.appContext=o,!0===n?n="svg":!1===n&&(n=void 0),t&&u?u(r,e):c(r,e,n),s=!0,(a._container=e).__vue_app__=a,Xl(r.component)||r.component.proxy}},unmount(){s&&(c(null,a._container),delete a._container.__vue_app__)},provide(e,t){return o.provides[e]=t,a},runWithContext(e){var t=Qr;Qr=a;try{return e()}finally{Qr=t}}};return a}}(n,void 0)}}}function vl({type:e,props:t},n){return"svg"===n&&"foreignObject"===e||"mathml"===n&&"annotation-xml"===e&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function yl({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function wl(e,t,n=!1){const r=e.children,l=t.children;if(j(r)&&j(l))for(let t=0;te??null,$l=({ref:e,ref_key:t,ref_for:n})=>null!=(e="number"==typeof e?""+e:e)?O(e)||S(e)||z(e)?{i:c,r:e,k:t,f:!!n}:e:null;function v(e,t=null,n=null,r=0,l=null,i=e===ee?0:1,o=!1,s=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Al(t),ref:t&&$l(t),scopeId:ur,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:i,patchFlag:r,dynamicProps:l,dynamicChildren:null,appContext:null,ctx:c};return s?(Ml(a,n),128&i&&e.normalize(a)):n&&(a.shapeFlag|=O(n)?8:16),0E||c;let Vl,Dl;{const eu=ft(),tu=(e,t)=>{let n;return(n=(n=eu[e])?n:eu[e]=[]).push(t),t=>{1e(t)):n[0](t)}};Vl=tu("__VUE_INSTANCE_SETTERS__",e=>E=e),Dl=tu("__VUE_SSR_SETTERS__",e=>ql=e)}const Hl=e=>{const t=E;return Vl(e),e.scope.on(),()=>{e.scope.off(),Vl(t)}},Bl=()=>{E&&E.scope.off(),Vl(null)};function Wl(e){return 4&e.vnode.shapeFlag}let ql=!1;function Gl(e,t,n){z(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:X(t)&&(e.setupState=Hn(t)),Kl(e,n)}let Zl;function Kl(e,t){const n=e.type;var r,l,i,o;e.render||(t||!Zl||n.render||(t=n.template||function(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:l,optionsCache:i,config:{optionMergeStrategies:o}}=e.appContext,s=i.get(t);let a;return s?a=s:l.length||n||r?(a={},l.length&&l.forEach(e=>Dr(a,e,o,!0)),Dr(a,t,o)):a=t,X(t)&&i.set(t,a),a}(e).template)&&({isCustomElement:o,compilerOptions:r}=e.appContext.config,{delimiters:l,compilerOptions:i}=n,o=f(f({isCustomElement:o,delimiters:l},r),i),n.render=Zl(t,o)),e.render=n.render||Ue)}const Ql={get(e,t){return h(e,0,""),e[t]}};function Xl(n){if(n.exposed)return n.exposeProxy||(n.exposeProxy=new Proxy(Hn((e=n.exposed,Object.isExtensible(e)&&pt(e,"__v_skip",!0),e)),{get(e,t){return t in e?e[t]:t in Ur?Ur[t](n):void 0},has(e,t){return t in e||t in Ur}}));var e}const F=(n,e)=>{{var[n,r=!1]=[n,ql];let e,t;var l=z(n);return t=l?(e=n,Ue):(e=n.get,n.set),new On(e,t,l||!t,r)}};function w(e,t,n){var r=arguments.length;return 2===r?X(t)&&!j(t)?Il(t)?te(e,null,[t]):te(e,t):te(e,null,t):(3{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const l="svg"===t?Yl.createElementNS("http://www.w3.org/2000/svg",e):"mathml"===t?Yl.createElementNS("http://www.w3.org/1998/Math/MathML",e):Yl.createElement(e,n?{is:n}:void 0);return"select"===e&&r&&null!=r.multiple&&l.setAttribute("multiple",r.multiple),l},createText:e=>Yl.createTextNode(e),createComment:e=>Yl.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Yl.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,l,i){var o=n?n.previousSibling:t.lastChild;if(l&&(l===i||l.nextSibling))for(;t.insertBefore(l.cloneNode(!0),n),l!==i&&(l=l.nextSibling););else{ei.innerHTML="svg"===r?`${e}`:"mathml"===r?`${e}`:e;const a=ei.content;if("svg"===r||"mathml"===r){for(var s=a.firstChild;s.firstChild;)a.appendChild(s.firstChild);a.removeChild(s)}t.insertBefore(a,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},ni=Symbol("_vtc");const ri=Symbol("_vod"),li=Symbol("_vsh"),ii={beforeMount(e,{value:t},{transition:n}){e[ri]="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):oi(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),oi(e,!0),r.enter(e)):r.leave(e,()=>{oi(e,!1)}):oi(e,t))},beforeUnmount(e,{value:t}){oi(e,t)}};function oi(e,t){e.style.display=t?e[ri]:"none",e[li]=!t}const si=Symbol(""),ai=/(^|;)\s*display\s*:/;const ci=/\s*!important$/;function ui(t,n,e){var r;j(e)?e.forEach(e=>ui(t,n,e)):(null==e&&(e=""),n.startsWith("--")?t.setProperty(n,e):(r=function(t,n){var e=di[n];if(e)return e;let r=lt(n);if("filter"!==r&&r in t)return di[n]=r;r=st(r);for(let e=0;e{if(e._vts){if(e._vts<=n.attached)return}else e._vts=Date.now();Wn(function(e,t){{if(j(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(t=>e=>!e._stopped&&t&&t(e))}return t}}(e,n.value),t,5,[e])};return n.value=e,n.attached=bi(),n}(r,l),a):o&&(r=o,e.removeEventListener(s,r,a),i[t]=void 0))}const vi=/(?:Once|Passive|Capture)$/;let yi=0;const wi=Promise.resolve(),bi=()=>yi||(wi.then(()=>yi=0),yi=Date.now());const ki=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&96{const t=e.props["onUpdate:modelValue"]||!1;return j(t)?e=>ut(t,e):t};function Ci(e){e.target.composing=!0}function Si(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const b=Symbol("_assign"),Li={created(t,{modifiers:{lazy:e,trim:n,number:r}},l){t[b]=xi(l);const i=r||l.props&&"number"===l.props.type;fi(t,e?"change":"input",e=>{if(!e.target.composing){let e=t.value;n&&(e=e.trim()),i&&(e=dt(e)),t[b](e)}}),n&&fi(t,"change",()=>{t.value=t.value.trim()}),e||(fi(t,"compositionstart",Ci),fi(t,"compositionend",Si),fi(t,"change",Si))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:r,number:l}},i){e[b]=xi(i),e.composing||(i=t??"",(!l&&"number"!==e.type||/^0\d/.test(e.value)?e.value:dt(e.value))===i||document.activeElement===e&&"range"!==e.type&&(n||r&&e.value.trim()===i)||(e.value=i))}},Ri={deep:!0,created(a,e,t){a[b]=xi(t),fi(a,"change",()=>{const e=a._modelValue,t=Ti(a),n=a.checked,r=a[b];if(j(e)){var l=xt(e,t),i=-1!==l;if(n&&!i)r(e.concat(t));else if(!n&&i){const o=[...e];o.splice(l,1),r(o)}}else if(qe(e)){const s=new Set(e);n?s.add(t):s.delete(t),r(s)}else r(ji(a,n))})},mounted:Ii,beforeUpdate(e,t,n){e[b]=xi(n),Ii(e,t,n)}};function Ii(e,{value:t,oldValue:n},r){e._modelValue=t,j(t)?e.checked=-1{e[b](Ti(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[b]=xi(r),t!==n&&(e.checked=kt(t,r.props.value))}},Ai={deep:!0,created(t,{value:e,modifiers:{number:n}},r){const l=qe(e);fi(t,"change",()=>{var e=Array.prototype.filter.call(t.options,e=>e.selected).map(e=>n?dt(Ti(e)):Ti(e));t[b](t.multiple?l?new Set(e):e:e[0]),t._assigning=!0,tr(()=>{t._assigning=!1})}),t[b]=xi(r)},mounted(e,{value:t,modifiers:{}}){$i(e,t)},beforeUpdate(e,t,n){e[b]=xi(n)},updated(e,{value:t,modifiers:{}}){e._assigning||$i(e,t)}};function $i(n,r){var l,i=n.multiple,o=j(r);if(!i||o||qe(r)){for(let e=0,t=n.options.length;eString(e)===String(a)):-1{var c,l="svg"===l;if("class"===e)f=r,p=l,u=(c=t)[ni],null==(f=u?(f?[f,...u]:[...u]).join(" "):f)?c.removeAttribute("class"):p?c.setAttribute("class",f):c.className=f;else if("style"===e){var u=t,p=n,d=r;const m=u.style,v=O(d);let e=!1;if(d&&!v){if(p)if(O(p))for(const y of p.split(";")){var h=y.slice(0,y.indexOf(":")).trim();null==d[h]&&ui(m,h,"")}else for(const w in p)null==d[w]&&ui(m,w,"");for(const b in d)"display"===b&&(e=!0),ui(m,b,d[b])}else v?p!==d&&((c=m[si])&&(d+=";"+c),m.cssText=d,e=ai.test(d)):p&&u.removeAttribute("style");ri in u&&(u[ri]=e?m.display:"",u[li]&&(m.display="none"))}else if(Ve(e))De(e)||mi(t,e,0,r,o);else{if(!("."===e[0]?(e=e.slice(1),1):"^"===e[0]?(e=e.slice(1),0):function(e,t,n,r){if(r)return"innerHTML"===t||"textContent"===t||t in e&&ki(t)&&z(n);if("spellcheck"===t||"draggable"===t||"translate"===t||"form"===t||"list"===t&&"INPUT"===e.tagName||"type"===t&&"TEXTAREA"===e.tagName)return;if("width"===t||"height"===t){r=e.tagName;if("IMG"===r||"VIDEO"===r||"CANVAS"===r||"SOURCE"===r)return}return(!ki(t)||!O(n))&&t in e}(t,e,r,l)))return"true-value"===e?t._trueValue=r:"false-value"===e&&(t._falseValue=r),o=t,s=e,a=r,void((i=l)&&s.startsWith("xlink:")?null==a?o.removeAttributeNS(hi,s.slice(6,s.length)):o.setAttributeNS(hi,s,a):(i=wt(s),null==a||i&&!bt(a)?o.removeAttribute(s):o.setAttribute(s,i?"":a)));var f=t,g=r;if("innerHTML"===(n=e)||"textContent"===n)i&&a(i,o,s),f[n]=g??"";else{const k=f.tagName;if("value"!==n||"PROGRESS"===k||k.includes("-")){let e=!1;""!==g&&null!=g||("boolean"==(i=typeof f[n])?g=bt(g):null==g&&"string"==i?(g="",e=!0):"number"==i&&(g=0,e=!0));try{f[n]=g}catch{}e&&f.removeAttribute(n)}else a=g??"",("OPTION"===k?f.getAttribute("value")||"":f.value)===a&&"_value"in f||(f.value=a),null==g&&f.removeAttribute(n),f._value=g}}}},ti);let Pi;const Ui=(...e)=>{const r=(Pi=Pi||ml(Mi)).createApp(...e),l=r["mount"];return r.mount=e=>{e=e;const t=O(e)?document.querySelector(e):e;if(t){const n=r._component;z(n)||n.render||n.template||(n.template=t.innerHTML),t.innerHTML="";e=l(t,!1,(e=t)instanceof SVGElement?"svg":"function"==typeof MathMLElement&&e instanceof MathMLElement?"mathml":void 0);return t instanceof Element&&(t.removeAttribute("v-cloak"),t.setAttribute("data-v-app","")),e}},r};function Ni(e){C&&(e=e,C&&C.cleanups.push(e))}function Fi(e){return"function"==typeof e?e():Vn(e)}const Vi=typeof window<"u"&&typeof document<"u",Di=Object.prototype.toString,Hi=e=>"[object Object]"===Di.call(e),Bi=()=>{};function Wi(r,l){return function(...n){return new Promise((e,t)=>{Promise.resolve(r(()=>l.apply(this,n),{fn:l,thisArg:this,args:n})).then(e).catch(t)})}}const qi=e=>e();function Gi(e,t=200,n={}){return Wi(function(e,i={}){let o,s,a=Bi;const c=e=>{clearTimeout(e),a(),a=Bi};return n=>{const r=Fi(e),l=Fi(i.maxWait);return o&&c(o),r<=0||void 0!==l&&l<=0?(s&&(c(s),s=null),Promise.resolve(n())):new Promise((e,t)=>{a=i.rejectOnCancel?t:e,l&&!s&&(s=setTimeout(()=>{o&&c(o),s=null,e(n())},l)),o=setTimeout(()=>{s&&c(s),s=null,e(n())},r)})}}(t,n),e)}function Zi(e,t,n={}){const{eventFilter:r,...l}=n,{eventFilter:i,pause:o,resume:s,isActive:a}=function(t=qi){const n=N(!0);return{isActive:Rn(n),pause:function(){n.value=!1},resume:function(){n.value=!0},eventFilter:(...e)=>{n.value&&t(...e)}}}(r);return{stop:function(e,t,n){const{eventFilter:r=qi,...l}=n;return Sr(e,Wi(r,t),l)}(e,t,{...l,eventFilter:i}),pause:o,resume:s,isActive:a}}function Ki(e,t=!0,n){Fl()?zr(e,n):t?e():tr(e)}const Qi=Vi?window:void 0,Xi=Vi?window.document:void 0;function Ji(...e){let t,l,i,n;if("string"==typeof e[0]||Array.isArray(e[0])?([l,i,n]=e,t=Qi):[t,l,i,n]=e,!t)return Bi;Array.isArray(l)||(l=[l]),Array.isArray(i)||(i=[i]);const o=[],s=()=>{o.forEach(e=>e()),o.length=0},r=Sr(()=>[function(e){var t,e=Fi(e);return null!=(t=null==e?void 0:e.$el)?t:e}(t),Fi(n)],([n,e])=>{if(s(),n){const r=Hi(e)?{...e}:e;o.push(...l.flatMap(t=>i.map(e=>((e,t,n,r)=>(e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)))(n,t,e,r))))}},{immediate:!0,flush:"post"}),a=()=>{r(),s()};Ni(a)}const Yi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},eo="__vueuse_ssr_handlers__",to=(eo in Yi||(Yi[eo]=Yi[eo]||{}),Yi[eo]);const no={boolean:{read:e=>"true"===e,write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},ro="vueuse-storage";function lo(r,e,l,t={}){const{flush:n="pre",deep:i=!0,listenToStorageChanges:o=!0,writeDefaults:s=!0,mergeDefaults:a=!1,shallow:c,window:u=Qi,eventFilter:p,onError:d=e=>{console.error(e)},initOnMounted:h}=t,f=(c?Un:N)("function"==typeof e?e():e);if(!l)try{l=(to.getDefaultStorage||(()=>{var e;return null==(e=Qi)?void 0:e.localStorage}))()}catch(e){d(e)}if(!l)return f;const g=Fi(e),m=null==(e=g)?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":"boolean"==typeof e?"boolean":"string"==typeof e?"string":"object"==typeof e?"object":Number.isNaN(e)?"any":"number",v=null!=(e=t.serializer)?e:no[m],{pause:y,resume:w}=Zi(f,()=>{var e=f.value;try{var t,n=l.getItem(r);null==e?(b(n,null),l.removeItem(r)):(t=v.write(e),n!==t&&(l.setItem(r,t),b(n,t)))}catch(e){d(e)}},{flush:n,deep:i,eventFilter:p});function b(e,t){u&&u.dispatchEvent(new CustomEvent(ro,{detail:{key:r,oldValue:e,newValue:t,storageArea:l}}))}function k(e){if(!e||e.storageArea===l)if(e&&null==e.key)f.value=g;else if(!e||e.key===r){y();try{(null==e?void 0:e.newValue)!==v.write(f.value)&&(f.value=null==(n=(t=e)?t.newValue:l.getItem(r))?(s&&null!=g&&l.setItem(r,v.write(g)),g):!t&&a?(t=v.read(n),"function"==typeof a?a(t,g):"object"!==m||Array.isArray(t)?t:{...g,...t}):"string"!=typeof n?n:v.read(n))}catch(e){d(e)}finally{e?tr(w):w()}}var t,n}function x(e){k(e.detail)}return u&&o&&Ki(()=>{Ji(u,"storage",k),Ji(u,ro,x),h&&k()}),h||k(),f}function io(e={}){const{controls:t=!1,interval:n="requestAnimationFrame"}=e,r=N(new Date),l=()=>r.value=new Date,i="requestAnimationFrame"===n?function(n,e){const{immediate:t=!0,fpsLimit:r=void 0,window:l=Qi}=e,i=N(!1),o=r?1e3/r:null;let s=0,a=null;function c(e){var t;i.value&&l&&(t=e-(s=s||e),a=(o&&t{o.value&&Vi&&c()})),Ni(a),{isActive:o,pause:a,resume:c}}(l,n,{immediate:!0});return t?{now:r,...i}:r}function oo(o,s=Bi,e={}){const{immediate:t=!0,manual:n=!1,type:a="text/javascript",async:c=!0,crossOrigin:u,referrerPolicy:p,noModule:d,defer:h,document:f=Xi,attrs:g={}}=e,m=N(null);let r=null;const l=(e=!0)=>r=r||(i=>new Promise((t,r)=>{const l=e=>(m.value=e,t(e),e);if(f){let e=!1,n=f.querySelector(`script[src="${Fi(o)}"]`);n?n.hasAttribute("data-loaded")&&l(n):((n=f.createElement("script")).type=a,n.async=c,n.src=Fi(o),h&&(n.defer=h),u&&(n.crossOrigin=u),d&&(n.noModule=d),p&&(n.referrerPolicy=p),Object.entries(g).forEach(([e,t])=>null==n?void 0:n.setAttribute(e,t)),e=!0),n.addEventListener("error",e=>r(e)),n.addEventListener("abort",e=>r(e)),n.addEventListener("load",()=>{n.setAttribute("data-loaded","true"),s(n),l(n)}),e&&(n=f.head.appendChild(n)),i||l(n)}else t(!1)}))(e),i=()=>{var e;f&&(r=null,m.value&&(m.value=null),(e=f.querySelector(`script[src="${Fi(o)}"]`))&&f.head.removeChild(e))};return t&&!n&&Ki(l),n||(e=i,Fl()&&Mr(e,v)),{scriptTag:m,load:l,unload:i};var v}let so=0;const ao=e=>!!/@[0-9]+\.[0-9]+\.[0-9]+/.test(e),co=(e,t="",n="",r="")=>(t?t+"/":"")+n+e+(r?"."+r:""),uo=e=>Promise.all(e.map(e=>{if($e(e)){var t=Le(e);const r=lo("WALINE_EMOJI",{}),l=ao(t);if(l){var n=r.value[t];if(n)return Promise.resolve(n)}return fetch(t+"/info.json").then(e=>e.json()).then(e=>{e={folder:t,...e};return l&&(r.value[t]=e),e})}return Promise.resolve(e)})).then(e=>{const s={tabs:[],map:{}};return e.forEach(e=>{const{name:t,folder:n,icon:r,prefix:l="",type:i,items:o}=e;s.tabs.push({name:t,icon:co(r,n,l,i),items:o.map(e=>{var t=""+l+e;return s.map[t]=co(e,n,l,i),t})})}),s}),po=e=>{"AbortError"!==e.name&&console.error(e.message)},ho=e=>e instanceof HTMLElement?e:$e(e)?document.querySelector(e):null,fo=e=>e.type.includes("image"),go=e=>{const t=Array.from(e).find(fo);return t?t.getAsFile():null};function mo(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let vo=mo();function yo(e){vo=e}const wo=/[&<>"']/,bo=new RegExp(wo.source,"g"),ko=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,xo=new RegExp(ko.source,"g"),_o={"&":"&","<":"<",">":">",'"':""","'":"'"},Co=e=>_o[e];function s(e,t){if(t){if(wo.test(e))return e.replace(bo,Co)}else if(ko.test(e))return e.replace(xo,Co);return e}const So=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;const Lo=/(^|[^\[])\^/g;function n(e,t){let r="string"==typeof e?e:e.source;t=t||"";const l={replace:(e,t)=>{let n="string"==typeof t?t:t.source;return n=n.replace(Lo,"$1"),r=r.replace(e,n),l},getRegex:()=>new RegExp(r,t)};return l}function Ro(e){try{e=encodeURI(e).replace(/%25/g,"%")}catch{return null}return e}t={exec:()=>null};function Io(e,t){const n=e.replace(/\|/g,(e,t,n)=>{let r=!1,l=t;for(;0<=--l&&"\\"===n[l];)r=!r;return r?"|":" |"}),r=n.split(/ \|/);let l=0;if(r[0].trim()||r.shift(),0t)r.splice(t);else for(;r.length{var t=e.match(/^\s+/);if(null===t)return e;var[t]=t;return t.length>=n.length?e.slice(n.length):e}).join(` +`)}(e=t[0],t[3]||""),{type:"code",raw:e,lang:t[2]&&t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"),text:n}}heading(e){const t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(/#$/.test(e)){const n=Eo(e,"#");!this.options.pedantic&&n&&!/ $/.test(n)||(e=n.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){e=this.rules.block.hr.exec(e);if(e)return{type:"hr",raw:e[0]}}blockquote(t){const n=this.rules.block.blockquote.exec(t);if(n){let e=n[0].replace(/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,` + $1`);e=Eo(e.replace(/^ *>[ \t]?/gm,""),` +`);var t=this.lexer.state.top,r=(this.lexer.state.top=!0,this.lexer.blockTokens(e));return this.lexer.state.top=t,{type:"blockquote",raw:n[0],tokens:r,text:e}}}list(u){let p=this.rules.block.list.exec(u);if(p){let e=p[1].trim();const t=1" ".repeat(3*e.length)),n=u.split(` +`,1)[0],r=0,l=(this.options.pedantic?(r=2,a=t.trimStart()):(r=4<(r=p[2].search(/[^ ]/))?1:r,a=t.slice(r),r+=p[1].length),!1);if(!t&&/^ *$/.test(n)&&(s+=n+` +`,u=u.substring(n.length+1),e=!0),!e){const g=new RegExp(`^ {0,${Math.min(3,r-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),m=new RegExp(`^ {0,${Math.min(3,r-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),v=new RegExp(`^ {0,${Math.min(3,r-1)}}(?:\`\`\`|~~~)`),y=new RegExp(`^ {0,${Math.min(3,r-1)}}#`);for(;u;){var d=u.split(` +`,1)[0];if(n=d,this.options.pedantic&&(n=n.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),v.test(n)||y.test(n)||g.test(n)||m.test(u))break;if(n.search(/[^ ]/)>=r||!n.trim())a+=` +`+n.slice(r);else{if(l||4<=t.search(/[^ ]/)||v.test(t)||y.test(t)||m.test(t))break;a+=` +`+n}l||n.trim()||(l=!0),s+=d+` +`,u=u.substring(d.length+1),t=n.slice(r)}}h.loose||(c?h.loose=!0:/\n *\n *$/.test(s)&&(c=!0));let i=null,o;this.options.gfm&&((i=/^\[[ xX]\] /.exec(a))&&(o="[ ] "!==i[0],a=a.replace(/^\[[ xX]\] +/,""))),h.items.push({type:"list_item",raw:s,task:!!i,checked:o,loose:!1,text:a,tokens:[]}),h.raw+=s}h.items[h.items.length-1].raw=s.trimEnd(),h.items[h.items.length-1].text=a.trimEnd(),h.raw=h.raw.trimEnd();for(let e=0;e"space"===e.type),r=0/\n.*\n/.test(e.raw));h.loose=r}if(h.loose)for(let e=0;e$/,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",r=t[3]&&t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"),{type:"def",tag:e,raw:t[0],href:n,title:r}}table(e){const t=this.rules.block.table.exec(e);if(t&&/[:|]/.test(t[2])){const n=Io(t[1]),r=t[2].replace(/^\||\| *$/g,"").split("|"),l=t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split(` +`):[],i={type:"table",raw:t[0],header:[],align:[],rows:[]};if(n.length===r.length){for(const o of r)/^ *-+: *$/.test(o)?i.align.push("right"):/^ *:-+: *$/.test(o)?i.align.push("center"):/^ *:-+ *$/.test(o)?i.align.push("left"):i.align.push(null);for(const s of n)i.header.push({text:s,tokens:this.lexer.inline(s)});for(const a of l)i.rows.push(Io(a,i.header.length).map(e=>({text:e,tokens:this.lexer.inline(e)})));return i}}}lheading(e){const t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:"="===t[2].charAt(0)?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){const t=this.rules.block.paragraph.exec(e);if(t)return e=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1],{type:"paragraph",raw:t[0],text:e,tokens:this.lexer.inline(e)}}text(e){e=this.rules.block.text.exec(e);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(e){e=this.rules.inline.escape.exec(e);if(e)return{type:"escape",raw:e[0],text:s(e[1])}}tag(e){e=this.rules.inline.tag.exec(e);if(e)return!this.lexer.state.inLink&&/^/i.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(n){const r=this.rules.inline.link.exec(n);if(r){const i=r[2].trim();if(!this.options.pedantic&&/^$/.test(i))return;n=Eo(i.slice(0,-1),"\\");if((i.length-n.length)%2==0)return}else{var l,n=function(t,n){if(-1===t.indexOf(n[1]))return-1;let r=0;for(let e=0;e$/.test(i)?e.slice(1):e.slice(1,-1)),Ao(r,{href:e&&e.replace(this.rules.inline.anyPunctuation,"$1"),title:t&&t.replace(this.rules.inline.anyPunctuation,"$1")},r[0],this.lexer)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){const r=(n[2]||n[1]).replace(/\s+/g," "),l=t[r.toLowerCase()];return l?Ao(n,l,n[0],this.lexer):{type:"text",raw:e=n[0].charAt(0),text:e}}}emStrong(l,i,e=""){let o=this.rules.inline.emStrongLDelim.exec(l);if(!(!o||o[3]&&e.match(/[\p{L}\p{N}]/u))&&(!o[1]&&!o[2]||!e||this.rules.inline.punctuation.exec(e))){var s=[...o[0]].length-1;let e,t,n=s,r=0;const c="*"===o[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,i=i.slice(-1*l.length+s);null!=(o=c.exec(i));)if(e=o[1]||o[2]||o[3]||o[4]||o[5]||o[6])if(t=[...e].length,o[3]||o[4])n+=t;else if((o[5]||o[6])&&s%3&&!((s+t)%3))r+=t;else if(!(0<(n-=t))){t=Math.min(t,t+n+r);const u=[...o[0]][0].length,p=l.slice(0,s+o.index+u+t);if(Math.min(s,t)%2)return a=p.slice(1,-1),{type:"em",raw:p,text:a,tokens:this.lexer.inlineTokens(a)};var a=p.slice(2,-2);return{type:"strong",raw:p,text:a,tokens:this.lexer.inlineTokens(a)}}}}codespan(t){const n=this.rules.inline.code.exec(t);if(n){let e=n[2].replace(/\n/g," ");var t=/[^ ]/.test(e),r=/^ /.test(e)&&/ $/.test(e);return e=s(e=t&&r?e.substring(1,e.length-1):e,!0),{type:"codespan",raw:n[0],text:e}}}br(e){e=this.rules.inline.br.exec(e);if(e)return{type:"br",raw:e[0]}}del(e){e=this.rules.inline.del.exec(e);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(n){n=this.rules.inline.autolink.exec(n);if(n){let e,t;return t="@"===n[2]?"mailto:"+(e=s(n[1])):e=s(n[1]),{type:"link",raw:n[0],text:e,href:t,tokens:[{type:"text",raw:e,text:e}]}}}url(e){var n,r;let l;if(l=this.rules.inline.url.exec(e)){let e,t;if("@"===l[2])e=s(l[0]),t="mailto:"+e;else{for(;r=l[0],l[0]=(null==(n=this.rules.inline._backpedal.exec(l[0]))?void 0:n[0])??"",r!==l[0];);e=s(l[0]),t="www."===l[1]?"http://"+l[0]:l[0]}return{type:"link",raw:l[0],text:e,href:t,tokens:[{type:"text",raw:e,text:e}]}}}inlineText(t){t=this.rules.inline.text.exec(t);if(t){let e;return e=this.lexer.state.inRawBlock?t[0]:s(t[0]),{type:"text",raw:t[0],text:e}}}}const To=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,jo=/(?:[*+-]|\d{1,9}[.)])/,zo=n(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g,jo).replace(/blockCode/g,/ {4}/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).getRegex(),Oo=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Mo=/(?!\s*\])(?:\\.|[^\[\]\\])+/,Po=n(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label",Mo).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Uo=n(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,jo).getRegex(),No="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Fo=/|$))/,Vo=n("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))","i").replace("comment",Fo).replace("tag",No).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),Do=n(Oo).replace("hr",To).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",No).getRegex(),Ho={blockquote:n(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",Do).getRegex(),code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,def:Po,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:To,html:Vo,lheading:zo,list:Uo,newline:/^(?: *(?:\n|$))+/,paragraph:Do,table:t,text:/^[^\n]+/},Bo=n("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",To).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",No).getRegex(),Wo={...Ho,table:Bo,paragraph:n(Oo).replace("hr",To).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Bo).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",No).getRegex()},qo={...Ho,html:n(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Fo).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:t,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:n(Oo).replace("hr",To).replace("heading",` *#{1,6} *[^ +]`).replace("lheading",zo).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Go=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Zo=/^( {2,}|\\)\n(?!\s*$)/,Ko="\\p{P}\\p{S}",Qo=n(/^((?![*_])[\spunctuation])/,"u").replace(/punctuation/g,Ko).getRegex(),Xo=n(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/,"u").replace(/punct/g,Ko).getRegex(),Jo=n("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])","gu").replace(/punct/g,Ko).getRegex(),Yo=n("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])","gu").replace(/punct/g,Ko).getRegex(),es=n(/\\([punct])/,"gu").replace(/punct/g,Ko).getRegex(),ts=n(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),ns=n(Fo).replace("(?:--\x3e|$)","--\x3e").getRegex(),rs=n("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",ns).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),ls=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,is=n(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",ls).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),os=n(/^!?\[(label)\]\[(ref)\]/).replace("label",ls).replace("ref",Mo).getRegex(),ss=n(/^!?\[(ref)\](?:\[\])?/).replace("ref",Mo).getRegex(),as=n("reflink|nolink(?!\\()","g").replace("reflink",os).replace("nolink",ss).getRegex(),cs={_backpedal:t,anyPunctuation:es,autolink:ts,blockSkip:/\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g,br:Zo,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:t,emStrongLDelim:Xo,emStrongRDelimAst:Jo,emStrongRDelimUnd:Yo,escape:Go,link:is,nolink:ss,punctuation:Qo,reflink:os,reflinkSearch:as,tag:rs,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\t+" ".repeat(n.length));let n,e,l,i;for(;r;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(e=>!!(n=e.call({lexer:this},r,t))&&(r=r.substring(n.raw.length),t.push(n),!0)))){if(n=this.tokenizer.space(r)){r=r.substring(n.raw.length),1===n.raw.length&&0{"number"==typeof(n=e.call({lexer:this},s))&&0<=n&&(t=Math.min(t,n))}),t<1/0&&0<=t&&(l=r.substring(0,t+1))}if(this.state.top&&(n=this.tokenizer.paragraph(l))){e=t[t.length-1],i&&"paragraph"===e.type?(e.raw+=` +`+n.raw,e.text+=` +`+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=e.text):t.push(n),i=l.length!==r.length,r=r.substring(n.raw.length);continue}if(n=this.tokenizer.text(r)){r=r.substring(n.raw.length),(e=t[t.length-1])&&"text"===e.type?(e.raw+=` +`+n.raw,e.text+=` +`+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=e.text):t.push(n);continue}if(r){var o="Infinite loop on byte: "+r.charCodeAt(0);if(this.options.silent){console.error(o);break}throw new Error(o)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(r,t=[]){let n,e,l,i=r,o,s,a;if(this.tokens.links){const u=Object.keys(this.tokens.links);if(0!!(n=e.call({lexer:this},r,t))&&(r=r.substring(n.raw.length),t.push(n),!0)))){if(n=this.tokenizer.escape(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.tag(r)){r=r.substring(n.raw.length),(e=t[t.length-1])&&"text"===n.type&&"text"===e.type?(e.raw+=n.raw,e.text+=n.text):t.push(n);continue}if(n=this.tokenizer.link(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.reflink(r,this.tokens.links)){r=r.substring(n.raw.length),(e=t[t.length-1])&&"text"===n.type&&"text"===e.type?(e.raw+=n.raw,e.text+=n.text):t.push(n);continue}if(n=this.tokenizer.emStrong(r,i,a)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.codespan(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.br(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.del(r)){r=r.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.autolink(r)){r=r.substring(n.raw.length),t.push(n);continue}if(!this.state.inLink&&(n=this.tokenizer.url(r))){r=r.substring(n.raw.length),t.push(n);continue}if(l=r,this.options.extensions&&this.options.extensions.startInline){let t=1/0;const p=r.slice(1);let n;this.options.extensions.startInline.forEach(e=>{"number"==typeof(n=e.call({lexer:this},p))&&0<=n&&(t=Math.min(t,n))}),t<1/0&&0<=t&&(l=r.substring(0,t+1))}if(n=this.tokenizer.inlineText(l)){r=r.substring(n.raw.length),"_"!==n.raw.slice(-1)&&(a=n.raw.slice(-1)),s=!0,(e=t[t.length-1])&&"text"===e.type?(e.raw+=n.raw,e.text+=n.text):t.push(n);continue}if(r){var c="Infinite loop on byte: "+r.charCodeAt(0);if(this.options.silent){console.error(c);break}throw new Error(c)}}return t}}class ms{options;constructor(e){this.options=e||vo}code(e,t,n){t=null==(t=(t||"").match(/^\S*/))?void 0:t[0];return e=e.replace(/\n$/,"")+` +`,t?'
    '+(n?e:s(e,!0))+`
    +`:"
    "+(n?e:s(e,!0))+`
    +`}blockquote(e){return`
    +${e}
    +`}html(e,t){return e}heading(e,t,n){return`${e} +`}hr(){return`
    +`}list(e,t,n){var r=t?"ol":"ul";return"<"+r+(t&&1!==n?' start="'+n+'"':"")+`> +`+e+" +`}listitem(e,t,n){return`
  • ${e}
  • +`}checkbox(e){return"'}paragraph(e){return`

    ${e}

    +`}table(e,t){return` + +`+e+` +`+(t=t&&`${t}`)+`
    +`}tablerow(e){return` +${e} +`}tablecell(e,t){var n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+` +`}strong(e){return`${e}`}em(e){return`${e}`}codespan(e){return`${e}`}br(){return"
    "}del(e){return`${e}`}link(e,t,n){var r=Ro(e);if(null===r)return n;let l='
    "}image(e,t,n){var r=Ro(e);if(null===r)return n;let l=`${n}"colon"===(t=t.toLowerCase())?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""));continue;case"code":i+=this.renderer.code(o.text,o.lang,!!o.escaped);continue;case"table":{var a=o;let e="",t="";for(let e=0;e{e=c[e].flat(1/0);r=r.concat(this.walkTokens(e,t))}):c.tokens&&(r=r.concat(this.walkTokens(c.tokens,t)))}}return r}use(...e){const w=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{const t={...e};if(t.async=this.defaults.async||t.async||!1,e.extensions&&(e.extensions.forEach(n=>{if(!n.name)throw new Error("extension name required");if("renderer"in n){const r=w.renderers[n.name];r?w.renderers[n.name]=function(...e){let t=n.renderer.apply(this,e);return t=!1===t?r.apply(this,e):t}:w.renderers[n.name]=n.renderer}if("tokenizer"in n){if(!n.level||"block"!==n.level&&"inline"!==n.level)throw new Error("extension level must be 'block' or 'inline'");const e=w[n.level];e?e.unshift(n.tokenizer):w[n.level]=[n.tokenizer],n.start&&("block"===n.level?w.startBlock?w.startBlock.push(n.start):w.startBlock=[n.start]:"inline"===n.level&&(w.startInline?w.startInline.push(n.start):w.startInline=[n.start]))}"childTokens"in n&&n.childTokens&&(w.childTokens[n.name]=n.childTokens)}),t.extensions=w),e.renderer){const n=this.defaults.renderer||new ms(this.defaults);for(const r in e.renderer){if(!(r in n))throw new Error(`renderer '${r}' does not exist`);if("options"!==r){const l=r,i=e.renderer[l],o=n[l];n[l]=(...e)=>{let t=i.apply(n,e);return(t=!1===t?o.apply(n,e):t)||""}}}t.renderer=n}if(e.tokenizer){const s=this.defaults.tokenizer||new $o(this.defaults);for(const a in e.tokenizer){if(!(a in s))throw new Error(`tokenizer '${a}' does not exist`);if(!["options","rules","lexer"].includes(a)){const c=a,u=e.tokenizer[c],p=s[c];s[c]=(...e)=>{let t=u.apply(s,e);return t=!1===t?p.apply(s,e):t}}}t.tokenizer=s}if(e.hooks){const d=this.defaults.hooks||new ws;for(const h in e.hooks){if(!(h in d))throw new Error(`hook '${h}' does not exist`);if("options"!==h){const f=h,g=e.hooks[f],m=d[f];ws.passThroughHooks.has(h)?d[f]=e=>{if(this.defaults.async)return Promise.resolve(g.call(d,e)).then(e=>m.call(d,e));e=g.call(d,e);return m.call(d,e)}:d[f]=(...e)=>{let t=g.apply(d,e);return t=!1===t?m.apply(d,e):t}}}t.hooks=d}if(e.walkTokens){const v=this.defaults.walkTokens,y=e.walkTokens;t.walkTokens=function(e){let t=[];return t.push(y.call(this,e)),t=v?t.concat(v.call(this,e)):t}}this.defaults={...this.defaults,...t}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return gs.lex(e,t??this.defaults)}parser(e,t){return ys.parse(e,t??this.defaults)}}i=new WeakSet,x=function(i,o){return(n,e)=>{const t={...e},r={...this.defaults,...t},l=(!0===this.defaults.async&&!1===t.async&&(r.silent||console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."),r.async=!0),_i(this,L,R).call(this,!!r.silent,!!r.async));if("u"i(e,r)).then(e=>r.hooks?r.hooks.processAllTokens(e):e).then(e=>r.walkTokens?Promise.all(this.walkTokens(e,r.walkTokens)).then(()=>e):e).then(e=>o(e,r)).then(e=>r.hooks?r.hooks.postprocess(e):e).catch(l);try{r.hooks&&(n=r.hooks.preprocess(n));let e=i(n,r),t=(r.hooks&&(e=r.hooks.processAllTokens(e)),r.walkTokens&&this.walkTokens(e,r.walkTokens),o(e,r));return t=r.hooks?r.hooks.postprocess(t):t}catch(e){return l(e)}}},L=new WeakSet,R=function(n,r){return e=>{var t;if(e.message+=` +Please report this to https://github.com/markedjs/marked.`,n)return t="

    An error occurred:

    "+s(e.message+"",!0)+"
    ",r?Promise.resolve(t):t;if(r)return Promise.reject(e);throw e}};const ks=new bs;function r(e,t){return ks.parse(e,t)}function xs(e){return(e||"").match(/\S*/)[0]}function _s(t){return e=>{"string"==typeof e&&e!==t.text&&(t.escaped=!0,t.text=e)}}r.options=r.setOptions=function(e){return ks.setOptions(e),yo(r.defaults=ks.defaults),r},r.getDefaults=mo,r.defaults=vo,r.use=function(...e){return ks.use(...e),yo(r.defaults=ks.defaults),r},r.walkTokens=function(e,t){return ks.walkTokens(e,t)},r.parseInline=ks.parseInline,r.Parser=ys,r.parser=ys.parse,r.Renderer=ms,r.TextRenderer=vs,r.Lexer=gs,r.lexer=gs.lex,r.Tokenizer=$o,r.Hooks=ws,r.parse=r;const Cs=/[&<>"']/,Ss=new RegExp(Cs.source,"g"),Ls=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,Rs=new RegExp(Ls.source,"g"),Is={"&":"&","<":"<",">":">",'"':""","'":"'"},Es=e=>Is[e];function As(e,t){if(t){if(Cs.test(e))return e.replace(Ss,Es)}else if(Ls.test(e))return e.replace(Rs,Es);return e}const $s=/\$.*?\$/,Ts=/^\$(.*?)\$/,js=/^(?:\s{0,3})\$\$((?:[^\n]|\n[^\n])+?)\n{0,1}\$\$/,zs=(e="",n={})=>e.replace(/:(.+?):/g,(e,t)=>n[t]?`${t}`:e),Os=(e,{emojiMap:t,highlighter:n,texRenderer:r})=>{const l=new bs;var i;return l.setOptions({breaks:!0}),n&&l.use(function(r){if((r="function"==typeof r?{highlight:r}:r)&&"function"==typeof r.highlight)return"string"!=typeof r.langPrefix&&(r.langPrefix="language-"),{async:!!r.async,walkTokens(e){if("code"===e.type){var t=xs(e.lang);if(r.async)return Promise.resolve(r.highlight(e.text,t,e.lang||"")).then(_s(e));t=r.highlight(e.text,t,e.lang||"");if(t instanceof Promise)throw new Error("markedHighlight is not set to async but the highlight function is async. Set the async option to true on markedHighlight to await the async highlight function.");_s(e)(t)}},renderer:{code(e,t,n){t=xs(t),t=t?` class="${r.langPrefix}${As(t)}"`:"";return e=e.replace(/\n$/,""),`
    ${n?e:As(e,!0)}
    +
    `}}};throw new Error("Must provide highlight function")}({highlight:n})),r&&(i=r,l.use({extensions:[{name:"blockMath",level:"block",tokenizer(e){e=js.exec(e);if(null!==e)return{type:"html",raw:e[0],text:i(!0,e[1])}}},{name:"inlineMath",level:"inline",start(e){var t=e.search($s);return-1!==t?t:e.length},tokenizer(e){e=Ts.exec(e);if(null!==e)return{type:"html",raw:e[0],text:i(!1,e[1])}}}]})),l.parse(zs(e,t))},Ms=e=>{e=e.dataset.path;return null!=e&&e.length?e:null},Ps=({serverURL:e,path:t=window.location.pathname,selector:n=".waline-comment-count",lang:r=navigator.language})=>{const l=new AbortController,i=document.querySelectorAll(n);return i.length&&B({serverURL:Ie(e),paths:Array.from(i).map(e=>Se(Ms(e)??t)),lang:r,signal:l.signal}).then(n=>{i.forEach((e,t)=>{e.innerText=n[t].toString()})}).catch(po),l.abort.bind(l)},Us=({size:e})=>w("svg",{class:"wl-close-icon",viewBox:"0 0 1024 1024",width:e,height:e},[w("path",{d:"M697.173 85.333h-369.92c-144.64 0-241.92 101.547-241.92 252.587v348.587c0 150.613 97.28 252.16 241.92 252.16h369.92c144.64 0 241.494-101.547 241.494-252.16V337.92c0-151.04-96.854-252.587-241.494-252.587z",fill:"currentColor"}),w("path",{d:"m640.683 587.52-75.947-75.861 75.904-75.862a37.29 37.29 0 0 0 0-52.778 37.205 37.205 0 0 0-52.779 0l-75.946 75.818-75.862-75.946a37.419 37.419 0 0 0-52.821 0 37.419 37.419 0 0 0 0 52.821l75.947 75.947-75.776 75.733a37.29 37.29 0 1 0 52.778 52.821l75.776-75.776 75.947 75.947a37.376 37.376 0 0 0 52.779-52.821z",fill:"#888"})]),Ns=()=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},w("path",{d:"m341.013 394.667 27.755 393.45h271.83l27.733-393.45h64.106l-28.01 397.952a64 64 0 0 1-63.83 59.498H368.768a64 64 0 0 1-63.83-59.52l-28.053-397.93h64.128zm139.307 19.818v298.667h-64V414.485h64zm117.013 0v298.667h-64V414.485h64zM181.333 288h640v64h-640v-64zm453.483-106.667v64h-256v-64h256z",fill:"red"})),Fs=()=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},w("path",{d:"M563.2 463.3 677 540c1.7 1.2 3.7 1.8 5.8 1.8.7 0 1.4-.1 2-.2 2.7-.5 5.1-2.1 6.6-4.4l25.3-37.8c1.5-2.3 2.1-5.1 1.6-7.8s-2.1-5.1-4.4-6.6l-73.6-49.1 73.6-49.1c2.3-1.5 3.9-3.9 4.4-6.6.5-2.7 0-5.5-1.6-7.8l-25.3-37.8a10.1 10.1 0 0 0-6.6-4.4c-.7-.1-1.3-.2-2-.2-2.1 0-4.1.6-5.8 1.8l-113.8 76.6c-9.2 6.2-14.7 16.4-14.7 27.5.1 11 5.5 21.3 14.7 27.4zM387 348.8h-45.5c-5.7 0-10.4 4.7-10.4 10.4v153.3c0 5.7 4.7 10.4 10.4 10.4H387c5.7 0 10.4-4.7 10.4-10.4V359.2c0-5.7-4.7-10.4-10.4-10.4zm333.8 241.3-41-20a10.3 10.3 0 0 0-8.1-.5c-2.6.9-4.8 2.9-5.9 5.4-30.1 64.9-93.1 109.1-164.4 115.2-5.7.5-9.9 5.5-9.5 11.2l3.9 45.5c.5 5.3 5 9.5 10.3 9.5h.9c94.8-8 178.5-66.5 218.6-152.7 2.4-5 .3-11.2-4.8-13.6zm186-186.1c-11.9-42-30.5-81.4-55.2-117.1-24.1-34.9-53.5-65.6-87.5-91.2-33.9-25.6-71.5-45.5-111.6-59.2-41.2-14-84.1-21.1-127.8-21.1h-1.2c-75.4 0-148.8 21.4-212.5 61.7-63.7 40.3-114.3 97.6-146.5 165.8-32.2 68.1-44.3 143.6-35.1 218.4 9.3 74.8 39.4 145 87.3 203.3.1.2.3.3.4.5l36.2 38.4c1.1 1.2 2.5 2.1 3.9 2.6 73.3 66.7 168.2 103.5 267.5 103.5 73.3 0 145.2-20.3 207.7-58.7 37.3-22.9 70.3-51.5 98.1-85 27.1-32.7 48.7-69.5 64.2-109.1 15.5-39.7 24.4-81.3 26.6-123.8 2.4-43.6-2.5-87-14.5-129zm-60.5 181.1c-8.3 37-22.8 72-43 104-19.7 31.1-44.3 58.6-73.1 81.7-28.8 23.1-61 41-95.7 53.4-35.6 12.7-72.9 19.1-110.9 19.1-82.6 0-161.7-30.6-222.8-86.2l-34.1-35.8c-23.9-29.3-42.4-62.2-55.1-97.7-12.4-34.7-18.8-71-19.2-107.9-.4-36.9 5.4-73.3 17.1-108.2 12-35.8 30-69.2 53.4-99.1 31.7-40.4 71.1-72 117.2-94.1 44.5-21.3 94-32.6 143.4-32.6 49.3 0 97 10.8 141.8 32 34.3 16.3 65.3 38.1 92 64.8 26.1 26 47.5 56 63.6 89.2 16.2 33.2 26.6 68.5 31 105.1 4.6 37.5 2.7 75.3-5.6 112.3z",fill:"currentColor"})),Vs=()=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},[w("path",{d:"M784 112H240c-88 0-160 72-160 160v480c0 88 72 160 160 160h544c88 0 160-72 160-160V272c0-88-72-160-160-160zm96 640c0 52.8-43.2 96-96 96H240c-52.8 0-96-43.2-96-96V272c0-52.8 43.2-96 96-96h544c52.8 0 96 43.2 96 96v480z",fill:"currentColor"}),w("path",{d:"M352 480c52.8 0 96-43.2 96-96s-43.2-96-96-96-96 43.2-96 96 43.2 96 96 96zm0-128c17.6 0 32 14.4 32 32s-14.4 32-32 32-32-14.4-32-32 14.4-32 32-32zm462.4 379.2-3.2-3.2-177.6-177.6c-25.6-25.6-65.6-25.6-91.2 0l-80 80-36.8-36.8c-25.6-25.6-65.6-25.6-91.2 0L200 728c-4.8 6.4-8 14.4-8 24 0 17.6 14.4 32 32 32 9.6 0 16-3.2 22.4-9.6L380.8 640l134.4 134.4c6.4 6.4 14.4 9.6 24 9.6 17.6 0 32-14.4 32-32 0-9.6-4.8-17.6-9.6-24l-52.8-52.8 80-80L769.6 776c6.4 4.8 12.8 8 20.8 8 17.6 0 32-14.4 32-32 0-8-3.2-16-8-20.8z",fill:"currentColor"})]),Ds=({active:e=!1})=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},[w("path",{d:"M850.654 323.804c-11.042-25.625-26.862-48.532-46.885-68.225-20.022-19.61-43.258-34.936-69.213-45.73-26.78-11.124-55.124-16.727-84.375-16.727-40.622 0-80.256 11.123-114.698 32.135A214.79 214.79 0 0 0 512 241.819a214.79 214.79 0 0 0-23.483-16.562c-34.442-21.012-74.076-32.135-114.698-32.135-29.25 0-57.595 5.603-84.375 16.727-25.872 10.711-49.19 26.12-69.213 45.73-20.105 19.693-35.843 42.6-46.885 68.225-11.453 26.615-17.303 54.877-17.303 83.963 0 27.439 5.603 56.03 16.727 85.117 9.31 24.307 22.659 49.52 39.715 74.981 27.027 40.293 64.188 82.316 110.33 124.915 76.465 70.615 152.189 119.394 155.402 121.371l19.528 12.525c8.652 5.52 19.776 5.52 28.427 0l19.529-12.525c3.213-2.06 78.854-50.756 155.401-121.371 46.143-42.6 83.304-84.622 110.33-124.915 17.057-25.46 30.487-50.674 39.716-74.981 11.124-29.087 16.727-57.678 16.727-85.117.082-29.086-5.768-57.348-17.221-83.963z"+(e?"":"M512 761.5S218.665 573.55 218.665 407.767c0-83.963 69.461-152.023 155.154-152.023 60.233 0 112.473 33.618 138.181 82.727 25.708-49.109 77.948-82.727 138.18-82.727 85.694 0 155.155 68.06 155.155 152.023C805.335 573.551 512 761.5 512 761.5z"),fill:e?"red":"currentColor"})]),Hs=()=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},[w("path",{d:"M710.816 654.301c70.323-96.639 61.084-230.578-23.705-314.843-46.098-46.098-107.183-71.109-172.28-71.109-65.008 0-126.092 25.444-172.28 71.109-45.227 46.098-70.756 107.183-70.756 172.106 0 64.923 25.444 126.007 71.194 172.106 46.099 46.098 107.184 71.109 172.28 71.109 51.414 0 100.648-16.212 142.824-47.404l126.53 126.006c7.058 7.06 16.297 10.979 26.406 10.979 10.105 0 19.343-3.919 26.402-10.979 14.467-14.467 14.467-38.172 0-52.723L710.816 654.301zm-315.107-23.265c-65.88-65.88-65.88-172.54 0-238.42 32.069-32.07 74.245-49.149 119.471-49.149 45.227 0 87.407 17.603 119.472 49.149 65.88 65.879 65.88 172.539 0 238.42-63.612 63.178-175.242 63.178-238.943 0zm0 0",fill:"currentColor"}),w("path",{d:"M703.319 121.603H321.03c-109.8 0-199.469 89.146-199.469 199.38v382.034c0 109.796 89.236 199.38 199.469 199.38h207.397c20.653 0 37.384-16.645 37.384-37.299 0-20.649-16.731-37.296-37.384-37.296H321.03c-68.582 0-124.352-55.77-124.352-124.267V321.421c0-68.496 55.77-124.267 124.352-124.267h382.289c68.582 0 124.352 55.771 124.352 124.267V524.72c0 20.654 16.736 37.299 37.385 37.299 20.654 0 37.384-16.645 37.384-37.299V320.549c-.085-109.8-89.321-198.946-199.121-198.946zm0 0",fill:"currentColor"})]),Bs=()=>w("svg",{width:"16",height:"16",ariaHidden:"true"},w("path",{d:"M14.85 3H1.15C.52 3 0 3.52 0 4.15v7.69C0 12.48.52 13 1.15 13h13.69c.64 0 1.15-.52 1.15-1.15v-7.7C16 3.52 15.48 3 14.85 3zM9 11H7V8L5.5 9.92 4 8v3H2V5h2l1.5 2L7 5h2v6zm2.99.5L9.5 8H11V5h2v3h1.5l-2.51 3.5z",fill:"currentColor"})),Ws=()=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},w("path",{d:"M810.667 213.333a64 64 0 0 1 64 64V704a64 64 0 0 1-64 64H478.336l-146.645 96.107a21.333 21.333 0 0 1-33.024-17.856V768h-85.334a64 64 0 0 1-64-64V277.333a64 64 0 0 1 64-64h597.334zm0 64H213.333V704h149.334v63.296L459.243 704h351.424V277.333zm-271.36 213.334v64h-176.64v-64h176.64zm122.026-128v64H362.667v-64h298.666z",fill:"currentColor"})),qs=()=>w("svg",{viewBox:"0 0 1024 1024",width:"24",height:"24"},w("path",{d:"M813.039 318.772L480.53 651.278H360.718V531.463L693.227 198.961C697.904 194.284 704.027 192 710.157 192C716.302 192 722.436 194.284 727.114 198.961L813.039 284.88C817.72 289.561 820 295.684 820 301.825C820 307.95 817.72 314.093 813.039 318.772ZM710.172 261.888L420.624 551.431V591.376H460.561L750.109 301.825L710.172 261.888ZM490.517 291.845H240.906V771.09H720.156V521.479C720.156 504.947 733.559 491.529 750.109 491.529C766.653 491.529 780.063 504.947 780.063 521.479V791.059C780.063 813.118 762.18 831 740.125 831H220.937C198.882 831 181 813.118 181 791.059V271.872C181 249.817 198.882 231.935 220.937 231.935H490.517C507.06 231.935 520.47 245.352 520.47 261.888C520.47 278.424 507.06 291.845 490.517 291.845Z",fill:"currentColor"})),Gs=()=>w("svg",{class:"verified-icon",viewBox:"0 0 1024 1024",width:"14",height:"14"},w("path",{d:"m894.4 461.56-54.4-63.2c-10.4-12-18.8-34.4-18.8-50.4v-68c0-42.4-34.8-77.2-77.2-77.2h-68c-15.6 0-38.4-8.4-50.4-18.8l-63.2-54.4c-27.6-23.6-72.8-23.6-100.8 0l-62.8 54.8c-12 10-34.8 18.4-50.4 18.4h-69.2c-42.4 0-77.2 34.8-77.2 77.2v68.4c0 15.6-8.4 38-18.4 50l-54 63.6c-23.2 27.6-23.2 72.4 0 100l54 63.6c10 12 18.4 34.4 18.4 50v68.4c0 42.4 34.8 77.2 77.2 77.2h69.2c15.6 0 38.4 8.4 50.4 18.8l63.2 54.4c27.6 23.6 72.8 23.6 100.8 0l63.2-54.4c12-10.4 34.4-18.8 50.4-18.8h68c42.4 0 77.2-34.8 77.2-77.2v-68c0-15.6 8.4-38.4 18.8-50.4l54.4-63.2c23.2-27.6 23.2-73.2-.4-100.8zm-216-25.2-193.2 193.2a30 30 0 0 1-42.4 0l-96.8-96.8a30.16 30.16 0 0 1 0-42.4c11.6-11.6 30.8-11.6 42.4 0l75.6 75.6 172-172c11.6-11.6 30.8-11.6 42.4 0 11.6 11.6 11.6 30.8 0 42.4z",fill:"#27ae60"})),Zs=({size:e=100})=>w("svg",{width:e,height:e,viewBox:"0 0 100 100",preserveAspectRatio:"xMidYMid"},w("circle",{cx:50,cy:50,fill:"none",stroke:"currentColor",strokeWidth:"4",r:"40","stroke-dasharray":"85 30"},w("animateTransform",{attributeName:"transform",type:"rotate",repeatCount:"indefinite",dur:"1s",values:"0 50 50;360 50 50",keyTimes:"0;1"}))),Ks=()=>w("svg",{width:24,height:24,fill:"currentcolor",viewBox:"0 0 24 24"},[w("path",{style:"transform: translateY(0.5px)",d:"M18.968 10.5H15.968V11.484H17.984V12.984H15.968V15H14.468V9H18.968V10.5V10.5ZM8.984 9C9.26533 9 9.49967 9.09367 9.687 9.281C9.87433 9.46833 9.968 9.70267 9.968 9.984V10.5H6.499V13.5H8.468V12H9.968V14.016C9.968 14.2973 9.87433 14.5317 9.687 14.719C9.49967 14.9063 9.26533 15 8.984 15H5.984C5.70267 15 5.46833 14.9063 5.281 14.719C5.09367 14.5317 5 14.2973 5 14.016V9.985C5 9.70367 5.09367 9.46933 5.281 9.282C5.46833 9.09467 5.70267 9.001 5.984 9.001H8.984V9ZM11.468 9H12.968V15H11.468V9V9Z"}),w("path",{d:"M18.5 3H5.75C3.6875 3 2 4.6875 2 6.75V18C2 20.0625 3.6875 21.75 5.75 21.75H18.5C20.5625 21.75 22.25 20.0625 22.25 18V6.75C22.25 4.6875 20.5625 3 18.5 3ZM20.75 18C20.75 19.2375 19.7375 20.25 18.5 20.25H5.75C4.5125 20.25 3.5 19.2375 3.5 18V6.75C3.5 5.5125 4.5125 4.5 5.75 4.5H18.5C19.7375 4.5 20.75 5.5125 20.75 6.75V18Z"})]);let Qs=null;const Xs=()=>Qs=Qs??lo("WALINE_LIKE",[]);let Js=null;var we=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Ys={},he={},fe={},ea=we&&we.__awaiter||function(e,o,s,a){return new(s=s||Promise)(function(n,t){function r(e){try{i(a.next(e))}catch(e){t(e)}}function l(e){try{i(a.throw(e))}catch(e){t(e)}}function i(e){var t;e.done?n(e.value):((t=e.value)instanceof s?t:new s(function(e){e(t)})).then(r,l)}i((a=a.apply(e,o||[])).next())})},ta=we&&we.__generator||function(r,l){var i,o,s,a={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]},e={next:t(0),throw:t(1),return:t(2)};return"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(n){return function(e){var t=[n,e];if(i)throw new TypeError("Generator is already executing.");for(;a;)try{if(i=1,o&&(s=2&t[0]?o.return:t[0]?o.throw||((s=o.return)&&s.call(o),0):o.next)&&!(s=s.call(o,t[1])).done)return s;switch(o=0,(t=s?[2&t[0],s.value]:t)[0]){case 0:case 1:s=t;break;case 4:return a.label++,{value:t[1],done:!1};case 5:a.label++,o=t[1],t=[0];continue;case 7:t=a.ops.pop(),a.trys.pop();continue;default:if(!(s=0<(s=a.trys).length&&s[s.length-1])&&(6===t[0]||2===t[0])){a=0;continue}if(3===t[0]&&(!s||t[1]>s[0]&&t[1]aa=aa??lo("WALINE_USER",{});be=Ar({__name:"ArticleReaction",setup(e,{expose:t}){t();const i=Js=Js??lo("WALINE_REACTION",{}),o=Xr("config"),s=N(-1),a=N([]),r=F(()=>o.value.locale),c=F(()=>0{const{reaction:e,path:n}=o.value;return e.map((e,t)=>({icon:e,desc:r.value["reaction"+t],active:i.value[n]===t}))});let u;const l=async()=>{if(c.value){const{serverURL:e,lang:t,path:n,reaction:r}=o.value,l=new AbortController,i=(u=l.abort.bind(l),await M({serverURL:e,lang:t,paths:[n],type:r.map((e,t)=>"reaction"+t),signal:l.signal}));a.value=r.map((e,t)=>i[0]["reaction"+t])}};zr(()=>{Lr(()=>[o.value.serverURL,o.value.path],()=>{l()},{immediate:!0})}),Mr(()=>null==u?void 0:u());t={reactionStorage:i,config:o,votingIndex:s,voteNumbers:a,locale:r,isReactionEnabled:c,reactionsInfo:n,get abort(){return u},set abort(e){u=e},fetchReaction:l,vote:async e=>{var t,n,r,l;-1===s.value&&({serverURL:t,lang:n,path:r}=o.value,l=i.value[r],s.value=e,void 0!==l&&(await P({serverURL:t,lang:n,path:r,type:"reaction"+l,action:"desc"}),a.value[l]=Math.max(a.value[l]-1,0)),l!==e&&(await P({serverURL:t,lang:n,path:r,type:"reaction"+e}),a.value[e]=(a.value[e]||0)+1),l===e?delete i.value[r]:i.value[r]=e,s.value=-1)},get LoadingIcon(){return Zs}};return Object.defineProperty(t,"__isScriptSetup",{enumerable:!1,value:!0}),t}}),t=(e,t)=>{const n=e.__vccOpts||e;for(var[r,l]of t)n[r]=l;return n};const ua={key:0,class:"wl-reaction"},pa=["textContent"],da={class:"wl-reaction-list"},ha=["onClick"],fa={class:"wl-reaction-img"},ga=["src","alt"],ma=["textContent"],va=["textContent"];var ya=t(be,[["render",function(e,t,n,l,r,i){return l.reactionsInfo.length?(g(),m("div",ua,[v("div",{class:"wl-reaction-title",textContent:a(l.locale.reactionTitle)},null,8,pa),v("ul",da,[(g(!0),m(ee,null,u(l.reactionsInfo,({active:e,icon:t,desc:n},r)=>(g(),m("li",{key:r,class:p(["wl-reaction-item",{active:e}]),onClick:e=>l.vote(r)},[v("div",fa,[v("img",{src:t,alt:n},null,8,ga),l.votingIndex===r?(g(),Rl(l.LoadingIcon,{key:0,class:"wl-reaction-loading"})):(g(),m("div",{key:1,class:"wl-reaction-votes",textContent:a(l.voteNumbers[r]||0)},null,8,ma))]),v("div",{class:"wl-reaction-text",textContent:a(n)},null,8,va)],10,ha))),128))])])):y("v-if",!0)}],["__file","ArticleReaction.vue"]]),wa=new Map;function ba(e){e=wa.get(e);e&&e.destroy()}function ka(e){e=wa.get(e);e&&e.update()}var we=null,xa=("u"parseFloat(s.maxHeight)?("hidden"===s.overflowY&&(i.style.overflow="scroll"),e=parseFloat(s.maxHeight)):"hidden"!==s.overflowY&&(i.style.overflow="hidden"),i.style.height=e+"px",n&&(i.style.textAlign=n),t&&t(),o!==e&&(i.dispatchEvent(new Event("autosize:resized",{bubbles:!0})),o=e),r===s.overflow||n)||(t=s.textAlign,"hidden"===s.overflow&&(i.style.textAlign="start"===t?"end":"start"),l({restoreTextAlign:t,testForHeightReduction:!0}))}function n(){l({testForHeightReduction:!0,restoreTextAlign:null})}var i,t,o,s,r,a;(i=e)&&i.nodeName&&"TEXTAREA"===i.nodeName&&!wa.has(i)&&(o=null,s=window.getComputedStyle(i),t=i.value,r=function(){l({testForHeightReduction:""===t||!i.value.startsWith(t),restoreTextAlign:null}),t=i.value},a=function(t){i.removeEventListener("autosize:destroy",a),i.removeEventListener("autosize:update",n),i.removeEventListener("input",r),window.removeEventListener("resize",n),Object.keys(t).forEach(function(e){return i.style[e]=t[e]}),wa.delete(i)}.bind(i,{height:i.style.height,resize:i.style.resize,textAlign:i.style.textAlign,overflowY:i.style.overflowY,overflowX:i.style.overflowX,wordWrap:i.style.wordWrap}),i.addEventListener("autosize:destroy",a),i.addEventListener("autosize:update",n),i.addEventListener("input",r),window.addEventListener("resize",n),i.style.overflowX="hidden",i.style.wordWrap="break-word",wa.set(i,{destroy:a,update:n}),n())}),e}).destroy=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],ba),e},we.update=function(e){return e&&Array.prototype.forEach.call(e.length?e:[e],ka),e}),we),ge=Ar({__name:"ImageWall",props:{items:{default:()=>[]},columnWidth:{default:300},gap:{default:0}},emits:["insert"],setup(e,{expose:t}){const n=e;t();let r=null;const l=N(null),i=N({}),o=N([]),s=()=>{var e=Math.floor((l.value.getBoundingClientRect().width+n.gap)/(n.columnWidth+n.gap));return 0new Array(e).fill(null).map(()=>[]),c=async e=>{var t;e>=n.items.length||(await tr(),t=Array.from((null==(t=l.value)?void 0:t.children)??[]).reduce((e,t)=>t.getBoundingClientRect().height{o.value.length===s()&&!e||(o.value=a(s()),e=window.scrollY,await c(0),window.scrollTo({top:e}))};zr(()=>{u(!0),(r=new ResizeObserver(()=>{u()})).observe(l.value),Sr(()=>[n.items],()=>{i.value={},u(!0)}),Sr(()=>[n.columnWidth,n.gap],()=>{u()})}),Or(()=>r.unobserve(l.value));e={props:n,get resizeObserver(){return r},set resizeObserver(e){r=e},wall:l,state:i,columns:o,getColumnCount:s,createColumns:a,fillColumns:c,redraw:u,imageLoad:e=>{i.value[e.target.src]=!0},get LoadingIcon(){return Zs}};return Object.defineProperty(e,"__isScriptSetup",{enumerable:!1,value:!0}),e}});const _a=["data-index"],Ca=["src","title","onClick"];var Sa=t(ge,[["render",function(n,e,r,l,t,i){return g(),m("div",{ref:"wall",class:"wl-gallery",style:gt({gap:r.gap+"px"})},[(g(!0),m(ee,null,u(l.columns,(e,t)=>(g(),m("div",{key:t,class:"wl-gallery-column","data-index":t,style:gt({gap:r.gap+"px"})},[(g(!0),m(ee,null,u(e,t=>(g(),m(ee,{key:t},[l.state[r.items[t].src]?y("v-if",!0):(g(),Rl(l.LoadingIcon,{key:0,size:36,style:{margin:"20px auto"}})),v("img",{class:"wl-gallery-item",src:r.items[t].src,title:r.items[t].title,loading:"lazy",onLoad:l.imageLoad,onClick:e=>n.$emit("insert",`![](${r.items[t].src})`)},null,40,Ca)],64))),128))],12,_a))),128))],4)}],["__file","ImageWall.vue"]]),me=Ar({__name:"CommentBox",props:{edit:{default:null},rootId:{default:""},replyId:{default:""},replyUser:{default:""}},emits:["log","cancelEdit","cancelReply","submit"],setup(e,{expose:t,emit:n}){t();const g=e,m=n,v=Xr("config"),y=lo("WALINE_COMMENT_BOX_EDITOR",""),w=lo("WALINE_USER_META",{nick:"",mail:"",link:""}),b=ca(),k=N({}),x=N(null),r=N(null),l=N(null),i=N(null),o=N(null),s=N(null),a=N(null),_=N({tabs:[],map:{}}),c=N(0),u=N(!1),p=N(!1),M=N(!1),C=N(""),S=N(0),d=Ln({loading:!0,list:[]}),h=N(0),L=N(!1),R=N(""),I=N(!1),f=N(!1),E=F(()=>v.value.locale),P=F(()=>{var e;return!(null==(e=b.value)||!e.token)}),A=F(()=>!1!==v.value.imageUploader),$=e=>{const t=x.value,n=t.selectionStart,r=t.selectionEnd||0,l=t.scrollTop;y.value=t.value.substring(0,n)+e+t.value.substring(r,t.value.length),t.focus(),t.selectionStart=n+e.length,t.selectionEnd=n+e.length,t.scrollTop=l},T=t=>{const n=`![${v.value.locale.uploading} ${t.name}]()`;return $(n),I.value=!0,Promise.resolve().then(()=>v.value.imageUploader(t)).then(e=>{y.value=y.value.replace(n,`\r +![${t.name}](${e})`)}).catch(e=>{alert(e.message),y.value=y.value.replace(n,"")}).then(()=>{I.value=!1})},j=async()=>{var e,t,n,r;const{serverURL:l,lang:i,login:o,wordLimit:s,requiredMeta:a,recaptchaV3Key:c,turnstileKey:u}=v.value,p=await(async()=>{if(!navigator)return"";const e=navigator["userAgentData"];let t=navigator.userAgent;if(!e||"Windows"!==e.platform)return t;const n=(await e.getHighEntropyValues(["platformVersion"]))["platformVersion"];return t=n&&13<=parseInt(n.split(".")[0])?t.replace("Windows NT 10.0","Windows NT 11.0"):t})(),d={comment:R.value,nick:w.value.nick,mail:w.value.mail,link:w.value.link,url:v.value.path,ua:p};if(!g.edit)if(null!=(n=b.value)&&n.token)d.nick=b.value.display_name,d.mail=b.value.email,d.link=b.value.url;else{if("force"===o)return;if(-1{const n=sa[e]??(sa[e]=Ys.load(e,{useRecaptchaNet:!0,autoHideBadge:!0}));return{execute:t=>n.then(e=>e.execute(t))}})(c).execute("social")),u&&(d.turnstile=(r=u,await(async t=>{const e=oo("https://challenges.cloudflare.com/turnstile/v0/api.js",void 0,{async:!1})["load"],n=(await e(),null==window?void 0:window.turnstile);return new Promise(e=>{null!=n&&n.ready(()=>{null!=n&&n.render(".wl-captcha-container",{sitekey:r,action:t,size:"compact",callback:e})})})})("social")));var h={serverURL:l,lang:i,token:null==(e=b.value)?void 0:e.token,comment:d},f=await(g.edit?H({objectId:g.edit.objectId,...h}):V(h));if(I.value=!1,f.errmsg)return alert(f.errmsg);m("submit",f.data),y.value="",C.value="",await tr(),g.replyId&&m("cancelReply"),null!=(t=g.edit)&&t.objectId&&m("cancelEdit")}catch(e){I.value=!1,alert(e.message)}}else null!=(n=x.value)&&n.focus()},z=e=>{var t;null!=(t=l.value)&&t.contains(e.target)||null!=(t=i.value)&&t.contains(e.target)||(u.value=!1),null!=(t=o.value)&&t.contains(e.target)||null!=(t=s.value)&&t.contains(e.target)||(p.value=!1)},O=async e=>{var t;const{scrollTop:n,clientHeight:r,scrollHeight:l}=e.target,i=(r+n)/l,o=v.value.search,s=(null==(t=a.value)?void 0:t.value)??"";i<.9||d.loading||f.value||(d.loading=!0,(o.more&&d.list.length?await o.more(s,d.list.length):await o.search(s)).length?d.list=[...d.list,...o.more&&d.list.length?await o.more(s,d.list.length):await o.search(s)]:f.value=!0,d.loading=!1,setTimeout(()=>{e.target.scrollTop=n},50))},U=Gi(e=>{d.list=[],f.value=!1,O(e)},300);Sr([v,S],([e,t])=>{e=e.wordLimit;e?te[1]?(h.value=e[1],L.value=!1):(h.value=e[1],L.value=!0):(h.value=0,L.value=!0)},{immediate:!0}),Ji("click",z),Ji("message",({data:e})=>{e&&"profile"===e.type&&(b.value={...b.value,...e.data},[localStorage,sessionStorage].filter(e=>e.getItem("WALINE_USER")).forEach(e=>e.setItem("WALINE_USER",JSON.stringify(b))))}),Sr(p,async e=>{if(e){const t=v.value.search;a.value&&(a.value.value=""),d.loading=!0,d.list=await((null==(e=t.default)?void 0:e.call(t))??t.search("")),d.loading=!1}}),zr(()=>{var e;null!=(e=g.edit)&&e.objectId&&(y.value=g.edit.orig),Lr(()=>y.value,e=>{var{highlighter:t,texRenderer:n}=v.value;R.value=e,C.value=Os(e,{emojiMap:_.value.map,highlighter:t,texRenderer:n}),S.value=((null==(n=(t=e).match(/[\w\d\s,.\u00C0-\u024F\u0400-\u04FF]+/giu))?void 0:n.reduce((e,t)=>e+(["",",","."].includes(t.trim())?0:t.trim().split(/\s+/u).length),0))??0)+((null==(n=t.match(/[\u4E00-\u9FD5]/gu))?void 0:n.length)??0),e?xa(x.value):xa.destroy(x.value)},{immediate:!0}),Lr(()=>v.value.emoji,e=>uo(e).then(e=>{_.value=e}),{immediate:!0})});t={props:g,emit:m,config:v,editor:y,userMeta:w,userInfo:b,inputRefs:k,editorRef:x,imageUploadRef:r,emojiButtonRef:l,emojiPopupRef:i,gifButtonRef:o,gifPopupRef:s,gifSearchInputRef:a,emoji:_,emojiTabIndex:c,showEmoji:u,showGif:p,showPreview:M,previewText:C,wordNumber:S,searchResults:d,wordLimit:h,isWordNumberLegal:L,content:R,isSubmitting:I,isImageListEnd:f,locale:E,isLogin:P,canUploadImage:A,insert:$,onKeyDown:e=>{var t=e.key;(e.ctrlKey||e.metaKey)&&"Enter"===t&&j()},uploadImage:T,onDrop:e=>{var t;null!=(t=e.dataTransfer)&&t.items&&(t=go(e.dataTransfer.items))&&A.value&&(T(t),e.preventDefault())},onPaste:e=>{e.clipboardData&&(e=go(e.clipboardData.items))&&A.value&&T(e)},onChange:()=>{const e=r.value;e.files&&A.value&&T(e.files[0]).then(()=>{e.value=""})},submitComment:j,onLogin:e=>{e.preventDefault();var{lang:e,serverURL:t}=v.value;W({serverURL:t,lang:e}).then(e=>{((b.value=e).remember?localStorage:sessionStorage).setItem("WALINE_USER",JSON.stringify(e)),m("log")})},onLogout:()=>{b.value={},localStorage.setItem("WALINE_USER","null"),sessionStorage.setItem("WALINE_USER","null"),m("log")},onProfile:e=>{e.preventDefault();const{lang:t,serverURL:n}=v.value,r=(window.innerWidth-800)/2,l=(window.innerHeight-800)/2,i=new URLSearchParams({lng:t,token:b.value.token}),o=window.open(n+"/ui/profile?"+i.toString(),"_blank",`width=800,height=800,left=${r},top=${l},scrollbars=no,resizable=no,status=no,location=no,toolbar=no,menubar=no`);null!=o&&o.postMessage({type:"TOKEN",data:b.value.token},"*")},popupHandler:z,onImageWallScroll:O,onGifSearch:U,get CloseIcon(){return Us},get EmojiIcon(){return Fs},get GifIcon(){return Ks},get ImageIcon(){return Vs},get LoadingIcon(){return Zs},get MarkdownIcon(){return Bs},get PreviewIcon(){return Hs},ImageWall:Sa};return Object.defineProperty(t,"__isScriptSetup",{enumerable:!1,value:!0}),t}});const La={key:0,class:"wl-login-info"},Ra={class:"wl-avatar"},Ia=["title"],Ea=["title"],Aa=["src"],$a=["title","textContent"],Ta={class:"wl-panel"},ja=["for","textContent"],za=["id","onUpdate:modelValue","name","type"],Oa=["placeholder"],Ma={class:"wl-preview"},Pa=v("hr",null,null,-1),Ua=["innerHTML"],Na={class:"wl-footer"},Fa={class:"wl-actions"},Va={href:"https://guides.github.com/features/mastering-markdown/",title:"Markdown Guide","aria-label":"Markdown is supported",class:"wl-action",target:"_blank",rel:"noopener noreferrer"},Da=["title"],Ha=["title"],Ba=["title"],Wa=["title"],qa={class:"wl-info"},Ga=v("div",{class:"wl-captcha-container"},null,-1),Za={class:"wl-text-number"},Ka={key:0},Qa=["textContent"],Xa=["textContent"],Ja=["disabled"],Ya=["placeholder"],ec={key:1,class:"wl-loading"},tc={key:0,class:"wl-tab-wrapper"},nc=["title","onClick"],rc=["src","alt"],lc={key:0,class:"wl-tabs"},ic=["onClick"],oc=["src","alt","title"],sc=["title"];var ac=t(me,[["render",function(e,t,n,r,l,i){var o;return g(),m("div",{key:r.userInfo.token,class:"wl-comment"},["disable"===r.config.login||!r.isLogin||null!=(o=n.edit)&&o.objectId?y("v-if",!0):(g(),m("div",La,[v("div",Ra,[v("button",{type:"submit",class:"wl-logout-btn",title:r.locale.logout,onClick:r.onLogout},[te(r.CloseIcon,{size:14})],8,Ia),v("a",{href:"#",class:"wl-login-nick","aria-label":"Profile",title:r.locale.profile,onClick:r.onProfile},[v("img",{src:r.userInfo.avatar,alt:"avatar"},null,8,Aa)],8,Ea)]),v("a",{href:"#",class:"wl-login-nick","aria-label":"Profile",title:r.locale.profile,onClick:r.onProfile,textContent:a(r.userInfo.display_name)},null,8,$a)])),v("div",Ta,["force"!==r.config.login&&r.config.meta.length&&!r.isLogin?(g(),m("div",{key:0,class:p(["wl-header","item"+r.config.meta.length])},[(g(!0),m(ee,null,u(r.config.meta,t=>(g(),m("div",{key:t,class:"wl-header-item"},[v("label",{for:"wl-"+t,textContent:a(r.locale[t]+(r.config.requiredMeta.includes(t)||!r.config.requiredMeta.length?"":`(${r.locale.optional})`))},null,8,ja),Ir(v("input",{id:"wl-"+t,ref_for:!0,ref:e=>{e&&(r.inputRefs[t]=e)},"onUpdate:modelValue":e=>r.userMeta[t]=e,class:p(["wl-input","wl-"+t]),name:t,type:"mail"===t?"email":"text"},null,10,za),[[zi,r.userMeta[t]]])]))),128))],2)):y("v-if",!0),Ir(v("textarea",{id:"wl-edit",ref:"editorRef","onUpdate:modelValue":t[0]||(t[0]=e=>r.editor=e),class:"wl-editor",placeholder:n.replyUser?"@"+n.replyUser:r.locale.placeholder,onKeydown:r.onKeyDown,onDrop:r.onDrop,onPaste:r.onPaste},null,40,Oa),[[Li,r.editor]]),Ir(v("div",Ma,[Pa,v("h4",null,a(r.locale.preview)+":",1),v("div",{class:"wl-content",innerHTML:r.previewText},null,8,Ua)],512),[[ii,r.showPreview]]),v("div",Na,[v("div",Fa,[v("a",Va,[te(r.MarkdownIcon)]),Ir(v("button",{ref:"emojiButtonRef",type:"button",class:p(["wl-action",{active:r.showEmoji}]),title:r.locale.emoji,onClick:t[1]||(t[1]=e=>r.showEmoji=!r.showEmoji)},[te(r.EmojiIcon)],10,Da),[[ii,r.emoji.tabs.length]]),r.config.search?(g(),m("button",{key:0,ref:"gifButtonRef",type:"button",class:p(["wl-action",{active:r.showGif}]),title:r.locale.gif,onClick:t[2]||(t[2]=e=>r.showGif=!r.showGif)},[te(r.GifIcon)],10,Ha)):y("v-if",!0),v("input",{id:"wl-image-upload",ref:"imageUploadRef",class:"upload",type:"file",accept:".png,.jpg,.jpeg,.webp,.bmp,.gif",onChange:r.onChange},null,544),r.canUploadImage?(g(),m("label",{key:1,for:"wl-image-upload",class:"wl-action",title:r.locale.uploadImage},[te(r.ImageIcon)],8,Ba)):y("v-if",!0),v("button",{type:"button",class:p(["wl-action",{active:r.showPreview}]),title:r.locale.preview,onClick:t[3]||(t[3]=e=>r.showPreview=!r.showPreview)},[te(r.PreviewIcon)],10,Wa)]),v("div",qa,[Ga,v("div",Za,[jl(a(r.wordNumber)+" ",1),r.config.wordLimit?(g(),m("span",Ka,[jl("  /  "),v("span",{class:p({illegal:!r.isWordNumberLegal}),textContent:a(r.wordLimit)},null,10,Qa)])):y("v-if",!0),jl("  "+a(r.locale.word),1)]),"disable"===r.config.login||r.isLogin?y("v-if",!0):(g(),m("button",{key:0,type:"button",class:"wl-btn",onClick:r.onLogin,textContent:a(r.locale.login)},null,8,Xa)),"force"!==r.config.login||r.isLogin?(g(),m("button",{key:1,type:"submit",class:"primary wl-btn",title:"Cmd|Ctrl + Enter",disabled:r.isSubmitting,onClick:r.submitComment},[r.isSubmitting?(g(),Rl(r.LoadingIcon,{key:0,size:16})):(g(),m(ee,{key:1},[jl(a(r.locale.submit),1)],64))],8,Ja)):y("v-if",!0)]),v("div",{ref:"gifPopupRef",class:p(["wl-gif-popup",{display:r.showGif}])},[v("input",{ref:"gifSearchInputRef",type:"text",placeholder:r.locale.gifSearchPlaceholder,onInput:t[4]||(t[4]=(...e)=>r.onGifSearch&&r.onGifSearch(...e))},null,40,Ya),r.searchResults.list.length?(g(),Rl(r.ImageWall,{key:0,items:r.searchResults.list,"column-width":200,gap:6,onInsert:t[5]||(t[5]=e=>r.insert(e)),onScroll:r.onImageWallScroll},null,8,["items"])):y("v-if",!0),r.searchResults.loading?(g(),m("div",ec,[te(r.LoadingIcon,{size:30})])):y("v-if",!0)],2),v("div",{ref:"emojiPopupRef",class:p(["wl-emoji-popup",{display:r.showEmoji}])},[(g(!0),m(ee,null,u(r.emoji.tabs,(e,t)=>(g(),m(ee,{key:e.name},[t===r.emojiTabIndex?(g(),m("div",tc,[(g(!0),m(ee,null,u(e.items,t=>(g(),m("button",{key:t,type:"button",title:t,onClick:e=>r.insert(`:${t}:`)},[r.showEmoji?(g(),m("img",{key:0,class:"wl-emoji",src:r.emoji.map[t],alt:t,loading:"lazy",referrerPolicy:"no-referrer"},null,8,rc)):y("v-if",!0)],8,nc))),128))])):y("v-if",!0)],64))),128)),1(g(),m("button",{key:e.name,type:"button",class:p(["wl-tab",{active:r.emojiTabIndex===t}]),onClick:e=>r.emojiTabIndex=t},[v("img",{class:"wl-emoji",src:e.icon,alt:e.name,title:e.name,loading:"lazy",referrerPolicy:"no-referrer"},null,8,oc)],10,ic))),128))])):y("v-if",!0)],2)])]),n.replyId||null!=(o=n.edit)&&o.objectId?(g(),m("button",{key:1,type:"button",class:"wl-close",title:r.locale.cancelReply,onClick:t[6]||(t[6]=e=>n.replyId?r.emit("cancelReply"):r.emit("cancelEdit"))},[te(r.CloseIcon,{size:24})],8,sc)):y("v-if",!0)])}],["__file","CommentBox.vue"]]),ve=Ar({__name:"CommentCard",props:{comment:{},edit:{default:null},rootId:{},reply:{default:null}},emits:["log","submit","delete","edit","like","status","sticky","reply"],setup(e,{expose:t,emit:n}){t();const r=e,l=n,i=Xr("config"),o=Xs(),s=io(),a=ca(),c=F(()=>i.value.locale),u=F(()=>{var e=r.comment["link"];return e?Re(e)?e:"https://"+e:""}),p=F(()=>o.value.includes(r.comment.objectId)),d=F(()=>ze(new Date(r.comment.time),s.value,c.value)),h=F(()=>"administrator"===a.value.type),f=F(()=>r.comment.user_id&&a.value.objectId===r.comment.user_id),g=F(()=>{var e;return r.comment.objectId===(null==(e=r.reply)?void 0:e.objectId)}),m=F(()=>{var e;return r.comment.objectId===(null==(e=r.edit)?void 0:e.objectId)}),v={props:r,emit:l,commentStatus:["approved","waiting","spam"],config:i,likes:o,now:s,userInfo:a,locale:c,link:u,like:p,time:d,isAdmin:h,isOwner:f,isReplyingCurrent:g,isEditingCurrent:m,CommentBox:ac,get DeleteIcon(){return Ns},get EditIcon(){return qs},get LikeIcon(){return Ds},get ReplyIcon(){return Ws},get VerifiedIcon(){return Gs}};return Object.defineProperty(v,"__isScriptSetup",{enumerable:!1,value:!0}),v}});const cc=["id"],uc={class:"wl-user","aria-hidden":"true"},pc=["src"],dc={class:"wl-card"},hc={class:"wl-head"},fc=["href"],gc={key:1,class:"wl-nick"},mc=["textContent"],vc=["textContent"],yc=["textContent"],wc=["textContent"],bc=["textContent"],kc={class:"wl-comment-actions"},xc=["title"],_c=["title"],Cc={class:"wl-meta","aria-hidden":"true"},Sc=["data-value","textContent"],Lc={key:0,class:"wl-content"},Rc={key:0},Ic=["href"],Ec=v("span",null,": ",-1),Ac=["innerHTML"],$c={key:1,class:"wl-admin-actions"},Tc={class:"wl-comment-status"},jc=["disabled","onClick","textContent"],zc={key:3,class:"wl-quote"};var Oc=t(ve,[["render",function(e,t,n,r,l,i){var o;const s=vr("CommentCard",!0);return g(),m("div",{id:n.comment.objectId,class:"wl-card-item"},[v("div",uc,[n.comment.avatar?(g(),m("img",{key:0,class:"wl-user-avatar",src:n.comment.avatar},null,8,pc)):y("v-if",!0),n.comment.type?(g(),Rl(r.VerifiedIcon,{key:1})):y("v-if",!0)]),v("div",dc,[v("div",hc,[r.link?(g(),m("a",{key:0,class:"wl-nick",href:r.link,target:"_blank",rel:"nofollow noopener noreferrer"},a(n.comment.nick),9,fc)):(g(),m("span",gc,a(n.comment.nick),1)),"administrator"===n.comment.type?(g(),m("span",{key:2,class:"wl-badge",textContent:a(r.locale.admin)},null,8,mc)):y("v-if",!0),n.comment.label?(g(),m("span",{key:3,class:"wl-badge",textContent:a(n.comment.label)},null,8,vc)):y("v-if",!0),n.comment.sticky?(g(),m("span",{key:4,class:"wl-badge",textContent:a(r.locale.sticky)},null,8,yc)):y("v-if",!0),"number"==typeof n.comment.level?(g(),m("span",{key:5,class:p("wl-badge level"+n.comment.level),textContent:a(r.locale["level"+n.comment.level]||"Level "+n.comment.level)},null,10,wc)):y("v-if",!0),v("span",{class:"wl-time",textContent:a(r.time)},null,8,bc),v("div",kc,[r.isAdmin||r.isOwner?(g(),m(ee,{key:0},[v("button",{type:"button",class:"wl-edit",onClick:t[0]||(t[0]=e=>r.emit("edit",n.comment))},[te(r.EditIcon)]),v("button",{type:"button",class:"wl-delete",onClick:t[1]||(t[1]=e=>r.emit("delete",n.comment))},[te(r.DeleteIcon)])],64)):y("v-if",!0),v("button",{type:"button",class:"wl-like",title:r.like?r.locale.cancelLike:r.locale.like,onClick:t[2]||(t[2]=e=>r.emit("like",n.comment))},[te(r.LikeIcon,{active:r.like},null,8,["active"]),jl(" "+a("like"in n.comment?n.comment.like:""),1)],8,xc),v("button",{type:"button",class:p(["wl-reply",{active:r.isReplyingCurrent}]),title:r.isReplyingCurrent?r.locale.cancelReply:r.locale.reply,onClick:t[3]||(t[3]=e=>r.emit("reply",r.isReplyingCurrent?null:n.comment))},[te(r.ReplyIcon)],10,_c)])]),v("div",Cc,[(g(),m(ee,null,u(["addr","browser","os"],e=>(g(),m(ee,null,[n.comment[e]?(g(),m("span",{key:e,class:p("wl-"+e),"data-value":n.comment[e],textContent:a(n.comment[e])},null,10,Sc)):y("v-if",!0)],64))),64))]),r.isEditingCurrent?y("v-if",!0):(g(),m("div",Lc,[n.comment.reply_user?(g(),m("p",Rc,[v("a",{href:"#"+n.comment.pid},"@"+a(n.comment.reply_user.nick),9,Ic),Ec])):y("v-if",!0),v("div",{innerHTML:n.comment.comment},null,8,Ac)])),r.isAdmin&&!r.isEditingCurrent?(g(),m("div",$c,[v("span",Tc,[(g(),m(ee,null,u(r.commentStatus,t=>v("button",{key:t,type:"submit",class:p("wl-btn wl-"+t),disabled:n.comment.status===t,onClick:e=>r.emit("status",{status:t,comment:n.comment}),textContent:a(r.locale[t])},null,10,jc)),64))]),!r.isAdmin||"rid"in n.comment?y("v-if",!0):(g(),m("button",{key:0,type:"submit",class:"wl-btn wl-sticky",onClick:t[4]||(t[4]=e=>r.emit("sticky",n.comment))},a(n.comment.sticky?r.locale.unsticky:r.locale.sticky),1))])):y("v-if",!0),r.isReplyingCurrent||r.isEditingCurrent?(g(),m("div",{key:2,class:p({"wl-reply-wrapper":r.isReplyingCurrent,"wl-edit-wrapper":r.isEditingCurrent})},[te(r.CommentBox,{edit:n.edit,"reply-id":null==(o=n.reply)?void 0:o.objectId,"reply-user":n.comment.nick,"root-id":n.rootId,onLog:t[5]||(t[5]=e=>r.emit("log")),onCancelReply:t[6]||(t[6]=e=>r.emit("reply",null)),onCancelEdit:t[7]||(t[7]=e=>r.emit("edit",null)),onSubmit:t[8]||(t[8]=e=>r.emit("submit",e))},null,8,["edit","reply-id","reply-user","root-id"])],2)):y("v-if",!0),"children"in n.comment?(g(),m("div",zc,[(g(!0),m(ee,null,u(n.comment.children,e=>(g(),Rl(s,{key:e.objectId,comment:e,reply:n.reply,edit:n.edit,"root-id":n.rootId,onLog:t[9]||(t[9]=e=>r.emit("log")),onDelete:t[10]||(t[10]=e=>r.emit("delete",e)),onEdit:t[11]||(t[11]=e=>r.emit("edit",e)),onLike:t[12]||(t[12]=e=>r.emit("like",e)),onReply:t[13]||(t[13]=e=>r.emit("reply",e)),onStatus:t[14]||(t[14]=e=>r.emit("status",e)),onSticky:t[15]||(t[15]=e=>r.emit("sticky",e)),onSubmit:t[16]||(t[16]=e=>r.emit("submit",e))},null,8,["comment","reply","edit","root-id"]))),128))])):y("v-if",!0)])],8,cc)}],["__file","CommentCard.vue"]]);he=Ar({__name:"WalineComment",props:["serverURL","path","meta","requiredMeta","dark","commentSorting","lang","locale","pageSize","wordLimit","emoji","login","highlighter","texRenderer","imageUploader","search","copyright","recaptchaV3Key","turnstileKey","reaction"],setup(t,{expose:n}){n();const e=t,o={latest:"insertedAt_desc",oldest:"insertedAt_asc",hottest:"like_desc"},r=Object.keys(o),s=ca(),a=Xs(),c=N("loading"),u=N(0),p=N(1),d=N(0),h=F(()=>Ae(e)),f=N(h.value.commentSorting),g=N([]),l=N(null),i=N(null),m=F(()=>(e=>$e(e)?"auto"===e?`@media(prefers-color-scheme:dark){body${Te}}`:""+e+Te:!0===e?":root"+Te:"")(h.value.dark)),v=F(()=>h.value.locale);{n=m;var y={id:"waline-darkmode"};const _=N(!1),{document:C=Xi,immediate:S=!0,manual:L=!1,id:R="vueuse_styletag_"+ ++so}=y,I=N(n);let e=()=>{};n=()=>{if(C){const t=C.getElementById(R)||C.createElement("style");t.isConnected||(t.id=R,y.media&&(t.media=y.media),C.head.appendChild(t)),_.value||(e=Sr(I,e=>{t.textContent=e},{immediate:!0}),_.value=!0)}},t=()=>{C&&_.value&&(e(),C.head.removeChild(C.getElementById(R)),_.value=!1)},S&&!L&&Ki(n),L||Ni(t),R,I,Rn(_)}let w;const b=t=>{var e;const{serverURL:n,path:r,pageSize:l}=h.value,i=new AbortController;c.value="loading",null!=w&&w(),U({serverURL:n,lang:h.value.lang,path:r,pageSize:l,sortBy:o[f.value],page:t,signal:i.signal,token:null==(e=s.value)?void 0:e.token}).then(e=>{c.value="success",u.value=e.count,g.value.push(...e.data),p.value=t,d.value=e.totalPages}).catch(e=>{"AbortError"!==e.name&&(console.error(e.message),c.value="error")}),w=i.abort.bind(i)},k=()=>{u.value=0,g.value=[],b(1)};n="config",t=h;if(E){let e=E.provides;var x=E.parent&&E.parent.provides;(e=x===e?E.provides=Object.create(x):e)[n]=t}zr(()=>{Lr(()=>[e.serverURL,e.path],()=>k(),{immediate:!0})}),Mr(()=>null==w?void 0:w());x={props:e,sortKeyMap:o,sortingMethods:r,userInfo:s,likeStorage:a,status:c,count:u,page:p,totalPages:d,config:h,commentSortingRef:f,data:g,reply:l,edit:i,darkmodeStyle:m,i18n:v,get abort(){return w},set abort(e){w=e},getCommentData:b,loadMore:()=>b(p.value+1),refresh:k,onSortByChange:e=>{f.value!==e&&(f.value=e,k())},onReply:e=>{l.value=e},onEdit:e=>{i.value=e},onSubmit:t=>{if(i.value)i.value.comment=t.comment,i.value.orig=t.orig;else if("rid"in t){const e=g.value.find(({objectId:e})=>e===t.rid);e&&(Array.isArray(e.children)||(e.children=[]),e.children.push(t))}else g.value.unshift(t),u.value+=1},onStatusChange:async({comment:e,status:t})=>{var n,r;e.status!==t&&({serverURL:n,lang:r}=h.value,await H({serverURL:n,lang:r,token:null==(n=s.value)?void 0:n.token,objectId:e.objectId,comment:{status:t}}),e.status=t)},onSticky:async e=>{var t,n;"rid"in e||({serverURL:t,lang:n}=h.value,await H({serverURL:t,lang:n,token:null==(t=s.value)?void 0:t.token,objectId:e.objectId,comment:{sticky:e.sticky?0:1}}),e.sticky=!e.sticky)},onDelete:async({objectId:l})=>{var e,t;confirm("Are you sure you want to delete this comment?")&&({serverURL:e,lang:t}=h.value,await D({serverURL:e,lang:t,token:null==(e=s.value)?void 0:e.token,objectId:l}),g.value.some((t,r)=>t.objectId===l?(g.value=g.value.filter((e,t)=>t!==r),!0):t.children.some((e,n)=>e.objectId===l&&(g.value[r].children=t.children.filter((e,t)=>t!==n),!0))))},onLike:async e=>{var t;const{serverURL:n,lang:r}=h.value,l=e["objectId"],i=a.value.includes(l);await H({serverURL:n,lang:r,objectId:l,token:null==(t=s.value)?void 0:t.token,comment:{like:!i}}),i?a.value=a.value.filter(e=>e!==l):(a.value=[...a.value,l],50(g(),m("li",{key:t,class:p([t===r.commentSortingRef?"active":""]),onClick:e=>r.onSortByChange(t)},a(r.i18n[t]),11,Vc))),128))])]),v("div",Dc,[(g(!0),m(ee,null,u(r.data,e=>(g(),Rl(r.CommentCard,{key:e.objectId,"root-id":e.objectId,comment:e,reply:r.reply,edit:r.edit,onLog:r.refresh,onReply:r.onReply,onEdit:r.onEdit,onSubmit:r.onSubmit,onStatus:r.onStatusChange,onDelete:r.onDelete,onSticky:r.onSticky,onLike:r.onLike},null,8,["root-id","comment","reply","edit"]))),128))]),"error"===r.status?(g(),m("div",Hc,[v("button",{type:"button",class:"wl-btn",onClick:r.refresh,textContent:a(r.i18n.refresh)},null,8,Bc)])):"loading"===r.status?(g(),m("div",Wc,[te(r.LoadingIcon,{size:30})])):r.data.length?r.page{e.forEach((e,t)=>{const n=r[t].time;"number"==typeof n&&(e.innerText=n.toString())})},Yc=({serverURL:e,path:n=window.location.pathname,selector:t=".waline-pageview-count",update:r=!0,lang:l=navigator.language})=>{const i=new AbortController,o=Array.from(document.querySelectorAll(t)),s=e=>{e=Ms(e);return null!==e&&n!==e},a=t=>q({serverURL:Ie(e),paths:t.map(e=>Ms(e)??n),lang:l,signal:i.signal}).then(e=>Jc(e,t)).catch(po);if(r){const c=o.filter(e=>!s(e)),u=o.filter(s);G({serverURL:Ie(e),path:n,lang:l}).then(e=>Jc(e,c)),u.length&&a(u)}else a(o);return i.abort.bind(i)};e.RecentComments=({el:e,serverURL:t,count:n,lang:r=navigator.language})=>{const l=ca(),i=ho(e),o=new AbortController;return Z({serverURL:t,count:n,lang:r,signal:o.signal,token:null==(e=l.value)?void 0:e.token}).then(e=>i&&e.length?(i.innerHTML=`
    `,{comments:e,destroy:()=>{o.abort(),i.innerHTML=""}}):{comments:e,destroy:()=>o.abort()})},e.UserList=({el:e,serverURL:t,count:n,locale:r,lang:l=navigator.language,mode:i="list"})=>{const o=ho(e),s=new AbortController;return K({serverURL:t,pageSize:n,lang:l,signal:s.signal}).then(e=>o&&e.length?(r={..._e(l),..."object"==typeof r?r:{}},o.innerHTML=``,{users:e,destroy:()=>{s.abort(),o.innerHTML=""}}):{users:e,destroy:()=>s.abort()})},e.addComment=V,e.commentCount=Ps,e.defaultLocales=xe,e.deleteComment=D,e.fetchCommentCount=B,e.getArticleCounter=M,e.getComment=U,e.getPageview=q,e.getRecentComment=Z,e.getUserList=K,e.init=({el:e="#waline",path:t=window.location.pathname,comment:n=!1,pageview:r=!1,...l})=>{var i=e?ho(e):null;if(e&&!i)throw new Error("Option 'el' do not match any domElement!");if(!l.serverURL)throw new Error("Option 'serverURL' is missing!");const o=Ln({...l}),s=Ln({comment:n,pageview:r,path:t}),a=i?Ui(()=>w(Xc,{path:s.path,...o})):null,c=(a&&a.mount(i),_r(()=>{s.comment&&Ps({serverURL:o.serverURL,path:s.path,...$e(s.comment)?{selector:s.comment}:{}})})),u=_r(()=>{s.pageview&&Yc({serverURL:o.serverURL,path:s.path,...$e(s.pageview)?{selector:s.pageview}:{}})});return{el:i,update:({comment:e,pageview:t,path:n=window.location.pathname,...r}={})=>{Object.entries(r).forEach(([e,t])=>{o[e]=t}),s.path=n,void 0!==e&&(s.comment=e),void 0!==t&&(s.pageview=t)},destroy:()=>{null!=a&&a.unmount(),c(),u()}}},e.login=W,e.pageviewCount=Yc,e.updateArticleCounter=P,e.updateComment=H,e.updatePageview=G,e.version="3.3.0"}); \ No newline at end of file From 85c3eb9d3b37f6503d6fda2cb29dc0d1a9a0da30 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Sat, 3 Aug 2024 23:07:03 +0800 Subject: [PATCH 06/42] :bug: Fixed the waline settings & color. --- assets/js/third-party/comments/waline3.js | 1 + exampleSite/config.yaml | 1 + 2 files changed, 2 insertions(+) diff --git a/assets/js/third-party/comments/waline3.js b/assets/js/third-party/comments/waline3.js index 82ab556..4219796 100644 --- a/assets/js/third-party/comments/waline3.js +++ b/assets/js/third-party/comments/waline3.js @@ -48,6 +48,7 @@ NexT.plugins.comments.waline3 = function () { requiredMeta : ${JSON.stringify(requiredmeta)}, reaction : ${reaction}, serverURL : '${serverurl}', + dark : 'html[data-theme="dark"]' }); NexT.utils.hiddeLodingCmp('${element}'); diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index ba291c9..5c703b4 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -842,6 +842,7 @@ params: # placeholder: "请文明发言哟 ヾ(≧▽≦*)o" # sofa: "快来发表你的意见吧 (≧∀≦)ゞ" # emoji: false + # search: true # imgUploader: false # wordLimit: 200 # requiredMeta: ['nick', 'mail'] From e6ee562996d04f93df922c2e8ae19088ca457597 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Mon, 5 Aug 2024 20:38:20 +0800 Subject: [PATCH 07/42] :sparkles::fire::lipstick: Remove sharethis & add others. --- .../_common/components/post/post-footer.scss | 18 ++++++++++++ assets/css/main.scss | 2 ++ assets/js/third-party/share/addthis.js | 16 ---------- assets/js/third-party/share/addtoany.js | 24 +++++++++++++++ assets/js/third-party/share/sharethis.js | 21 ++++++++++++++ data/resources.yaml | 8 +++-- exampleSite/config.yaml | 18 ++++++++---- .../partials/_thirdparty/share/addthis.html | 3 -- .../partials/_thirdparty/share/addtoany.html | 11 +++++++ .../partials/_thirdparty/share/sharethis.html | 1 + layouts/partials/init.html | 29 +++++++++++++++---- layouts/partials/post/footer.html | 17 +++++++++-- layouts/partials/scripts/global.html | 19 ++++++++++-- 13 files changed, 150 insertions(+), 37 deletions(-) delete mode 100644 assets/js/third-party/share/addthis.js create mode 100644 assets/js/third-party/share/addtoany.js create mode 100644 assets/js/third-party/share/sharethis.js delete mode 100644 layouts/partials/_thirdparty/share/addthis.html create mode 100644 layouts/partials/_thirdparty/share/addtoany.html create mode 100644 layouts/partials/_thirdparty/share/sharethis.html diff --git a/assets/css/_common/components/post/post-footer.scss b/assets/css/_common/components/post/post-footer.scss index a7aa412..5cb7f52 100644 --- a/assets/css/_common/components/post/post-footer.scss +++ b/assets/css/_common/components/post/post-footer.scss @@ -91,3 +91,21 @@ } } } + +@if $post_share_enable { + .post-share-tools { + display: flex; + justify-content: center; + + a { + border: 0px; + } + } + + @if $post_sharethis_set { + .st-cmp-settings { + display: none; + } + } +} + diff --git a/assets/css/main.scss b/assets/css/main.scss index 1865bbd..11fba61 100644 --- a/assets/css/main.scss +++ b/assets/css/main.scss @@ -85,6 +85,8 @@ $post_edit_enable : {{ $P.postEdit.enable }}; $post_meta_item_text : {{ $P.postMeta.itemText }}; $reward_settings_animation : {{ $P.rewardSets.animation }}; $post_end_tag_icon : {{ $P.postFooter.tagIcon }}; +$post_share_enable : {{ $P.share.enable }}; +$post_sharethis_set : {{ isset $P.share "sharethis" }}; // TODO find the paramters $text_align_desktop : {{ $P.textAlign.desktop }}; diff --git a/assets/js/third-party/share/addthis.js b/assets/js/third-party/share/addthis.js deleted file mode 100644 index 1bc88e3..0000000 --- a/assets/js/third-party/share/addthis.js +++ /dev/null @@ -1,16 +0,0 @@ -/* AddThis share plugin */ -NexT.plugins.share.addthis = function() { - const element = '.addthis_inline_share_toolbox'; - if (!NexT.CONFIG.addthis || !NexT.utils.checkDOMExist(element)) return; - - const addthis_js = NexT.CONFIG.addthis.js + '?pubid=' + NexT.CONFIG.addthis.cfg.pubid; - - NexT.utils.lazyLoadComponent(element, function() { - NexT.utils.getScript(addthis_js, { - attributes: { - async: false - }, - parentNode: document.querySelector(element) - }); - }); -} \ No newline at end of file diff --git a/assets/js/third-party/share/addtoany.js b/assets/js/third-party/share/addtoany.js new file mode 100644 index 0000000..950b0b1 --- /dev/null +++ b/assets/js/third-party/share/addtoany.js @@ -0,0 +1,24 @@ +/* Addtoany share plugin */ +NexT.plugins.share.addtoany = function() { + const element = '.a2a_kit'; + if (!NexT.CONFIG.share.enable || !NexT.utils.checkDOMExist(element)) return; + + const addtoany = NexT.CONFIG.share.addtoany; + + if (!addtoany) return; + + NexT.utils.lazyLoadComponent(element, function() { + let addtoany_cfg = ` + var a2a_config = a2a_config || {}; + a2a_config.onclick = 1; + a2a_config.locale = "${addtoany.locale}"; + a2a_config.num_services = ${addtoany.num}; + `; + + NexT.utils.getScript(null, { + textContent: addtoany_cfg + }); + + NexT.utils.getScript(addtoany.js, () => { NexT.utils.hiddeLodingCmp(element); }); + }); +} \ No newline at end of file diff --git a/assets/js/third-party/share/sharethis.js b/assets/js/third-party/share/sharethis.js new file mode 100644 index 0000000..8a78257 --- /dev/null +++ b/assets/js/third-party/share/sharethis.js @@ -0,0 +1,21 @@ +/* Sharethis share plugin */ +NexT.plugins.share.sharethis = function() { + const element = '.sharethis-inline-share-buttons'; + if (!NexT.CONFIG.share.enable || !NexT.utils.checkDOMExist(element)) return; + + const sharethis = NexT.CONFIG.share.sharethis; + + if (!sharethis) return; + + const sharethis_js = sharethis.js.replace(/id/, sharethis.id); + + NexT.utils.lazyLoadComponent(element, function() { + NexT.utils.getScript(sharethis_js, { + attributes: { + async: 'async' + } + }); + + NexT.utils.hiddeLodingCmp(element); + }); +} \ No newline at end of file diff --git a/data/resources.yaml b/data/resources.yaml index 2da1d7e..41c1148 100644 --- a/data/resources.yaml +++ b/data/resources.yaml @@ -90,8 +90,12 @@ analytics: # 文章分享 # Share -addthis: - js: https://s7.addthis.com/js/300/addthis_widget.js +share: + sharethis: + js: https://platform-api.sharethis.com/js/sharethis.js#property=id&product=inline-share-buttons&source=platform + + addtoany: + js: https://static.addtoany.com/menu/page.js # 评论组件 # Comment component diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 5c703b4..87ba743 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -935,11 +935,19 @@ params: id: # color: "#fc6423" - # AddThis文章分享功能(服务商已下线,不推荐使用) - # 更多信息及配置请参考:https://www.addthis.com - # AddThis Share (The service provider has been offline, not recommended for use) - # See: https://www.addthis.com - # addThisId: # + # 文章分享功能 + share: + enable: true + # 更多信息与配置,请参考:https://sharethis.com + # For more information and configuration, please refer to:https://sharethis.com + # sharethis: + # id: # + # 简单的在线分享,没有统计数据功能,更多信息可参考:https://www.addtoany.com/ + # Simple online sharing without statistical data function. + # For more information, please refer to: https://www.addtoany.com/ + addtoany: + locale: zh-CN + num_services: 8 # --------------------------------------------------------------- diff --git a/layouts/partials/_thirdparty/share/addthis.html b/layouts/partials/_thirdparty/share/addthis.html deleted file mode 100644 index 520e2e1..0000000 --- a/layouts/partials/_thirdparty/share/addthis.html +++ /dev/null @@ -1,3 +0,0 @@ -{{ if isset .Site.Params "addthisid" }} -
    -{{ end }} \ No newline at end of file diff --git a/layouts/partials/_thirdparty/share/addtoany.html b/layouts/partials/_thirdparty/share/addtoany.html new file mode 100644 index 0000000..f2a2718 --- /dev/null +++ b/layouts/partials/_thirdparty/share/addtoany.html @@ -0,0 +1,11 @@ +
    + + + + + + + + + +
    \ No newline at end of file diff --git a/layouts/partials/_thirdparty/share/sharethis.html b/layouts/partials/_thirdparty/share/sharethis.html new file mode 100644 index 0000000..74b3f22 --- /dev/null +++ b/layouts/partials/_thirdparty/share/sharethis.html @@ -0,0 +1 @@ +
    \ No newline at end of file diff --git a/layouts/partials/init.html b/layouts/partials/init.html index 5b16e82..1fe126d 100644 --- a/layouts/partials/init.html +++ b/layouts/partials/init.html @@ -139,12 +139,29 @@ {{ $config = merge $config (dict "utterances" $utterances) }} {{ end }} -{{ with .Site.Params.addThisId }} -{{ $addthis := dict - "js" $.Site.Data.resources.addthis.js - "cfg" (dict "pubid" .) -}} -{{ $config = merge $config (dict "addthis" $addthis) }} +{{ with .Site.Params.share }} + +{{ $share := dict "enable" .enable }} + +{{ if isset . "sharethis" }} + {{ $sharethis := dict + "js" $.Site.Data.resources.share.sharethis.js + "id" .sharethis.id + }} + {{ $share = merge $share (dict "sharethis" $sharethis) }} +{{ end }} + +{{ if isset . "addtoany" }} + {{ $addtoany := dict + "js" $.Site.Data.resources.share.addtoany.js + "locale" .addtoany.locale + "num" .addtoany.num_services + }} + + {{ $share = merge $share (dict "addtoany" $addtoany) }} +{{ end }} + +{{ $config = merge $config (dict "share" $share) }} {{ end }} {{ with .Site.Params.siteState.statistic }} diff --git a/layouts/partials/post/footer.html b/layouts/partials/post/footer.html index 5995722..1cda9eb 100644 --- a/layouts/partials/post/footer.html +++ b/layouts/partials/post/footer.html @@ -10,8 +10,21 @@
    {{ else }} {{ partial "post/footer_meta/tags.html" . }} -{{ if and (not (isset .Params "share")) (not .Params.share) }} -{{ partial "_thirdparty/share/addthis.html" . }} +{{ $enable := .Params.share | default .Site.Params.share.enable }} +{{ with .Site.Params.share }} + {{ if $enable }} +
    +
    + +
    + {{ if isset . "sharethis" }} + {{ partial "_thirdparty/share/sharethis.html" }} + {{ end }} + {{ if isset . "addtoany" }} + {{ partial "_thirdparty/share/addtoany.html" }} + {{ end }} +
    + {{ end }} {{ end }}
    {{ partial "post/footer_meta/reward.html" . }} diff --git a/layouts/partials/scripts/global.html b/layouts/partials/scripts/global.html index d017f2b..956dd88 100644 --- a/layouts/partials/scripts/global.html +++ b/layouts/partials/scripts/global.html @@ -40,9 +40,22 @@ {{ end }} {{/* Share scripts */}} -{{ if isset .Site.Params "addthisid" }} -{{ $addthisjs := resources.Get "js/third-party/share/addthis.js" }} -{{ $nextjs = $nextjs | append $addthisjs }} +{{/** if and .Site.Params.share.enable (isset .Site.Params "sharethisid") }} +{{ $sharethisjs := resources.Get "js/third-party/share/sharethis.js" }} +{{ $nextjs = $nextjs | append $sharethisjs }} +{{ end **/}} + +{{ with .Site.Params.share }} +{{ if or .enable .Params.share }} + {{ if isset . "sharethis" }} + {{ $sharethisjs := resources.Get "js/third-party/share/sharethis.js" }} + {{ $nextjs = $nextjs | append $sharethisjs }} + {{ end }} + {{ if isset . "addtoany" }} + {{ $addtoanyjs := resources.Get "js/third-party/share/addtoany.js" }} + {{ $nextjs = $nextjs | append $addtoanyjs }} + {{ end }} +{{ end }} {{ end }} {{/* Comments scripts */}} From ebd38a18aebefbaefbd4cf54f5813221bc560206 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Mon, 12 Aug 2024 21:26:02 +0800 Subject: [PATCH 08/42] :bug: Fixed the tags link 404 in post footer. --- layouts/_default/terms.html | 2 +- layouts/partials/post/footer_meta/tags.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html index 2559499..75d5b38 100644 --- a/layouts/_default/terms.html +++ b/layouts/_default/terms.html @@ -82,7 +82,7 @@
    {{ $randNums := (seq 10) }} {{- range $name, $items := $tags }} - {{ .Page.Title }} + {{ .Page.Title }} ({{ len $items }}) diff --git a/layouts/partials/post/footer_meta/tags.html b/layouts/partials/post/footer_meta/tags.html index 81c71a8..8bed5a0 100644 --- a/layouts/partials/post/footer_meta/tags.html +++ b/layouts/partials/post/footer_meta/tags.html @@ -1,7 +1,7 @@ {{ with .Params.tags }} \n \n
    \n
    \n
    \n
    \n
    \n
    \n'):(t+='\n
    \n
    \n
    ',t+=s.play,t+='
    \n
    \n
    \n
    \n No audio\n \n
    \n
    \n
    \n
    \n
    \n
    \n
    \n
    \n
    \n \n ',t+=s.loading,t+='\n \n
    \n
    \n
    \n
    \n \n 00:00 / 00:00\n \n \n ',t+=s.skip,t+='\n \n \n ',t+=s.play,t+='\n \n \n ',t+=s.skip,t+='\n \n
    \n \n
    \n
    \n
    \n
    \n
    \n
    \n \n \n \n \n
    \n
    \n
    \n
    \n
    \n
    \n
    \n '},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t){e.exports=''},function(e,t,n){"use strict";var i,a,r=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function l(e){if(i===setTimeout)return setTimeout(e,0);if((i===o||!i)&&setTimeout)return i=setTimeout,setTimeout(e,0);try{return i(e,0)}catch(t){try{return i.call(null,e,0)}catch(t){return i.call(this,e,0)}}}!function(){try{i="function"==typeof setTimeout?setTimeout:o}catch(e){i=o}try{a="function"==typeof clearTimeout?clearTimeout:s}catch(e){a=s}}();var u,c=[],p=!1,d=-1;function h(){p&&u&&(p=!1,u.length?c=u.concat(c):d=-1,c.length&&y())}function y(){if(!p){var e=l(h);p=!0;for(var t=c.length;t;){for(u=c,c=[];++d1)for(var n=1;n=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},n(35),t.setImmediate=setImmediate,t.clearImmediate=clearImmediate},function(e,t,n){"use strict";(function(t){var n="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},i=setTimeout;function a(){}function r(e){if(!(this instanceof r))throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],c(e,this)}function o(e,t){for(;3===e._state;)e=e._value;0!==e._state?(e._handled=!0,r._immediateFn(function(){var n=1===e._state?t.onFulfilled:t.onRejected;if(null!==n){var i;try{i=n(e._value)}catch(e){return void l(t.promise,e)}s(t.promise,i)}else(1===e._state?s:l)(t.promise,e._value)})):e._deferreds.push(t)}function s(e,t){try{if(t===e)throw new TypeError("A promise cannot be resolved with itself.");if(t&&("object"===(void 0===t?"undefined":n(t))||"function"==typeof t)){var i=t.then;if(t instanceof r)return e._state=3,e._value=t,void u(e);if("function"==typeof i)return void c((a=i,o=t,function(){a.apply(o,arguments)}),e)}e._state=1,e._value=t,u(e)}catch(t){l(e,t)}var a,o}function l(e,t){e._state=2,e._value=t,u(e)}function u(e){2===e._state&&0===e._deferreds.length&&r._immediateFn(function(){e._handled||r._unhandledRejectionFn(e._value)});for(var t=0,n=e._deferreds.length;t1&&this.container.classList.add("aplayer-withlist"),r.default.isMobile&&this.container.classList.add("aplayer-mobile"),this.arrow=this.container.offsetWidth<=300,this.arrow&&this.container.classList.add("aplayer-arrow"),this.container=this.options.container,2===this.options.lrcType||!0===this.options.lrcType)for(var n=this.container.getElementsByClassName("aplayer-lrc-content"),i=0;i1?(e.notice("An audio error has occurred, player will skip forward in 2 seconds."),t=setTimeout(function(){e.skipForward(),e.paused||e.play()},2e3)):1===e.list.audios.length&&e.notice("An audio error has occurred.")}),this.events.on("listswitch",function(){t&&clearTimeout(t)}),this.on("ended",function(){"none"===e.options.loop?"list"===e.options.order?e.list.index0&&void 0!==arguments[0]?arguments[0]:this.list.audios[this.list.index].theme||this.options.theme,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.list.index;(!(arguments.length>2&&void 0!==arguments[2])||arguments[2])&&this.list.audios[t]&&(this.list.audios[t].theme=e),this.template.listCurs[t]&&(this.template.listCurs[t].style.backgroundColor=e),t===this.list.index&&(this.template.pic.style.backgroundColor=e,this.template.played.style.background=e,this.template.thumb.style.background=e,this.template.volume.style.background=e)}},{key:"seek",value:function(e){e=Math.max(e,0),e=Math.min(e,this.duration),this.audio.currentTime=e,this.bar.set("played",e/this.duration,"width"),this.template.ptime.innerHTML=r.default.secondToTime(e)}},{key:"setUIPlaying",value:function(){var e=this;if(this.paused&&(this.paused=!1,this.template.button.classList.remove("aplayer-play"),this.template.button.classList.add("aplayer-pause"),this.template.button.innerHTML="",setTimeout(function(){e.template.button.innerHTML=o.default.pause},100),this.template.skipPlayButton.innerHTML=o.default.pause),this.timer.enable("loading"),this.options.mutex)for(var t=0;t=.95?this.template.volumeButton.innerHTML=o.default.volumeUp:this.volume()>0?this.template.volumeButton.innerHTML=o.default.volumeDown:this.template.volumeButton.innerHTML=o.default.volumeOff}},{key:"volume",value:function(e,t){return e=parseFloat(e),isNaN(e)||(e=Math.max(e,0),e=Math.min(e,1),this.bar.set("volume",e,"height"),t||this.storage.set("volume",e),this.audio.volume=e,this.audio.muted&&(this.audio.muted=!1),this.switchVolumeIcon()),this.audio.muted?0:this.audio.volume}},{key:"on",value:function(e,t){this.events.on(e,t)}},{key:"toggle",value:function(){this.template.button.classList.contains("aplayer-play")?this.play():this.template.button.classList.contains("aplayer-pause")&&this.pause()}},{key:"switchAudio",value:function(e){this.list.switch(e)}},{key:"addAudio",value:function(e){this.list.add(e)}},{key:"removeAudio",value:function(e){this.list.remove(e)}},{key:"destroy",value:function(){m.splice(m.indexOf(this),1),this.pause(),this.container.innerHTML="",this.audio.src="",this.timer.destroy(),this.events.trigger("destroy")}},{key:"setMode",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"normal";this.mode=e,"mini"===e?this.container.classList.add("aplayer-narrow"):"normal"===e&&this.container.classList.remove("aplayer-narrow")}},{key:"notice",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2e3,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:.8;this.template.notice.innerHTML=e,this.template.notice.style.opacity=i,this.noticeTime&&clearTimeout(this.noticeTime),this.events.trigger("noticeshow",{text:e}),n&&(this.noticeTime=setTimeout(function(){t.template.notice.style.opacity=0,t.events.trigger("noticehide")},n))}},{key:"prevIndex",value:function(){if(!(this.list.audios.length>1))return 0;if("list"===this.options.order)return this.list.index-1<0?this.list.audios.length-1:this.list.index-1;if("random"===this.options.order){var e=this.randomOrder.indexOf(this.list.index);return 0===e?this.randomOrder[this.randomOrder.length-1]:this.randomOrder[e-1]}}},{key:"nextIndex",value:function(){if(!(this.list.audios.length>1))return 0;if("list"===this.options.order)return(this.list.index+1)%this.list.audios.length;if("random"===this.options.order){var e=this.randomOrder.indexOf(this.list.index);return e===this.randomOrder.length-1?this.randomOrder[0]:this.randomOrder[e+1]}}},{key:"skipBack",value:function(){this.list.switch(this.prevIndex())}},{key:"skipForward",value:function(){this.list.switch(this.nextIndex())}},{key:"duration",get:function(){return isNaN(this.audio.duration)?0:this.audio.duration}}],[{key:"version",get:function(){return"1.10.1"}}]),e}();t.default=g},,function(e,t,n){},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n(40);var i,a=n(38),r=(i=a)&&i.__esModule?i:{default:i};console.log("\n %c APlayer v1.10.1 af84efb %c http://aplayer.js.org \n","color: #fadfa3; background: #030307; padding:5px 0;","background: #fadfa3; padding:5px 0;"),t.default=r.default}]).default}); \ No newline at end of file diff --git a/static/3rd/artalk/2.6.4/Artalk.min.css b/static/js/3rd/artalk/2.6.4/Artalk.min.css similarity index 100% rename from static/3rd/artalk/2.6.4/Artalk.min.css rename to static/js/3rd/artalk/2.6.4/Artalk.min.css diff --git a/static/3rd/artalk/2.6.4/Artalk.min.js b/static/js/3rd/artalk/2.6.4/Artalk.min.js similarity index 100% rename from static/3rd/artalk/2.6.4/Artalk.min.js rename to static/js/3rd/artalk/2.6.4/Artalk.min.js diff --git a/static/3rd/auto-render/0.16.11/contrib/auto-render.min.js b/static/js/3rd/auto-render/0.16.11/contrib/auto-render.min.js similarity index 100% rename from static/3rd/auto-render/0.16.11/contrib/auto-render.min.js rename to static/js/3rd/auto-render/0.16.11/contrib/auto-render.min.js diff --git a/static/js/3rd/dn.txt b/static/js/3rd/dn.txt new file mode 100644 index 0000000..9b21ee7 --- /dev/null +++ b/static/js/3rd/dn.txt @@ -0,0 +1,3 @@ +https://unpkg.com/meting@2.0.1/dist/Meting.min.js +https://unpkg.com/browse/aplayer@1.10.1/dist/APlayer.min.js +https://unpkg.com/browse/aplayer@1.10.1/dist/APlayer.min.css diff --git a/static/3rd/font-awesome/6.7.2/css/all.min.css b/static/js/3rd/font-awesome/6.7.2/css/all.min.css similarity index 100% rename from static/3rd/font-awesome/6.7.2/css/all.min.css rename to static/js/3rd/font-awesome/6.7.2/css/all.min.css diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.ttf b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.ttf similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.ttf rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.ttf diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.woff2 b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.woff2 similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.woff2 rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-brands-400.woff2 diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.ttf b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.ttf similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.ttf rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.ttf diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.woff2 b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.woff2 similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.woff2 rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-regular-400.woff2 diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.ttf b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.ttf similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.ttf rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.ttf diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.woff2 b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.woff2 similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.woff2 rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-solid-900.woff2 diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.ttf b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.ttf similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.ttf rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.ttf diff --git a/static/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.woff2 b/static/js/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.woff2 similarity index 100% rename from static/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.woff2 rename to static/js/3rd/font-awesome/6.7.2/webfonts/fa-v4compatibility.woff2 diff --git a/static/3rd/instantsearch.js/4.73.2/instantsearch.production.min.js b/static/js/3rd/instantsearch.js/4.73.2/instantsearch.production.min.js similarity index 100% rename from static/3rd/instantsearch.js/4.73.2/instantsearch.production.min.js rename to static/js/3rd/instantsearch.js/4.73.2/instantsearch.production.min.js diff --git a/static/3rd/katex/0.16.15/contrib/auto-render.min.js b/static/js/3rd/katex/0.16.15/contrib/auto-render.min.js similarity index 100% rename from static/3rd/katex/0.16.15/contrib/auto-render.min.js rename to static/js/3rd/katex/0.16.15/contrib/auto-render.min.js diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_AMS-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Bold.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Caligraphic-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Bold.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Fraktur-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Bold.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-BoldItalic.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Italic.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Main-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-BoldItalic.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Math-Italic.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Bold.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Italic.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_SansSerif-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Script-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size1-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size2-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size3-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Size4-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.ttf b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.ttf similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.ttf rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.ttf diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff diff --git a/static/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff2 b/static/js/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff2 similarity index 100% rename from static/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff2 rename to static/js/3rd/katex/0.16.15/fonts/KaTeX_Typewriter-Regular.woff2 diff --git a/static/3rd/katex/0.16.15/katex.min.css b/static/js/3rd/katex/0.16.15/katex.min.css similarity index 100% rename from static/3rd/katex/0.16.15/katex.min.css rename to static/js/3rd/katex/0.16.15/katex.min.css diff --git a/static/3rd/katex/0.16.15/katex.min.js b/static/js/3rd/katex/0.16.15/katex.min.js similarity index 100% rename from static/3rd/katex/0.16.15/katex.min.js rename to static/js/3rd/katex/0.16.15/katex.min.js diff --git a/static/3rd/mathjax/3.2.2/es5/tex-mml-svg.min.js b/static/js/3rd/mathjax/3.2.2/es5/tex-mml-svg.min.js similarity index 100% rename from static/3rd/mathjax/3.2.2/es5/tex-mml-svg.min.js rename to static/js/3rd/mathjax/3.2.2/es5/tex-mml-svg.min.js diff --git a/static/3rd/mermaid/10.9.1/mermaid.min.js b/static/js/3rd/mermaid/10.9.1/mermaid.min.js similarity index 100% rename from static/3rd/mermaid/10.9.1/mermaid.min.js rename to static/js/3rd/mermaid/10.9.1/mermaid.min.js diff --git a/static/js/3rd/meting/2.0.1/Meting.min.js b/static/js/3rd/meting/2.0.1/Meting.min.js new file mode 100644 index 0000000..da4394a --- /dev/null +++ b/static/js/3rd/meting/2.0.1/Meting.min.js @@ -0,0 +1 @@ +"use strict";function _objectSpread(a){for(var b=1;bb.toUpperCase())}_init(){let a={};for(let b=0;ba.json()).then(a=>this._loadPlayer(a))}_loadPlayer(a){let b={audio:a,mutex:!0,lrcType:this.meta.lrcType||3,storageName:"metingjs"};if(a.length){let a=_objectSpread({},b,this.config);for(let b in a)("true"===a[b]||"false"===a[b])&&(a[b]="true"===a[b]);let c=document.createElement("div");a.container=c,this.appendChild(c),this.aplayer=new APlayer(a)}}}console.log("\n %c MetingJS v2.0.1 %c https://github.com/metowolf/MetingJS \n","color: #fadfa3; background: #030307; padding:5px 0;","background: #fadfa3; padding:5px 0;"),window.customElements&&!window.customElements.get("meting-js")&&(window.MetingJSElement=MetingJSElement,window.customElements.define("meting-js",MetingJSElement)); \ No newline at end of file diff --git a/static/3rd/viewerjs/1.11.6/viewer.min.css b/static/js/3rd/viewerjs/1.11.6/viewer.min.css similarity index 100% rename from static/3rd/viewerjs/1.11.6/viewer.min.css rename to static/js/3rd/viewerjs/1.11.6/viewer.min.css diff --git a/static/3rd/viewerjs/1.11.6/viewer.min.js b/static/js/3rd/viewerjs/1.11.6/viewer.min.js similarity index 100% rename from static/3rd/viewerjs/1.11.6/viewer.min.js rename to static/js/3rd/viewerjs/1.11.6/viewer.min.js diff --git a/static/3rd/waline/2.15.8/comment.min.js b/static/js/3rd/waline/2.15.8/comment.min.js similarity index 100% rename from static/3rd/waline/2.15.8/comment.min.js rename to static/js/3rd/waline/2.15.8/comment.min.js diff --git a/static/3rd/waline/2.15.8/pageview.min.js b/static/js/3rd/waline/2.15.8/pageview.min.js similarity index 100% rename from static/3rd/waline/2.15.8/pageview.min.js rename to static/js/3rd/waline/2.15.8/pageview.min.js diff --git a/static/3rd/waline/2.15.8/waline.css b/static/js/3rd/waline/2.15.8/waline.css similarity index 100% rename from static/3rd/waline/2.15.8/waline.css rename to static/js/3rd/waline/2.15.8/waline.css diff --git a/static/3rd/waline/2.15.8/waline.min.js b/static/js/3rd/waline/2.15.8/waline.min.js similarity index 100% rename from static/3rd/waline/2.15.8/waline.min.js rename to static/js/3rd/waline/2.15.8/waline.min.js diff --git a/static/3rd/waline/3.3.0/comment.min.js b/static/js/3rd/waline/3.3.0/comment.min.js similarity index 100% rename from static/3rd/waline/3.3.0/comment.min.js rename to static/js/3rd/waline/3.3.0/comment.min.js diff --git a/static/3rd/waline/3.3.0/pageview.min.js b/static/js/3rd/waline/3.3.0/pageview.min.js similarity index 100% rename from static/3rd/waline/3.3.0/pageview.min.js rename to static/js/3rd/waline/3.3.0/pageview.min.js diff --git a/static/3rd/waline/3.3.0/waline.min.css b/static/js/3rd/waline/3.3.0/waline.min.css similarity index 100% rename from static/3rd/waline/3.3.0/waline.min.css rename to static/js/3rd/waline/3.3.0/waline.min.css diff --git a/static/3rd/waline/3.3.0/waline.min.js b/static/js/3rd/waline/3.3.0/waline.min.js similarity index 100% rename from static/3rd/waline/3.3.0/waline.min.js rename to static/js/3rd/waline/3.3.0/waline.min.js diff --git a/static/3rd/waline/3.3.0/waline.umd.min.js b/static/js/3rd/waline/3.3.0/waline.umd.min.js similarity index 100% rename from static/3rd/waline/3.3.0/waline.umd.min.js rename to static/js/3rd/waline/3.3.0/waline.umd.min.js diff --git a/static/js/index.js b/static/js/index.js deleted file mode 100644 index 6975cf0..0000000 --- a/static/js/index.js +++ /dev/null @@ -1 +0,0 @@ -// TODO keep the js folder \ No newline at end of file From b2e0be5a6ab7d90cfb54096e3d9f97e830555f3a Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Wed, 15 Jan 2025 21:42:22 +0800 Subject: [PATCH 25/42] :sparkles: Use store method impl the music etc shortcode. --- assets/js/utils.js | 4 +-- exampleSite/content/post/mermaid-charts.md | 2 -- exampleSite/content/post/shortcodes.md | 16 +++++------- exampleSite/static/music/gongqijun.jpg | Bin 0 -> 5754 bytes exampleSite/static/music/sky.mp3 | Bin 0 -> 41708 bytes layouts/partials/head.html | 4 +-- layouts/partials/head/config.html | 24 ++++++++++++++---- .../partials/head/{ => script}/analytics.html | 0 .../{scripts => head/script}/global.html | 0 .../{scripts => head/script}/plugins.html | 10 +++++++- layouts/partials/head/style/global.html | 3 +++ layouts/partials/head/style/plugins.html | 13 ++++++++++ .../partials/head/{style.html => styles.html} | 14 +++++----- layouts/partials/scripts.html | 4 +-- layouts/shortcodes/mermaid.html | 4 ++- layouts/shortcodes/music.html | 4 ++- 16 files changed, 70 insertions(+), 32 deletions(-) create mode 100644 exampleSite/static/music/gongqijun.jpg create mode 100644 exampleSite/static/music/sky.mp3 rename layouts/partials/head/{ => script}/analytics.html (100%) rename layouts/partials/{scripts => head/script}/global.html (100%) rename layouts/partials/{scripts => head/script}/plugins.html (60%) create mode 100644 layouts/partials/head/style/global.html create mode 100644 layouts/partials/head/style/plugins.html rename layouts/partials/head/{style.html => styles.html} (87%) diff --git a/assets/js/utils.js b/assets/js/utils.js index bd15af3..a8c0778 100644 --- a/assets/js/utils.js +++ b/assets/js/utils.js @@ -9,10 +9,10 @@ HTMLElement.prototype.wrap = function (wrapper) { NexT.utils = { registerAPlayer: function () { this.getStyle( - NexT.utils.getCDNResource(NexT.CONFIG.page.aplayer.css) + NexT.utils.getCDNResource(NexT.CONFIG.page.music.css) ); - NexT.CONFIG.page.aplayer.js.forEach(function (js) { + NexT.CONFIG.page.music.js.forEach(function (js) { NexT.utils.getScript(NexT.utils.getCDNResource(js), true); }); diff --git a/exampleSite/content/post/mermaid-charts.md b/exampleSite/content/post/mermaid-charts.md index cf426ac..b5a19fe 100644 --- a/exampleSite/content/post/mermaid-charts.md +++ b/exampleSite/content/post/mermaid-charts.md @@ -14,7 +14,6 @@ tags: - 时序图 url: "demo/mermaid-charts.html" -mermaid: true toc: true --- @@ -28,7 +27,6 @@ toc: true {{< note info >}} - 通过 `hugo new` 命令创建一篇新的文章 -- 在文章头部配置 `mermaid: true` - 使用短代码书写各种类型的图,自带2个参数: align(对齐) 和 bc(背景色),可参考如下使用示例 {{< /note >}} diff --git a/exampleSite/content/post/shortcodes.md b/exampleSite/content/post/shortcodes.md index 2f61483..01c9fd7 100644 --- a/exampleSite/content/post/shortcodes.md +++ b/exampleSite/content/post/shortcodes.md @@ -14,7 +14,6 @@ tags: - 语法 url: "demo/shortcodes.html" toc: true -music: true --- 虽然 `Markdown` 语法已经非常丰富能够满足我们写文章的绝大部分需求,但是为更好的对文章内容进行更友好的排版,为引设计一套自定义的短语,便于在使用时能够快速引用。 @@ -101,7 +100,7 @@ music: true 或者 {{}} ``` -{{}} +{{< bilibili id=BV1Sx411T7QQ >}} ## 音乐播放器 @@ -131,23 +130,22 @@ music: true ### 单曲播放 ```markdown -{{}} +{{}} ``` -{{< music theme="#2980b9" server="netease" type="song" id="1868553" mini="true" >}} +{{< music theme="#2980b9" server="tencent" type="song" id="002u4ZTb0CXmJA" mini="true" >}} ### 列表播放 ```markdown -{{}} +{{}} ``` -{{< music server="netease" type="playlist" id="769332917" list-max-height="140px" >}} - +{{< music server="netease" type="playlist" id="1982066521" list-max-height="140px" >}} ### 自定义音乐源 ```markdown -{{}} +{{}} ``` -{{< music url="https://ri-sycdn.kuwo.cn/ea345253b94e7ad564e6fb0cdf37fee6/677b6574/resource/n1/87/56/4272600974.mp3" name="天空之城" artist="宫崎骏" cover="http://img4.kuwo.cn/star/starheads/500/27/66/2532818318.jpg" autoplay="true" >}} +{{< music url="/music/sky.mp3" name="天空之城" artist="宫崎骏" cover="/music/gongqijun.jpg" autoplay="true" >}} diff --git a/exampleSite/static/music/gongqijun.jpg b/exampleSite/static/music/gongqijun.jpg new file mode 100644 index 0000000000000000000000000000000000000000..4aa1edc8190f3c79e44a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}} +{{ partialCached "head/script/analytics.html" . }} diff --git a/layouts/partials/head/config.html b/layouts/partials/head/config.html index d0448e8..09ba67b 100644 --- a/layouts/partials/head/config.html +++ b/layouts/partials/head/config.html @@ -1,21 +1,24 @@ + +{{/** Short code params **/}} +{{ $scParam := .Store.Get "scParams" }} + {{ $pageCfg := dict "isHome" .IsHome "isPage" .IsPage "comments" (.Scratch.Get "isComment") "toc" (default .Site.Params.toc.enable .Params.Toc) - "music" .Params.music "permalink" (.Page.Permalink | absURL) "path" (.Page.Permalink | path.Base) "title" .Page.Title }} {{/** Append APlayer plugin */}} -{{ if .Params.music }} +{{ if $scParam.music }} {{ $aplayer := dict "js" $.Site.Data.resources.plugins.music.js "css" $.Site.Data.resources.plugins.music.css }} -{{ $pageCfg = merge $pageCfg (dict "aplayer" $aplayer) }} +{{ $pageCfg = merge $pageCfg (dict "music" $aplayer) }} {{ end }} {{/* Append post expired config */}} @@ -51,7 +54,7 @@ {{ end }} {{/* Append mermaid plugin */}} -{{ if .Params.mermaid }} +{{ if $scParam.mermaid }} {{ $mermaid := dict "js" .Site.Data.resources.plugins.mermaid.js }} @@ -72,4 +75,15 @@ {{ $pageCfg = merge $pageCfg (dict "math" $math) }} {{ end }} - \ No newline at end of file + + +{{/** Special CSS Style for page **/}} +{{ if .IsPage }} + +{{ end }} \ No newline at end of file diff --git a/layouts/partials/head/analytics.html b/layouts/partials/head/script/analytics.html similarity index 100% rename from layouts/partials/head/analytics.html rename to layouts/partials/head/script/analytics.html diff --git a/layouts/partials/scripts/global.html b/layouts/partials/head/script/global.html similarity index 100% rename from layouts/partials/scripts/global.html rename to layouts/partials/head/script/global.html diff --git a/layouts/partials/scripts/plugins.html b/layouts/partials/head/script/plugins.html similarity index 60% rename from layouts/partials/scripts/plugins.html rename to layouts/partials/head/script/plugins.html index 4587138..184b90d 100644 --- a/layouts/partials/scripts/plugins.html +++ b/layouts/partials/head/script/plugins.html @@ -1,9 +1,17 @@ {{/* Defind loading plugin scripts which only need in pages */}} +{{ if .IsPage }} +{{/** Short code params **/}} +{{ $scParam := .Store.Get "scParams" }} + +{{/** Append math render action **/}} {{ if or .Params.math .Site.Params.math }} {{ partial "_funs/get_plugin.html" (dict "ctx" . "class" "others" "plugin" "math.js") }} {{ end }} -{{ if .Params.mermaid }} +{{/** Append mermaid render action **/}} +{{ if $scParam.mermaid }} {{ partial "_funs/get_plugin.html" (dict "ctx" . "class" "others" "plugin" "mermaid.js") }} +{{ end }} + {{ end }} \ No newline at end of file diff --git a/layouts/partials/head/style/global.html b/layouts/partials/head/style/global.html new file mode 100644 index 0000000..5d3ff7b --- /dev/null +++ b/layouts/partials/head/style/global.html @@ -0,0 +1,3 @@ +.post-footer, .flinks-list-footer hr:after { + content: "{{ .Site.Params.postFooter.endLineTip }}"; +} \ No newline at end of file diff --git a/layouts/partials/head/style/plugins.html b/layouts/partials/head/style/plugins.html new file mode 100644 index 0000000..bcf7286 --- /dev/null +++ b/layouts/partials/head/style/plugins.html @@ -0,0 +1,13 @@ +{{/* Defind loading plugin entend style which only need in pages */}} +{{ if .IsPage }} + +{{/** Short code params **/}} +{{ $scParam := .Store.Get "scParams" }} + +{{ if $scParam.mermaid }} +.post-block .post-body .mermaid { + background: var(--highlight-foreground); +} +{{ end }} + +{{ end }} \ No newline at end of file diff --git a/layouts/partials/head/style.html b/layouts/partials/head/styles.html similarity index 87% rename from layouts/partials/head/style.html rename to layouts/partials/head/styles.html index cb96efc..6ac92d9 100644 --- a/layouts/partials/head/style.html +++ b/layouts/partials/head/styles.html @@ -17,14 +17,14 @@ {{ end }} {{ $unixHref := partial "_funs/add_unix_param.html" $css.RelPermalink }} -{{ if .IsPage }} - -{{ end }} + + + + {{ $custom := .Scratch.Get "style" }} {{ if $custom }} {{ $unixHref := partial "_funs/add_unix_param.html" $custom }} diff --git a/layouts/partials/scripts.html b/layouts/partials/scripts.html index 3f5d575..7ab93de 100644 --- a/layouts/partials/scripts.html +++ b/layouts/partials/scripts.html @@ -1,2 +1,2 @@ -{{ partialCached "scripts/global.html" . }} -{{ partial "scripts/plugins.html" . }} \ No newline at end of file +{{ partialCached "head/script/global.html" . }} +{{ partial "head/script/plugins.html" . }} \ No newline at end of file diff --git a/layouts/shortcodes/mermaid.html b/layouts/shortcodes/mermaid.html index d6aa690..4ffed72 100644 --- a/layouts/shortcodes/mermaid.html +++ b/layouts/shortcodes/mermaid.html @@ -1,3 +1,5 @@
    {{ safeHTML .Inner }} -
    \ No newline at end of file +
    + +{{ .Page.Store.SetInMap "scParams" "mermaid" true }} \ No newline at end of file diff --git a/layouts/shortcodes/music.html b/layouts/shortcodes/music.html index 3512921..73b6f3e 100644 --- a/layouts/shortcodes/music.html +++ b/layouts/shortcodes/music.html @@ -19,4 +19,6 @@ {{ with .Get "mutex" }} mutex="{{ . }}" {{ end }} {{ with .Get "list-folded" }} list-folded="{{ . }}" {{ end }} {{ with .Get "list-max-height" }} list-max-height="{{ . }}" {{ end }} - > \ No newline at end of file + > + +{{ .Page.Store.SetInMap "scParams" "music" true }} \ No newline at end of file From 9cd3e0bf68480484f2334ee513f37fa771a3de6c Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Thu, 16 Jan 2025 08:50:54 +0800 Subject: [PATCH 26/42] :lipstick: Closed #154, Add margin top pixes layout in small screen. --- assets/css/_common/outline/mobile.scss | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/assets/css/_common/outline/mobile.scss b/assets/css/_common/outline/mobile.scss index 8282056..63bc6c9 100644 --- a/assets/css/_common/outline/mobile.scss +++ b/assets/css/_common/outline/mobile.scss @@ -20,7 +20,10 @@ } .post-block { - margin-top: initial !important; + //margin-top: initial !important; + // https://github.com/hugo-next/hugo-theme-next/issues/154 + // make the post block more clear in small screen + margin-top: 5px !important; // Inside posts blocks content padding (default 40px). padding: $content-mobile-padding 18px $content-mobile-padding !important; } From ba5ae7c295a29f11661315d844f90bb979e209d6 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Sat, 18 Jan 2025 22:06:49 +0800 Subject: [PATCH 27/42] :lipstick: Closed #111, add post summary show. --- assets/css/_colors.scss | 4 ++ .../_common/components/post/post-body.scss | 37 ++++++++++++++++++- assets/css/_variables/base.scss | 4 +- exampleSite/config.yaml | 3 ++ exampleSite/content/post/no-header-title.md | 1 + i18n/en.yaml | 2 + i18n/fr.yaml | 2 + i18n/zh-cn.yaml | 2 + i18n/zh-tw.yaml | 3 +- layouts/partials/post/body.html | 14 +++++++ 10 files changed, 68 insertions(+), 4 deletions(-) diff --git a/assets/css/_colors.scss b/assets/css/_colors.scss index 62b163b..85a3128 100644 --- a/assets/css/_colors.scss +++ b/assets/css/_colors.scss @@ -14,6 +14,8 @@ --menu-item-bg-color: #{$menu-item-bg-color}; --theme-color: #{$theme-color}; + --border-color: #{$border-color}; + --btn-default-bg: #{$btn-default-bg}; --btn-default-color: #{$btn-default-color}; --btn-default-border-color: #{$btn-default-border-color}; @@ -46,6 +48,8 @@ --menu-item-bg-color: #{$menu-item-bg-color-dark}; --theme-color: #{$theme-color-dark}; + --border-color: #{$border-color-dark}; + --btn-default-bg: #{$btn-default-bg-dark}; --btn-default-color: #{$btn-default-color-dark}; --btn-default-border-color: #{$btn-default-border-color-dark}; diff --git a/assets/css/_common/components/post/post-body.scss b/assets/css/_common/components/post/post-body.scss index d084853..c9fbdc3 100644 --- a/assets/css/_common/components/post/post-body.scss +++ b/assets/css/_common/components/post/post-body.scss @@ -86,11 +86,19 @@ visibility: hidden; } + /** Defined speical border properties for top card of post **/ + $speical-border-width: 5px; + $speical-border-radius: 8px; .post-expired-tip { - font-size: 0.825em; + $expired-color: #4A90E2; + + font-size: var(--font-size-small); border: 1px solid #4A90E2; - border-left: 6px solid #4A90E2; + border-radius: $speical-border-radius; + border-left: $speical-border-width solid #4A90E2; + border-top: $speical-border-width solid #4A90E2; + box-shadow: .6rem .5rem 0.3rem var(--body-bg-color); margin: 0 0 0.85em 0; padding: 0.65em 0.15em 0.65em 0.95em; display: none; @@ -108,5 +116,30 @@ } } + .post-summary-wrapper { + $summary-color: #ea6733; + + margin: 0 0 .85em 0; + border-radius: $speical-border-radius; + border: 1px solid $summary-color; + border-right: $speical-border-width solid $summary-color; + border-bottom: $speical-border-width solid $summary-color; + box-shadow: .6rem .5rem 0.3rem var(--body-bg-color); + + .summary-title { + margin: .65em .93em 0 .93em; + color: $summary-color; + font-weight: bold; + } + + .summary-content { + background-color: var(--card-bg-color); + border-radius: $speical-border-radius; + box-shadow: .08rem .06rem 0.03rem var(--body-bg-color); + margin: .85em; + padding: .85em .95em; + } + } + @import 'post-alert'; } diff --git a/assets/css/_variables/base.scss b/assets/css/_variables/base.scss index f41ea0a..ac11f59 100644 --- a/assets/css/_variables/base.scss +++ b/assets/css/_variables/base.scss @@ -13,6 +13,7 @@ $grey-lighter : #ddd; $grey-light : #ccc; $grey : #bbb; $grey-dark : #999; +$grey-cnt : #5c5c5c; $grey-dim : #666; $black-light : #555; $black-dim : #333; @@ -49,7 +50,8 @@ $blockquote-color : $grey-dim; $blockquote-color-dark : $grey; // Global border color. -$border-color : $grey-light; +$border-color : $grey-dark; +$border-color-dark : $grey-lighter; // Background color for $body-bg-color : white; diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 9682ff1..ffc19d5 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -498,6 +498,9 @@ params: # 是否开启过期提示 # Expired tip expired: false + # 是否开启摘要显示 + # Enable summary + summary: false # 文章内容中的提示信息设置 # Alert settings in post content diff --git a/exampleSite/content/post/no-header-title.md b/exampleSite/content/post/no-header-title.md index 0aa4629..63b96e3 100644 --- a/exampleSite/content/post/no-header-title.md +++ b/exampleSite/content/post/no-header-title.md @@ -1,6 +1,7 @@ --- title: "没有H1-6标题头和评论的文章" description: "用于测试在没有H1-6标题头时,文章的目录导航是否会直接关闭,并关闭评论功能。" +summary: "用于测试在没有H1-6标题头时,文章的目录导航是否会直接关闭,并关闭评论功能,同时也是展现下有关于文章的摘要功能。" keywords: "toc,header" date: 2022-10-06T09:02:26+08:00 diff --git a/i18n/en.yaml b/i18n/en.yaml index 85e3d17..0851315 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -75,6 +75,8 @@ PostMeta: title: "Note" info: "🕰️ Hey,This article is an aged wine of over # the information may need updating, please check the best before date before reading." warn: "🚀 Heads up! This article is from # ago and might not keep up with the pace of time. Bring your own time machine for reading, watch out for the time travel!" + summary: + title: Summary PostAlert: info : "Info" diff --git a/i18n/fr.yaml b/i18n/fr.yaml index 673a00b..c23bffe 100644 --- a/i18n/fr.yaml +++ b/i18n/fr.yaml @@ -74,6 +74,8 @@ PostMeta: title: "Astuce bienveillante" info: "🕰️ Hey,This article is an aged wine of over # the information may need updating, please check the best before date before reading." warn: "🚀 Heads up! this article is from # ago and might not keep up with the pace of time. Bring your own time machine for reading, watch out for the time travel!" + summary: + title: Summary PostAlert: info : "Info" diff --git a/i18n/zh-cn.yaml b/i18n/zh-cn.yaml index 440ba74..cdc328c 100644 --- a/i18n/zh-cn.yaml +++ b/i18n/zh-cn.yaml @@ -75,6 +75,8 @@ PostMeta: title: "温馨提醒" info: "🕰️ 嗨,这篇文章已是#前的陈年佳酿,信息可能需要更新,阅读前请检查最佳赏味期限。" warn: "🚀 注意啦!这篇文章来自#以前,可能已跟不上时代的步伐。阅读时请自备时光机,小心穿越哦!" + summary: + title: 总结摘要 PostAlert: info : "信息" diff --git a/i18n/zh-tw.yaml b/i18n/zh-tw.yaml index 62ae52e..7e557dd 100644 --- a/i18n/zh-tw.yaml +++ b/i18n/zh-tw.yaml @@ -75,7 +75,8 @@ PostMeta: title: "温馨提醒" info: "🕰️ 嗨,这篇文章已是#前的陳年佳釀,資訊可能需要更新,閱讀前請檢查最佳賞味期限。" warn: "🚀 請注意啦!這篇文章来自#以前,可能已經跟不上時代的腳步了。閱讀時請自備時光機,小心穿越哦!" - + summary: + title: 總結摘要 PostAlert: info : "信息 " note : "注意" diff --git a/layouts/partials/post/body.html b/layouts/partials/post/body.html index d8a98ea..6804129 100644 --- a/layouts/partials/post/body.html +++ b/layouts/partials/post/body.html @@ -6,6 +6,7 @@ {{ .Summary }} {{ end }} {{ else }} + {{/** Post expired tip message **/}} {{ $expired := default .Site.Params.PostMeta.expired .Params.Expired }} {{ if $expired }}
    @@ -16,6 +17,19 @@
    {{ end }} + {{/** Post summary **/}} + {{ $summary := default .Site.Params.PostMeta.summary .Params.Summary }} + {{ if $summary }} +
    +
    + + {{ T "PostMeta.summary.title" }} +
    +
    + {{ default .Summary .Params.Summary }} +
    +
    + {{ end }} {{/** Started use the read more content anchor the need Hugo framework min marjo version greater than 0.134.0 **/}} {{ .Summary }} From e9297ac28bec696da627be373b76c8385328460d Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Sun, 19 Jan 2025 19:05:34 +0800 Subject: [PATCH 28/42] :bug: Fixed #140, add selection backgroud make it show clear. --- assets/css/_colors.scss | 4 ++++ assets/css/_common/scaffolding/base.scss | 5 +++-- assets/css/_common/scaffolding/highlight/copy-code.scss | 9 ++++++--- assets/css/_variables/base.scss | 4 +++- 4 files changed, 16 insertions(+), 6 deletions(-) diff --git a/assets/css/_colors.scss b/assets/css/_colors.scss index 85a3128..bf74c6d 100644 --- a/assets/css/_colors.scss +++ b/assets/css/_colors.scss @@ -4,6 +4,8 @@ --content-bg-color: #{$content-bg-color}; --card-bg-color: #{$card-bg-color}; --text-color: #{$text-color}; + --selection-bg: #{$grey-lighter}; + --selection-color: #{$black-deep}; --blockquote-color: #{$blockquote-color}; --link-color: #{$link-color}; --link-hover-color: #{$link-hover-color}; @@ -38,6 +40,8 @@ --content-bg-color: #{$content-bg-color-dark}; --card-bg-color: #{$card-bg-color-dark}; --text-color: #{$text-color-dark}; + --selection-bg: #{$gainsboro}; + --selection-color: #{$black-dim}; --blockquote-color: #{$blockquote-color-dark}; --link-color: #{$link-color-dark}; --link-hover-color: #{$link-hover-color-dark}; diff --git a/assets/css/_common/scaffolding/base.scss b/assets/css/_common/scaffolding/base.scss index 3f3e049..2ca5f66 100644 --- a/assets/css/_common/scaffolding/base.scss +++ b/assets/css/_common/scaffolding/base.scss @@ -1,6 +1,7 @@ ::selection { - background: $selection-bg; - color: $selection-color; + background: var(--selection-bg); + color: var(--selection-color); + } html, body { diff --git a/assets/css/_common/scaffolding/highlight/copy-code.scss b/assets/css/_common/scaffolding/highlight/copy-code.scss index d69c9d0..fc7e19a 100644 --- a/assets/css/_common/scaffolding/highlight/copy-code.scss +++ b/assets/css/_common/scaffolding/highlight/copy-code.scss @@ -3,6 +3,7 @@ background: var(--highlight-background); margin-bottom: 26px; + line-height: 1.185; //TODO Need fixed the copy button show position. div:first-child { @@ -12,14 +13,16 @@ pre { position: relative; overflow-x: auto; - padding: 4px; + padding: 6px; + overflow-wrap: break-word; + line-break: anywhere; } - table tbody tr { + /* table tbody tr { //TODO Fixed the too long code line over // layout background color. background: #272822; - } + }*/ /* pre > code span { white-space: break-spaces; diff --git a/assets/css/_variables/base.scss b/assets/css/_variables/base.scss index ac11f59..9de4314 100644 --- a/assets/css/_variables/base.scss +++ b/assets/css/_variables/base.scss @@ -60,8 +60,10 @@ $content-bg-color : white; $content-bg-color-dark : $black-dim; // Selection -$selection-bg : $blue-deep; +$selection-bg : rgba(53, 166, 247, 0.25) !default; +$selection-bg-dark : rgba(50, 112, 194, 0.4) !default; $selection-color : $gainsboro; +$selection-color-dark : $grey-dark; // Dark mode color $card-bg-color : $whitesmoke; From 23e220b5f314841562262aa2bc214d5a3123169d Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Mon, 20 Jan 2025 09:28:56 +0800 Subject: [PATCH 29/42] :bug: Fxied #139, make render code block & clipboard remove last enter line. --- .../scaffolding/highlight/copy-code.scss | 2 +- assets/js/3rd/others/clipboard.js | 37 +++++++++++ assets/js/next-boot.js | 1 - assets/js/utils.js | 64 ++++++++++++++----- data/resources.yaml | 9 ++- exampleSite/content/post/hugo-blockquote.md | 3 - .../_default/_markup/render-codeblock.html | 4 ++ layouts/partials/head/config.html | 8 +++ layouts/partials/head/script/plugins.html | 5 ++ .../js/3rd/clipboard/2.0.11/clipboard.min.js | 7 ++ 10 files changed, 118 insertions(+), 22 deletions(-) create mode 100644 assets/js/3rd/others/clipboard.js create mode 100644 layouts/_default/_markup/render-codeblock.html create mode 100644 static/js/3rd/clipboard/2.0.11/clipboard.min.js diff --git a/assets/css/_common/scaffolding/highlight/copy-code.scss b/assets/css/_common/scaffolding/highlight/copy-code.scss index fc7e19a..bafac01 100644 --- a/assets/css/_common/scaffolding/highlight/copy-code.scss +++ b/assets/css/_common/scaffolding/highlight/copy-code.scss @@ -3,7 +3,7 @@ background: var(--highlight-background); margin-bottom: 26px; - line-height: 1.185; + line-height: 1.25; //TODO Need fixed the copy button show position. div:first-child { diff --git a/assets/js/3rd/others/clipboard.js b/assets/js/3rd/others/clipboard.js new file mode 100644 index 0000000..8862e2b --- /dev/null +++ b/assets/js/3rd/others/clipboard.js @@ -0,0 +1,37 @@ +/* clipboard plugin */ +NexT.plugins.others.clipboard = function() { + const clipboard_js = NexT.utils.getCDNResource(NexT.CONFIG.page.clipboard.js); + + NexT.utils.getScript(clipboard_js, function(){ + + let figure = document.querySelectorAll('.highlight pre'); + if (figure.length === 0 || !NexT.CONFIG.copybtn) return; + figure.forEach(element => { + let cn = element.querySelector('code').className; + if (cn === '') return; + element.children[0].insertAdjacentHTML('beforebegin', '
    '); + var clipboard = new ClipboardJS(element.children[0], + { + text: function(trigger) { + return trigger.nextElementSibling.textContent.trim(); + } + }); + clipboard.on('success', function (e) { + e.clearSelection(); + button.querySelector('i').className = 'fa fa-check-circle fa-fw'; + }); + + clipboard.on('error', function (e) { + console.error('Copy failed:', e); + button.querySelector('i').className = 'fa fa-times-circle fa-fw'; + }); + + const button = element.querySelector('.copy-btn'); + element.addEventListener('mouseleave', () => { + setTimeout(() => { + button.querySelector('i').className = 'fa fa-copy fa-fw'; + }, 300); + }); + }); + }); +} \ No newline at end of file diff --git a/assets/js/next-boot.js b/assets/js/next-boot.js index 0e5104a..b6c3ed2 100644 --- a/assets/js/next-boot.js +++ b/assets/js/next-boot.js @@ -67,7 +67,6 @@ NexT.boot.refresh = function() { if (NexT.CONFIG.page.expired) NexT.utils.calPostExpiredDate(); if (NexT.CONFIG.page.music) NexT.utils.registerAPlayer(); - NexT.utils.registerCopyCode(); NexT.utils.registerImageViewer(); NexT.utils.registerPostReward(); diff --git a/assets/js/utils.js b/assets/js/utils.js index a8c0778..1050fca 100644 --- a/assets/js/utils.js +++ b/assets/js/utils.js @@ -306,27 +306,57 @@ NexT.utils = { registerCopyCode: function () { if (!NexT.CONFIG.copybtn) return; - let figure = document.querySelectorAll('.highlight pre'); + /** let figure = document.querySelectorAll('.highlight pre'); if (figure.length === 0 || !NexT.CONFIG.copybtn) return; figure.forEach(element => { - let cn = element.querySelector('code').className; - // TODO seems hard code need find other ways fixed it. - if (cn == '') return; - element.insertAdjacentHTML('beforeend', '
    '); + let cn = element.querySelector('code').className; + if (cn === '') return; + element.children[0].insertAdjacentHTML('beforebegin', '
    '); + var clipboard = new ClipboardJS(element.children[0], + { + text: function(trigger) { + return trigger.nextElementSibling.textContent.trim(); + } + }); + clipboard.on('success', function (e) { + e.clearSelection(); + console.info('Action:', e.action); + console.info('Text:', e.text); + button.querySelector('i').className = 'fa fa-check-circle fa-fw'; + }); + clipboard.on('error', function (e) { + console.error('复制失败:', e); + button.querySelector('i').className = 'fa fa-times-circle fa-fw'; + }); const button = element.querySelector('.copy-btn'); - button.addEventListener('click', () => { + element.addEventListener('mouseleave', () => { + setTimeout(() => { + button.querySelector('i').className = 'fa fa-copy fa-fw'; + }, 300); + }); + });**/ + /** figure.forEach(element => { + let cn = element.querySelector('code').className; + if (cn === '') return; + element.insertAdjacentHTML('beforeend', '
    '); + // element.insertAdjacentHTML('beforeend', '
    '); + const button = element.querySelector('.copy-btn'); + button.addEventListener('click', async () => { const lines = element.querySelector('.code') || element.querySelector('code'); - const code = lines.innerText.replace(/(\n{2,})/g, '\n'); + let code = lines.textContent.trim(); + console.log('尝试复制代码:', code); + if (navigator.clipboard) { - // https://caniuse.com/mdn-api_clipboard_writetext navigator.clipboard.writeText(code).then(() => { + console.log('复制成功'); button.querySelector('i').className = 'fa fa-check-circle fa-fw'; - }, () => { + }).catch((err) => { + console.error('复制失败:', err); button.querySelector('i').className = 'fa fa-times-circle fa-fw'; }); } else { const ta = document.createElement('textarea'); - ta.style.top = window.scrollY + 'px'; // Prevent page scrolling + ta.style.top = window.scrollY + 'px'; ta.style.position = 'absolute'; ta.style.opacity = '0'; ta.readOnly = true; @@ -334,20 +364,22 @@ NexT.utils = { document.body.append(ta); ta.select(); ta.setSelectionRange(0, code.length); - ta.readOnly = false; - const result = document.execCommand('copy'); - button.querySelector('i').className = result ? 'fa fa-check-circle fa-fw' : 'fa fa-times-circle fa-fw'; - ta.blur(); // For iOS - button.blur(); + try { + const successful = document.execCommand('copy'); + if (!successful) throw new Error('复制命令执行失败'); + } catch (err) { + console.error('复制失败:', err); + } document.body.removeChild(ta); } + }); element.addEventListener('mouseleave', () => { setTimeout(() => { button.querySelector('i').className = 'fa fa-copy fa-fw'; }, 300); }); - }); + });**/ }, wrapTableWithBox: function () { diff --git a/data/resources.yaml b/data/resources.yaml index a8ad1cd..5c6eabd 100644 --- a/data/resources.yaml +++ b/data/resources.yaml @@ -145,6 +145,7 @@ utterances: livere: js: https://cdn-city.livere.com/js/embed.dist.js + # 全文搜索 # Full text search algolia: @@ -231,4 +232,10 @@ plugins: css: name: aplayer version: 1.10.1 - file: dist/APlayer.min.css \ No newline at end of file + file: dist/APlayer.min.css + # 复制到剪贴板 + clipboard: + js: + name: clipboard + version: 2.0.11 + file: dist/clipboard.min.js \ No newline at end of file diff --git a/exampleSite/content/post/hugo-blockquote.md b/exampleSite/content/post/hugo-blockquote.md index 6c1b1ec..cc1ee62 100644 --- a/exampleSite/content/post/hugo-blockquote.md +++ b/exampleSite/content/post/hugo-blockquote.md @@ -27,9 +27,7 @@ expired: true 用户可以找到如下两处配置项的位置,然后根据自己喜欢的风格和颜色进行调整: ```yaml - # config.yaml 或 hugo.toml - postAlerts: info: icon: "circle-info" @@ -56,7 +54,6 @@ postAlerts: ```yaml # i18n/zh-cn.yaml - PostAlert: info : "信息" note : "注意" diff --git a/layouts/_default/_markup/render-codeblock.html b/layouts/_default/_markup/render-codeblock.html new file mode 100644 index 0000000..5e27219 --- /dev/null +++ b/layouts/_default/_markup/render-codeblock.html @@ -0,0 +1,4 @@ +{{ $result := transform.HighlightCodeBlock . }} +{{ $result.Wrapped }} + +{{ .Page.Store.Set "codeblock" true }} \ No newline at end of file diff --git a/layouts/partials/head/config.html b/layouts/partials/head/config.html index 09ba67b..8bf3a27 100644 --- a/layouts/partials/head/config.html +++ b/layouts/partials/head/config.html @@ -12,6 +12,14 @@ "title" .Page.Title }} +{{/** Append clipboard plugin */}} +{{ if .Store.Get "codeblock" }} +{{ $clipboard := dict + "js" $.Site.Data.resources.plugins.clipboard.js +}} +{{ $pageCfg = merge $pageCfg (dict "clipboard" $clipboard) }} +{{ end }} + {{/** Append APlayer plugin */}} {{ if $scParam.music }} {{ $aplayer := dict diff --git a/layouts/partials/head/script/plugins.html b/layouts/partials/head/script/plugins.html index 184b90d..d2d38d1 100644 --- a/layouts/partials/head/script/plugins.html +++ b/layouts/partials/head/script/plugins.html @@ -1,6 +1,11 @@ {{/* Defind loading plugin scripts which only need in pages */}} {{ if .IsPage }} +{{/** Append codeblack render action **/}} +{{ if .Store.Get "codeblock" }} + {{ partial "_funs/get_plugin.html" (dict "ctx" . "class" "others" "plugin" "clipboard.js") }} +{{ end }} + {{/** Short code params **/}} {{ $scParam := .Store.Get "scParams" }} diff --git a/static/js/3rd/clipboard/2.0.11/clipboard.min.js b/static/js/3rd/clipboard/2.0.11/clipboard.min.js new file mode 100644 index 0000000..9f97edb --- /dev/null +++ b/static/js/3rd/clipboard/2.0.11/clipboard.min.js @@ -0,0 +1,7 @@ +/*! + * clipboard.js v2.0.11 + * https://clipboardjs.com/ + * + * Licensed MIT © Zeno Rocha + */ +!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.ClipboardJS=e():t.ClipboardJS=e()}(this,function(){return n={686:function(t,e,n){"use strict";n.d(e,{default:function(){return b}});var e=n(279),i=n.n(e),e=n(370),u=n.n(e),e=n(817),r=n.n(e);function c(t){try{return document.execCommand(t)}catch(t){return}}var a=function(t){t=r()(t);return c("cut"),t};function o(t,e){var n,o,t=(n=t,o="rtl"===document.documentElement.getAttribute("dir"),(t=document.createElement("textarea")).style.fontSize="12pt",t.style.border="0",t.style.padding="0",t.style.margin="0",t.style.position="absolute",t.style[o?"right":"left"]="-9999px",o=window.pageYOffset||document.documentElement.scrollTop,t.style.top="".concat(o,"px"),t.setAttribute("readonly",""),t.value=n,t);return e.container.appendChild(t),e=r()(t),c("copy"),t.remove(),e}var f=function(t){var e=1 Date: Tue, 21 Jan 2025 20:44:34 +0800 Subject: [PATCH 30/42] :bug: Fixed #155, the code block overflow in the markdown file. --- .../scaffolding/highlight/copy-code.scss | 165 ++++++++++++++---- assets/js/3rd/others/clipboard.js | 46 +++-- exampleSite/config.yaml | 20 +-- .../content/post/syntax-highlighting.md | 58 +++++- 4 files changed, 208 insertions(+), 81 deletions(-) diff --git a/assets/css/_common/scaffolding/highlight/copy-code.scss b/assets/css/_common/scaffolding/highlight/copy-code.scss index bafac01..23c14c5 100644 --- a/assets/css/_common/scaffolding/highlight/copy-code.scss +++ b/assets/css/_common/scaffolding/highlight/copy-code.scss @@ -5,31 +5,130 @@ margin-bottom: 26px; line-height: 1.25; - //TODO Need fixed the copy button show position. - div:first-child { - overflow-x: auto; - } - - pre { + > .chroma { position: relative; - overflow-x: auto; - padding: 6px; - overflow-wrap: break-word; - line-break: anywhere; + + pre { + padding: .45rem 0; + } + + .lntd:first-child { + min-width: 1.6rem; + text-align: right; + background-color: #272822; + + a { + border-bottom: none; + } + } + + .lntd:last-child { + width: 100%; + + pre { + overflow-wrap: break-word; + white-space: pre-wrap; + line-break: anywhere; + word-break: break-all; + overflow-x: auto; + } + } + + > code > span { + overflow-wrap: break-word; + white-space: pre-wrap; + line-break: anywhere; + word-break: break-all; + } } - /* table tbody tr { - //TODO Fixed the too long code line over - // layout background color. - background: #272822; - }*/ - - /* pre > code span { - white-space: break-spaces; - overflow: hidden; - word-break: break-all; - word-wrap: break-word; - } */ + /** monokai highlight style **/ + /* Background */ .bg { color:#f8f8f2;background-color:#272822; } + /* PreWrapper */ .chroma { color:#f8f8f2;background-color:#272822; } + /* Other */ .chroma .x { } + /* Error */ .chroma .err { color:#960050;background-color:#1e0010 } + /* CodeLine */ .chroma .cl { } + /* LineLink */ .chroma .lnlinks { outline:none;text-decoration:none;color:inherit } + /* LineTableTD */ .chroma .lntd { vertical-align:top;padding:0;margin:0;border:0; } + /* LineTable */ .chroma .lntable { border-spacing:0;padding:0;margin:0;border:0; } + /* LineHighlight */ .chroma .hl { background-color:#3c3d38 } + /* LineNumbersTable */ .chroma .lnt { white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f } + /* LineNumbers */ .chroma .ln { white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f } + /* Line */ .chroma .line { display:flex; } + /* Keyword */ .chroma .k { color:#66d9ef } + /* KeywordConstant */ .chroma .kc { color:#66d9ef } + /* KeywordDeclaration */ .chroma .kd { color:#66d9ef } + /* KeywordNamespace */ .chroma .kn { color:#f92672 } + /* KeywordPseudo */ .chroma .kp { color:#66d9ef } + /* KeywordReserved */ .chroma .kr { color:#66d9ef } + /* KeywordType */ .chroma .kt { color:#66d9ef } + /* Name */ .chroma .n { } + /* NameAttribute */ .chroma .na { color:#a6e22e } + /* NameBuiltin */ .chroma .nb { } + /* NameBuiltinPseudo */ .chroma .bp { } + /* NameClass */ .chroma .nc { color:#a6e22e } + /* NameConstant */ .chroma .no { color:#66d9ef } + /* NameDecorator */ .chroma .nd { color:#a6e22e } + /* NameEntity */ .chroma .ni { } + /* NameException */ .chroma .ne { color:#a6e22e } + /* NameFunction */ .chroma .nf { color:#a6e22e } + /* NameFunctionMagic */ .chroma .fm { } + /* NameLabel */ .chroma .nl { } + /* NameNamespace */ .chroma .nn { } + /* NameOther */ .chroma .nx { color:#a6e22e } + /* NameProperty */ .chroma .py { } + /* NameTag */ .chroma .nt { color:#f92672 } + /* NameVariable */ .chroma .nv { } + /* NameVariableClass */ .chroma .vc { } + /* NameVariableGlobal */ .chroma .vg { } + /* NameVariableInstance */ .chroma .vi { } + /* NameVariableMagic */ .chroma .vm { } + /* Literal */ .chroma .l { color:#ae81ff } + /* LiteralDate */ .chroma .ld { color:#e6db74 } + /* LiteralString */ .chroma .s { color:#e6db74 } + /* LiteralStringAffix */ .chroma .sa { color:#e6db74 } + /* LiteralStringBacktick */ .chroma .sb { color:#e6db74 } + /* LiteralStringChar */ .chroma .sc { color:#e6db74 } + /* LiteralStringDelimiter */ .chroma .dl { color:#e6db74 } + /* LiteralStringDoc */ .chroma .sd { color:#e6db74 } + /* LiteralStringDouble */ .chroma .s2 { color:#e6db74 } + /* LiteralStringEscape */ .chroma .se { color:#ae81ff } + /* LiteralStringHeredoc */ .chroma .sh { color:#e6db74 } + /* LiteralStringInterpol */ .chroma .si { color:#e6db74 } + /* LiteralStringOther */ .chroma .sx { color:#e6db74 } + /* LiteralStringRegex */ .chroma .sr { color:#e6db74 } + /* LiteralStringSingle */ .chroma .s1 { color:#e6db74 } + /* LiteralStringSymbol */ .chroma .ss { color:#e6db74 } + /* LiteralNumber */ .chroma .m { color:#ae81ff } + /* LiteralNumberBin */ .chroma .mb { color:#ae81ff } + /* LiteralNumberFloat */ .chroma .mf { color:#ae81ff } + /* LiteralNumberHex */ .chroma .mh { color:#ae81ff } + /* LiteralNumberInteger */ .chroma .mi { color:#ae81ff } + /* LiteralNumberIntegerLong */ .chroma .il { color:#ae81ff } + /* LiteralNumberOct */ .chroma .mo { color:#ae81ff } + /* Operator */ .chroma .o { color:#f92672 } + /* OperatorWord */ .chroma .ow { color:#f92672 } + /* Punctuation */ .chroma .p { } + /* Comment */ .chroma .c { color:#75715e } + /* CommentHashbang */ .chroma .ch { color:#75715e } + /* CommentMultiline */ .chroma .cm { color:#75715e } + /* CommentSingle */ .chroma .c1 { color:#75715e } + /* CommentSpecial */ .chroma .cs { color:#75715e } + /* CommentPreproc */ .chroma .cp { color:#75715e } + /* CommentPreprocFile */ .chroma .cpf { color:#75715e } + /* Generic */ .chroma .g { } + /* GenericDeleted */ .chroma .gd { color:#f92672 } + /* GenericEmph */ .chroma .ge { font-style:italic } + /* GenericError */ .chroma .gr { } + /* GenericHeading */ .chroma .gh { } + /* GenericInserted */ .chroma .gi { color:#a6e22e } + /* GenericOutput */ .chroma .go { } + /* GenericPrompt */ .chroma .gp { } + /* GenericStrong */ .chroma .gs { font-weight:bold } + /* GenericSubheading */ .chroma .gu { color:#75715e } + /* GenericTraceback */ .chroma .gt { } + /* GenericUnderline */ .chroma .gl { } + /* TextWhitespace */ .chroma .w { } } @if $codeblock_copy_btn_enable { @@ -76,17 +175,15 @@ box-shadow: 0 10px 30px 0 rgba(0, 0, 0, .4); padding-top: 30px; - .table-container { - border-radius: 0 0 5px 5px; - } - - &::before { - background: #fc625d; - box-shadow: 20px 0 #fdbc40, 40px 0 #35cd4b; - margin-top: -20px; - margin-left: 10px; - position: absolute; - @include round-icon(12px); - } + > div { + &::before { + background: #fc625d; + box-shadow: 20px 0 #fdbc40, 40px 0 #35cd4b; + margin-top: -20px; + margin-left: 10px; + position: absolute; + @include round-icon(12px); + } + } } } \ No newline at end of file diff --git a/assets/js/3rd/others/clipboard.js b/assets/js/3rd/others/clipboard.js index 8862e2b..02985cc 100644 --- a/assets/js/3rd/others/clipboard.js +++ b/assets/js/3rd/others/clipboard.js @@ -1,37 +1,35 @@ /* clipboard plugin */ -NexT.plugins.others.clipboard = function() { +NexT.plugins.others.clipboard = function () { const clipboard_js = NexT.utils.getCDNResource(NexT.CONFIG.page.clipboard.js); - NexT.utils.getScript(clipboard_js, function(){ + NexT.utils.getScript(clipboard_js, function () { let figure = document.querySelectorAll('.highlight pre'); if (figure.length === 0 || !NexT.CONFIG.copybtn) return; + + /** Add copy button DOM. **/ figure.forEach(element => { - let cn = element.querySelector('code').className; + let cn = element.querySelector('code').className; if (cn === '') return; - element.children[0].insertAdjacentHTML('beforebegin', '
    '); - var clipboard = new ClipboardJS(element.children[0], - { - text: function(trigger) { - return trigger.nextElementSibling.textContent.trim(); - } - }); - clipboard.on('success', function (e) { - e.clearSelection(); - button.querySelector('i').className = 'fa fa-check-circle fa-fw'; - }); + element.insertAdjacentHTML('beforeend', '
    '); + }); - clipboard.on('error', function (e) { - console.error('Copy failed:', e); - button.querySelector('i').className = 'fa fa-times-circle fa-fw'; - }); + /** Register the clipboard event. **/ + var clipboard = new ClipboardJS('.copy-btn', { + text: function (trigger) { + // TODO: Why there clipboard default text content with enter? + return trigger.previousElementSibling.textContent.trim(); + } + }); - const button = element.querySelector('.copy-btn'); - element.addEventListener('mouseleave', () => { - setTimeout(() => { - button.querySelector('i').className = 'fa fa-copy fa-fw'; - }, 300); - }); + clipboard.on('success', function (e) { + e.clearSelection(); + e.trigger.querySelector('i').className = 'fa fa-fw fa-check-circle'; + }); + + clipboard.on('error', function (e) { + console.error('Copy failed:', e); + e.trigger.querySelector('i').className = 'fa fa-fw fa-times-circle'; }); }); } \ No newline at end of file diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index ffc19d5..2ec80a4 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -39,25 +39,15 @@ markup: goldmark: renderer: unsafe: true + # 高亮代码的样式 + # Highlight style of code highlight: - # # 高亮代码的样式名称,可选:monokai | emacs | api | dracula | friendly - # # 更多的样式:https://xyproto.github.io/splash/docs/all.html - # # Highlight style: monokai | emacs | api | dracula | friendly - # # More: https://xyproto.github.io/splash/docs/all.html - # style: "monokai" anchorLineNos: true codeFences: true guessSyntax: true - hl_Lines: "" - hl_inline: false - lineAnchors: "" - lineNoStart: 1 - lineNos: false - lineNumbersInTable: false - noClasses: true - noHl: false - style: monokai - tabWidth: 2 + lineNos: true + lineNumbersInTable: true + noClasses: false tableOfContents: # 开始/结束标题级别:1-6 (建议从2开始) # Heading title level of start or end: 1-6 diff --git a/exampleSite/content/post/syntax-highlighting.md b/exampleSite/content/post/syntax-highlighting.md index eafb9fb..f946f7d 100644 --- a/exampleSite/content/post/syntax-highlighting.md +++ b/exampleSite/content/post/syntax-highlighting.md @@ -27,6 +27,23 @@ Hugo 通过 Chroma 提供非常快速的语法高亮显示,现 Hugo 中使用 ### GO +```makrdown +{{}} + +func GetTitleFunc(style string) func(s string) string { + switch strings.ToLower(style) { + case "go": + return strings.Title + case "chicago": + return transform.NewTitleConverter(transform.ChicagoStyle) + default: + return transform.NewTitleConverter(transform.APStyle) + } +} + +{{}} +``` + {{< highlight go "linenos=table,hl_lines=8 15-17,linenostart=199" >}} func GetTitleFunc(style string) func(s string) string { @@ -48,14 +65,14 @@ func GetTitleFunc(style string) func(s string) string { import javax.swing.JFrame; //Importing class JFrame import javax.swing.JLabel; //Importing class JLabel public class HelloWorld { - public static void main(String[] args) { - JFrame frame = new JFrame(); //Creating frame - frame.setTitle("Hi!"); //Setting title frame - frame.add(new JLabel("Hello, world!"));//Adding text to frame - frame.pack(); //Setting size to smallest - frame.setLocationRelativeTo(null); //Centering frame - frame.setVisible(true); //Showing frame - } + public static void main(String[] args) { + JFrame frame = new JFrame(); //Creating frame + frame.setTitle("Hi!"); //Setting title frame + frame.add(new JLabel("Hello, world!"));//Adding text to frame + frame.pack(); //Setting size to smallest + frame.setLocationRelativeTo(null); //Centering frame + frame.setVisible(true); //Showing frame + } } ``` @@ -143,5 +160,30 @@ FROM WHERE column_name = "condition" {{< / highlight >}} +### 自动猜测代码高亮显示 + +``` +.highlight { + + // 其他代码 + ...... + + > .chroma { + position: relative; + + + // 修复代码块溢出问题 + pre { + overflow-wrap: break-word; + white-space: pre-wrap; + line-break: anywhere; + word-break: break-all; + overflow-x: auto; + } + } + } +} +``` + 除以上列举的代码高亮显示外,还支持诸如:C 语言、C++、HTML、CSS、Shell脚本等各主流的代码语言高亮显示,可自行测试效果。 \ No newline at end of file From 4ec1f8e732be8aeb32cbaf2e42e948b07b61b833 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Wed, 22 Jan 2025 22:07:49 +0800 Subject: [PATCH 31/42] :sparkles: Closed#108, collapse code blocks. --- .../scaffolding/highlight/copy-code.scss | 239 ++++++++---------- .../_common/scaffolding/highlight/index.scss | 3 +- .../scaffolding/highlight/monokai.scss | 87 +++++++ assets/css/_variables/base.scss | 54 ++++ assets/js/3rd/others/clipboard.js | 53 ++-- 5 files changed, 293 insertions(+), 143 deletions(-) create mode 100644 assets/css/_common/scaffolding/highlight/monokai.scss diff --git a/assets/css/_common/scaffolding/highlight/copy-code.scss b/assets/css/_common/scaffolding/highlight/copy-code.scss index 23c14c5..ad3e72e 100644 --- a/assets/css/_common/scaffolding/highlight/copy-code.scss +++ b/assets/css/_common/scaffolding/highlight/copy-code.scss @@ -5,8 +5,66 @@ margin-bottom: 26px; line-height: 1.25; + > .code-header { + color:#f8f8f2; + display: flex; + justify-content: space-between; + align-items: center; + padding: .25rem 0; + width: 100%; + + &:hover { + cursor: pointer; + } + + .code-lang { + width: 100%; + text-align: center; + font-weight: bold; + + &::after { + content: "Code"; + } + } + + .collapse-btn { + font-family: "Font Awesome 6 Free"; + font-weight: 900; + text-align: center; + width: 1.25em; + display: inline-block; + font-style: normal; + font-variant: normal; + line-height: 1; + text-rendering: auto; + padding-right: .25rem; + + &::before { + content: "\f102"; + } + + &.collapse::before { + content: "\f103"; + } + } + + @each $type, $text in $code-type-list { + &.#{$type} .code-lang::after { + content: $text; + } + } + + .ellipses-btn { + padding-right: .45rem; + } + } + > .chroma { position: relative; + + &.hidden-code { + display: none; + } pre { padding: .45rem 0; @@ -40,150 +98,77 @@ line-break: anywhere; word-break: break-all; } - } - /** monokai highlight style **/ - /* Background */ .bg { color:#f8f8f2;background-color:#272822; } - /* PreWrapper */ .chroma { color:#f8f8f2;background-color:#272822; } - /* Other */ .chroma .x { } - /* Error */ .chroma .err { color:#960050;background-color:#1e0010 } - /* CodeLine */ .chroma .cl { } - /* LineLink */ .chroma .lnlinks { outline:none;text-decoration:none;color:inherit } - /* LineTableTD */ .chroma .lntd { vertical-align:top;padding:0;margin:0;border:0; } - /* LineTable */ .chroma .lntable { border-spacing:0;padding:0;margin:0;border:0; } - /* LineHighlight */ .chroma .hl { background-color:#3c3d38 } - /* LineNumbersTable */ .chroma .lnt { white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f } - /* LineNumbers */ .chroma .ln { white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f } - /* Line */ .chroma .line { display:flex; } - /* Keyword */ .chroma .k { color:#66d9ef } - /* KeywordConstant */ .chroma .kc { color:#66d9ef } - /* KeywordDeclaration */ .chroma .kd { color:#66d9ef } - /* KeywordNamespace */ .chroma .kn { color:#f92672 } - /* KeywordPseudo */ .chroma .kp { color:#66d9ef } - /* KeywordReserved */ .chroma .kr { color:#66d9ef } - /* KeywordType */ .chroma .kt { color:#66d9ef } - /* Name */ .chroma .n { } - /* NameAttribute */ .chroma .na { color:#a6e22e } - /* NameBuiltin */ .chroma .nb { } - /* NameBuiltinPseudo */ .chroma .bp { } - /* NameClass */ .chroma .nc { color:#a6e22e } - /* NameConstant */ .chroma .no { color:#66d9ef } - /* NameDecorator */ .chroma .nd { color:#a6e22e } - /* NameEntity */ .chroma .ni { } - /* NameException */ .chroma .ne { color:#a6e22e } - /* NameFunction */ .chroma .nf { color:#a6e22e } - /* NameFunctionMagic */ .chroma .fm { } - /* NameLabel */ .chroma .nl { } - /* NameNamespace */ .chroma .nn { } - /* NameOther */ .chroma .nx { color:#a6e22e } - /* NameProperty */ .chroma .py { } - /* NameTag */ .chroma .nt { color:#f92672 } - /* NameVariable */ .chroma .nv { } - /* NameVariableClass */ .chroma .vc { } - /* NameVariableGlobal */ .chroma .vg { } - /* NameVariableInstance */ .chroma .vi { } - /* NameVariableMagic */ .chroma .vm { } - /* Literal */ .chroma .l { color:#ae81ff } - /* LiteralDate */ .chroma .ld { color:#e6db74 } - /* LiteralString */ .chroma .s { color:#e6db74 } - /* LiteralStringAffix */ .chroma .sa { color:#e6db74 } - /* LiteralStringBacktick */ .chroma .sb { color:#e6db74 } - /* LiteralStringChar */ .chroma .sc { color:#e6db74 } - /* LiteralStringDelimiter */ .chroma .dl { color:#e6db74 } - /* LiteralStringDoc */ .chroma .sd { color:#e6db74 } - /* LiteralStringDouble */ .chroma .s2 { color:#e6db74 } - /* LiteralStringEscape */ .chroma .se { color:#ae81ff } - /* LiteralStringHeredoc */ .chroma .sh { color:#e6db74 } - /* LiteralStringInterpol */ .chroma .si { color:#e6db74 } - /* LiteralStringOther */ .chroma .sx { color:#e6db74 } - /* LiteralStringRegex */ .chroma .sr { color:#e6db74 } - /* LiteralStringSingle */ .chroma .s1 { color:#e6db74 } - /* LiteralStringSymbol */ .chroma .ss { color:#e6db74 } - /* LiteralNumber */ .chroma .m { color:#ae81ff } - /* LiteralNumberBin */ .chroma .mb { color:#ae81ff } - /* LiteralNumberFloat */ .chroma .mf { color:#ae81ff } - /* LiteralNumberHex */ .chroma .mh { color:#ae81ff } - /* LiteralNumberInteger */ .chroma .mi { color:#ae81ff } - /* LiteralNumberIntegerLong */ .chroma .il { color:#ae81ff } - /* LiteralNumberOct */ .chroma .mo { color:#ae81ff } - /* Operator */ .chroma .o { color:#f92672 } - /* OperatorWord */ .chroma .ow { color:#f92672 } - /* Punctuation */ .chroma .p { } - /* Comment */ .chroma .c { color:#75715e } - /* CommentHashbang */ .chroma .ch { color:#75715e } - /* CommentMultiline */ .chroma .cm { color:#75715e } - /* CommentSingle */ .chroma .c1 { color:#75715e } - /* CommentSpecial */ .chroma .cs { color:#75715e } - /* CommentPreproc */ .chroma .cp { color:#75715e } - /* CommentPreprocFile */ .chroma .cpf { color:#75715e } - /* Generic */ .chroma .g { } - /* GenericDeleted */ .chroma .gd { color:#f92672 } - /* GenericEmph */ .chroma .ge { font-style:italic } - /* GenericError */ .chroma .gr { } - /* GenericHeading */ .chroma .gh { } - /* GenericInserted */ .chroma .gi { color:#a6e22e } - /* GenericOutput */ .chroma .go { } - /* GenericPrompt */ .chroma .gp { } - /* GenericStrong */ .chroma .gs { font-weight:bold } - /* GenericSubheading */ .chroma .gu { color:#75715e } - /* GenericTraceback */ .chroma .gt { } - /* GenericUnderline */ .chroma .gl { } - /* TextWhitespace */ .chroma .w { } -} + @if $codeblock_copy_btn_enable { -@if $codeblock_copy_btn_enable { + &:hover .copy-btn { + opacity: 1; + } + + .copy-btn { + color: $black-dim; + cursor: pointer; + line-height: 1.6; + opacity: 0; + padding: 2px 6px; + position: absolute; + right: 8px; + top: 4px; + border-radius: 3px; + font-size: $font-size-medium; + transition: opacity $transition-ease; + background: var(--highlight-background); + + font-family: "Font Awesome 6 Free"; + font-weight: 900; + text-align: center; + width: 1.25em; + display: inline-block; + font-style: normal; + font-variant: normal; + text-rendering: auto; - .highlight:hover .copy-btn, pre:hover .copy-btn { - opacity: 1; - } + &::before { + content: "\f0c5"; + } - .copy-btn { - color: $black-dim; - cursor: pointer; - line-height: 1.6; - opacity: 0; - padding: 2px 6px; - position: absolute; - right: 8px; - top: 4px; - transition: opacity $transition-ease; - background: var(--highlight-background); + &.copied::before { + content: "\f058"; + } - @if $codeblock_style == 'flat' { - background: white; - border: 0; - font-size: $font-size-smaller; - - } @else if $codeblock_style == 'mac' { - color: var(--highlight-foreground); - font-size: 14px; - border-radius: 3px; - } @else { - background-color: $gainsboro; - background-image: linear-gradient(#fcfcfc, $gainsboro); - border: 1px solid #d5d5d5; - border-radius: 3px; - font-size: $font-size-smaller; - + &.uncopied::before { + content: "\f057"; + } + + @if $codeblock_style == 'flat' { + background: white; + border: 0; + } @else if $codeblock_style == 'mac' { + color: var(--highlight-foreground); + } @else { + background-color: $gainsboro; + background-image: linear-gradient(#fcfcfc, $gainsboro); + border: 1px solid #d5d5d5; + } + } } } -} -@if $codeblock_style == 'mac' { - .highlight { + + @if $codeblock_style == 'mac' { + border-radius: 5px; box-shadow: 0 10px 30px 0 rgba(0, 0, 0, .4); - padding-top: 30px; - > div { + .code-header { + &::before { background: #fc625d; box-shadow: 20px 0 #fdbc40, 40px 0 #35cd4b; - margin-top: -20px; margin-left: 10px; - position: absolute; @include round-icon(12px); } } } + } \ No newline at end of file diff --git a/assets/css/_common/scaffolding/highlight/index.scss b/assets/css/_common/scaffolding/highlight/index.scss index bea46e8..fa461bd 100644 --- a/assets/css/_common/scaffolding/highlight/index.scss +++ b/assets/css/_common/scaffolding/highlight/index.scss @@ -1,4 +1,5 @@ @import 'copy-code'; +@import 'monokai'; %code-inline { background: var(--highlight-background); @@ -8,7 +9,7 @@ pre { padding: 18px; margin: 0; -} +} p > code, li > code { @extend %code-inline; diff --git a/assets/css/_common/scaffolding/highlight/monokai.scss b/assets/css/_common/scaffolding/highlight/monokai.scss new file mode 100644 index 0000000..46d95f2 --- /dev/null +++ b/assets/css/_common/scaffolding/highlight/monokai.scss @@ -0,0 +1,87 @@ +/** monokai highlight style **/ + /* Background */ .bg { color:#f8f8f2;background-color:#272822; } + /* PreWrapper */ .chroma { color:#f8f8f2;background-color:#272822; } + /* Other */ .chroma .x { } + /* Error */ .chroma .err { color:#960050;background-color:#1e0010 } + /* CodeLine */ .chroma .cl { } + /* LineLink */ .chroma .lnlinks { outline:none;text-decoration:none;color:inherit } + /* LineTableTD */ .chroma .lntd { vertical-align:top;padding:0;margin:0;border:0; } + /* LineTable */ .chroma .lntable { border-spacing:0;padding:0;margin:0;border:0; } + /* LineHighlight */ .chroma .hl { background-color:#3c3d38 } + /* LineNumbersTable */ .chroma .lnt { white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f } + /* LineNumbers */ .chroma .ln { white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f } + /* Line */ .chroma .line { display:flex; } + /* Keyword */ .chroma .k { color:#66d9ef } + /* KeywordConstant */ .chroma .kc { color:#66d9ef } + /* KeywordDeclaration */ .chroma .kd { color:#66d9ef } + /* KeywordNamespace */ .chroma .kn { color:#f92672 } + /* KeywordPseudo */ .chroma .kp { color:#66d9ef } + /* KeywordReserved */ .chroma .kr { color:#66d9ef } + /* KeywordType */ .chroma .kt { color:#66d9ef } + /* Name */ .chroma .n { } + /* NameAttribute */ .chroma .na { color:#a6e22e } + /* NameBuiltin */ .chroma .nb { } + /* NameBuiltinPseudo */ .chroma .bp { } + /* NameClass */ .chroma .nc { color:#a6e22e } + /* NameConstant */ .chroma .no { color:#66d9ef } + /* NameDecorator */ .chroma .nd { color:#a6e22e } + /* NameEntity */ .chroma .ni { } + /* NameException */ .chroma .ne { color:#a6e22e } + /* NameFunction */ .chroma .nf { color:#a6e22e } + /* NameFunctionMagic */ .chroma .fm { } + /* NameLabel */ .chroma .nl { } + /* NameNamespace */ .chroma .nn { } + /* NameOther */ .chroma .nx { color:#a6e22e } + /* NameProperty */ .chroma .py { } + /* NameTag */ .chroma .nt { color:#f92672 } + /* NameVariable */ .chroma .nv { } + /* NameVariableClass */ .chroma .vc { } + /* NameVariableGlobal */ .chroma .vg { } + /* NameVariableInstance */ .chroma .vi { } + /* NameVariableMagic */ .chroma .vm { } + /* Literal */ .chroma .l { color:#ae81ff } + /* LiteralDate */ .chroma .ld { color:#e6db74 } + /* LiteralString */ .chroma .s { color:#e6db74 } + /* LiteralStringAffix */ .chroma .sa { color:#e6db74 } + /* LiteralStringBacktick */ .chroma .sb { color:#e6db74 } + /* LiteralStringChar */ .chroma .sc { color:#e6db74 } + /* LiteralStringDelimiter */ .chroma .dl { color:#e6db74 } + /* LiteralStringDoc */ .chroma .sd { color:#e6db74 } + /* LiteralStringDouble */ .chroma .s2 { color:#e6db74 } + /* LiteralStringEscape */ .chroma .se { color:#ae81ff } + /* LiteralStringHeredoc */ .chroma .sh { color:#e6db74 } + /* LiteralStringInterpol */ .chroma .si { color:#e6db74 } + /* LiteralStringOther */ .chroma .sx { color:#e6db74 } + /* LiteralStringRegex */ .chroma .sr { color:#e6db74 } + /* LiteralStringSingle */ .chroma .s1 { color:#e6db74 } + /* LiteralStringSymbol */ .chroma .ss { color:#e6db74 } + /* LiteralNumber */ .chroma .m { color:#ae81ff } + /* LiteralNumberBin */ .chroma .mb { color:#ae81ff } + /* LiteralNumberFloat */ .chroma .mf { color:#ae81ff } + /* LiteralNumberHex */ .chroma .mh { color:#ae81ff } + /* LiteralNumberInteger */ .chroma .mi { color:#ae81ff } + /* LiteralNumberIntegerLong */ .chroma .il { color:#ae81ff } + /* LiteralNumberOct */ .chroma .mo { color:#ae81ff } + /* Operator */ .chroma .o { color:#f92672 } + /* OperatorWord */ .chroma .ow { color:#f92672 } + /* Punctuation */ .chroma .p { } + /* Comment */ .chroma .c { color:#75715e } + /* CommentHashbang */ .chroma .ch { color:#75715e } + /* CommentMultiline */ .chroma .cm { color:#75715e } + /* CommentSingle */ .chroma .c1 { color:#75715e } + /* CommentSpecial */ .chroma .cs { color:#75715e } + /* CommentPreproc */ .chroma .cp { color:#75715e } + /* CommentPreprocFile */ .chroma .cpf { color:#75715e } + /* Generic */ .chroma .g { } + /* GenericDeleted */ .chroma .gd { color:#f92672 } + /* GenericEmph */ .chroma .ge { font-style:italic } + /* GenericError */ .chroma .gr { } + /* GenericHeading */ .chroma .gh { } + /* GenericInserted */ .chroma .gi { color:#a6e22e } + /* GenericOutput */ .chroma .go { } + /* GenericPrompt */ .chroma .gp { } + /* GenericStrong */ .chroma .gs { font-weight:bold } + /* GenericSubheading */ .chroma .gu { color:#75715e } + /* GenericTraceback */ .chroma .gt { } + /* GenericUnderline */ .chroma .gl { } + /* TextWhitespace */ .chroma .w { } \ No newline at end of file diff --git a/assets/css/_variables/base.scss b/assets/css/_variables/base.scss index 9de4314..42be5bb 100644 --- a/assets/css/_variables/base.scss +++ b/assets/css/_variables/base.scss @@ -175,6 +175,60 @@ $highlight-foreground-dark : $highlight_dark_foreground; $highlight-gutter-background-dark : mix($highlight-background-dark, $highlight-foreground-dark, 90%); $highlight-gutter-foreground-dark : mix($highlight-background-dark, $highlight-foreground-dark, 10%); +// Code type list +$code-type-list: + "language-bash" "Bash", + "language-c" "C", + "language-cs" "C#", + "language-cpp" "C++", + "language-clojure" "Clojure", + "language-coffeescript" "CoffeeScript", + "language-css" "CSS", + "language-dart" "Dart", + "language-diff" "Diff", + "language-erlang" "Erlang", + "language-go" "Go", + "language-go-html-template" "Go HTML Template", + "language-groovy" "Groovy", + "language-haskell" "Haskell", + "language-html" "HTML", + "language-http" "HTTP", + "language-xml" "XML", + "language-java" "Java", + "language-js" "JavaScript", + "language-javascript" "JavaScript", + "language-json" "JSON", + "language-kotlin" "Kotlin", + "language-latex" "LaTeX", + "language-less" "Less", + "language-lisp" "Lisp", + "language-lua" "Lua", + "language-makefile" "Makefile", + "language-markdown" "Markdown", + "language-matlab" "Matlab", + "language-objectivec" "Objective-C", + "language-php" "PHP", + "language-perl" "Perl", + "language-powershell" "PowerShell", + "language-posh" "PowerShell", + "language-pwsh" "PowerShell", + "language-python" "Python", + "language-r" "R", + "language-ruby" "Ruby", + "language-rust" "Rust", + "language-scala" "Scala", + "language-scss" "Scss", + "language-shell" "Shell", + "language-sql" "SQL", + "language-swift" "Swift", + "language-tex" "TeX", + "language-toml" "TOML", + "language-ts" "TypeScript", + "language-typescript" "TypeScript", + "language-vue" "Vue", + "language-yml" "YAML", + "language-yaml" "YAML", + !default; // Buttons // -------------------------------------------------- diff --git a/assets/js/3rd/others/clipboard.js b/assets/js/3rd/others/clipboard.js index 02985cc..f4743ab 100644 --- a/assets/js/3rd/others/clipboard.js +++ b/assets/js/3rd/others/clipboard.js @@ -1,20 +1,43 @@ /* clipboard plugin */ NexT.plugins.others.clipboard = function () { - const clipboard_js = NexT.utils.getCDNResource(NexT.CONFIG.page.clipboard.js); + if (!NexT.CONFIG.copybtn) return; + const clipboard_js = NexT.utils.getCDNResource(NexT.CONFIG.page.clipboard.js); NexT.utils.getScript(clipboard_js, function () { - let figure = document.querySelectorAll('.highlight pre'); - if (figure.length === 0 || !NexT.CONFIG.copybtn) return; - - /** Add copy button DOM. **/ - figure.forEach(element => { - let cn = element.querySelector('code').className; - if (cn === '') return; - element.insertAdjacentHTML('beforeend', '
    '); - }); + let chromaDiv = document.querySelectorAll('div.highlight div.chroma'); + if (chromaDiv.length === 0) return; - /** Register the clipboard event. **/ + chromaDiv.forEach(element => { + // Add copy button DOM. + let codeblock = element.querySelector('code[class]:not([class=""]'); + let lang = codeblock.className; + let copyBtn = document.createElement('div'); + copyBtn.classList.add('copy-btn'); + codeblock.parentNode .appendChild(copyBtn); + + element.addEventListener('mouseleave', () => { + setTimeout(() => { + copyBtn.classList.remove('copied'); + copyBtn.classList.remove('copieduncopied'); + }, 300); + }); + + // Add code header show + var ch = document.createElement('div'); + ch.classList.add('code-header'); + ch.classList.add(lang); + ch.insertAdjacentHTML('afterbegin', + ''); + ch.addEventListener('click', function () { + element.classList.toggle('hidden-code'); + ch.querySelector('.collapse-btn').classList.toggle('collapse'); + }, false); + + element.parentNode.insertBefore(ch, element); + }); + + // Register the clipboard event. var clipboard = new ClipboardJS('.copy-btn', { text: function (trigger) { // TODO: Why there clipboard default text content with enter? @@ -24,12 +47,12 @@ NexT.plugins.others.clipboard = function () { clipboard.on('success', function (e) { e.clearSelection(); - e.trigger.querySelector('i').className = 'fa fa-fw fa-check-circle'; + e.trigger.classList.add('copied'); }); clipboard.on('error', function (e) { - console.error('Copy failed:', e); - e.trigger.querySelector('i').className = 'fa fa-fw fa-times-circle'; + console.error('Copy failed:', e); + e.trigger.classList.add('uncopied'); }); - }); + }); } \ No newline at end of file From 0b8bdc0e00f0c811e7a4dc2c33ba10dce4af7b37 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Thu, 23 Jan 2025 17:12:34 +0800 Subject: [PATCH 32/42] =?UTF-8?q?=E2=9C=A8=20Closed=20#108,=20add=20animat?= =?UTF-8?q?ed=20transition=20when=20expand=20and=20collapse=20code=20block?= =?UTF-8?q?.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../_common/scaffolding/highlight/copy-code.scss | 14 ++++++++++++-- assets/js/3rd/others/clipboard.js | 9 ++++----- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/assets/css/_common/scaffolding/highlight/copy-code.scss b/assets/css/_common/scaffolding/highlight/copy-code.scss index ad3e72e..b1eeff8 100644 --- a/assets/css/_common/scaffolding/highlight/copy-code.scss +++ b/assets/css/_common/scaffolding/highlight/copy-code.scss @@ -37,7 +37,8 @@ font-variant: normal; line-height: 1; text-rendering: auto; - padding-right: .25rem; + padding-right: .25rem; + transition: content 1s ease-in-out; &::before { content: "\f102"; @@ -61,9 +62,18 @@ > .chroma { position: relative; + max-height: 500px; + opacity: 1; + visibility: visible; + transition: max-height 0.8s ease-in-out, opacity 0.7s ease-in-out; &.hidden-code { - display: none; + max-height: 0; + opacity: 0; + visibility: hidden; + + animation-name: slideInUp; + animation-duration: 1s; } pre { diff --git a/assets/js/3rd/others/clipboard.js b/assets/js/3rd/others/clipboard.js index f4743ab..e1a6f73 100644 --- a/assets/js/3rd/others/clipboard.js +++ b/assets/js/3rd/others/clipboard.js @@ -14,12 +14,11 @@ NexT.plugins.others.clipboard = function () { let lang = codeblock.className; let copyBtn = document.createElement('div'); copyBtn.classList.add('copy-btn'); - codeblock.parentNode .appendChild(copyBtn); + codeblock.parentNode.appendChild(copyBtn); element.addEventListener('mouseleave', () => { setTimeout(() => { - copyBtn.classList.remove('copied'); - copyBtn.classList.remove('copieduncopied'); + copyBtn.classList.remove('copied','uncopied'); }, 300); }); @@ -29,8 +28,8 @@ NexT.plugins.others.clipboard = function () { ch.classList.add(lang); ch.insertAdjacentHTML('afterbegin', ''); - ch.addEventListener('click', function () { - element.classList.toggle('hidden-code'); + ch.addEventListener('click', function () { + element.classList.toggle('hidden-code'); ch.querySelector('.collapse-btn').classList.toggle('collapse'); }, false); From 60b14e65e9959a832450002e9b7a7f0613d886f0 Mon Sep 17 00:00:00 2001 From: elkan1788 Date: Fri, 24 Jan 2025 21:47:06 +0800 Subject: [PATCH 33/42] :sparkles: Closed #148, add multiple lananguages support. --- assets/css/_common/outline/footer/index.scss | 140 ++++++++++++++++++- assets/js/next-boot.js | 1 + assets/js/utils.js | 61 ++++++-- layouts/partials/footer.html | 21 ++- layouts/partials/head/script/global.html | 5 - layouts/partials/init.html | 1 + layouts/partials/widgets.html | 2 - static/css/google-translate.min.css | 1 - static/imgs/flags/en-US.png | Bin 0 -> 2288 bytes static/imgs/flags/fr-FR.png | Bin 0 -> 596 bytes static/imgs/flags/zh-CN.png | Bin 0 -> 617 bytes 11 files changed, 206 insertions(+), 26 deletions(-) delete mode 100644 static/css/google-translate.min.css create mode 100644 static/imgs/flags/en-US.png create mode 100644 static/imgs/flags/fr-FR.png create mode 100644 static/imgs/flags/zh-CN.png diff --git a/assets/css/_common/outline/footer/index.scss b/assets/css/_common/outline/footer/index.scss index c07848a..3d7a3ee 100644 --- a/assets/css/_common/outline/footer/index.scss +++ b/assets/css/_common/outline/footer/index.scss @@ -29,7 +29,143 @@ font-size: $font-size-smallest; } - .google-translate { + .i18n-translate { + display: flex; + justify-content: center; + + .fa { + font-size: $font-size-largest; + margin: auto 0; + line-height: normal; + } + + .lang-select, .lang-options { + + .flag-icon { + background-size: cover; + width: 30px; + height: 20px; + display: none; + } + + .flag-icon-zh-cn { + background-image: url("/imgs/flags/zh-CN.png"); + } + + .flag-icon-en-us { + background-image: url("/imgs/flags/en-US.png"); + } + + .flag-icon-fr-fr { + background-image: url("/imgs/flags/fr-FR.png"); + } + } + + .lang-select { + + .flag-icon { + display: block; + } + } + + .lang-select { + margin-left: 16px; + position: relative; + display: inline-block; + line-height: 1.25; + + .fa { + font-size: $font-size-large; + } + + .selected-option { + display: flex; + align-items: center; + cursor: pointer; + padding: 5px; + border: 1px solid #ccc; + border-radius: 4px; + justify-content: center; + width: 140px; + + /* &:hover { + + .lang-options { + display: block; + opacity: 1; + transform: translateY(0); + } + } */ + + .selected-language { + margin: 0 10px; + } + } + + .lang-options { + display: none; + position: absolute; + top: 100%; + left: 0; + right: 0; + border: 1px solid var(--border-color); + border-top: none; + border-radius: 0 0 4px 4px; + background-color: #ffffff; + opacity: 0; + transform: translateY(-10px); + transition: opacity 0.3s ease, transform 0.3s ease; + z-index: 1; + + &:hover { + display: block; + opacity: 1; + transform: translateY(0); + } + + .lang-option { + padding: 5px; + cursor: pointer; + display: flex; + justify-content: left; + padding-left: 14px; + + &:hover { + background-color: var(--selection-bg); + } + + .lang-name { + margin: 0 16px 0 8px; + } + } + } + } + } + + /* select { + margin-left: 10px; + + option { + font-size: $font-size-small; + background-repeat: no-repeat; + background-position: right center; + padding-right: 30px; + background-size: cover; + } + } + + .flag-icon-zh-cn { + background-image: url("../imgs/flags/zh-CN.png"); + } + + .flag-icon-en-us { + background-image: url("../imgs/flags/en-US.png"); + } + + .flag-icon-fr-fr { + background-image: url("../imgs/flags/fr-FR.png"); + } + } */ + /* .google-translate { display: flex; justify-content: center; .fa { @@ -37,7 +173,7 @@ margin: auto 0; line-height: normal; } - } + } */ @if $footer_vendors_enable { .vendors-list { diff --git a/assets/js/next-boot.js b/assets/js/next-boot.js index b6c3ed2..1fe057c 100644 --- a/assets/js/next-boot.js +++ b/assets/js/next-boot.js @@ -60,6 +60,7 @@ NexT.boot.registerEvents = function() { NexT.boot.refresh = function() { NexT.utils.fmtSiteInfo(); + NexT.utils.registerLangSelect(); if (!NexT.CONFIG.page.isPage) return; diff --git a/assets/js/utils.js b/assets/js/utils.js index 1050fca..16430f0 100644 --- a/assets/js/utils.js +++ b/assets/js/utils.js @@ -499,22 +499,59 @@ NexT.utils = { const isSubPath = !NexT.CONFIG.root.startsWith(target.pathname) && location.pathname.startsWith(target.pathname); target.classList.toggle('menu-item-active', target.hostname === location.hostname && (isSamePath || isSubPath)); }); - }, + },*/ registerLangSelect: function() { - const selects = document.querySelectorAll('.lang-select'); - selects.forEach(sel => { - sel.value = NexT.CONFIG.page.lang; - sel.addEventListener('change', () => { - const target = sel.options[sel.selectedIndex]; - document.querySelectorAll('.lang-select-label span').forEach(span => { - span.innerText = target.text; - }); - // Disable Pjax to force refresh translation of menu item - window.location.href = target.dataset.href; + let selects = document.getElementById('lang-select'); + if (!selects) return; + + let selected = selects.querySelector('#lang-selected'); + let selectedVal = selected.querySelectorAll('span'); + let flagIcon = selectedVal[0]; + let langName = selectedVal[1]; + let selectIcon = selected.querySelector('i'); + + + let options = selects.querySelectorAll('#lang-options>div'); + let optionsDom = options[0].parentNode; + options.forEach(option => { + option.addEventListener('click', () => { + let langCode = option.getAttribute('lang-code'); + flagIcon.className = 'flag-icon flag-icon-'+langCode; + langName.innerHTML = option.getAttribute('lang-name'); + selectIcon.className = 'fa fa-chevron-down'; + optionsDom.style.opacity = '0'; + optionsDom.style.transform = 'translateY(-10px)'; + + const currentUrl = window.location.href; + const newUrl = currentUrl.replace(/(\/[^\/]+)?(\/[^\/]+)?$/, `/${langCode}$1$2`); + + setTimeout(() => { + optionsDom.style.display = 'none'; + window.location.href = newUrl; + }, 300); }); + }); + + selected.addEventListener('mouseenter', function() { + selectIcon.className = 'fa fa-chevron-up'; + optionsDom.style.display = 'block'; + optionsDom.style.opacity = '1'; + optionsDom.style.transform = 'translateY(0)'; + }); - },*/ + + optionsDom.addEventListener('mouseleave', function() { + selectIcon.className = 'fa fa-chevron-down'; + optionsDom.style.opacity = '0'; + optionsDom.style.transform = 'translateY(-10px)'; + + setTimeout(() => { + optionsDom.style.display = 'none'; + }, 300); + }); + + }, registerSidebarTOC: function () { const toc = document.getElementById('TableOfContents'); diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 24bfa31..1756d3f 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -1,10 +1,23 @@ {{ $ft := .Site.Params.footer }} -{{ if $ft.translate }} -
    +
    -
    +
    +
    + + {{ .Site.Language.LanguageName }} + +
    +
    + {{ range .Site.Languages }} +
    + + {{ .LanguageName }} +
    + {{ end }} +
    +
    +
    -{{ end }} {{ end }} - {{ if .Site.Params.footer.translate }}
    - {{ end }}
    diff --git a/static/css/google-translate.min.css b/static/css/google-translate.min.css deleted file mode 100644 index 2ba6c46..0000000 --- a/static/css/google-translate.min.css +++ /dev/null @@ -1 +0,0 @@ -@charset "UTF-8";:root{--gt-blue:#2640b2;--gt-border:#d1d5db}@keyframes "goog-te-spinner-rotator"{0%{transform:rotate(0)}100%{transform:rotate(270deg)}}@keyframes "goog-te-spinner-dash"{0%{stroke-dashoffset:187}50%{stroke-dashoffset:46.75;transform:rotate(135deg)}100%{stroke-dashoffset:187;transform:rotate(450deg)}}.goog-te-banner-frame{left:0;top:0;height:39px;width:100%;z-index:10000001;position:fixed;border:none;border-bottom:1px solid #6b90da;margin:0;box-shadow:0 0 8px 1px #999999;_position:absolute}.goog-te-menu-frame{z-index:10000002;position:fixed;box-shadow:.5rem .875rem 2.375rem rgba(39,44,49,6%),.0625rem .1875rem .5rem rgba(39,44,49,3%);_position:absolute}.goog-te-ftab-frame{z-index:10000000;border:none;margin:0}.goog-te-gadget{font-family:arial;font-size:11px;color:#666;white-space:nowrap;display:inline-flex}.goog-te-gadget img{vertical-align:middle;border:none;display:inline-block}.goog-te-gadget .goog-te-combo{margin:4px 0}.goog-te-gadget div:first-child{margin:0 10px}.goog-te-gadget-simple{background-color:#fff;border-left:1px solid #d5d5d5;border-top:1px solid #9b9b9b;border-bottom:1px solid #e8e8e8;border-right:1px solid #d5d5d5;font-size:10pt;display:inline-block;padding-top:1px;padding-bottom:2px;cursor:pointer;zoom:1;*display:inline}.goog-te-gadget-simple .goog-te-menu-value{color:#000}.goog-te-gadget-simple .goog-te-menu-value span{text-decoration:none}.goog-te-gadget-icon{margin-left:2px;margin-right:2px;width:19px;height:19px;border:none;vertical-align:middle}.goog-te-combo{margin-left:4px;margin-right:4px;vertical-align:baseline;*vertical-align:middle;font-family:arial;font-size:10pt}.goog-logo-link{font-size:12px;font-weight:700;color:#444;text-decoration:none;margin:0 5px;border-bottom:0}.goog-logo-link:link{font-size:12px;font-weight:700;color:#444;text-decoration:none}.goog-logo-link:visited{font-size:12px;font-weight:700;color:#444;text-decoration:none}.goog-logo-link:hover{font-size:12px;font-weight:700;color:#444;text-decoration:none}.goog-logo-link:active{font-size:12px;font-weight:700;color:#444;text-decoration:none}.goog-te-banner{margin:0;background-color:#fff;overflow:hidden}.goog-te-banner .goog-logo-link{display:block;margin:0 10px;padding-top:2px;padding-left:4px}.goog-te-banner *{font-family:arial;font-size:10pt}.goog-te-banner img{border:none}.goog-te-banner table tbody tr td:nth-child(2){display:none}.goog-close-link{display:block;margin:0 10px}.goog-te-ftab{margin:0;background-color:#fff;white-space:nowrap}.goog-te-ftab *{font-family:arial;font-size:10pt}.goog-te-menu{background-color:#fff;text-decoration:none;border:2px solid #c3d9ff;overflow-y:scroll;overflow-x:hidden;position:absolute;left:0;top:0}.goog-te-menu *{font-family:arial;font-size:10pt}.goog-te-menu2{background-color:#fff;text-decoration:none;overflow:hidden;padding:4px;border:1px solid var(--gt-border);border-radius:4px}.goog-te-menu2 *{font-family:arial;font-size:10pt}.goog-te-balloon{background-color:#fff;overflow:hidden;padding:8px;border:none;border-radius:10px}.goog-te-balloon *{font-family:arial;font-size:10pt}.goog-te-balloon img{border:none}.goog-te-banner-content{color:#000}.goog-te-banner-content img{vertical-align:middle}.goog-te-banner-info{color:#666;vertical-align:top;margin-top:0;font-size:7pt}.goog-te-banner-margin{width:8px}.goog-te-button div{border:1px solid var(--gt-border);height:20px}.goog-te-button button{background:0 0;border:none;cursor:pointer;height:20px;overflow:hidden;margin:0;vertical-align:top;white-space:nowrap}.goog-te-button button:active{background:repeat #ccc}.goog-te-ftab-link{text-decoration:none;font-weight:700;font-size:10pt;border:1px outset #888;padding:6px 10px;white-space:nowrap;position:absolute;left:0;top:0}.goog-te-ftab-link img{margin-left:2px;margin-right:2px;width:19px;height:19px;border:none;vertical-align:middle}.goog-te-ftab-link span{text-decoration:underline;margin-left:2px;margin-right:2px;vertical-align:middle}.goog-float-top .goog-te-ftab-link{padding:2px;border-top-width:0}.goog-float-bottom .goog-te-ftab-link{padding:2px;border-bottom-width:0}.goog-te-menu-value{text-decoration:none;color:var(--gt-blue);white-space:nowrap;margin-left:4px;margin-right:4px}.goog-te-menu-value span{text-decoration:underline}.goog-te-menu-value span::after{content:"▼"}.goog-te-menu-value img{margin-left:2px;margin-right:2px;display:none}.goog-te-menu-item{padding:3px;text-decoration:none;color:var(--gt-blue);background:#fff}.goog-te-menu-item:link{color:var(--gt-blue);background:#fff}.goog-te-menu-item:visited{color:#551a8b}.goog-te-menu-item:hover{background:#c3d9ff}.goog-te-menu-item:active{color:var(--gt-blue)}.goog-te-menu2-colpad{width:16px}.goog-te-menu2-separator{margin:6px 0;height:1px;background-color:var(--gt-border);overflow:hidden}.goog-te-menu2-item{text-decoration:none}.goog-te-menu2-item div{padding:4px;color:var(--gt-blue);background:#fff}.goog-te-menu2-item .indicator{display:none}.goog-te-menu2-item:link div{color:var(--gt-blue);background:#fff}.goog-te-menu2-item:visited div{color:var(--gt-blue);background:#fff}.goog-te-menu2-item:active div{color:var(--gt-blue);background:#fff}.goog-te-menu2-item:hover div{color:#fff;background:#36c;border-radius:2px}.goog-te-menu2-item-selected{text-decoration:none}.goog-te-menu2-item-selected div{padding:4px;color:#000;font-weight:700}.goog-te-menu2-item-selected .indicator{display:auto}.goog-te-menu2-item-selected .text{padding-left:4px;padding-right:4px}.goog-te-menu2-item-selected:link div{color:#000;font-weight:700}.goog-te-menu2-item-selected:visited div{color:#000;font-weight:700}.goog-te-menu2-item-selected:hover div{color:#000;font-weight:700}.goog-te-menu2-item-selected:active div{color:#000;font-weight:700}.goog-te-balloon-frame{background-color:#fff;border:1px solid #6b90da;box-shadow:.5rem .875rem 2.375rem rgba(39,44,49,6%),.0625rem .1875rem .5rem rgba(39,44,49,3%);border-radius:8px}.goog-te-balloon-text{margin-top:6px}.goog-te-balloon-zippy{margin-top:6px;white-space:nowrap}.goog-te-balloon-zippy *{vertical-align:middle}.goog-te-balloon-zippy .minus{background-image:url(//www.google.com/images/zippy_minus_sm.gif)}.goog-te-balloon-zippy .plus{background-image:url(//www.google.com/images/zippy_plus_sm.gif)}.goog-te-balloon-zippy span{color:#00c;text-decoration:underline;cursor:pointer;margin:0 4px}.goog-te-balloon-form{margin:6px 0 0}.goog-te-balloon-form form{margin:0}.goog-te-balloon-form form textarea{margin-bottom:4px;width:100%}.goog-te-balloon-footer{margin:6px 0 4px}.goog-te-spinner-pos{z-index:1000;position:fixed;transition-delay:.6s;left:-1000px;top:-1000px}.goog-te-spinner-animation{background:#ccc;display:flex;align-items:center;justify-content:center;width:104px;height:104px;border-radius:50px;background:#fff url(//www.gstatic.com/images/branding/product/2x/translate_24dp.png)50% no-repeat;transition:all .6s ease-in-out;transform:scale(.4);opacity:0}.goog-te-spinner-animation-show{transform:scale(.5);opacity:1}.goog-te-spinner{margin:2px 0 0 2px;animation:goog-te-spinner-rotator 1.4s linear infinite}.goog-te-spinner-path{stroke-dasharray:187;stroke-dashoffset:0;stroke:#4285f4;transform-origin:center;animation:goog-te-spinner-dash 1.4s ease-in-out infinite}#goog-gt-tt{color:#222;background-color:#fff;border:1px solid #eee;box-shadow:0 4px 16px rgba(0,0,0,.2);display:none;font-family:arial;font-size:10pt;width:420px;padding:12px;position:absolute;z-index:10000}#goog-gt-tt .original-text{clear:both;font-size:10pt;position:relative;text-align:justify;width:100%}#goog-gt-tt .title{color:#999;font-family:arial,sans-serif;margin:4px 0;text-align:left}#goog-gt-tt .close-button{display:none}#goog-gt-tt .logo{float:left;margin:0}#goog-gt-tt .activity-links{display:inline-block}#goog-gt-tt .started-activity-container{display:none;width:100%}#goog-gt-tt .activity-root{margin-top:20px}#goog-gt-tt .left{float:left}#goog-gt-tt .right{float:right}#goog-gt-tt .bottom{min-height:15px;position:relative;height:1%}#goog-gt-tt .status-message{background:linear-gradient(top,#29910d 0%,#20af0e 100%);background:#29910d;border-radius:4px;box-shadow:inset 0 2px 2px #1e6609;color:#fff;font-size:9pt;font-weight:bolder;margin-top:12px;padding:6px;text-shadow:1px 1px 1px #1e6609}#goog-gt-tt .activity-link{color:#15c;cursor:pointer;font-family:arial;font-size:11px;margin-right:15px;text-decoration:none}#goog-gt-tt textarea{font-family:arial;resize:vertical;width:100%;margin-bottom:10px;border-radius:1px;border:1px solid #d9d9d9;border-top:1px solid silver;font-size:13px;height:auto;overflow-y:auto;padding:1px}#goog-gt-tt textarea:focus{box-shadow:inset 0 1px 2px rgba(0,0,0,.3);border:1px solid #4d90fe;outline:none}#goog-gt-tt .activity-cancel{margin-right:10px}#goog-gt-tt .translate-form{min-height:25px;vertical-align:middle;padding-top:8px}#goog-gt-tt .translate-form .activity-form{margin-bottom:5px;margin-bottom:0}#goog-gt-tt .translate-form .activity-form input{display:inline-block;min-width:54px;*min-width:70px;border:1px solid #dcdcdc;border:1px solid rgba(0,0,0,.1);text-align:center;color:#444;font-size:11px;font-weight:700;height:27px;outline:0;padding:0 8px;vertical-align:middle;line-height:27px;margin:0 16px 0 0;box-shadow:0 1px 2px rgba(0,0,0,.1);border-radius:2px;transition:all .218s;background-color:#f5f5f5;background-image:linear-gradient(top,#f5f5f5,#f1f1f1);-webkit-user-select:none;-moz-user-select:none;cursor:default}#goog-gt-tt .translate-form .activity-form input:hover{border:1px solid #c6c6c6;color:#222;transition:all 0s;background-color:#f8f8f8;background-image:linear-gradient(top,#f8f8f8,#f1f1f1);border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input:active{border:1px solid #c6c6c6;color:#333;background-color:#f6f6f6;background-image:linear-gradient(top,#f6f6f6,#f1f1f1);border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input:focus{outline:none;border:1px solid #4d90fe;z-index:4!important;border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input:focus #goog-gt-tt .translate-form .activity-form input.focus #goog-gt-tt .translate-form .activity-form input:active{box-shadow:inset 0 0 0 1px rgba(255,255,255,.5)}#goog-gt-tt .translate-form .activity-form input:focus:active{box-shadow:inset 0 0 0 1px rgba(255,255,255,.5)}#goog-gt-tt .translate-form .activity-form input.focus:active{box-shadow:inset 0 0 0 1px rgba(255,255,255,.5)}#goog-gt-tt .translate-form .activity-form input.focus{outline:none;border:1px solid #4d90fe;z-index:4!important;border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input.selected{background-color:#eee;background-image:linear-gradient(top,#eeeeee,#e0e0e0);box-shadow:inset 0 1px 2px rgba(0,0,0,.1);border:1px solid #ccc;color:#333}#goog-gt-tt .translate-form .activity-form input.activity-submit{color:#fff;border-color:#3079ed;background-color:#4d90fe;background-image:linear-gradient(top,#4d90fe,#4787ed)}#goog-gt-tt .translate-form .activity-form input.activity-submit:hover{box-shadow:inset 0 0 0 1px #fff,0 1px 1px rgba(0,0,0,.1);border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input.activity-submit:hover #goog-gt-tt .translate-form .activity-form input.activity-submit:focus{border-color:#3079ed;background-color:#357ae8;background-image:linear-gradient(top,#4d90fe,#357ae8)}#goog-gt-tt .translate-form .activity-form input.activity-submit:focus{border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input.activity-submit:active{border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input.activity-submit.focus{border-color:#3079ed}#goog-gt-tt .translate-form .activity-form input.activity-submit.focus #goog-gt-tt .translate-form .activity-form input.activity-submit:active{border-color:#3079ed;background-color:#357ae8;background-image:linear-gradient(top,#4d90fe,#357ae8)}#goog-gt-tt .gray{color:#999;font-family:arial,sans-serif}#goog-gt-tt .alt-helper-text{color:#999;font-size:11px;font-family:arial,sans-serif;margin:15px 0 5px}#goog-gt-tt .alt-error-text{color:#800;display:none;font-size:9pt}#goog-gt-tt .alt-menu.goog-menu{background:#fff;border:1px solid #ddd;box-shadow:0 2px 4px #99a;min-width:0;outline:none;padding:0;position:absolute;z-index:2000}#goog-gt-tt .alt-menu .goog-menuitem{cursor:pointer;padding:2px 5px 5px;margin-right:0;border-style:none}#goog-gt-tt .alt-menu .goog-menuitem h1{font-size:100%;font-weight:700;margin:4px 0}#goog-gt-tt .alt-menu .goog-menuitem strong{color:#345aad}#goog-gt-tt .alt-menu div.goog-menuitem:hover{background:#ddd}#goog-gt-tt .goog-submenu-arrow{text-align:right;position:absolute;right:0;left:auto}#goog-gt-tt .goog-menuitem-rtl .goog-submenu-arrow{text-align:left;position:absolute;left:0;right:auto}#goog-gt-tt .gt-hl-text{background-color:#f1ea00;border-radius:4px;box-shadow:rgba(0,0,0,.5)3px 3px 4px;box-sizing:border-box;color:#f1ea00;cursor:pointer;margin:-2px -2px -2px -3px;padding:2px 2px 2px 3px;position:relative}#goog-gt-tt .trans-target-highlight{background-color:#f1ea00;border-radius:4px;box-shadow:rgba(0,0,0,.5)3px 3px 4px;box-sizing:border-box;color:#f1ea00;cursor:pointer;margin:-2px -2px -2px -3px;padding:2px 2px 2px 3px;position:relative;color:#222}#goog-gt-tt .gt-hl-layer{color:#fff;position:absolute!important}#goog-gt-tt .trans-target{background-color:#c9d7f1;border-radius:4px 4px 0 0;box-shadow:rgba(0,0,0,.5)3px 3px 4px;box-sizing:border-box;cursor:pointer;margin:-2px -2px -2px -3px;padding:2px 2px 3px 3px;position:relative}#goog-gt-tt .trans-target .trans-target-highlight{background-color:#c9d7f1;border-radius:4px 4px 0 0;box-shadow:rgba(0,0,0,.5)3px 3px 4px;box-sizing:border-box;cursor:pointer;margin:-2px -2px -2px -3px;padding:2px 2px 3px 3px;position:relative}#goog-gt-tt .trans-edit{background-color:transparent;border:1px solid #4d90fe;border-radius:0;margin:-2px;padding:1px}#goog-gt-tt .gt-trans-highlight-l{border-left:2px solid red;margin-left:-2px}#goog-gt-tt .gt-trans-highlight-r{border-right:2px solid red;margin-right:-2px}#goog-gt-tt #alt-input{padding:2px}#goog-gt-tt #alt-input-text{font-size:11px;padding:2px 2px 3px;margin:0;background-color:#fff;color:#333;border:1px solid #d9d9d9;border-top:1px solid silver;display:inline-block;vertical-align:top;height:21px;box-sizing:border-box}#goog-gt-tt #alt-input-text:hover{border:1px solid #b9b9b9;border-top:1px solid #a0a0a0;box-shadow:inset 0 1px 2px rgba(0,0,0,.1)}#goog-gt-tt #alt-input-text:focus{box-shadow:inset 0 1px 2px rgba(0,0,0,.3);outline:none;border:1px solid #4d90fe}#goog-gt-tt #alt-input-submit{font-size:11px;padding:2px 6px 3px;margin:0 0 0 2px;height:21px}div#goog-gt-tt{padding:10px 14px}.gt-hl-layer{clear:both;font-size:10pt;position:relative;text-align:justify;width:100%}.goog-text-highlight{background-color:#c9d7f1;box-shadow:2px 2px 4px #9999aa;box-sizing:border-box;position:relative} \ No newline at end of file diff --git a/static/imgs/flags/en-US.png b/static/imgs/flags/en-US.png new file mode 100644 index 0000000000000000000000000000000000000000..fc24fa5f5b2d066b251e39f023ca6a22d80e10d9 GIT binary patch literal 2288 zcmVoG0A_|6tM^K15B}Oov zS`)$PBTXlzg4UV#kF;sp#A#|f6PjjhW2a50?ZnYelg=?>h&2IByTbt*ELA0>MKeVTPDJ zR5W9c-EKwF$SnvKU?wmCMV<7}p1HLNB>)}^dl)Q}^C1Doh>M?GXL`S6N4^Q$Sz^XY zip}pnxg!tpaS;->eS02~lB4wg8DJH}b_B2;ifYG9ip6e+Mb$66%ca`%OS?A+=jNuF z8p+B`HeqYi3lXt&zJx_Bn~$id`<;BjV9&lY?LzF~0zgdq zrT=z!>Dbss2oDd%rAzHngV|XLsHtg|u-x2K{PSOzB`j~_`{!0 z;BSAwU=aTO>)*xEV`ouWdB!08>jPytd#(wG4!w)-b(}E`NT|M9*^WssiafQm5VMo; zz19L|@@cto5SErX4@R5`VSTnwpD|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01vW}c(LPa4KkPjCPMi57;F#_AWhlT*`KeIEaaG) z8N_zgrx0LlV8BbvOH-zc01zA=?$ZD#hKKyW3E(T?|CK^Vl5$v4$uJK4vL8JQu@6a& z^RyBrU+1t)MBl^<8k>M%6~w|Ajye;?^kLV6yzF1tJdh6bu!F+FyjEGpZ6JLY)Ag@I zTO9X_<5Lsqy5SE87d%Cd3g z1R|mRTY%6K2oVXs4}HkTGxthV9Q74~7?C?B zV=&|;#quEOZjf+xg5Rmj3`mqLSpi7mGsx0000< KMNUMnLSTX}@mRG0 literal 0 HcmV?d00001 diff --git a/static/imgs/flags/fr-FR.png b/static/imgs/flags/fr-FR.png new file mode 100644 index 0000000000000000000000000000000000000000..23b7c0b163c12ce043a81a15628b4e4b4c21f7ad GIT binary patch literal 596 zcmV-a0;~OrP)@YezE#Ls4lIqd7J<%Yt{uz0zb304(*XET&xZ9Q?VWXuyoa6xDK-Oy~ zzxOvhu&s8d^UVo6buMi?m=EFY8l<3D^JM!J0(v%qq^H@yf6hCGX-n6X@b{(iwp<9= zt!^Bezt>1h%ABz5BG_--jPU8$x+I%!<5W7iXw^(1gz=1hDAd-AYWlQP^|q%fxvThX z=e5T`JggEcL#0i#uyG7~0*BtE_W~U}Vq8*AJ;mF}xc zTiA_4nJ2$g^^GF4iGu;aewVwn>p>#lR`{F7x1*MbTUwAxzgII%gynTRiKHrv$s*y z(C{$3MzyLPgS1ez>XC+9dKcJ)mU`aVv2K3igQXodt5!LcRrjZy+_b*`&*i<(U)(zN z?9)-kdpD*vm&xL|A@bQl1=*h?-x@Wu1qpEo%!4H z_j8-=NfY-yIU>JC?9f8x^2PjIPr|;ntB8y{#loWlVxh=3VJ@7@W$%V#I0 zF1= Date: Sat, 25 Jan 2025 11:15:11 +0800 Subject: [PATCH 34/42] :lipstick: Update config file & remove google translate. --- assets/js/next-boot.js | 5 ++++- assets/js/utils.js | 7 +++---- exampleSite/config.yaml | 23 +++++++++++++++++++---- i18n/{en.yaml => en-us.yaml} | 0 i18n/{fr.yaml => fr-fr.yaml} | 0 layouts/_default/baseof.html | 3 ++- layouts/partials/footer.html | 19 ------------------- layouts/partials/init.html | 2 +- layouts/partials/langs.html | 23 +++++++++++++++++++++++ layouts/partials/widgets.html | 6 ++++-- 10 files changed, 56 insertions(+), 32 deletions(-) rename i18n/{en.yaml => en-us.yaml} (100%) rename i18n/{fr.yaml => fr-fr.yaml} (100%) create mode 100644 layouts/partials/langs.html diff --git a/assets/js/next-boot.js b/assets/js/next-boot.js index 1fe057c..c3123cd 100644 --- a/assets/js/next-boot.js +++ b/assets/js/next-boot.js @@ -60,7 +60,10 @@ NexT.boot.registerEvents = function() { NexT.boot.refresh = function() { NexT.utils.fmtSiteInfo(); - NexT.utils.registerLangSelect(); + + if (NexT.CONFIG.isMultiLang) { + NexT.utils.registerLangSelect(); + } if (!NexT.CONFIG.page.isPage) return; diff --git a/assets/js/utils.js b/assets/js/utils.js index 16430f0..e278601 100644 --- a/assets/js/utils.js +++ b/assets/js/utils.js @@ -523,12 +523,11 @@ NexT.utils = { optionsDom.style.opacity = '0'; optionsDom.style.transform = 'translateY(-10px)'; - const currentUrl = window.location.href; - const newUrl = currentUrl.replace(/(\/[^\/]+)?(\/[^\/]+)?$/, `/${langCode}$1$2`); - + let url = option.getAttribute('lang-url'); + setTimeout(() => { optionsDom.style.display = 'none'; - window.location.href = newUrl; + window.location.href = url; }, 300); }); }); diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 2ec80a4..63af6c9 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -23,6 +23,24 @@ theme: hugo-theme-next # Default laguage & code for website defaultContentLanguage: zh-cn languageCode: zh-CN +# 多语言配置 +# Multi-language settings +# languages: +# zh-cn: +# languageCode: zh-CN +# languageDirection: ltr +# languageName: "简体中文" +# weight: 1 +# en-us: +# languageCode: en-US +# languageDirection: ltr +# languageName: English +# weight: 2 +# fr-fr: +# languageCode: fr-FR +# languageDirection: ltr +# languageName: French +# weight: 2 # 是否包含中文,日语,韩文 # Whether contains Chinese, Japanese and Korean hasCJKLanguage: true @@ -376,10 +394,7 @@ params: # 站点底部设置 # Footer Settings # --------------------------------------------------------------- - footer: - # 启动谷歌翻译功能 - # Enable google translate in footer - translate: false + footer: # 站点开始年份,默认为当下时间的年份 # Specify the year when the site was setup. # If not defined, current year will be used. diff --git a/i18n/en.yaml b/i18n/en-us.yaml similarity index 100% rename from i18n/en.yaml rename to i18n/en-us.yaml diff --git a/i18n/fr.yaml b/i18n/fr-fr.yaml similarity index 100% rename from i18n/fr.yaml rename to i18n/fr-fr.yaml diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index b4851e7..4fef69c 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -27,7 +27,7 @@ {{ end }} - {{ partial "widgets.html" . }} + {{ partialCached "widgets.html" . }}
    {{ block "main" . }}{{ end }} @@ -38,6 +38,7 @@
    diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 1756d3f..f69d2d6 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -1,23 +1,4 @@ {{ $ft := .Site.Params.footer }} -
    - -
    -
    - - {{ .Site.Language.LanguageName }} - -
    -
    - {{ range .Site.Languages }} -
    - - {{ .LanguageName }} -
    - {{ end }} -
    -
    - -