Display a button to open the editing link while in read-only mode if we know it
This commit is contained in:
@@ -687,6 +687,10 @@ define([
|
||||
displayed: ['useradmin', 'language', 'spinner', 'lag', 'state', 'share', 'userlist', 'newpad'],
|
||||
userData: userData,
|
||||
readOnly: readOnly,
|
||||
share: {
|
||||
secret: secret,
|
||||
channel: info.channel
|
||||
},
|
||||
title: {
|
||||
onRename: renameCb,
|
||||
defaultName: defaultName,
|
||||
@@ -712,17 +716,6 @@ define([
|
||||
var $forgetPad = Cryptpad.createButton('forget', true, {}, forgetCb);
|
||||
$rightside.append($forgetPad);
|
||||
|
||||
if (!readOnly) {
|
||||
$editShare.append(Cryptpad.createButton('editshare', false, {editHash: editHash}));
|
||||
}
|
||||
if (viewHash) {
|
||||
/* add a 'links' button */
|
||||
$viewShare.append(Cryptpad.createButton('viewshare', false, {viewHash: viewHash}));
|
||||
if (!readOnly) {
|
||||
$viewShare.append(Cryptpad.createButton('viewopen', false, {viewHash: viewHash}));
|
||||
}
|
||||
}
|
||||
|
||||
// set the hash
|
||||
if (!readOnly) { Cryptpad.replaceHash(editHash); }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user