未登录不显示-专区申请创建按钮

This commit is contained in:
caishi 2023-09-14 18:18:15 +08:00
parent c2d418c0e1
commit 2a6402e5bb
1 changed files with 2 additions and 2 deletions

View File

@ -364,13 +364,13 @@ class NewHeader extends Component {
onMouseOut={ () => { this.setState( {showSubMenu: false }) } }
>
<a onClick={ () => { this.setState( {showSubMenu: true }) } }>特色专区</a>
<ul className={ `drop-down ${ showSubMenu ? 'drop-down-show' : '' }` } style={{ height : showSubMenu ? `${ (zoneList.length+1) * 46}px` : 0 }}>
<ul className={ `drop-down ${ showSubMenu ? 'drop-down-show' : '' }` } style={{ height : showSubMenu ? `${ current_user && current_user.login ? ((zoneList.length+1) * 46) : (zoneList.length * 46)}px` : 0 }}>
{
zoneList.map((e, k) => {
return <li className="drop-down-item" key={ k }><a href={ e.link } className="task-hide" title={ e.name } target="_blank">{ e.name }</a></li>
})
}
<li className="drop-down-item"><Link to="/zone/apply" target="_blank">+申请创建</Link></li>
{current_user && current_user.login && <li className="drop-down-item"><Link to="/zone/apply" target="_blank">+申请创建</Link></li> }
</ul>
</li>
}