.navbar-login {
margin-right: -10px;
- white-space: nowrap;
}
.navbar-avatar {
height: var(--globalNavHeight);
}
-.global-navbar-menu > li > a {
+.global-navbar-menu > li > a,
+.global-navbar-menu .navbar-login {
display: block;
height: var(--globalNavHeight);
padding: calc((var(--globalNavHeight) - var(--globalNavContentHeight)) / 2) 10px;
.global-navbar-menu > li > a.active,
.global-navbar-menu > li > a:hover,
.global-navbar-menu > li > a:focus,
-.global-navbar-menu > .dropdown.open > a {
+.navbar-login.active,
+.navbar-login:hover,
+.navbar-login:focus {
background-color: #020202;
border-bottom-color: var(--blue);
}
<GlobalNavMenu currentUser={currentUser} location={location} />
- <ul className="global-navbar-menu global-navbar-menu-right">
+ <div className="global-navbar-menu global-navbar-menu-right">
<EmbedDocsPopupHelper />
<Search />
<GlobalNavUser currentUser={currentUser} />
- </ul>
+ </div>
</NavBar>
);
}
</a>
</li>
</ul>
- }
- tagName="li">
+ }>
<a className="dropdown-toggle navbar-avatar" href="#" title={currentUser.name}>
<Avatar
hash={currentUser.avatar}
renderAnonymous() {
return (
- <li>
+ <div>
<a className="navbar-login" href="/sessions/new" onClick={this.handleLogin}>
{translate('layout.login')}
</a>
- </li>
+ </div>
);
}
}
}
/>
- <ul
+ <div
className="global-navbar-menu global-navbar-menu-right"
>
<EmbedDocsPopupHelper />
}
}
/>
- </ul>
+ </div>
</NavBar>
`;
}
}
/>
- <ul
+ <div
className="global-navbar-menu global-navbar-menu-right"
>
<EmbedDocsPopupHelper />
}
}
/>
- </ul>
+ </div>
</NavBar>
`;
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`should render the right interface for anonymous user 1`] = `
-<li>
+<div>
<a
className="navbar-login"
href="/sessions/new"
>
layout.login
</a>
-</li>
+</div>
`;
exports[`should render the right interface for logged in user 1`] = `
</li>
</ul>
}
- tagName="li"
>
<a
className="dropdown-toggle navbar-avatar"
render() {
const search = (
- <li className="navbar-search dropdown">
+ <div className="navbar-search dropdown">
<DeferredSpinner className="navbar-search-icon" loading={this.state.loading} />
<SearchBox
</div>
</DropdownOverlay>
)}
- </li>
+ </div>
);
return this.state.open ? (
render() {
return (
- <li className="dropdown">
+ <div className="dropdown">
<Toggler
onRequestClose={this.closeHelp}
open={this.state.helpOpen}
<HelpIcon />
</ButtonLink>
</Toggler>
- </li>
+ </div>
);
}
}