From 96d2ff67e1ede59355562ac82869f5cc02ee99da Mon Sep 17 00:00:00 2001 From: ansuz Date: Thu, 13 Jul 2017 15:22:11 +0200 Subject: [PATCH] user-plus as icon for add-friend --- customize.dist/src/less/toolbar.less | 7 +++++++ www/common/toolbar2.js | 19 ++++++++++++++----- 2 files changed, 21 insertions(+), 5 deletions(-) diff --git a/customize.dist/src/less/toolbar.less b/customize.dist/src/less/toolbar.less index 6e8b60036..8cb7a5a20 100644 --- a/customize.dist/src/less/toolbar.less +++ b/customize.dist/src/less/toolbar.less @@ -119,6 +119,13 @@ body .userlist-drawer { } } } + .friend { + display: flex; + text-align: right; + &:hover { + background-color: rgba(0, 0, 0, 0.1); + } + } } body { diff --git a/www/common/toolbar2.js b/www/common/toolbar2.js index cddc79b3e..0a178640f 100644 --- a/www/common/toolbar2.js +++ b/www/common/toolbar2.js @@ -208,12 +208,21 @@ define([ var name = data.name || Messages.anonymous; var $span = $('', {'title': name, 'class': 'avatar'}); var $rightCol = $('', {'class': 'right-col'}); - $('', {'class': 'name'}).text(name).appendTo($rightCol); + var $nameSpan = $('', {'class': 'name'}).text(name).appendTo($rightCol); var proxy = Cryptpad.getProxy(); - if (Cryptpad.isLoggedIn() && data.edPublic && data.edPublic !== proxy.edPublic) { - if (!proxy.friends || !proxy.friends[data.edPublic]) { - var $button = $('