', {id: DISPLAYNAME_ID}).appendTo($container);
+
+
var getValue = function (cb) {
cb(APP.lm.proxy.name);
};
@@ -161,6 +225,8 @@ define([
getValue(function (value) {
$span.text(value || Messages.anonymous);
});
+
+ addCreateInviteLinkButton($block);
return;
}
var setValue = function (value, cb) {
@@ -168,7 +234,7 @@ define([
cb();
};
var rt = Cryptpad.getStore().getProxy().info.realtime;
- createEditableInput($block, DISPLAYNAME_ID, placeholder, getValue, setValue, rt);
+ createEditableInput($block, DISPLAYNAME_ID, placeholder, getValue, setValue, rt, Messages.anonymous);
};
var addLink = function ($container) {
@@ -330,9 +396,18 @@ define([
$container.append($block);
};
+
var onReady = function () {
APP.$container.find('#'+CREATE_ID).remove();
+ var obj = APP.lm && APP.lm.proxy;
+ if (!APP.readOnly) {
+ var pubKeys = Cryptpad.getPublicKeys();
+ if (pubKeys && pubKeys.curve) {
+ obj.curveKey = pubKeys.curve;
+ }
+ }
+
if (!APP.initialized) {
var $header = $('
', {id: HEADER_ID}).appendTo(APP.$container);
addAvatar($header);
@@ -340,6 +415,7 @@ define([
addDisplayName($rightside);
addLink($rightside);
addDescription(APP.$container);
+ addViewButton(APP.$container); //$rightside);
addPublicKey(APP.$container);
APP.initialized = true;
}
@@ -377,7 +453,7 @@ define([
if (obj.profile && obj.profile.view && obj.profile.edit) {
return void andThen(obj.profile.edit);
}
- // If the user doesn't have a public profile, ask him if he wants to create one
+ // If the user doesn't have a public profile, ask them if they want to create one
var todo = function () {
var secret = Cryptpad.getSecrets();
obj.profile = {};
diff --git a/www/profile/main.less b/www/profile/main.less
index 32804c328..afac32043 100644
--- a/www/profile/main.less
+++ b/www/profile/main.less
@@ -100,6 +100,10 @@
#inviteButton {
float: right;
}
+ #viewProfileButton {
+ margin-bottom: 20px;
+ float: right;
+ }
#description {
position: relative;
font-size: 16px;