Browse Source

fix: componentPage

pull/20281/head
ycjcl868 5 years ago
parent
commit
b241e9d6be
  1. 3
      site/theme/template/Content/MainContent.jsx

3
site/theme/template/Content/MainContent.jsx

@ -298,6 +298,7 @@ class MainContent extends Component {
{menuItems} {menuItems}
</Menu> </Menu>
); );
const componentPage = /^\/?components/.test(this.props.location.pathname);
return ( return (
<div className="main-wrapper"> <div className="main-wrapper">
@ -321,11 +322,13 @@ class MainContent extends Component {
<Article {...this.props} content={localizedPageData} /> <Article {...this.props} content={localizedPageData} />
)} )}
</section> </section>
{componentPage && (
<div className="fixed-widgets"> <div className="fixed-widgets">
<div> <div>
<Button onClick={this.changeTheme}>{theme}</Button> <Button onClick={this.changeTheme}>{theme}</Button>
</div> </div>
</div> </div>
)}
<PrevAndNext prev={prev} next={next} /> <PrevAndNext prev={prev} next={next} />
<Footer /> <Footer />
</Col> </Col>

Loading…
Cancel
Save