mirror of
https://jihulab.com/DGP-Studio/Snap.Hutao.Docs.git
synced 2025-11-19 21:16:31 +08:00
✨ 添加 Ducalis 的更新说明
This commit is contained in:
@@ -22,6 +22,37 @@ export default defineUserConfig({
|
|||||||
src: "https://get.microsoft.com/badge/ms-store-badge.bundled.js",
|
src: "https://get.microsoft.com/badge/ms-store-badge.bundled.js",
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
[
|
||||||
|
"script",
|
||||||
|
{},
|
||||||
|
`
|
||||||
|
!function(b,c,f,d,a,e){b.dclsPxl||(((d=b.dclsPxl=function(){d.callMethod?d.callMethod.apply(d,arguments):d.queue.push(arguments)}).push=d).queue=[],(a=c.createElement("script")).async=!0,a.src=f,(e=c.getElementsByTagName("script")[0]).parentNode.insertBefore(a,e))}(window,document,"https://ducalis.io/js/widget.js");
|
||||||
|
dclsPxl("initWidget", {
|
||||||
|
appId: "a64fd9c44c5b0c957fa36f76d39d47a80e5d5869",
|
||||||
|
boardId: "abcf6f090ecb20af83d067f0498ef7c5"
|
||||||
|
});
|
||||||
|
`,
|
||||||
|
],
|
||||||
|
// 创建自定义func用于触发点击事件
|
||||||
|
[
|
||||||
|
"script",
|
||||||
|
{},
|
||||||
|
`!function() {
|
||||||
|
const addDcls = () => {
|
||||||
|
// 查找 aria-label 为“ducalis-changelog-widget”的元素
|
||||||
|
const widget = document.querySelector('[aria-label="ducalis-changelog-widget"]');
|
||||||
|
// 如果找到了元素,且元素没有 ducalis-changelog-widget 的 class,则添加该 class
|
||||||
|
if (widget && !widget.classList.contains('ducalis-changelog-widget')) {
|
||||||
|
widget.classList.add('ducalis-changelog-widget');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 监听路由变化
|
||||||
|
const observer = new MutationObserver(addDcls);
|
||||||
|
observer.observe(document.querySelector('body'), { childList: true, subtree: true });
|
||||||
|
// 页面加载完成后执行一次
|
||||||
|
addDcls();
|
||||||
|
}();`,
|
||||||
|
],
|
||||||
],
|
],
|
||||||
|
|
||||||
locales: {
|
locales: {
|
||||||
|
|||||||
@@ -12,6 +12,12 @@ export const enNavbar = navbar([
|
|||||||
icon: "iconfont icon-install",
|
icon: "iconfont icon-install",
|
||||||
link: "/en/quick-start",
|
link: "/en/quick-start",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
text: "Update Log",
|
||||||
|
icon: "iconfont icon-update",
|
||||||
|
ariaLabel: "ducalis-changelog-widget",
|
||||||
|
link: `javascript:void(0);`,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
text: "Support us",
|
text: "Support us",
|
||||||
icon: "iconfont icon-like",
|
icon: "iconfont icon-like",
|
||||||
|
|||||||
@@ -12,6 +12,12 @@ export const zhNavbar = navbar([
|
|||||||
icon: "iconfont icon-install",
|
icon: "iconfont icon-install",
|
||||||
link: "/zh/quick-start",
|
link: "/zh/quick-start",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
text: "更新日志",
|
||||||
|
icon: "iconfont icon-update",
|
||||||
|
ariaLabel: "ducalis-changelog-widget",
|
||||||
|
link: `javascript:void(0);`,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
text: "支持我们",
|
text: "支持我们",
|
||||||
icon: "iconfont icon-like",
|
icon: "iconfont icon-like",
|
||||||
|
|||||||
Reference in New Issue
Block a user