Make group by tag button consistent with other toggle buttons

pull/2078/head
Alex P 2017-10-05 12:23:09 -07:00
parent 2a978ea6d8
commit 6417141ed3
2 changed files with 6 additions and 4 deletions

View File

@ -99,7 +99,7 @@ const TagListItem = React.createClass({
},
render() {
const {tagKey, tagValues} = this.props
const {tagKey, tagValues, isUsingGroupBy} = this.props
const {isOpen} = this.state
const tagItemLabel = `${tagKey}${tagValues.length}`
@ -115,8 +115,9 @@ const TagListItem = React.createClass({
{tagItemLabel}
</span>
<div
className={classnames('btn btn-default btn-xs group-by-tag', {
active: this.props.isUsingGroupBy,
className={classnames('btn btn-xs group-by-tag', {
'btn-primary': isUsingGroupBy,
'btn-default': !isUsingGroupBy,
})}
onClick={this.handleGroupBy}
>

View File

@ -198,7 +198,8 @@
}
}
.query-builder--list-item:hover .group-by-tag,
.query-builder--list-item.active .group-by-tag {
.query-builder--list-item.active .group-by-tag,
.query-builder--list-item .group-by-tag.btn-primary {
visibility: visible;
}
.query-builder--db-dropdown {