Pad creation screen translations and link to settings
This commit is contained in:
@@ -176,7 +176,7 @@ Version 1
|
||||
secret.keys = Crypto.createEditCryptor();
|
||||
secret.key = Crypto.createEditCryptor().editKeyStr;
|
||||
};
|
||||
if (!secretHash && !/#/.test(window.location.href)) {
|
||||
if (!secretHash && !window.location.hash) { //!/#/.test(window.location.href)) {
|
||||
generate();
|
||||
return secret;
|
||||
} else {
|
||||
|
||||
@@ -1816,6 +1816,13 @@ define([
|
||||
$button.click(function () {
|
||||
create();
|
||||
});
|
||||
|
||||
// Settings button
|
||||
var origin = common.getMetadataMgr().getPrivateData().origin;
|
||||
$(h('div.cp-creation-settings', h('a', {
|
||||
href: origin + '/settings/#creation',
|
||||
target: '_blank'
|
||||
}, Messages.creation_settings))).appendTo($creation);
|
||||
};
|
||||
|
||||
return UIElements;
|
||||
|
||||
@@ -75,7 +75,7 @@ define([
|
||||
}
|
||||
};
|
||||
|
||||
if (!AppConfig.dislayCreationScreen) {
|
||||
if (!AppConfig.displayCreationScreen) {
|
||||
delete categories.creation;
|
||||
}
|
||||
if (AppConfig.disableFeedback) {
|
||||
@@ -789,7 +789,7 @@ define([
|
||||
var $categories = $('<div>', {'class': 'cp-sidebarlayout-categories'})
|
||||
.appendTo(APP.$leftside);
|
||||
APP.$usage = $('<div>', {'class': 'usage'}).appendTo(APP.$leftside);
|
||||
var active = 'account';
|
||||
var active = privateData.category || 'account';
|
||||
Object.keys(categories).forEach(function (key) {
|
||||
var $category = $('<div>', {'class': 'cp-sidebarlayout-category'}).appendTo($categories);
|
||||
if (key === 'account') { $category.append($('<span>', {'class': 'fa fa-user-o'})); }
|
||||
|
||||
@@ -66,9 +66,18 @@ define([
|
||||
Cryptpad.mergeAnonDrive(cb);
|
||||
});
|
||||
};
|
||||
var category;
|
||||
if (window.location.hash) {
|
||||
category = window.location.hash.slice(1);
|
||||
window.location.hash = '';
|
||||
}
|
||||
var addData = function (obj) {
|
||||
if (category) { obj.category = category; }
|
||||
};
|
||||
SFCommonO.start({
|
||||
noRealtime: true,
|
||||
addRpc: addRpc
|
||||
addRpc: addRpc,
|
||||
addData: addData
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user