diff --git a/_config.yml b/_config.yml index 179e7307..31898f18 100644 --- a/_config.yml +++ b/_config.yml @@ -1052,6 +1052,18 @@ links: avatar: "/img/favicon.png" } + # 失效/未激活的友链Add commentMore actions + inactive: + enable: false + label: "异常友链 | 长时间不可访问站点" + inactiveItems: + - { + title: "404 Links", + intro: "404 Links", + link: "https://hexo.fluid-dev.com/404", + avatar: "/img/favicon.png" + } + # 当成员头像加载失败时,替换为指定图片 # When the member avatar fails to load, replace the specified image onerror_avatar: /img/avatar.png diff --git a/languages/de.yml b/languages/de.yml index d6a541cc..b9ece040 100644 --- a/languages/de.yml +++ b/languages/de.yml @@ -32,6 +32,9 @@ links: menu: 'Weblinks' title: 'Weblinks' subtitle: 'Weblinks' + inactive: + collapsed: 'Erweitern' + expanded: 'Reduzieren' page404: menu: 'Die Seite wurde nicht gefunden' diff --git a/languages/en.yml b/languages/en.yml index b54328d5..a52b6745 100644 --- a/languages/en.yml +++ b/languages/en.yml @@ -32,6 +32,9 @@ links: menu: 'Links' title: 'Links' subtitle: 'Links' + inactive: + collapsed: 'Expand' + expanded: 'Collapse' page404: menu: 'Page not found' diff --git a/languages/eo.yml b/languages/eo.yml index 68105a2c..63284ed4 100644 --- a/languages/eo.yml +++ b/languages/eo.yml @@ -32,6 +32,9 @@ links: menu: 'Ligoj' title: 'Ligoj' subtitle: 'Ligoj' + inactive: + collapsed: 'Malfermi' + expanded: 'Fermi' page404: menu: 'Paĝo ne trovita' diff --git a/languages/es.yml b/languages/es.yml index 854d2ede..45f2b5f0 100644 --- a/languages/es.yml +++ b/languages/es.yml @@ -32,6 +32,9 @@ links: menu: 'Enlaces' title: 'Enlaces' subtitle: 'Enlaces' + inactive: + collapsed: 'Expandir' + expanded: 'Contraer' page404: menu: 'Página no encontrada' diff --git a/languages/ja.yml b/languages/ja.yml index edbf20ff..16123283 100644 --- a/languages/ja.yml +++ b/languages/ja.yml @@ -32,6 +32,9 @@ links: menu: 'リンク' title: 'リンク' subtitle: 'リンク' + inactive: + collapsed: '開く' + expanded: '閉じる' page404: menu: 'ページが見つかりませんでした' diff --git a/languages/ru.yml b/languages/ru.yml index 20582192..df445ecf 100644 --- a/languages/ru.yml +++ b/languages/ru.yml @@ -32,6 +32,9 @@ links: menu: 'Ссылки' title: 'Ссылки' subtitle: 'Ссылки' + inactive: + collapsed: 'Открыть' + expanded: 'Закрыть' page404: menu: 'Страница не найдена' diff --git a/languages/zh-CN.yml b/languages/zh-CN.yml index 850d755e..57402bf3 100644 --- a/languages/zh-CN.yml +++ b/languages/zh-CN.yml @@ -32,6 +32,9 @@ links: menu: '友链' title: '友链' subtitle: '友情链接' + inactive: + collapsed: '展开内容' + expanded: '收起内容' page404: menu: '页面不存在' diff --git a/languages/zh-HK.yml b/languages/zh-HK.yml index 01a267f6..0b822585 100644 --- a/languages/zh-HK.yml +++ b/languages/zh-HK.yml @@ -32,6 +32,9 @@ links: menu: '連結' title: '交換連結' subtitle: '交換連結' + inactive: + collapsed: '展開內容' + expanded: '收起內容' page404: menu: '頁面不存在' diff --git a/languages/zh-TW.yml b/languages/zh-TW.yml index 42e45ced..efdcd2b3 100644 --- a/languages/zh-TW.yml +++ b/languages/zh-TW.yml @@ -32,6 +32,9 @@ links: menu: '連結' title: '交換連結' subtitle: '交換連結' + inactive: + collapsed: '展開內容' + expanded: '收起內容' page404: menu: '頁面不存在' diff --git a/layout/links.ejs b/layout/links.ejs index aa5e4626..71b59011 100644 --- a/layout/links.ejs +++ b/layout/links.ejs @@ -12,11 +12,12 @@ page.comment = theme.links.comments.type <% for(const each of theme.links.items || []) { %> <% if (!each.title || !each.link) continue %>
- +
<% if (each.avatar || each.image) { %> <% } %> @@ -30,6 +31,60 @@ page.comment = theme.links.comments.type <% } %>
+<% if (theme.links.inactive && theme.links.inactive.enable && theme.links.inactive.inactiveItems) { %> +
+ <% if (theme.links.inactive.label) { %> +
+

<%- theme.links.inactive.label %>

+ +
+ <% } %> + +
+ +
+ + +<% } %> + + <% if(theme.links.custom && theme.links.custom.enable && theme.links.custom.content) { %>