0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-25 22:42:41 +00:00

set .sort-option to .active rather than button within.

This commit is contained in:
Gazook89
2022-09-19 11:06:33 -05:00
parent 8ac4d93581
commit 9fcc7b84c3

View File

@@ -114,11 +114,10 @@ const ListPage = createClass({
},
renderSortOption : function(sortTitle, sortValue){
return <div className='sort-option'>
return <div className={`sort-option ${(this.state.sortType == sortValue ? 'active' : '')}`}>
<button
value={`${sortValue}`}
onClick={this.handleSortOptionChange}
className={`${(this.state.sortType == sortValue ? 'active' : '')}`}
>
{`${sortTitle}`}
</button>