1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 09:46:22 +00:00

implement tagItem active styleName

This commit is contained in:
Sosuke Suzuki
2017-10-10 00:31:26 +09:00
parent 9b60814292
commit ff4b96b622
3 changed files with 17 additions and 4 deletions

View File

@@ -95,7 +95,7 @@ class SideNav extends React.Component {
}
tagListComponent () {
const { data } = this.props
const { data, location } = this.props
let tagList = data.tagNoteMap.map((tag, key) => {
return key
})
@@ -104,6 +104,7 @@ class SideNav extends React.Component {
<TagListItem
name={tag}
handleClickTagListItem={this.handleClickTagListItem.bind(this)}
isActive={!!location.pathname.match(tag)}
key={tag}
/>
))