Basic CryptDrive export with pads

This commit is contained in:
yflory
2018-10-17 14:32:33 +02:00
parent f4d5a7567f
commit 92ce311694
6 changed files with 211 additions and 3 deletions

View File

@@ -744,6 +744,15 @@ define([
Cryptpad.removeLoginBlock(data, cb);
});
sframeChan.on('Q_CRYPTGET', function (data, cb) {
Cryptget.get(data.hash, function (err, val) {
cb({
error: err,
data: val
});
}, data.opts);
});
if (cfg.addRpc) {
cfg.addRpc(sframeChan, Cryptpad, Utils);
}

View File

@@ -270,5 +270,9 @@ define({
'Q_IS_PAD_STORED': true,
// Import mediatag from a pad
'Q_IMPORT_MEDIATAG': true
'Q_IMPORT_MEDIATAG': true,
// Ability to get a pad's content from its hash
'Q_CRYPTGET': true,
});

View File

@@ -562,6 +562,8 @@ define(function () {
out.settings_backupCategory = "Backup";
out.settings_backupHint = "Backup or restore all your CryptDrive's content. It won't contain the content of your pads, just the link to access them.";
out.settings_backup = "Backup";
out.settings_backupHint2 = "Download all your pads. Pads will be downloaded in an readable format when available.";
out.settings_backup2 = "Download my CryptDrive";
out.settings_restore = "Restore";
out.settings_resetNewTitle = "Clean CryptDrive";