Merge branch 'master' of github.com:xwiki-labs/cryptpad
This commit is contained in:
commit
b280e41b03
@ -40,8 +40,9 @@ During this development period we performed an extensive audit of our existing f
|
|||||||
* it's now possible to export files and folders (as zips) directly from your CryptDrive
|
* it's now possible to export files and folders (as zips) directly from your CryptDrive
|
||||||
* the ctrl-e and right-click menus in the drive now features an entry for uploading files and folders
|
* the ctrl-e and right-click menus in the drive now features an entry for uploading files and folders
|
||||||
* certain plain-text file formats uploaded as static files can now be rendered within other documents or used as the basis of a new code pad
|
* certain plain-text file formats uploaded as static files can now be rendered within other documents or used as the basis of a new code pad
|
||||||
* regular folders in your CryptDrive can be converted into shared folders from the right-click menu as long as they do not contain shared folders and are not within another shared folder
|
* ~~regular folders in your CryptDrive can be converted into shared folders from the right-click menu as long as they do not contain shared folders and are not within another shared folder~~
|
||||||
* nesting is complicated for a variety of technical reasons, but we're discussing whether it's worthwhile to try to find a solution
|
* nesting is complicated for a variety of technical reasons, but we're discussing whether it's worthwhile to try to find a solution
|
||||||
|
* we found a critical bug in the implementation of this feature and disabled it for this release
|
||||||
* documents and folders within your CryptDrive can now be moved to parent folders by dropping them on the file path in the toolbar
|
* documents and folders within your CryptDrive can now be moved to parent folders by dropping them on the file path in the toolbar
|
||||||
* Styles
|
* Styles
|
||||||
* the upload/download progress table has been restyled to be less invasive
|
* the upload/download progress table has been restyled to be less invasive
|
||||||
|
|||||||
@ -3,10 +3,11 @@ define([
|
|||||||
'/file/file-crypto.js',
|
'/file/file-crypto.js',
|
||||||
'/common/common-hash.js',
|
'/common/common-hash.js',
|
||||||
'/common/common-util.js',
|
'/common/common-util.js',
|
||||||
|
'/customize/messages.js',
|
||||||
'/bower_components/nthen/index.js',
|
'/bower_components/nthen/index.js',
|
||||||
'/bower_components/saferphore/index.js',
|
'/bower_components/saferphore/index.js',
|
||||||
'/bower_components/jszip/dist/jszip.min.js',
|
'/bower_components/jszip/dist/jszip.min.js',
|
||||||
], function (Crypt, FileCrypto, Hash, Util, nThen, Saferphore, JsZip) {
|
], function (Crypt, FileCrypto, Hash, Util, Messages, nThen, Saferphore, JsZip) {
|
||||||
var saveAs = window.saveAs;
|
var saveAs = window.saveAs;
|
||||||
|
|
||||||
var sanitize = function (str) {
|
var sanitize = function (str) {
|
||||||
@ -273,7 +274,7 @@ define([
|
|||||||
fileHost: fileHost,
|
fileHost: fileHost,
|
||||||
get: getPad,
|
get: getPad,
|
||||||
data: data.uo.drive,
|
data: data.uo.drive,
|
||||||
folder: data.folder || ctx.data.root,
|
folder: data.folder,
|
||||||
sf: data.sf,
|
sf: data.sf,
|
||||||
zip: new JsZip(),
|
zip: new JsZip(),
|
||||||
errors: [],
|
errors: [],
|
||||||
@ -286,8 +287,8 @@ define([
|
|||||||
progress('reading', -1);
|
progress('reading', -1);
|
||||||
nThen(function (waitFor) {
|
nThen(function (waitFor) {
|
||||||
ctx.waitFor = waitFor;
|
ctx.waitFor = waitFor;
|
||||||
var zipRoot = ctx.zip.folder('Root');
|
var zipRoot = ctx.zip.folder(data.name || Messages.fm_rootName);
|
||||||
makeFolder(ctx, ctx.folder, zipRoot, filesData);
|
makeFolder(ctx, ctx.folder || ctx.data.root, zipRoot, filesData);
|
||||||
progress('download', {});
|
progress('download', {});
|
||||||
}).nThen(function () {
|
}).nThen(function () {
|
||||||
console.log(ctx.zip);
|
console.log(ctx.zip);
|
||||||
@ -311,7 +312,7 @@ define([
|
|||||||
|
|
||||||
var _downloadFolder = function (ctx, data, cb, updateProgress) {
|
var _downloadFolder = function (ctx, data, cb, updateProgress) {
|
||||||
create(data, ctx.get, ctx.fileHost, function (blob, errors) {
|
create(data, ctx.get, ctx.fileHost, function (blob, errors) {
|
||||||
console.error(errors); // TODO show user errors
|
if (errors && errors.length) { console.error(errors); } // TODO show user errors
|
||||||
var dl = function () {
|
var dl = function () {
|
||||||
saveAs(blob, data.folderName);
|
saveAs(blob, data.folderName);
|
||||||
};
|
};
|
||||||
|
|||||||
@ -3746,6 +3746,7 @@ define([
|
|||||||
var todo = function (data) {
|
var todo = function (data) {
|
||||||
data.folder = folderElement;
|
data.folder = folderElement;
|
||||||
data.sharedFolderId = sfId;
|
data.sharedFolderId = sfId;
|
||||||
|
data.name = Util.fixFileName(folderName);
|
||||||
data.folderName = Util.fixFileName(folderName) + '.zip';
|
data.folderName = Util.fixFileName(folderName) + '.zip';
|
||||||
|
|
||||||
APP.FM.downloadFolder(data, function (err, obj) {
|
APP.FM.downloadFolder(data, function (err, obj) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user