diff --git a/client/homebrew/navbar/account.navitem.jsx b/client/homebrew/navbar/account.navitem.jsx
index 6b4d054df..3f3e48b72 100644
--- a/client/homebrew/navbar/account.navitem.jsx
+++ b/client/homebrew/navbar/account.navitem.jsx
@@ -18,11 +18,39 @@ const Account = createClass({
}
},
+ handleLogout : function(){
+ if(confirm('Are you sure you want to log out?')) {
+ document.cookie = `nc_session=;expires=Thu, 01 Jan 1970 00:00:01 GMT;path=/;samesite=lax;${window.domain ? `domain=${window.domain}` : ''}`;
+ window.location = '/';
+ };
+ },
+
render : function(){
if(global.account){
- return
- {global.account.username}
- ;
+ return
+
+ {global.account.username}
+
+
+ brews
+
+
+ logout
+
+ ;
}
return
diff --git a/client/homebrew/navbar/navbar.less b/client/homebrew/navbar/navbar.less
index a149307e8..95cc04c7a 100644
--- a/client/homebrew/navbar/navbar.less
+++ b/client/homebrew/navbar/navbar.less
@@ -142,4 +142,7 @@
text-align : center;
}
}
+ .account.navItem{
+ min-width: 100px;
+ }
}