diff options
| author | Eltrac <hi@guhub.cn> | 2023-03-17 00:09:13 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-03-17 00:09:13 +0800 |
| commit | a9c3180ecdf84add5d6084a19c9c79eedc14af9b (patch) | |
| tree | d2f9d01c96cad4113317be6fbcfcdb8c1725c1a5 /includes | |
| parent | 004b44e2372088cf3875e75ed245cb2fbc135686 (diff) | |
| parent | 02947175352b377114bf3e4c7bf524cc02cf937b (diff) | |
Merge pull request #24 from LiCaoZ/sidebarCategories
:newspaper: Feat: 支持分类导航 & 部分导航逻辑重构
Diffstat (limited to 'includes')
| -rw-r--r-- | includes/header.php | 2 | ||||
| -rw-r--r-- | includes/sidebar.php | 6 |
2 files changed, 6 insertions, 2 deletions
diff --git a/includes/header.php b/includes/header.php index a74b47a..c1cf591 100644 --- a/includes/header.php +++ b/includes/header.php @@ -18,7 +18,7 @@ $this->need("includes/head.php"); ?> <div class="navbar-dropdown"> <button class="navbar-button navbar-dropup" id="nav-rise"><span>+</span></button> <h2>页面</h2> - <ul class="widget-list"><?php Matcha::pageNav($this, "li"); ?></ul> + <ul class="widget-list"><li><a href="<?php $this->options->siteUrl(); ?>" rel="section">首页</a></li><?php Matcha::pageNav($this, "li"); ?></ul> <h2>分类</h2> <ul class="widget-list widget-category"> <?php $this->widget('Widget_Metas_Category_List')->to($categories); ?> diff --git a/includes/sidebar.php b/includes/sidebar.php index 32df2e7..77109e9 100644 --- a/includes/sidebar.php +++ b/includes/sidebar.php @@ -3,7 +3,11 @@ <aside id="sidebar" class="sidebar" role="complementary"> <section class="widget widget-nav sidebar-nav"> <header id="header" class="header"><?php Matcha::siteName(); ?></header> - <ul class="widget-list"><?php Matcha::pageNav($this, "li"); ?></ul> + <ul class="widget-list"> + <li><a href="<?php $this->options->siteUrl(); ?>" rel="section">首页</a></li> + <?php Matcha::categoryNav($this, "li"); ?> + <?php Matcha::pageNav($this, "li"); ?> + </ul> </section> <!-- 版权信息 --> <section class="widget sidebar-foot"> |
