From b241e9d6be8e91410ca122f8ad447e9b7aecb15f Mon Sep 17 00:00:00 2001 From: ycjcl868 <45808948@qq.com> Date: Fri, 20 Dec 2019 22:49:55 +0800 Subject: [PATCH] fix: componentPage --- site/theme/template/Content/MainContent.jsx | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/site/theme/template/Content/MainContent.jsx b/site/theme/template/Content/MainContent.jsx index 7ca01ebd8f..76732ff280 100644 --- a/site/theme/template/Content/MainContent.jsx +++ b/site/theme/template/Content/MainContent.jsx @@ -298,6 +298,7 @@ class MainContent extends Component { {menuItems} ); + const componentPage = /^\/?components/.test(this.props.location.pathname); return (
@@ -321,11 +322,13 @@ class MainContent extends Component {
)} -
-
- + {componentPage && ( +
+
+ +
-
+ )}