mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-02-06 07:04:57 +00:00
new version 5.16.1 of fineuploader
This commit is contained in:
parent
d6ff82ccb8
commit
cd075863e9
|
@ -1,5 +1,7 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2010-2012, Andrew Valums
|
||||
Copyright (c) 2012-2013, Andrew Valums and Raymond S. Nicholus, III
|
||||
Copyright (c) 2013-present, Widen Enterprises, Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
// Fine Uploader 5.12.0 - (c) 2013-present Widen Enterprises, Inc. MIT licensed. http://fineuploader.com
|
||||
// Fine Uploader 5.16.2 - MIT licensed. http://fineuploader.com
|
||||
(function(global) {
|
||||
var qq = function(element) {
|
||||
"use strict";
|
||||
|
@ -578,7 +578,7 @@
|
|||
global.qq = qq;
|
||||
}
|
||||
})();
|
||||
qq.version = "5.12.0";
|
||||
qq.version = "5.16.2";
|
||||
qq.supportedFeatures = function() {
|
||||
"use strict";
|
||||
var supportsUploading, supportsUploadingBlobs, supportsFileDrop, supportsAjaxFileUploading, supportsFolderDrop, supportsChunking, supportsResume, supportsUploadViaPaste, supportsUploadCors, supportsDeleteFileXdr, supportsDeleteFileCorsXhr, supportsDeleteFileCors, supportsFolderSelection, supportsImagePreviews, supportsUploadProgress;
|
||||
|
@ -596,9 +596,6 @@
|
|||
}
|
||||
return supported;
|
||||
}
|
||||
function isChrome21OrHigher() {
|
||||
return (qq.chrome() || qq.opera()) && navigator.userAgent.match(/Chrome\/[2][1-9]|Chrome\/[3-9][0-9]/) !== undefined;
|
||||
}
|
||||
function isChrome14OrHigher() {
|
||||
return (qq.chrome() || qq.opera()) && navigator.userAgent.match(/Chrome\/[1][4-9]|Chrome\/[2-9][0-9]/) !== undefined;
|
||||
}
|
||||
|
@ -636,7 +633,11 @@
|
|||
supportsAjaxFileUploading = supportsUploading && qq.isXhrUploadSupported();
|
||||
supportsUploadingBlobs = supportsAjaxFileUploading && !qq.androidStock();
|
||||
supportsFileDrop = supportsAjaxFileUploading && isDragAndDropSupported();
|
||||
supportsFolderDrop = supportsFileDrop && isChrome21OrHigher();
|
||||
supportsFolderDrop = supportsFileDrop && function() {
|
||||
var input = document.createElement("input");
|
||||
input.type = "file";
|
||||
return !!("webkitdirectory" in (input || document.querySelectorAll("input[type=file]")[0]));
|
||||
}();
|
||||
supportsChunking = supportsAjaxFileUploading && qq.isFileChunkingSupported();
|
||||
supportsResume = supportsAjaxFileUploading && supportsChunking && isLocalStorageSupported();
|
||||
supportsUploadViaPaste = supportsAjaxFileUploading && isChrome14OrHigher();
|
||||
|
@ -765,12 +766,7 @@
|
|||
var parseEntryPromise = new qq.Promise();
|
||||
if (entry.isFile) {
|
||||
entry.file(function(file) {
|
||||
var name = entry.name, fullPath = entry.fullPath, indexOfNameInFullPath = fullPath.indexOf(name);
|
||||
fullPath = fullPath.substr(0, indexOfNameInFullPath);
|
||||
if (fullPath.charAt(0) === "/") {
|
||||
fullPath = fullPath.substr(1);
|
||||
}
|
||||
file.qqPath = fullPath;
|
||||
file.qqPath = extractDirectoryPath(entry);
|
||||
droppedFiles.push(file);
|
||||
parseEntryPromise.success();
|
||||
}, function(fileError) {
|
||||
|
@ -798,6 +794,14 @@
|
|||
}
|
||||
return parseEntryPromise;
|
||||
}
|
||||
function extractDirectoryPath(entry) {
|
||||
var name = entry.name, fullPath = entry.fullPath, indexOfNameInFullPath = fullPath.lastIndexOf(name);
|
||||
fullPath = fullPath.substr(0, indexOfNameInFullPath);
|
||||
if (fullPath.charAt(0) === "/") {
|
||||
fullPath = fullPath.substr(1);
|
||||
}
|
||||
return fullPath;
|
||||
}
|
||||
function getFilesInDirectory(entry, reader, accumEntries, existingPromise) {
|
||||
var promise = existingPromise || new qq.Promise(), dirReader = reader || entry.createReader();
|
||||
dirReader.readEntries(function readSuccess(entries) {
|
||||
|
@ -885,9 +889,6 @@
|
|||
return fileDrag;
|
||||
}
|
||||
function leavingDocumentOut(e) {
|
||||
if (qq.firefox()) {
|
||||
return !e.relatedTarget;
|
||||
}
|
||||
if (qq.safari()) {
|
||||
return e.x < 0 || e.y < 0;
|
||||
}
|
||||
|
@ -927,8 +928,10 @@
|
|||
maybeHideDropZones();
|
||||
});
|
||||
disposeSupport.attach(document, "drop", function(e) {
|
||||
e.preventDefault();
|
||||
maybeHideDropZones();
|
||||
if (isFileDrag(e)) {
|
||||
e.preventDefault();
|
||||
maybeHideDropZones();
|
||||
}
|
||||
});
|
||||
disposeSupport.attach(document, HIDE_ZONES_EVENT_NAME, maybeHideDropZones);
|
||||
}
|
||||
|
@ -953,6 +956,8 @@
|
|||
});
|
||||
}
|
||||
});
|
||||
this._testing = {};
|
||||
this._testing.extractDirectoryPath = extractDirectoryPath;
|
||||
};
|
||||
qq.DragAndDrop.callbacks = function() {
|
||||
"use strict";
|
||||
|
@ -1005,7 +1010,7 @@
|
|||
}
|
||||
var effectTest, dt = e.dataTransfer, isSafari = qq.safari();
|
||||
effectTest = qq.ie() && qq.supportedFeatures.fileDrop ? true : dt.effectAllowed !== "none";
|
||||
return dt && effectTest && (dt.files || !isSafari && dt.types.contains && dt.types.contains("Files"));
|
||||
return dt && effectTest && (dt.files && dt.files.length || !isSafari && dt.types.contains && dt.types.contains("Files") || dt.types.includes && dt.types.includes("Files"));
|
||||
}
|
||||
function isOrSetDropDisabled(isDisabled) {
|
||||
if (isDisabled !== undefined) {
|
||||
|
@ -1088,6 +1093,8 @@
|
|||
return element;
|
||||
}
|
||||
});
|
||||
this._testing = {};
|
||||
this._testing.isValidFileDrag = isValidFileDrag;
|
||||
};
|
||||
})(window);
|
||||
//# sourceMappingURL=dnd.js.map
|
File diff suppressed because one or more lines are too long
4
styles/bootstrap/fine-uploader/dnd.min.js
vendored
4
styles/bootstrap/fine-uploader/dnd.min.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1 +1 @@
|
|||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B,4BACI,WAAY,eACZ,MAAO,KACP,OAAQ,KACR,eAAgB,IAChB,QAAS,aAEb,2BACI,WAAY,eACZ,MAAO,KACP,OAAQ,KACR,eAAgB,IAChB,QAAS,aACT,MAAO,KAEX,8BACI,WAAY,kBACZ,MAAO,KACP,OAAQ,KACR,eAAgB,IAChB,QAAS,aAEb,2BACI,WAAY,eACZ,MAAO,KACP,OAAQ,KACR,eAAgB,IAChB,QAAS,aAGb,qBACI,QAAS,KAMb,kDACI,4DACA,QAAS,GAGb,kCACI,SAAU,OACV,SAAU,SAGV,OAAQ,MACR,MAAO,MAEX,mCACI,cAAe,IAAI,IAAI,EAAE,EACzB,OAAQ,EAGR,IAAK,EAGL,OAAO,KACP,QAAS,MAIb,2CAEI,SAAU,SACV,IAAK,IACL,UAAW,iBACX,eAAgB,iBAChB,cAAe,iBACf,kBAAmB,iBAIvB,+BACI,QAAS,KAGb,qCACI,QAAS,MAGb,+BACI,QAAS,KAGb,qCACI,QAAS,MAGb,kDACI,WAAY,OACZ,YAAa,KAGjB,yDACI,YAAa,IACb,aAAc,IAGlB,2DACI,eAAgB,KAGpB,0CACI,iBAAkB"}
|
File diff suppressed because one or more lines are too long
|
@ -1 +1 @@
|
|||
{"version":3,"sources":["_build/fine-uploader-new.css"],"names":[],"mappings":"AAMA,QAkDA,kBAWI,WAAY,EAAE,IAAI,IAAI,sBAA0B,MAAO,IAAI,EAAE,IAAI,sBAA0B,MAAO,EAAE,IAAI,EAAE,gBAAqB,EAAE,KAAK,KAAK,gBAAoB,MA7DnK,QAGI,QAAS,IAAI,IACb,OAAQ,IAAI,MAAM,KAClB,cAAe,IACf,MAAO,QACP,iBAAkB,KAKtB,kBAEI,iBAAkB,QAClB,MAAO,QACP,aAAc,QACd,YAAa,EAAE,IAAI,IAAI,gBAE3B,wBACI,iBAAkB,QAEtB,kBAEI,iBAAkB,QAClB,aAAc,QAElB,wBACI,iBAAkB,QAEtB,iBAEI,iBAAkB,QAClB,aAAc,QAElB,uBACI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QAAS,KACT,WAAY,OACZ,YAAa,IAEjB,uBACI,QAAQ,KACR,MAAM,KACN,OAAO,KACP,eAAe,YAEnB,uCACI,QAAS,OAEb,2CACI,QAAS,OAEb,qCACI,iBAAkB,QAClB,MAAO,QACP,cAAe,IAAI,MAAM,QACzB,WAAY,IAAI,MAAM,QAE1B,kCACI,iBAAkB,QAClB,MAAO,QACP,cAAe,IAAI,MAAM,QACzB,WAAY,IAAI,MAAM,QAE1B,iBACI,QAAS,MACT,QAAS,MACT,WAAY,QACZ,MAAO,EACP,OAAQ,KACR,cAAe,IACf,cAAe,IAGnB,uBACI,OAAQ,KACR,cAAe,IAGnB,iCACI,YAAa,IACb,QAAS,OACT,MAAO,MACP,MAAO,MAGX,uBACI,SAAU,SACV,QAAS,EAET,QAAS,GAIb,4BACI,OAAQ,QACR,aAAc,IAGlB,mCACI,QAAS,aACT,OAAQ,QAGZ,kCACI,SAAU,OACV,OAAQ,KACR,QAAS,EAAE,IACX,aAAc,KACd,cAAe,KACf,OAAQ,IAAI,MAAM,KAClB,cAAe,IACf,UAAW,KAEX,QAAS,EAKb,uBACI,QAAS,KACT,WAAY,cACZ,MAAO,KACP,OAAQ,KACR,eAAgB,YAChB,aAAc,KAGlB,SACI,QAAS,KAMb,uBACI,eAAgB,OAChB,aAAc,KAKlB,oBACI,QAAS,KAGb,0BACI,QAAS,MAGb,oBACI,QAAS,KAGb,0BACI,QAAS,MAGb,uCACI,WAAY,OACZ,YAAa,KAGjB,8CACI,YAAa,IACb,aAAc,IAGlB,gDACI,eAAgB,KAGpB,8BACI,iBAAkB"}
|
|
@ -1,4 +1,4 @@
|
|||
// Fine Uploader 5.12.0 - (c) 2013-present Widen Enterprises, Inc. MIT licensed. http://fineuploader.com
|
||||
// Fine Uploader 5.16.2 - MIT licensed. http://fineuploader.com
|
||||
(function(global) {
|
||||
var qq = function(element) {
|
||||
"use strict";
|
||||
|
@ -585,7 +585,7 @@
|
|||
};
|
||||
qq.Error.prototype = new Error();
|
||||
})();
|
||||
qq.version = "5.12.0";
|
||||
qq.version = "5.16.2";
|
||||
qq.supportedFeatures = function() {
|
||||
"use strict";
|
||||
var supportsUploading, supportsUploadingBlobs, supportsFileDrop, supportsAjaxFileUploading, supportsFolderDrop, supportsChunking, supportsResume, supportsUploadViaPaste, supportsUploadCors, supportsDeleteFileXdr, supportsDeleteFileCorsXhr, supportsDeleteFileCors, supportsFolderSelection, supportsImagePreviews, supportsUploadProgress;
|
||||
|
@ -603,9 +603,6 @@
|
|||
}
|
||||
return supported;
|
||||
}
|
||||
function isChrome21OrHigher() {
|
||||
return (qq.chrome() || qq.opera()) && navigator.userAgent.match(/Chrome\/[2][1-9]|Chrome\/[3-9][0-9]/) !== undefined;
|
||||
}
|
||||
function isChrome14OrHigher() {
|
||||
return (qq.chrome() || qq.opera()) && navigator.userAgent.match(/Chrome\/[1][4-9]|Chrome\/[2-9][0-9]/) !== undefined;
|
||||
}
|
||||
|
@ -643,7 +640,11 @@
|
|||
supportsAjaxFileUploading = supportsUploading && qq.isXhrUploadSupported();
|
||||
supportsUploadingBlobs = supportsAjaxFileUploading && !qq.androidStock();
|
||||
supportsFileDrop = supportsAjaxFileUploading && isDragAndDropSupported();
|
||||
supportsFolderDrop = supportsFileDrop && isChrome21OrHigher();
|
||||
supportsFolderDrop = supportsFileDrop && function() {
|
||||
var input = document.createElement("input");
|
||||
input.type = "file";
|
||||
return !!("webkitdirectory" in (input || document.querySelectorAll("input[type=file]")[0]));
|
||||
}();
|
||||
supportsChunking = supportsAjaxFileUploading && qq.isFileChunkingSupported();
|
||||
supportsResume = supportsAjaxFileUploading && supportsChunking && isLocalStorageSupported();
|
||||
supportsUploadViaPaste = supportsAjaxFileUploading && isChrome14OrHigher();
|
||||
|
@ -903,7 +904,8 @@
|
|||
originalName: spec.name,
|
||||
uuid: spec.uuid,
|
||||
size: spec.size == null ? -1 : spec.size,
|
||||
status: status
|
||||
status: status,
|
||||
file: spec.file
|
||||
}) - 1;
|
||||
if (spec.batchId) {
|
||||
data[id].batchId = spec.batchId;
|
||||
|
@ -925,6 +927,7 @@
|
|||
byStatus[status] = [];
|
||||
}
|
||||
byStatus[status].push(id);
|
||||
spec.onBeforeStatusChange && spec.onBeforeStatusChange(id);
|
||||
uploaderProxy.onStatusChange(id, null, status);
|
||||
return id;
|
||||
},
|
||||
|
@ -941,6 +944,12 @@
|
|||
return qq.extend([], data, true);
|
||||
}
|
||||
},
|
||||
removeFileRef: function(id) {
|
||||
var record = getDataByIds(id);
|
||||
if (record) {
|
||||
delete record.file;
|
||||
}
|
||||
},
|
||||
reset: function() {
|
||||
data = [];
|
||||
byUuid = {};
|
||||
|
@ -993,6 +1002,7 @@
|
|||
CANCELED: "canceled",
|
||||
PAUSED: "paused",
|
||||
UPLOADING: "uploading",
|
||||
UPLOAD_FINALIZING: "upload finalizing",
|
||||
UPLOAD_RETRYING: "retrying upload",
|
||||
UPLOAD_SUCCESSFUL: "upload successful",
|
||||
UPLOAD_FAILED: "upload failed",
|
||||
|
@ -1073,7 +1083,14 @@
|
|||
}
|
||||
},
|
||||
cancel: function(id) {
|
||||
this._handler.cancel(id);
|
||||
var uploadData = this._uploadData.retrieve({
|
||||
id: id
|
||||
});
|
||||
if (uploadData && uploadData.status === qq.status.UPLOAD_FINALIZING) {
|
||||
this.log(qq.format("Ignoring cancel for file ID {} ({}). Finalizing upload.", id, this.getName(id)), "error");
|
||||
} else {
|
||||
this._handler.cancel(id);
|
||||
}
|
||||
},
|
||||
cancelAll: function() {
|
||||
var storedIdsCopy = [], self = this;
|
||||
|
@ -1150,7 +1167,17 @@
|
|||
return this._endpointStore.get(fileId);
|
||||
},
|
||||
getFile: function(fileOrBlobId) {
|
||||
return this._handler.getFile(fileOrBlobId) || null;
|
||||
var file = this._handler.getFile(fileOrBlobId);
|
||||
var uploadDataRecord;
|
||||
if (!file) {
|
||||
uploadDataRecord = this._uploadData.retrieve({
|
||||
id: fileOrBlobId
|
||||
});
|
||||
if (uploadDataRecord) {
|
||||
file = uploadDataRecord.file;
|
||||
}
|
||||
}
|
||||
return file || null;
|
||||
},
|
||||
getInProgress: function() {
|
||||
return this._uploadData.retrieve({
|
||||
|
@ -1199,6 +1226,9 @@
|
|||
id: id
|
||||
}).uuid;
|
||||
},
|
||||
isResumable: function(id) {
|
||||
return this._handler.hasResumeRecord(id);
|
||||
},
|
||||
log: function(str, level) {
|
||||
if (this._options.debug && (!level || level === "info")) {
|
||||
qq.log("[Fine Uploader " + qq.version + "] " + str);
|
||||
|
@ -1225,6 +1255,10 @@
|
|||
}
|
||||
return false;
|
||||
},
|
||||
removeFileRef: function(id) {
|
||||
this._handler.expunge(id);
|
||||
this._uploadData.removeFileRef(id);
|
||||
},
|
||||
reset: function() {
|
||||
this.log("Resetting uploader...");
|
||||
this._handler.reset();
|
||||
|
@ -1247,6 +1281,7 @@
|
|||
this._succeededSinceLastAllComplete = [];
|
||||
this._failedSinceLastAllComplete = [];
|
||||
this._totalProgress && this._totalProgress.reset();
|
||||
this._customResumeDataStore.reset();
|
||||
},
|
||||
retry: function(id) {
|
||||
return this._manualRetry(id);
|
||||
|
@ -1262,6 +1297,9 @@
|
|||
setCustomHeaders: function(headers, id) {
|
||||
this._customHeadersStore.set(headers, id);
|
||||
},
|
||||
setCustomResumeData: function(id, data) {
|
||||
this._customResumeDataStore.set(data, id);
|
||||
},
|
||||
setDeleteFileCustomHeaders: function(headers, id) {
|
||||
this._deleteFileCustomHeadersStore.set(headers, id);
|
||||
},
|
||||
|
@ -1289,6 +1327,28 @@
|
|||
setUuid: function(id, newUuid) {
|
||||
return this._uploadData.uuidChanged(id, newUuid);
|
||||
},
|
||||
setStatus: function(id, newStatus) {
|
||||
var fileRecord = this.getUploads({
|
||||
id: id
|
||||
});
|
||||
if (!fileRecord) {
|
||||
throw new qq.Error(id + " is not a valid file ID.");
|
||||
}
|
||||
switch (newStatus) {
|
||||
case qq.status.DELETED:
|
||||
this._onDeleteComplete(id, null, false);
|
||||
break;
|
||||
|
||||
case qq.status.DELETE_FAILED:
|
||||
this._onDeleteComplete(id, null, true);
|
||||
break;
|
||||
|
||||
default:
|
||||
var errorMessage = "Method setStatus called on '" + name + "' not implemented yet for " + newStatus;
|
||||
this.log(errorMessage);
|
||||
throw new qq.Error(errorMessage);
|
||||
}
|
||||
},
|
||||
uploadStoredFiles: function() {
|
||||
if (this._storedIds.length === 0) {
|
||||
this._itemError("noFilesError");
|
||||
|
@ -1299,20 +1359,22 @@
|
|||
};
|
||||
qq.basePrivateApi = {
|
||||
_addCannedFile: function(sessionData) {
|
||||
var id = this._uploadData.addFile({
|
||||
var self = this;
|
||||
return this._uploadData.addFile({
|
||||
uuid: sessionData.uuid,
|
||||
name: sessionData.name,
|
||||
size: sessionData.size,
|
||||
status: qq.status.UPLOAD_SUCCESSFUL
|
||||
status: qq.status.UPLOAD_SUCCESSFUL,
|
||||
onBeforeStatusChange: function(id) {
|
||||
sessionData.deleteFileEndpoint && self.setDeleteFileEndpoint(sessionData.deleteFileEndpoint, id);
|
||||
sessionData.deleteFileParams && self.setDeleteFileParams(sessionData.deleteFileParams, id);
|
||||
if (sessionData.thumbnailUrl) {
|
||||
self._thumbnailUrls[id] = sessionData.thumbnailUrl;
|
||||
}
|
||||
self._netUploaded++;
|
||||
self._netUploadedOrQueued++;
|
||||
}
|
||||
});
|
||||
sessionData.deleteFileEndpoint && this.setDeleteFileEndpoint(sessionData.deleteFileEndpoint, id);
|
||||
sessionData.deleteFileParams && this.setDeleteFileParams(sessionData.deleteFileParams, id);
|
||||
if (sessionData.thumbnailUrl) {
|
||||
this._thumbnailUrls[id] = sessionData.thumbnailUrl;
|
||||
}
|
||||
this._netUploaded++;
|
||||
this._netUploadedOrQueued++;
|
||||
return id;
|
||||
},
|
||||
_annotateWithButtonId: function(file, associatedInput) {
|
||||
if (qq.isFile(file)) {
|
||||
|
@ -1547,17 +1609,28 @@
|
|||
onUploadPrep: qq.bind(this._onUploadPrep, this),
|
||||
onUpload: function(id, name) {
|
||||
self._onUpload(id, name);
|
||||
self._options.callbacks.onUpload(id, name);
|
||||
var onUploadResult = self._options.callbacks.onUpload(id, name);
|
||||
if (qq.isGenericPromise(onUploadResult)) {
|
||||
self.log(qq.format("onUpload for {} returned a Promise - waiting for resolution.", id));
|
||||
return onUploadResult;
|
||||
}
|
||||
return new qq.Promise().success();
|
||||
},
|
||||
onUploadChunk: function(id, name, chunkData) {
|
||||
self._onUploadChunk(id, chunkData);
|
||||
self._options.callbacks.onUploadChunk(id, name, chunkData);
|
||||
var onUploadChunkResult = self._options.callbacks.onUploadChunk(id, name, chunkData);
|
||||
if (qq.isGenericPromise(onUploadChunkResult)) {
|
||||
self.log(qq.format("onUploadChunk for {}.{} returned a Promise - waiting for resolution.", id, chunkData.partIndex));
|
||||
return onUploadChunkResult;
|
||||
}
|
||||
return new qq.Promise().success();
|
||||
},
|
||||
onUploadChunkSuccess: function(id, chunkData, result, xhr) {
|
||||
self._onUploadChunkSuccess(id, chunkData);
|
||||
self._options.callbacks.onUploadChunkSuccess.apply(self, arguments);
|
||||
},
|
||||
onResume: function(id, name, chunkData) {
|
||||
return self._options.callbacks.onResume(id, name, chunkData);
|
||||
onResume: function(id, name, chunkData, customResumeData) {
|
||||
return self._options.callbacks.onResume(id, name, chunkData, customResumeData);
|
||||
},
|
||||
onAutoRetry: function(id, name, responseJSON, xhr) {
|
||||
return self._onAutoRetry.apply(self, arguments);
|
||||
|
@ -1582,7 +1655,16 @@
|
|||
return status === qq.status.QUEUED || status === qq.status.SUBMITTED || status === qq.status.UPLOAD_RETRYING || status === qq.status.PAUSED;
|
||||
},
|
||||
getIdsInProxyGroup: self._uploadData.getIdsInProxyGroup,
|
||||
getIdsInBatch: self._uploadData.getIdsInBatch
|
||||
getIdsInBatch: self._uploadData.getIdsInBatch,
|
||||
isInProgress: function(id) {
|
||||
return self.getUploads({
|
||||
id: id
|
||||
}).status === qq.status.UPLOADING;
|
||||
},
|
||||
getCustomResumeData: qq.bind(self._getCustomResumeData, self),
|
||||
setStatus: function(id, status) {
|
||||
self._uploadData.setStatus(id, status);
|
||||
}
|
||||
};
|
||||
qq.each(this._options.request, function(prop, val) {
|
||||
options[prop] = val;
|
||||
|
@ -1659,6 +1741,9 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
_getCustomResumeData: function(fileId) {
|
||||
return this._customResumeDataStore.get(fileId);
|
||||
},
|
||||
_getNotFinished: function() {
|
||||
return this._uploadData.retrieve({
|
||||
status: [ qq.status.UPLOADING, qq.status.UPLOAD_RETRYING, qq.status.QUEUED, qq.status.SUBMITTING, qq.status.SUBMITTED, qq.status.PAUSED ]
|
||||
|
@ -1760,7 +1845,8 @@
|
|||
uuid: uuid,
|
||||
name: name,
|
||||
size: size,
|
||||
batchId: batchId
|
||||
batchId: batchId,
|
||||
file: file
|
||||
});
|
||||
this._handler.add(id, file);
|
||||
this._trackButton(id);
|
||||
|
@ -1781,6 +1867,28 @@
|
|||
blob: blob
|
||||
});
|
||||
},
|
||||
_handleDeleteSuccess: function(id) {
|
||||
if (this.getUploads({
|
||||
id: id
|
||||
}).status !== qq.status.DELETED) {
|
||||
var name = this.getName(id);
|
||||
this._netUploadedOrQueued--;
|
||||
this._netUploaded--;
|
||||
this._handler.expunge(id);
|
||||
this._uploadData.setStatus(id, qq.status.DELETED);
|
||||
this.log("Delete request for '" + name + "' has succeeded.");
|
||||
}
|
||||
},
|
||||
_handleDeleteFailed: function(id, xhrOrXdr) {
|
||||
var name = this.getName(id);
|
||||
this._uploadData.setStatus(id, qq.status.DELETE_FAILED);
|
||||
this.log("Delete request for '" + name + "' has failed.", "error");
|
||||
if (!xhrOrXdr || xhrOrXdr.withCredentials === undefined) {
|
||||
this._options.callbacks.onError(id, name, "Delete request failed", xhrOrXdr);
|
||||
} else {
|
||||
this._options.callbacks.onError(id, name, "Delete request failed with response code " + xhrOrXdr.status, xhrOrXdr);
|
||||
}
|
||||
},
|
||||
_initExtraButton: function(spec) {
|
||||
var button = this._createUploadButton({
|
||||
accept: spec.validation.acceptFiles,
|
||||
|
@ -1933,7 +2041,7 @@
|
|||
_onAutoRetry: function(id, name, responseJSON, xhr, callback) {
|
||||
var self = this;
|
||||
self._preventRetries[id] = responseJSON[self._options.retry.preventRetryResponseProperty];
|
||||
if (self._shouldAutoRetry(id, name, responseJSON)) {
|
||||
if (self._shouldAutoRetry(id)) {
|
||||
var retryWaitPeriod = self._options.retry.autoAttemptDelay * 1e3;
|
||||
self._maybeParseAndSendUploadError.apply(self, arguments);
|
||||
self._options.callbacks.onAutoRetry(id, name, self._autoRetries[id]);
|
||||
|
@ -2006,19 +2114,9 @@
|
|||
_onDeleteComplete: function(id, xhrOrXdr, isError) {
|
||||
var name = this.getName(id);
|
||||
if (isError) {
|
||||
this._uploadData.setStatus(id, qq.status.DELETE_FAILED);
|
||||
this.log("Delete request for '" + name + "' has failed.", "error");
|
||||
if (xhrOrXdr.withCredentials === undefined) {
|
||||
this._options.callbacks.onError(id, name, "Delete request failed", xhrOrXdr);
|
||||
} else {
|
||||
this._options.callbacks.onError(id, name, "Delete request failed with response code " + xhrOrXdr.status, xhrOrXdr);
|
||||
}
|
||||
this._handleDeleteFailed(id, xhrOrXdr);
|
||||
} else {
|
||||
this._netUploadedOrQueued--;
|
||||
this._netUploaded--;
|
||||
this._handler.expunge(id);
|
||||
this._uploadData.setStatus(id, qq.status.DELETED);
|
||||
this.log("Delete request for '" + name + "' has succeeded.");
|
||||
this._handleDeleteSuccess(id);
|
||||
}
|
||||
},
|
||||
_onInputChange: function(input) {
|
||||
|
@ -2078,6 +2176,11 @@
|
|||
this._uploadData.setStatus(id, qq.status.UPLOADING);
|
||||
},
|
||||
_onUploadChunk: function(id, chunkData) {},
|
||||
_onUploadChunkSuccess: function(id, chunkData) {
|
||||
if (!this._preventRetries[id] && this._options.retry.enableAuto) {
|
||||
this._autoRetries[id] = 0;
|
||||
}
|
||||
},
|
||||
_onUploadStatusChange: function(id, oldStatus, newStatus) {
|
||||
if (newStatus === qq.status.PAUSED) {
|
||||
clearTimeout(this._retryTimeouts[id]);
|
||||
|
@ -2173,7 +2276,7 @@
|
|||
this._uploadData.updateSize(id, newSize);
|
||||
this._totalProgress && this._totalProgress.onNewSize(id);
|
||||
},
|
||||
_shouldAutoRetry: function(id, name, responseJSON) {
|
||||
_shouldAutoRetry: function(id) {
|
||||
var uploadData = this._uploadData.retrieve({
|
||||
id: id
|
||||
});
|
||||
|
@ -2322,6 +2425,7 @@
|
|||
maxConnections: 3,
|
||||
disableCancelForFormUploads: false,
|
||||
autoUpload: true,
|
||||
warnBeforeUnload: true,
|
||||
request: {
|
||||
customHeaders: {},
|
||||
endpoint: "/server/upload",
|
||||
|
@ -2329,8 +2433,10 @@
|
|||
forceMultipart: true,
|
||||
inputName: "qqfile",
|
||||
method: "POST",
|
||||
omitDefaultParams: false,
|
||||
params: {},
|
||||
paramsInBody: true,
|
||||
requireSuccessJson: true,
|
||||
totalFileSizeName: "qqtotalfilesize",
|
||||
uuidName: "qquuid"
|
||||
},
|
||||
|
@ -2358,7 +2464,7 @@
|
|||
onUpload: function(id, name) {},
|
||||
onUploadChunk: function(id, name, chunkData) {},
|
||||
onUploadChunkSuccess: function(id, chunkData, responseJSON, xhr) {},
|
||||
onResume: function(id, fileName, chunkData) {},
|
||||
onResume: function(id, fileName, chunkData, customResumeData) {},
|
||||
onProgress: function(id, name, loaded, total) {},
|
||||
onTotalProgress: function(loaded, total) {},
|
||||
onError: function(id, name, reason, maybeXhrOrXdr) {},
|
||||
|
@ -2411,9 +2517,20 @@
|
|||
totalFileSize: "qqtotalfilesize",
|
||||
totalParts: "qqtotalparts"
|
||||
},
|
||||
partSize: 2e6,
|
||||
partSize: function(id) {
|
||||
return 2e6;
|
||||
},
|
||||
success: {
|
||||
endpoint: null
|
||||
endpoint: null,
|
||||
headers: function(id) {
|
||||
return null;
|
||||
},
|
||||
jsonPayload: false,
|
||||
method: "POST",
|
||||
params: function(id) {
|
||||
return null;
|
||||
},
|
||||
resetOnStatus: []
|
||||
}
|
||||
},
|
||||
resume: {
|
||||
|
@ -2421,6 +2538,9 @@
|
|||
recordsExpireIn: 7,
|
||||
paramNames: {
|
||||
resuming: "qqresume"
|
||||
},
|
||||
customKeys: function(fileId) {
|
||||
return [];
|
||||
}
|
||||
},
|
||||
formatFileName: function(fileOrBlobName) {
|
||||
|
@ -2519,7 +2639,7 @@
|
|||
this.log("Paste support module not found", "error");
|
||||
}
|
||||
}
|
||||
this._preventLeaveInProgress();
|
||||
this._options.warnBeforeUnload && this._preventLeaveInProgress();
|
||||
this._imageGenerator = qq.ImageGenerator && new qq.ImageGenerator(qq.bind(this.log, this));
|
||||
this._refreshSessionData();
|
||||
this._succeededSinceLastAllComplete = [];
|
||||
|
@ -2537,6 +2657,7 @@
|
|||
});
|
||||
}
|
||||
this._currentItemLimit = this._options.validation.itemLimit;
|
||||
this._customResumeDataStore = this._createStore();
|
||||
};
|
||||
qq.FineUploaderBasic.prototype = qq.basePublicApi;
|
||||
qq.extend(qq.FineUploaderBasic.prototype, qq.basePrivateApi);
|
||||
|
@ -2606,7 +2727,7 @@
|
|||
return xhrOrXdr;
|
||||
}
|
||||
function getXhrOrXdr(id, suppliedXhr) {
|
||||
var xhrOrXdr = requestData[id].xhr;
|
||||
var xhrOrXdr = requestData[id] && requestData[id].xhr;
|
||||
if (!xhrOrXdr) {
|
||||
if (suppliedXhr) {
|
||||
xhrOrXdr = suppliedXhr;
|
||||
|
@ -2869,13 +2990,14 @@
|
|||
onUploadChunk: function(id, fileName, chunkData) {},
|
||||
onUploadChunkSuccess: function(id, chunkData, response, xhr) {},
|
||||
onAutoRetry: function(id, fileName, response, xhr) {},
|
||||
onResume: function(id, fileName, chunkData) {},
|
||||
onResume: function(id, fileName, chunkData, customResumeData) {},
|
||||
onUuidChanged: function(id, newUuid) {},
|
||||
getName: function(id) {},
|
||||
setSize: function(id, newSize) {},
|
||||
isQueued: function(id) {},
|
||||
getIdsInProxyGroup: function(id) {},
|
||||
getIdsInBatch: function(id) {}
|
||||
getIdsInBatch: function(id) {},
|
||||
isInProgress: function(id) {}
|
||||
}, chunked = {
|
||||
done: function(id, chunkIdx, response, xhr) {
|
||||
var chunkData = handler._getChunkData(id, chunkIdx);
|
||||
|
@ -2894,13 +3016,13 @@
|
|||
handler._maybeDeletePersistedChunkData(id);
|
||||
upload.cleanup(id, normaizedResponse, xhr);
|
||||
}, function(response, xhr) {
|
||||
var normaizedResponse = upload.normalizeResponse(response, false);
|
||||
log("Problem finalizing chunks for file ID " + id + " - " + normaizedResponse.error, "error");
|
||||
if (normaizedResponse.reset) {
|
||||
var normalizedResponse = upload.normalizeResponse(response, false);
|
||||
log("Problem finalizing chunks for file ID " + id + " - " + normalizedResponse.error, "error");
|
||||
if (normalizedResponse.reset || xhr && options.chunking.success.resetOnStatus.indexOf(xhr.status) >= 0) {
|
||||
chunked.reset(id);
|
||||
}
|
||||
if (!options.onAutoRetry(id, name, normaizedResponse, xhr)) {
|
||||
upload.cleanup(id, normaizedResponse, xhr);
|
||||
if (!options.onAutoRetry(id, name, normalizedResponse, xhr)) {
|
||||
upload.cleanup(id, normalizedResponse, xhr);
|
||||
}
|
||||
});
|
||||
},
|
||||
|
@ -2912,7 +3034,8 @@
|
|||
if (responseToReport.reset) {
|
||||
chunked.reset(id);
|
||||
} else {
|
||||
inProgressIdx = qq.indexOf(handler._getFileState(id).chunking.inProgress, chunkIdx);
|
||||
var inProgressChunksArray = handler._getFileState(id).chunking.inProgress;
|
||||
inProgressIdx = inProgressChunksArray ? qq.indexOf(inProgressChunksArray, chunkIdx) : -1;
|
||||
if (inProgressIdx >= 0) {
|
||||
handler._getFileState(id).chunking.inProgress.splice(inProgressIdx, 1);
|
||||
handler._getFileState(id).chunking.remaining.unshift(chunkIdx);
|
||||
|
@ -2950,13 +3073,14 @@
|
|||
handler._maybeDeletePersistedChunkData(id);
|
||||
handler.reevaluateChunking(id);
|
||||
handler._getFileState(id).loaded = 0;
|
||||
handler._getFileState(id).attemptingResume = false;
|
||||
},
|
||||
sendNext: function(id) {
|
||||
var size = options.getSize(id), name = options.getName(id), chunkIdx = chunked.nextPart(id), chunkData = handler._getChunkData(id, chunkIdx), resuming = handler._getFileState(id).attemptingResume, inProgressChunks = handler._getFileState(id).chunking.inProgress || [];
|
||||
if (handler._getFileState(id).loaded == null) {
|
||||
handler._getFileState(id).loaded = 0;
|
||||
var size = options.getSize(id), name = options.getName(id), chunkIdx = chunked.nextPart(id), chunkData = handler._getChunkData(id, chunkIdx), fileState = handler._getFileState(id), resuming = fileState.attemptingResume, inProgressChunks = fileState.chunking.inProgress || [];
|
||||
if (fileState.loaded == null) {
|
||||
fileState.loaded = 0;
|
||||
}
|
||||
if (resuming && options.onResume(id, name, chunkData) === false) {
|
||||
if (resuming && options.onResume(id, name, chunkData, fileState.customResumeData) === false) {
|
||||
chunked.reset(id);
|
||||
chunkIdx = chunked.nextPart(id);
|
||||
chunkData = handler._getChunkData(id, chunkIdx);
|
||||
|
@ -2965,8 +3089,6 @@
|
|||
if (chunkIdx == null && inProgressChunks.length === 0) {
|
||||
chunked.finalize(id);
|
||||
} else {
|
||||
log(qq.format("Sending chunked upload request for item {}.{}, bytes {}-{} of {}.", id, chunkIdx, chunkData.start + 1, chunkData.end, size));
|
||||
options.onUploadChunk(id, name, handler._getChunkDataForCallback(chunkData));
|
||||
inProgressChunks.push(chunkIdx);
|
||||
handler._getFileState(id).chunking.inProgress = inProgressChunks;
|
||||
if (concurrentChunkingPossible) {
|
||||
|
@ -2978,30 +3100,45 @@
|
|||
if (chunkData.blob.size === 0) {
|
||||
log(qq.format("Chunk {} for file {} will not be uploaded, zero sized chunk.", chunkIdx, id), "error");
|
||||
chunked.handleFailure(chunkIdx, id, "File is no longer available", null);
|
||||
} else {
|
||||
handler.uploadChunk(id, chunkIdx, resuming).then(function success(response, xhr) {
|
||||
log("Chunked upload request succeeded for " + id + ", chunk " + chunkIdx);
|
||||
handler.clearCachedChunk(id, chunkIdx);
|
||||
var inProgressChunks = handler._getFileState(id).chunking.inProgress || [], responseToReport = upload.normalizeResponse(response, true), inProgressChunkIdx = qq.indexOf(inProgressChunks, chunkIdx);
|
||||
log(qq.format("Chunk {} for file {} uploaded successfully.", chunkIdx, id));
|
||||
chunked.done(id, chunkIdx, responseToReport, xhr);
|
||||
if (inProgressChunkIdx >= 0) {
|
||||
inProgressChunks.splice(inProgressChunkIdx, 1);
|
||||
}
|
||||
handler._maybePersistChunkedState(id);
|
||||
if (!chunked.hasMoreParts(id) && inProgressChunks.length === 0) {
|
||||
chunked.finalize(id);
|
||||
} else if (chunked.hasMoreParts(id)) {
|
||||
chunked.sendNext(id);
|
||||
} else {
|
||||
log(qq.format("File ID {} has no more chunks to send and these chunk indexes are still marked as in-progress: {}", id, JSON.stringify(inProgressChunks)));
|
||||
}
|
||||
}, function failure(response, xhr) {
|
||||
chunked.handleFailure(chunkIdx, id, response, xhr);
|
||||
}).done(function() {
|
||||
handler.clearXhr(id, chunkIdx);
|
||||
});
|
||||
}
|
||||
var onUploadChunkPromise = options.onUploadChunk(id, name, handler._getChunkDataForCallback(chunkData));
|
||||
onUploadChunkPromise.then(function(requestOverrides) {
|
||||
if (!options.isInProgress(id)) {
|
||||
log(qq.format("Not sending chunked upload request for item {}.{} - no longer in progress.", id, chunkIdx));
|
||||
} else {
|
||||
log(qq.format("Sending chunked upload request for item {}.{}, bytes {}-{} of {}.", id, chunkIdx, chunkData.start + 1, chunkData.end, size));
|
||||
var uploadChunkData = {
|
||||
chunkIdx: chunkIdx,
|
||||
id: id,
|
||||
overrides: requestOverrides,
|
||||
resuming: resuming
|
||||
};
|
||||
handler.uploadChunk(uploadChunkData).then(function success(response, xhr) {
|
||||
log("Chunked upload request succeeded for " + id + ", chunk " + chunkIdx);
|
||||
handler.clearCachedChunk(id, chunkIdx);
|
||||
var inProgressChunks = handler._getFileState(id).chunking.inProgress || [], responseToReport = upload.normalizeResponse(response, true), inProgressChunkIdx = qq.indexOf(inProgressChunks, chunkIdx);
|
||||
log(qq.format("Chunk {} for file {} uploaded successfully.", chunkIdx, id));
|
||||
chunked.done(id, chunkIdx, responseToReport, xhr);
|
||||
if (inProgressChunkIdx >= 0) {
|
||||
inProgressChunks.splice(inProgressChunkIdx, 1);
|
||||
}
|
||||
handler._maybePersistChunkedState(id);
|
||||
if (!chunked.hasMoreParts(id) && inProgressChunks.length === 0) {
|
||||
chunked.finalize(id);
|
||||
} else if (chunked.hasMoreParts(id)) {
|
||||
chunked.sendNext(id);
|
||||
} else {
|
||||
log(qq.format("File ID {} has no more chunks to send and these chunk indexes are still marked as in-progress: {}", id, JSON.stringify(inProgressChunks)));
|
||||
}
|
||||
}, function failure(response, xhr) {
|
||||
chunked.handleFailure(chunkIdx, id, response, xhr);
|
||||
}).done(function() {
|
||||
handler.clearXhr(id, chunkIdx);
|
||||
});
|
||||
}
|
||||
}, function(error) {
|
||||
chunked.handleFailure(chunkIdx, id, error, null);
|
||||
});
|
||||
}
|
||||
}
|
||||
}, connectionManager = {
|
||||
|
@ -3077,7 +3214,12 @@
|
|||
}
|
||||
}, simple = {
|
||||
send: function(id, name) {
|
||||
handler._getFileState(id).loaded = 0;
|
||||
var fileState = handler._getFileState(id);
|
||||
if (!fileState) {
|
||||
log("Ignoring send request as this upload may have been cancelled, File ID " + id, "warn");
|
||||
return;
|
||||
}
|
||||
fileState.loaded = 0;
|
||||
log("Sending simple upload request for " + id);
|
||||
handler.uploadFile(id).then(function(response, optXhr) {
|
||||
log("Simple upload request succeeded for " + id);
|
||||
|
@ -3113,6 +3255,7 @@
|
|||
initHandler: function() {
|
||||
var handlerType = namespace ? qq[namespace] : qq.traditional, handlerModuleSubtype = qq.supportedFeatures.ajaxUploading ? "Xhr" : "Form";
|
||||
handler = new handlerType[handlerModuleSubtype + "UploadHandler"](options, {
|
||||
getCustomResumeData: options.getCustomResumeData,
|
||||
getDataByUuid: options.getDataByUuid,
|
||||
getName: options.getName,
|
||||
getSize: options.getSize,
|
||||
|
@ -3120,7 +3263,10 @@
|
|||
log: log,
|
||||
onCancel: options.onCancel,
|
||||
onProgress: options.onProgress,
|
||||
onUuidChanged: options.onUuidChanged
|
||||
onUuidChanged: options.onUuidChanged,
|
||||
onFinalizing: function(id) {
|
||||
options.setStatus(id, qq.status.UPLOAD_FINALIZING);
|
||||
}
|
||||
});
|
||||
if (handler._removeExpiredChunkingRecords) {
|
||||
handler._removeExpiredChunkingRecords();
|
||||
|
@ -3193,12 +3339,26 @@
|
|||
if (!controller.isValid(id)) {
|
||||
throw new qq.Error(id + " is not a valid file ID to upload!");
|
||||
}
|
||||
options.onUpload(id, name);
|
||||
if (chunkingPossible && handler._shouldChunkThisFile(id)) {
|
||||
chunked.sendNext(id);
|
||||
} else {
|
||||
simple.send(id, name);
|
||||
}
|
||||
options.onUpload(id, name).then(function(response) {
|
||||
if (response && response.pause) {
|
||||
options.setStatus(id, qq.status.PAUSED);
|
||||
handler.pause(id);
|
||||
connectionManager.free(id);
|
||||
} else {
|
||||
if (chunkingPossible && handler._shouldChunkThisFile(id)) {
|
||||
chunked.sendNext(id);
|
||||
} else {
|
||||
simple.send(id, name);
|
||||
}
|
||||
}
|
||||
}, function(error) {
|
||||
error = error || {};
|
||||
log(id + " upload start aborted due to rejected onUpload Promise - details: " + error, "error");
|
||||
if (!options.onAutoRetry(id, name, error.responseJSON || {})) {
|
||||
var response = upload.normalizeResponse(error.responseJSON, false);
|
||||
upload.cleanup(id, response);
|
||||
}
|
||||
});
|
||||
},
|
||||
start: function(id) {
|
||||
var blobToUpload = upload.getProxyOrBlob(id);
|
||||
|
@ -3277,6 +3437,13 @@
|
|||
isValid: function(id) {
|
||||
return handler.isValid(id);
|
||||
},
|
||||
hasResumeRecord: function(id) {
|
||||
var key = handler.isValid(id) && handler._getLocalStorageId && handler._getLocalStorageId(id);
|
||||
if (key) {
|
||||
return !!localStorage.getItem(key);
|
||||
}
|
||||
return false;
|
||||
},
|
||||
getResumableFilesData: function() {
|
||||
if (handler.getResumableFilesData) {
|
||||
return handler.getResumableFilesData();
|
||||
|
@ -3296,6 +3463,9 @@
|
|||
}
|
||||
return false;
|
||||
},
|
||||
isAttemptingResume: function(id) {
|
||||
return !!handler.isAttemptingResume && handler.isAttemptingResume(id);
|
||||
},
|
||||
isResumable: function(id) {
|
||||
return !!handler.isResumable && handler.isResumable(id);
|
||||
}
|
||||
|
@ -3486,7 +3656,19 @@
|
|||
};
|
||||
qq.XhrUploadHandler = function(spec) {
|
||||
"use strict";
|
||||
var handler = this, namespace = spec.options.namespace, proxy = spec.proxy, chunking = spec.options.chunking, resume = spec.options.resume, chunkFiles = chunking && spec.options.chunking.enabled && qq.supportedFeatures.chunking, resumeEnabled = resume && spec.options.resume.enabled && chunkFiles && qq.supportedFeatures.resume, getName = proxy.getName, getSize = proxy.getSize, getUuid = proxy.getUuid, getEndpoint = proxy.getEndpoint, getDataByUuid = proxy.getDataByUuid, onUuidChanged = proxy.onUuidChanged, onProgress = proxy.onProgress, log = proxy.log;
|
||||
var handler = this, namespace = spec.options.namespace, proxy = spec.proxy, chunking = spec.options.chunking, getChunkSize = function(id) {
|
||||
var fileState = handler._getFileState(id);
|
||||
if (fileState.chunkSize) {
|
||||
return fileState.chunkSize;
|
||||
} else {
|
||||
var chunkSize = chunking.partSize;
|
||||
if (qq.isFunction(chunkSize)) {
|
||||
chunkSize = chunkSize(id, getSize(id));
|
||||
}
|
||||
fileState.chunkSize = chunkSize;
|
||||
return chunkSize;
|
||||
}
|
||||
}, resume = spec.options.resume, chunkFiles = chunking && spec.options.chunking.enabled && qq.supportedFeatures.chunking, resumeEnabled = resume && spec.options.resume.enabled && chunkFiles && qq.supportedFeatures.resume, getName = proxy.getName, getSize = proxy.getSize, getUuid = proxy.getUuid, getEndpoint = proxy.getEndpoint, getDataByUuid = proxy.getDataByUuid, onUuidChanged = proxy.onUuidChanged, onProgress = proxy.onProgress, log = proxy.log, getCustomResumeData = proxy.getCustomResumeData;
|
||||
function abort(id) {
|
||||
qq.each(handler._getXhrs(id), function(xhrId, xhr) {
|
||||
var ajaxRequester = handler._getAjaxRequester(id, xhrId);
|
||||
|
@ -3524,7 +3706,10 @@
|
|||
});
|
||||
qq.extend(this, {
|
||||
clearCachedChunk: function(id, chunkIdx) {
|
||||
delete handler._getFileState(id).temp.cachedChunks[chunkIdx];
|
||||
var fileState = handler._getFileState(id);
|
||||
if (fileState) {
|
||||
delete fileState.temp.cachedChunks[chunkIdx];
|
||||
}
|
||||
},
|
||||
clearXhr: function(id, chunkIdx) {
|
||||
var tempState = handler._getFileState(id).temp;
|
||||
|
@ -3561,15 +3746,21 @@
|
|||
if (uploadData.key) {
|
||||
data.key = uploadData.key;
|
||||
}
|
||||
if (uploadData.customResumeData) {
|
||||
data.customResumeData = uploadData.customResumeData;
|
||||
}
|
||||
resumableFilesData.push(data);
|
||||
});
|
||||
return resumableFilesData;
|
||||
},
|
||||
isAttemptingResume: function(id) {
|
||||
return handler._getFileState(id).attemptingResume;
|
||||
},
|
||||
isResumable: function(id) {
|
||||
return !!chunking && handler.isValid(id) && !handler._getFileState(id).notResumable;
|
||||
},
|
||||
moveInProgressToRemaining: function(id, optInProgress, optRemaining) {
|
||||
var inProgress = optInProgress || handler._getFileState(id).chunking.inProgress, remaining = optRemaining || handler._getFileState(id).chunking.remaining;
|
||||
var fileState = handler._getFileState(id) || {}, chunkingState = fileState.chunking || {}, inProgress = optInProgress || chunkingState.inProgress, remaining = optRemaining || chunkingState.remaining;
|
||||
if (inProgress) {
|
||||
log(qq.format("Moving these chunks from in-progress {}, to remaining.", JSON.stringify(inProgress)));
|
||||
inProgress.reverse();
|
||||
|
@ -3628,7 +3819,7 @@
|
|||
return handler._getFileState(id).temp.ajaxRequesters[chunkIdx];
|
||||
},
|
||||
_getChunkData: function(id, chunkIndex) {
|
||||
var chunkSize = chunking.partSize, fileSize = getSize(id), fileOrBlob = handler.getFile(id), startBytes = chunkSize * chunkIndex, endBytes = startBytes + chunkSize >= fileSize ? fileSize : startBytes + chunkSize, totalChunks = handler._getTotalChunks(id), cachedChunks = this._getFileState(id).temp.cachedChunks, blob = cachedChunks[chunkIndex] || qq.sliceBlob(fileOrBlob, startBytes, endBytes);
|
||||
var chunkSize = getChunkSize(id), fileSize = getSize(id), fileOrBlob = handler.getFile(id), startBytes = chunkSize * chunkIndex, endBytes = startBytes + chunkSize >= fileSize ? fileSize : startBytes + chunkSize, totalChunks = handler._getTotalChunks(id), cachedChunks = this._getFileState(id).temp.cachedChunks, blob = cachedChunks[chunkIndex] || qq.sliceBlob(fileOrBlob, startBytes, endBytes);
|
||||
cachedChunks[chunkIndex] = blob;
|
||||
return {
|
||||
part: chunkIndex,
|
||||
|
@ -3648,8 +3839,11 @@
|
|||
};
|
||||
},
|
||||
_getLocalStorageId: function(id) {
|
||||
var formatVersion = "5.0", name = getName(id), size = getSize(id), chunkSize = chunking.partSize, endpoint = getEndpoint(id);
|
||||
return qq.format("qq{}resume{}-{}-{}-{}-{}", namespace, formatVersion, name, size, chunkSize, endpoint);
|
||||
var formatVersion = "5.0", name = getName(id), size = getSize(id), chunkSize = getChunkSize(id), endpoint = getEndpoint(id), customKeys = resume.customKeys(id), localStorageId = qq.format("qq{}resume{}-{}-{}-{}-{}", namespace, formatVersion, name, size, chunkSize, endpoint);
|
||||
customKeys.forEach(function(key) {
|
||||
localStorageId += "-" + key;
|
||||
});
|
||||
return localStorageId;
|
||||
},
|
||||
_getMimeType: function(id) {
|
||||
return handler.getFile(id).type;
|
||||
|
@ -3659,7 +3853,7 @@
|
|||
},
|
||||
_getTotalChunks: function(id) {
|
||||
if (chunking) {
|
||||
var fileSize = getSize(id), chunkSize = chunking.partSize;
|
||||
var fileSize = getSize(id), chunkSize = getChunkSize(id);
|
||||
return Math.ceil(fileSize / chunkSize);
|
||||
}
|
||||
},
|
||||
|
@ -3717,6 +3911,7 @@
|
|||
state.key = persistedData.key;
|
||||
state.chunking = persistedData.chunking;
|
||||
state.loaded = persistedData.loaded;
|
||||
state.customResumeData = persistedData.customResumeData;
|
||||
state.attemptingResume = true;
|
||||
handler.moveInProgressToRemaining(id);
|
||||
}
|
||||
|
@ -3726,6 +3921,7 @@
|
|||
_maybePersistChunkedState: function(id) {
|
||||
var state = handler._getFileState(id), localStorageId, persistedData;
|
||||
if (resumeEnabled && handler.isResumable(id)) {
|
||||
var customResumeData = getCustomResumeData(id);
|
||||
localStorageId = handler._getLocalStorageId(id);
|
||||
persistedData = {
|
||||
name: getName(id),
|
||||
|
@ -3736,6 +3932,9 @@
|
|||
loaded: state.loaded,
|
||||
lastUpdated: Date.now()
|
||||
};
|
||||
if (customResumeData) {
|
||||
persistedData.customResumeData = customResumeData;
|
||||
}
|
||||
try {
|
||||
localStorage.setItem(localStorageId, JSON.stringify(persistedData));
|
||||
} catch (error) {
|
||||
|
@ -3792,10 +3991,12 @@
|
|||
},
|
||||
_shouldChunkThisFile: function(id) {
|
||||
var state = handler._getFileState(id);
|
||||
if (!state.chunking) {
|
||||
handler.reevaluateChunking(id);
|
||||
if (state) {
|
||||
if (!state.chunking) {
|
||||
handler.reevaluateChunking(id);
|
||||
}
|
||||
return state.chunking.enabled;
|
||||
}
|
||||
return state.chunking.enabled;
|
||||
}
|
||||
});
|
||||
};
|
||||
|
@ -5322,18 +5523,24 @@
|
|||
"use strict";
|
||||
var handler = this, getName = proxy.getName, getSize = proxy.getSize, getUuid = proxy.getUuid, log = proxy.log, multipart = spec.forceMultipart || spec.paramsInBody, addChunkingSpecificParams = function(id, params, chunkData) {
|
||||
var size = getSize(id), name = getName(id);
|
||||
params[spec.chunking.paramNames.partIndex] = chunkData.part;
|
||||
params[spec.chunking.paramNames.partByteOffset] = chunkData.start;
|
||||
params[spec.chunking.paramNames.chunkSize] = chunkData.size;
|
||||
params[spec.chunking.paramNames.totalParts] = chunkData.count;
|
||||
params[spec.totalFileSizeName] = size;
|
||||
if (multipart) {
|
||||
if (!spec.omitDefaultParams) {
|
||||
params[spec.chunking.paramNames.partIndex] = chunkData.part;
|
||||
params[spec.chunking.paramNames.partByteOffset] = chunkData.start;
|
||||
params[spec.chunking.paramNames.chunkSize] = chunkData.size;
|
||||
params[spec.chunking.paramNames.totalParts] = chunkData.count;
|
||||
params[spec.totalFileSizeName] = size;
|
||||
}
|
||||
if (multipart && !spec.omitDefaultParams) {
|
||||
params[spec.filenameParam] = name;
|
||||
}
|
||||
}, allChunksDoneRequester = new qq.traditional.AllChunksDoneAjaxRequester({
|
||||
cors: spec.cors,
|
||||
endpoint: spec.chunking.success.endpoint,
|
||||
log: log
|
||||
headers: spec.chunking.success.headers,
|
||||
jsonPayload: spec.chunking.success.jsonPayload,
|
||||
log: log,
|
||||
method: spec.chunking.success.method,
|
||||
params: spec.chunking.success.params
|
||||
}), createReadyStateChangedHandler = function(id, xhr) {
|
||||
var promise = new qq.Promise();
|
||||
xhr.onreadystatechange = function() {
|
||||
|
@ -5355,7 +5562,7 @@
|
|||
params[spec.chunking.paramNames.totalParts] = handler._getTotalChunks(id);
|
||||
return params;
|
||||
}, isErrorUploadResponse = function(xhr, response) {
|
||||
return qq.indexOf([ 200, 201, 202, 203, 204 ], xhr.status) < 0 || !response.success || response.reset;
|
||||
return qq.indexOf([ 200, 201, 202, 203, 204 ], xhr.status) < 0 || spec.requireSuccessJson && !response.success || response.reset;
|
||||
}, onUploadOrChunkComplete = function(id, xhr) {
|
||||
var response;
|
||||
log("xhr - server response received for " + id);
|
||||
|
@ -5371,7 +5578,7 @@
|
|||
log(qq.format("Received response status {} with body: {}", xhr.status, xhr.responseText));
|
||||
response = qq.parseJson(xhr.responseText);
|
||||
} catch (error) {
|
||||
upload && log("Error when attempting to parse xhr response text (" + error.message + ")", "error");
|
||||
upload && spec.requireSuccessJson && log("Error when attempting to parse xhr response text (" + error.message + ")", "error");
|
||||
}
|
||||
return response;
|
||||
}, sendChunksCompleteRequest = function(id) {
|
||||
|
@ -5382,17 +5589,32 @@
|
|||
promise.failure(parseResponse(false, xhr), xhr);
|
||||
});
|
||||
return promise;
|
||||
}, setParamsAndGetEntityToSend = function(params, xhr, fileOrBlob, id) {
|
||||
var formData = new FormData(), method = spec.method, endpoint = spec.endpointStore.get(id), name = getName(id), size = getSize(id);
|
||||
params[spec.uuidName] = getUuid(id);
|
||||
params[spec.filenameParam] = name;
|
||||
if (multipart) {
|
||||
params[spec.totalFileSizeName] = size;
|
||||
}
|
||||
if (!spec.paramsInBody) {
|
||||
if (!multipart) {
|
||||
}, setParamsAndGetEntityToSend = function(entityToSendParams) {
|
||||
var fileOrBlob = entityToSendParams.fileOrBlob;
|
||||
var id = entityToSendParams.id;
|
||||
var xhr = entityToSendParams.xhr;
|
||||
var xhrOverrides = entityToSendParams.xhrOverrides || {};
|
||||
var customParams = entityToSendParams.customParams || {};
|
||||
var defaultParams = entityToSendParams.params || {};
|
||||
var xhrOverrideParams = xhrOverrides.params || {};
|
||||
var params;
|
||||
var formData = multipart ? new FormData() : null, method = xhrOverrides.method || spec.method, endpoint = xhrOverrides.endpoint || spec.endpointStore.get(id), name = getName(id), size = getSize(id);
|
||||
if (spec.omitDefaultParams) {
|
||||
params = qq.extend({}, customParams);
|
||||
qq.extend(params, xhrOverrideParams);
|
||||
} else {
|
||||
params = qq.extend({}, customParams);
|
||||
qq.extend(params, xhrOverrideParams);
|
||||
qq.extend(params, defaultParams);
|
||||
params[spec.uuidName] = getUuid(id);
|
||||
params[spec.filenameParam] = name;
|
||||
if (multipart) {
|
||||
params[spec.totalFileSizeName] = size;
|
||||
} else if (!spec.paramsInBody) {
|
||||
params[spec.inputName] = name;
|
||||
}
|
||||
}
|
||||
if (!spec.paramsInBody) {
|
||||
endpoint = qq.obj2url(params, endpoint);
|
||||
}
|
||||
xhr.open(method, endpoint, true);
|
||||
|
@ -5407,42 +5629,74 @@
|
|||
return formData;
|
||||
}
|
||||
return fileOrBlob;
|
||||
}, setUploadHeaders = function(id, xhr) {
|
||||
var extraHeaders = spec.customHeaders.get(id), fileOrBlob = handler.getFile(id);
|
||||
xhr.setRequestHeader("Accept", "application/json");
|
||||
xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest");
|
||||
xhr.setRequestHeader("Cache-Control", "no-cache");
|
||||
if (!multipart) {
|
||||
xhr.setRequestHeader("Content-Type", "application/octet-stream");
|
||||
xhr.setRequestHeader("X-Mime-Type", fileOrBlob.type);
|
||||
}, setUploadHeaders = function(headersOptions) {
|
||||
var headerOverrides = headersOptions.headerOverrides;
|
||||
var id = headersOptions.id;
|
||||
var xhr = headersOptions.xhr;
|
||||
if (headerOverrides) {
|
||||
qq.each(headerOverrides, function(headerName, headerValue) {
|
||||
xhr.setRequestHeader(headerName, headerValue);
|
||||
});
|
||||
} else {
|
||||
var extraHeaders = spec.customHeaders.get(id), fileOrBlob = handler.getFile(id);
|
||||
xhr.setRequestHeader("Accept", "application/json");
|
||||
xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest");
|
||||
xhr.setRequestHeader("Cache-Control", "no-cache");
|
||||
if (!multipart) {
|
||||
xhr.setRequestHeader("Content-Type", "application/octet-stream");
|
||||
xhr.setRequestHeader("X-Mime-Type", fileOrBlob.type);
|
||||
}
|
||||
qq.each(extraHeaders, function(name, val) {
|
||||
xhr.setRequestHeader(name, val);
|
||||
});
|
||||
}
|
||||
qq.each(extraHeaders, function(name, val) {
|
||||
xhr.setRequestHeader(name, val);
|
||||
});
|
||||
};
|
||||
qq.extend(this, {
|
||||
uploadChunk: function(id, chunkIdx, resuming) {
|
||||
var chunkData = handler._getChunkData(id, chunkIdx), xhr = handler._createXhr(id, chunkIdx), size = getSize(id), promise, toSend, params;
|
||||
uploadChunk: function(uploadChunkParams) {
|
||||
var id = uploadChunkParams.id;
|
||||
var chunkIdx = uploadChunkParams.chunkIdx;
|
||||
var overrides = uploadChunkParams.overrides || {};
|
||||
var resuming = uploadChunkParams.resuming;
|
||||
var chunkData = handler._getChunkData(id, chunkIdx), xhr = handler._createXhr(id, chunkIdx), promise, toSend, customParams, params = {};
|
||||
promise = createReadyStateChangedHandler(id, xhr);
|
||||
handler._registerProgressHandler(id, chunkIdx, chunkData.size);
|
||||
params = spec.paramsStore.get(id);
|
||||
customParams = spec.paramsStore.get(id);
|
||||
addChunkingSpecificParams(id, params, chunkData);
|
||||
if (resuming) {
|
||||
params[spec.resume.paramNames.resuming] = true;
|
||||
}
|
||||
toSend = setParamsAndGetEntityToSend(params, xhr, chunkData.blob, id);
|
||||
setUploadHeaders(id, xhr);
|
||||
toSend = setParamsAndGetEntityToSend({
|
||||
fileOrBlob: chunkData.blob,
|
||||
id: id,
|
||||
customParams: customParams,
|
||||
params: params,
|
||||
xhr: xhr,
|
||||
xhrOverrides: overrides
|
||||
});
|
||||
setUploadHeaders({
|
||||
headerOverrides: overrides.headers,
|
||||
id: id,
|
||||
xhr: xhr
|
||||
});
|
||||
xhr.send(toSend);
|
||||
return promise;
|
||||
},
|
||||
uploadFile: function(id) {
|
||||
var fileOrBlob = handler.getFile(id), promise, xhr, params, toSend;
|
||||
var fileOrBlob = handler.getFile(id), promise, xhr, customParams, toSend;
|
||||
xhr = handler._createXhr(id);
|
||||
handler._registerProgressHandler(id);
|
||||
promise = createReadyStateChangedHandler(id, xhr);
|
||||
params = spec.paramsStore.get(id);
|
||||
toSend = setParamsAndGetEntityToSend(params, xhr, fileOrBlob, id);
|
||||
setUploadHeaders(id, xhr);
|
||||
customParams = spec.paramsStore.get(id);
|
||||
toSend = setParamsAndGetEntityToSend({
|
||||
fileOrBlob: fileOrBlob,
|
||||
id: id,
|
||||
customParams: customParams,
|
||||
xhr: xhr
|
||||
});
|
||||
setUploadHeaders({
|
||||
id: id,
|
||||
xhr: xhr
|
||||
});
|
||||
xhr.send(toSend);
|
||||
return promise;
|
||||
}
|
||||
|
@ -5458,6 +5712,7 @@
|
|||
qq.override(this, function(super_) {
|
||||
return {
|
||||
finalizeChunks: function(id) {
|
||||
proxy.onFinalizing(id);
|
||||
if (spec.chunking.success.endpoint) {
|
||||
return sendChunksCompleteRequest(id);
|
||||
} else {
|
||||
|
@ -5469,24 +5724,29 @@
|
|||
};
|
||||
qq.traditional.AllChunksDoneAjaxRequester = function(o) {
|
||||
"use strict";
|
||||
var requester, method = "POST", options = {
|
||||
var requester, options = {
|
||||
cors: {
|
||||
allowXdr: false,
|
||||
expected: false,
|
||||
sendCredentials: false
|
||||
},
|
||||
endpoint: null,
|
||||
log: function(str, level) {}
|
||||
log: function(str, level) {},
|
||||
method: "POST"
|
||||
}, promises = {}, endpointHandler = {
|
||||
get: function(id) {
|
||||
if (qq.isFunction(options.endpoint)) {
|
||||
return options.endpoint(id);
|
||||
}
|
||||
return options.endpoint;
|
||||
}
|
||||
};
|
||||
qq.extend(options, o);
|
||||
requester = qq.extend(this, new qq.AjaxRequester({
|
||||
acceptHeader: "application/json",
|
||||
validMethods: [ method ],
|
||||
method: method,
|
||||
contentType: options.jsonPayload ? "application/json" : "application/x-www-form-urlencoded",
|
||||
validMethods: [ options.method ],
|
||||
method: options.method,
|
||||
endpointStore: endpointHandler,
|
||||
allowXRequestedWithAndCacheControl: false,
|
||||
cors: options.cors,
|
||||
|
@ -5506,7 +5766,7 @@
|
|||
var promise = new qq.Promise();
|
||||
options.log("Submitting All Chunks Done request for " + id);
|
||||
promises[id] = promise;
|
||||
requester.initTransport(id).withParams(params).withHeaders(headers).send(xhr);
|
||||
requester.initTransport(id).withParams(options.params(id) || params).withHeaders(options.headers(id) || headers).send(xhr);
|
||||
return promise;
|
||||
}
|
||||
});
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
|
@ -1 +1 @@
|
|||
.qq-uploader{position:relative;width:100%}.qq-upload-button{display:block;width:105px;padding:7px 0;text-align:center;background:#800;border-bottom:1px solid #DDD;color:#FFF}.qq-upload-button-hover{background:#C00}.qq-upload-button-focus{outline:#000 dotted 1px}.qq-upload-drop-area,.qq-upload-extra-drop-area{position:absolute;top:0;left:0;width:100%;height:100%;min-height:30px;z-index:2;background:#FF9797;text-align:center}.qq-upload-drop-area span{display:block;position:absolute;top:50%;width:100%;margin-top:-8px;font-size:16px}.qq-upload-extra-drop-area{position:relative;margin-top:50px;font-size:16px;padding-top:30px;height:20px;min-height:40px}.qq-upload-drop-area-active{background:#FF7171}.qq-upload-list{margin:0;padding:0;list-style:none}.qq-upload-list li{margin:0;padding:9px;line-height:15px;font-size:16px;background-color:#FFF0BD}.qq-upload-cancel,.qq-upload-continue,.qq-upload-delete,.qq-upload-failed-text,.qq-upload-file,.qq-upload-pause,.qq-upload-retry,.qq-upload-size,.qq-upload-spinner{margin-right:12px;display:inline}.qq-upload-spinner{display:inline-block;background:url(loading.gif);width:15px;height:15px;vertical-align:text-bottom}.qq-drop-processing{display:block}.qq-drop-processing-spinner{display:inline-block;background:url(processing.gif);width:24px;height:24px;vertical-align:text-bottom}.qq-upload-continue,.qq-upload-delete,.qq-upload-pause{display:inline}.qq-upload-cancel,.qq-upload-continue,.qq-upload-delete,.qq-upload-pause,.qq-upload-retry{color:#000}.qq-upload-cancel,.qq-upload-continue,.qq-upload-delete,.qq-upload-pause,.qq-upload-retry,.qq-upload-size{font-size:12px;font-weight:400}.qq-upload-failed-text{display:none;font-style:italic;font-weight:700}.qq-upload-failed-icon{display:none;width:15px;height:15px;vertical-align:text-bottom}.qq-upload-fail .qq-upload-failed-text{display:inline}.qq-upload-retrying .qq-upload-failed-text{display:inline;color:#D60000}.qq-upload-list li.qq-upload-success{background-color:#5DA30C;color:#FFF}.qq-upload-list li.qq-upload-fail{background-color:#D60000;color:#FFF}.qq-progress-bar{display:block;background:-moz-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:-webkit-gradient(linear,left top,left bottom,color-stop(0,rgba(30,87,153,1)),color-stop(50%,rgba(41,137,216,1)),color-stop(51%,rgba(32,124,202,1)),color-stop(100%,rgba(125,185,232,1)));background:-webkit-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:-o-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:-ms-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:linear-gradient(to bottom,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);width:0;height:15px;border-radius:6px;margin-bottom:3px}.qq-total-progress-bar{height:25px;border-radius:9px}.qq-total-progress-bar-container{margin:9px}INPUT.qq-edit-filename{position:absolute;opacity:0;filter:alpha(opacity=0);z-index:-1;-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)"}.qq-upload-file.qq-editable{cursor:pointer}.qq-edit-filename-icon.qq-editable{display:inline-block;cursor:pointer}.qq-hide,.qq-uploader DIALOG{display:none}INPUT.qq-edit-filename.qq-editing{position:static;margin-top:-5px;margin-right:10px;margin-bottom:-5px;opacity:1;filter:alpha(opacity=100);-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=100)"}.qq-edit-filename-icon{display:none;background:url(edit.gif);width:15px;height:15px;vertical-align:text-bottom;margin-right:5px}.qq-uploader DIALOG[open]{display:block}.qq-uploader DIALOG .qq-dialog-buttons{text-align:center;padding-top:10px}.qq-uploader DIALOG .qq-dialog-buttons BUTTON{margin-left:5px;margin-right:5px}.qq-uploader DIALOG .qq-dialog-message-selector{padding-bottom:10px}.qq-uploader DIALOG::backdrop{background-color:rgba(0,0,0,.7)}/*# sourceMappingURL=fine-uploader.min.css.map */
|
||||
.qq-uploader{position:relative;width:100%}.qq-upload-button{display:block;width:105px;padding:7px 0;text-align:center;background:#800;border-bottom:1px solid #ddd;color:#fff}.qq-upload-button-hover{background:#c00}.qq-upload-button-focus{outline:1px dotted #000}.qq-upload-drop-area,.qq-upload-extra-drop-area{position:absolute;top:0;left:0;width:100%;height:100%;min-height:30px;z-index:2;background:#ff9797;text-align:center}.qq-upload-drop-area span{display:block;position:absolute;top:50%;width:100%;margin-top:-8px;font-size:16px}.qq-upload-extra-drop-area{position:relative;margin-top:50px;font-size:16px;padding-top:30px;height:20px;min-height:40px}.qq-upload-drop-area-active{background:#ff7171}.qq-upload-list{margin:0;padding:0;list-style:none}.qq-upload-list li{margin:0;padding:9px;line-height:15px;font-size:16px;background-color:#fff0bd}.qq-upload-cancel,.qq-upload-continue,.qq-upload-delete,.qq-upload-failed-text,.qq-upload-file,.qq-upload-pause,.qq-upload-retry,.qq-upload-size,.qq-upload-spinner{margin-right:12px;display:inline}.qq-upload-spinner{display:inline-block;background:url(loading.gif);width:15px;height:15px;vertical-align:text-bottom}.qq-drop-processing{display:block}.qq-drop-processing-spinner{display:inline-block;background:url(processing.gif);width:24px;height:24px;vertical-align:text-bottom}.qq-upload-continue,.qq-upload-delete,.qq-upload-pause{display:inline}.qq-upload-cancel,.qq-upload-continue,.qq-upload-delete,.qq-upload-pause,.qq-upload-retry{color:#000}.qq-upload-cancel,.qq-upload-continue,.qq-upload-delete,.qq-upload-pause,.qq-upload-retry,.qq-upload-size{font-size:12px;font-weight:400}.qq-upload-failed-text{display:none;font-style:italic;font-weight:700}.qq-upload-failed-icon{display:none;width:15px;height:15px;vertical-align:text-bottom}.qq-upload-fail .qq-upload-failed-text{display:inline}.qq-upload-retrying .qq-upload-failed-text{display:inline;color:#d60000}.qq-upload-list li.qq-upload-success{background-color:#5da30c;color:#fff}.qq-upload-list li.qq-upload-fail{background-color:#d60000;color:#fff}.qq-progress-bar{display:block;background:-moz-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:-webkit-gradient(linear,left top,left bottom,color-stop(0,rgba(30,87,153,1)),color-stop(50%,rgba(41,137,216,1)),color-stop(51%,rgba(32,124,202,1)),color-stop(100%,rgba(125,185,232,1)));background:-webkit-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:-o-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:-ms-linear-gradient(top,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);background:linear-gradient(to bottom,rgba(30,87,153,1) 0,rgba(41,137,216,1) 50%,rgba(32,124,202,1) 51%,rgba(125,185,232,1) 100%);width:0;height:15px;border-radius:6px;margin-bottom:3px}.qq-total-progress-bar{height:25px;border-radius:9px}.qq-total-progress-bar-container{margin:9px}INPUT.qq-edit-filename{position:absolute;opacity:0;z-index:-1}.qq-upload-file.qq-editable{cursor:pointer}.qq-edit-filename-icon.qq-editable{display:inline-block;cursor:pointer}INPUT.qq-edit-filename.qq-editing{position:static;margin-top:-5px;margin-right:10px;margin-bottom:-5px;opacity:1}.qq-edit-filename-icon{display:none;background:url(edit.gif);width:15px;height:15px;vertical-align:text-bottom;margin-right:5px}.qq-hide{display:none}.qq-uploader DIALOG{display:none}.qq-uploader DIALOG[open]{display:block}.qq-uploader DIALOG{display:none}.qq-uploader DIALOG[open]{display:block}.qq-uploader DIALOG .qq-dialog-buttons{text-align:center;padding-top:10px}.qq-uploader DIALOG .qq-dialog-buttons BUTTON{margin-left:5px;margin-right:5px}.qq-uploader DIALOG .qq-dialog-message-selector{padding-bottom:10px}.qq-uploader DIALOG::backdrop{background-color:rgba(0,0,0,.7)}/*# sourceMappingURL=fine-uploader.min.css.map */
|
|
@ -1 +1 @@
|
|||
{"version":3,"sources":["_build/fine-uploader.css"],"names":[],"mappings":"AAAA,aACI,SAAU,SACV,MAAO,KAEX,kBACI,QAAS,MACT,MAAO,MACP,QAAS,IAAI,EACb,WAAY,OACZ,WAAY,KACZ,cAAe,IAAI,MAAM,KACzB,MAAO,KAEX,wBACI,WAAY,KAEhB,wBACI,QAAoB,KAAP,OAAJ,IAEb,qBAAsB,2BAClB,SAAU,SACV,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DAGhB,4BACI,OAAQ,QAGZ,mCACI,QAAS,aACT,OAAQ,QAuBZ,SAaA,oBACI,QAAS,KAlCb,kCACI,SAAU,OACV,WAAY,KACZ,aAAc,KACd,cAAe,KAEf,QAAS,EACT,OAAQ,mBACR,WAAY,uDAGhB,uBACI,QAAS,KACT,WAAY,cACZ,MAAO,KACP,OAAQ,KACR,eAAgB,YAChB,aAAc,IAoBlB,0BACI,QAAS,MAGb,uCACI,WAAY,OACZ,YAAa,KAGjB,8CACI,YAAa,IACb,aAAc,IAGlB,gDACI,eAAgB,KAGpB,8BACI,iBAAkB"}
|
||||
{"version":3,"sources":["_build/fine-uploader.css"],"names":[],"mappings":"AAAA,aACI,SAAU,SACV,MAAO,KAEX,kBACI,QAAS,MACT,MAAO,MACP,QAAS,IAAI,EACb,WAAY,OACZ,WAAY,KACZ,cAAe,IAAI,MAAM,KACzB,MAAO,KAEX,wBACI,WAAY,KAEhB,wBACI,QAAS,IAAI,OAAO,KAExB,qBAAsB,2BAClB,SAAU,SACV,IAAK,EACL,KAAM,EACN,MAAO,KACP,OAAQ,KACR,WAAY,KACZ,QAAS,EACT,WAAY,QACZ,WAAY,OAEhB,0BACI,QAAS,MACT,SAAU,SACV,IAAK,IACL,MAAO,KACP,WAAY,KACZ,UAAW,KAEf,2BACI,SAAU,SACV,WAAY,KACZ,UAAW,KACX,YAAa,KACb,OAAQ,KACR,WAAY,KAEhB,4BACI,WAAY,QAEhB,gBACI,OAAQ,EACR,QAAS,EACT,WAAY,KAEhB,mBACI,OAAQ,EACR,QAAS,IACT,YAAa,KACb,UAAW,KACX,iBAAkB,QAGtB,kBACqC,oBAArC,kBADqC,uBADrC,gBAEmB,iBADA,iBADkB,gBAApB,mBAGb,aAAc,KACd,QAAS,OAIb,mBACI,QAAS,aACT,WAAY,iBACZ,MAAO,KACP,OAAQ,KACR,eAAgB,YAEpB,oBACI,QAAS,MAEb,4BACI,QAAS,aACT,WAAY,oBACZ,MAAO,KACP,OAAQ,KACR,eAAgB,YAGiB,oBAArC,kBAAmB,iBACf,QAAS,OAGwB,kBACnB,oBADA,kBAClB,iBADA,iBAEI,MAAO,KAGM,kBACoB,oBAArC,kBAAmB,iBADiB,iBAApC,gBAEI,UAAW,KACX,YAAa,IAEjB,uBACI,QAAS,KACT,WAAY,OACZ,YAAa,IAEjB,uBACI,QAAQ,KACR,MAAM,KACN,OAAO,KACP,eAAe,YAEnB,uCACI,QAAS,OAEb,2CACI,QAAS,OACT,MAAO,QAEX,qCACI,iBAAkB,QAClB,MAAO,KAEX,kCACI,iBAAkB,QAClB,MAAO,KAEX,iBACI,QAAS,MACT,WAAY,qHACZ,WAAY,yLACZ,WAAY,wHACZ,WAAY,mHACZ,WAAY,oHACZ,WAAY,sHACZ,MAAO,EACP,OAAQ,KACR,cAAe,IACf,cAAe,IAGnB,uBACI,OAAQ,KACR,cAAe,IAGnB,iCACI,OAAQ,IAGZ,uBACI,SAAU,SACV,QAAS,EAET,QAAS,GAIb,4BACI,OAAQ,QAGZ,mCACI,QAAS,aACT,OAAQ,QAGZ,kCACI,SAAU,OACV,WAAY,KACZ,aAAc,KACd,cAAe,KAEf,QAAS,EAKb,uBACI,QAAS,KACT,WAAY,cACZ,MAAO,KACP,OAAQ,KACR,eAAgB,YAChB,aAAc,IAGlB,SACI,QAAS,KAIb,oBACI,QAAS,KAGb,0BACI,QAAS,MAGb,oBACI,QAAS,KAGb,0BACI,QAAS,MAGb,uCACI,WAAY,OACZ,YAAa,KAGjB,8CACI,YAAa,IACb,aAAc,IAGlB,gDACI,eAAgB,KAGpB,8BACI,iBAAkB"}
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user