From ec821a56c5d76a43b3c60ec173758d556fdbea9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=BB=93=E5=8F=91=E5=8F=97=E9=95=BF=E7=94=9F?= Date: Fri, 25 May 2018 11:53:42 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=9E=E9=AA=8C=E5=AE=A4=E9=93=BE=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- themes/hexo-theme-xups/_config.yml | 16 ++++++---------- .../hexo-theme-xups/layout/_partial/sidebar.ejs | 8 ++++---- .../layout/_widget/friend_links.ejs | 8 -------- themes/hexo-theme-xups/layout/_widget/links.ejs | 8 ++++++++ 4 files changed, 18 insertions(+), 22 deletions(-) delete mode 100644 themes/hexo-theme-xups/layout/_widget/friend_links.ejs create mode 100644 themes/hexo-theme-xups/layout/_widget/links.ejs diff --git a/themes/hexo-theme-xups/_config.yml b/themes/hexo-theme-xups/_config.yml index bfc4cbc..8a9f4cc 100644 --- a/themes/hexo-theme-xups/_config.yml +++ b/themes/hexo-theme-xups/_config.yml @@ -94,19 +94,15 @@ archives: date_format: YYYY年MM月 #---------------------------- -# 友情链接 +# 常用链接 #---------------------------- -friends: - enable: false +links: + enable: true list: 1: - name: google - title: 谷歌 - link: https://www.google.com.hk/ - 2: - name: youtube - title: 油管 - link: https://www.youtube.com/ + name: 实验室 + link: /lab/ + target: _self #---------------------------- # 头部链接 diff --git a/themes/hexo-theme-xups/layout/_partial/sidebar.ejs b/themes/hexo-theme-xups/layout/_partial/sidebar.ejs index 343b78a..f6114a7 100644 --- a/themes/hexo-theme-xups/layout/_partial/sidebar.ejs +++ b/themes/hexo-theme-xups/layout/_partial/sidebar.ejs @@ -19,11 +19,11 @@ <% } %> - <% if (theme.friends.enable && theme.friends['list']) { %> - + <% if (theme.links.enable && theme.links['list']) { %> +
-

友情链接

- <%- partial('_widget/friend_links') %> +

常用链接

+ <%- partial('_widget/links') %>
<% } %> diff --git a/themes/hexo-theme-xups/layout/_widget/friend_links.ejs b/themes/hexo-theme-xups/layout/_widget/friend_links.ejs deleted file mode 100644 index 710941b..0000000 --- a/themes/hexo-theme-xups/layout/_widget/friend_links.ejs +++ /dev/null @@ -1,8 +0,0 @@ - - \ No newline at end of file diff --git a/themes/hexo-theme-xups/layout/_widget/links.ejs b/themes/hexo-theme-xups/layout/_widget/links.ejs new file mode 100644 index 0000000..1a44207 --- /dev/null +++ b/themes/hexo-theme-xups/layout/_widget/links.ejs @@ -0,0 +1,8 @@ + + \ No newline at end of file