Commit 576254ce by zhanghaozhe

search history

parent 4b659a32
...@@ -59,6 +59,8 @@ class Search extends PureComponent { ...@@ -59,6 +59,8 @@ class Search extends PureComponent {
/> />
<Loading isLoading={this.state.isLoading}> <Loading isLoading={this.state.isLoading}>
<div className="search-main"> <div className="search-main">
{
searchHistory.length > 0 &&
<div className="search-land"> <div className="search-land">
<div className='search-history'> <div className='search-history'>
<span>最近搜索</span> <span>最近搜索</span>
...@@ -66,7 +68,7 @@ class Search extends PureComponent { ...@@ -66,7 +68,7 @@ class Search extends PureComponent {
</div> </div>
<div className="search-tag"> <div className="search-tag">
{ {
searchHistory.length > 0 ?
searchHistory.map((v, i) => { searchHistory.map((v, i) => {
return ( return (
<Link <Link
...@@ -77,10 +79,10 @@ class Search extends PureComponent { ...@@ -77,10 +79,10 @@ class Search extends PureComponent {
</Link> </Link>
) )
}) })
: <div className={'no_search_history'} style={{textAlign: 'center', padding: '20px'}}>暂无历史</div>
} }
</div> </div>
</div> </div>
}
<div className="search-land search-hot"> <div className="search-land search-hot">
<label className={'search-history'}> <label className={'search-history'}>
<span>热门搜索</span> <span>热门搜索</span>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment