fix: change subcategory format (#1026)

* fix: change subcategory format

* Fix sidebars

* Refactor

* Fix implementation

* Change format
This commit is contained in:
Yangshun Tay 2018-10-10 08:33:20 -07:00 committed by GitHub
parent c277f46a60
commit fe500dea82
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 493 additions and 15047 deletions

View file

@ -27,8 +27,12 @@ class BlogSidebar extends React.Component {
const contents = [
{
name: blogSidebarTitle,
links: MetadataBlog.slice(0, blogSidebarCount),
type: 'CATEGORY',
title: blogSidebarTitle,
children: MetadataBlog.slice(0, blogSidebarCount).map(item => ({
type: 'LINK',
item,
})),
},
];
const title = this.props.current && this.props.current.title;