@syncfusion/ej2-filemanager 27.2.5 → 28.1.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/ej2-filemanager.min.js +1 -10
- package/dist/ej2-filemanager.umd.min.js +1 -10
- package/dist/ej2-filemanager.umd.min.js.map +1 -1
- package/dist/es6/ej2-filemanager.es2015.js +134 -28
- package/dist/es6/ej2-filemanager.es2015.js.map +1 -1
- package/dist/es6/ej2-filemanager.es5.js +142 -36
- package/dist/es6/ej2-filemanager.es5.js.map +1 -1
- package/dist/global/ej2-filemanager.min.js +1 -10
- package/dist/global/ej2-filemanager.min.js.map +1 -1
- package/dist/global/index.d.ts +0 -9
- package/package.json +16 -17
- package/src/file-manager/base/file-manager-model.d.ts +2 -1
- package/src/file-manager/base/file-manager.d.ts +4 -1
- package/src/file-manager/base/file-manager.js +39 -4
- package/src/file-manager/common/operations.js +44 -15
- package/src/file-manager/common/utility.d.ts +9 -0
- package/src/file-manager/common/utility.js +19 -3
- package/src/file-manager/layout/details-view.js +10 -0
- package/src/file-manager/layout/large-icons-view.js +7 -5
- package/src/file-manager/layout/navigation-pane.js +9 -5
- package/src/file-manager/models/upload-settings-model.d.ts +9 -0
- package/src/file-manager/models/upload-settings.d.ts +8 -0
- package/src/file-manager/models/upload-settings.js +3 -0
- package/src/file-manager/pop-up/context-menu.d.ts +1 -0
- package/src/file-manager/pop-up/context-menu.js +4 -3
- package/src/file-manager/pop-up/dialog.js +8 -2
- package/styles/bds-lite.css +1284 -0
- package/styles/bds-lite.scss +16 -0
- package/styles/bds.css +1876 -0
- package/styles/bds.scss +17 -0
- package/styles/file-manager/_bigger.scss +69 -6
- package/styles/file-manager/_fluent2-definition.scss +1 -1
- package/styles/file-manager/_layout.scss +77 -14
- package/styles/file-manager/_material3-definition.scss +2 -2
- package/styles/file-manager/_tailwind3-definition.scss +243 -0
- package/styles/file-manager/_theme.scss +4 -1
- package/styles/file-manager/bds.css +1876 -0
- package/styles/file-manager/bds.scss +17 -0
- package/styles/file-manager/fluent2.css +2 -2
- package/styles/file-manager/icons/_tailwind3.scss +235 -0
- package/styles/file-manager/material3-dark.css +3 -2
- package/styles/file-manager/material3.css +3 -2
- package/styles/file-manager/tailwind3.css +1666 -0
- package/styles/file-manager/tailwind3.scss +17 -0
- package/styles/fluent2.css +2 -2
- package/styles/material3-dark.css +3 -2
- package/styles/material3.css +3 -2
- package/styles/tailwind3-lite.css +1069 -0
- package/styles/tailwind3-lite.scss +16 -0
- package/styles/tailwind3.css +1666 -0
- package/styles/tailwind3.scss +17 -0
@@ -383,6 +383,9 @@ var UploadSettings = /** @__PURE__ @class */ (function (_super) {
|
|
383
383
|
__decorate$6([
|
384
384
|
Property(30000000)
|
385
385
|
], UploadSettings.prototype, "maxFileSize", void 0);
|
386
|
+
__decorate$6([
|
387
|
+
Property(0)
|
388
|
+
], UploadSettings.prototype, "chunkSize", void 0);
|
386
389
|
return UploadSettings;
|
387
390
|
}(ChildProperty));
|
388
391
|
|
@@ -1730,7 +1733,7 @@ function pasteHandler(parent) {
|
|
1730
1733
|
if (parent.selectedNodes.length !== 0 && parent.enablePaste) {
|
1731
1734
|
var path = (parent.folderPath === '') ? parent.path : parent.folderPath;
|
1732
1735
|
if (parent.activeModule === 'navigationpane' && !parent.selectedNodes[0].includes('/')) {
|
1733
|
-
parent.targetPath =
|
1736
|
+
parent.targetPath = getTargetPath(parent, parent.actionRecords[0]);
|
1734
1737
|
}
|
1735
1738
|
var subFolder = validateSubFolder(parent, parent.actionRecords, path, parent.path);
|
1736
1739
|
if (!subFolder) {
|
@@ -1860,9 +1863,9 @@ function getDirectoryPath(parent, args) {
|
|
1860
1863
|
var fPath = getValue(parent.hasId && !isNullOrUndefined(parent.ajaxSettings.url) ? 'filterId' : 'filterPath', args.cwd);
|
1861
1864
|
if (!isNullOrUndefined(fPath)) {
|
1862
1865
|
if (fPath === '') {
|
1863
|
-
return
|
1866
|
+
return '/';
|
1864
1867
|
}
|
1865
|
-
return fPath.replace(/\\/g, '/') + filePath;
|
1868
|
+
return fPath.replace(/\\/g, '/').replace(/^.*?(?=\/)/, '') + filePath;
|
1866
1869
|
}
|
1867
1870
|
else {
|
1868
1871
|
return isFileSystemData(parent) ? filePath : parent.path + filePath;
|
@@ -2471,6 +2474,22 @@ function closePopup(parent) {
|
|
2471
2474
|
parent.dialogObj.hide();
|
2472
2475
|
}
|
2473
2476
|
}
|
2477
|
+
/**
|
2478
|
+
* Get target path from item data.
|
2479
|
+
*
|
2480
|
+
* @param {IFileManager} parent - specifies the parent.
|
2481
|
+
* @param {Object} itemData - specifies the item elements.
|
2482
|
+
* @returns {string} returns the path.
|
2483
|
+
* @private
|
2484
|
+
*/
|
2485
|
+
function getTargetPath(parent, itemData) {
|
2486
|
+
if (parent.hasId && !isNullOrUndefined(getValue('filterId', itemData))) {
|
2487
|
+
return getValue('filterId', itemData).replace(/\\/g, '/').replace(/^[^/]+\//, '/');
|
2488
|
+
}
|
2489
|
+
else {
|
2490
|
+
return getValue('filterPath', itemData).replace(/\\/g, '/');
|
2491
|
+
}
|
2492
|
+
}
|
2474
2493
|
/**
|
2475
2494
|
* Access control handler
|
2476
2495
|
*
|
@@ -2753,7 +2772,7 @@ function createNewItem(data, target, itemName, isCopy) {
|
|
2753
2772
|
}
|
2754
2773
|
}
|
2755
2774
|
var currentDate = new Date();
|
2756
|
-
var folderPath = target.id !== 0 ? target.filterPath + target.name : '\\';
|
2775
|
+
var folderPath = String(target.id) !== String(0) && !isNullOrUndefined(target.parentId) ? target.filterPath + target.name + '\\' : '\\';
|
2757
2776
|
Object.assign(newItem, {
|
2758
2777
|
dateCreated: currentDate,
|
2759
2778
|
dateModified: currentDate,
|
@@ -2887,7 +2906,9 @@ function triggerRenameOperation(parent, data, eventArgs) {
|
|
2887
2906
|
if (isFileSystemData(parent)) {
|
2888
2907
|
if (!isFileExists(parent.fileSystemData, args.newName)) {
|
2889
2908
|
var fileData = filterById(parent, args.itemData[0].id);
|
2909
|
+
var oldName = fileData.name;
|
2890
2910
|
fileData.name = args.newName;
|
2911
|
+
updateChildrenFilterPath(parent, fileData.id, oldName, args.newName);
|
2891
2912
|
}
|
2892
2913
|
else {
|
2893
2914
|
var message = 'Cannot rename' + args.itemData[0].name + 'to' + args.newName + ': destination already exists.';
|
@@ -2896,6 +2917,26 @@ function triggerRenameOperation(parent, data, eventArgs) {
|
|
2896
2917
|
}
|
2897
2918
|
});
|
2898
2919
|
}
|
2920
|
+
/**
|
2921
|
+
* Function to update child item filter path.
|
2922
|
+
*
|
2923
|
+
* @param {IFileManager} parent - specifies the parent element.
|
2924
|
+
* @param {string | number} parentId - specifies the parent id.
|
2925
|
+
* @param {string} oldName - specifies the previous name.
|
2926
|
+
* @param {string} newName - specifies the new name.
|
2927
|
+
* @returns {void}
|
2928
|
+
* @private
|
2929
|
+
*/
|
2930
|
+
function updateChildrenFilterPath(parent, parentId, oldName, newName) {
|
2931
|
+
parent.fileSystemData.forEach(function (item) {
|
2932
|
+
if (String(item.parentId) === String(parentId)) {
|
2933
|
+
var oldPath = item.filterPath;
|
2934
|
+
var newPath = oldPath.replace(oldName + '\\', newName + '\\');
|
2935
|
+
item.filterPath = newPath;
|
2936
|
+
updateChildrenFilterPath(parent, item.id, oldName, newName);
|
2937
|
+
}
|
2938
|
+
});
|
2939
|
+
}
|
2899
2940
|
/**
|
2900
2941
|
* Function to trigger move or copy operation.
|
2901
2942
|
*
|
@@ -2951,18 +2992,23 @@ function triggerMoveOrCopyOperation(parent, data, eventArgs) {
|
|
2951
2992
|
}
|
2952
2993
|
return;
|
2953
2994
|
}
|
2954
|
-
var
|
2955
|
-
var getTargetFiles = filterByParent(parent,
|
2995
|
+
var target_1 = args.targetData;
|
2996
|
+
var getTargetFiles = filterByParent(parent, target_1.id);
|
2956
2997
|
for (var i = 0; i < args.itemData.length; i++) {
|
2957
2998
|
var currItem = args.itemData[i];
|
2958
2999
|
if (!isFileExists(getTargetFiles, currItem.name) || getValue('renameFiles', data).length > 0) {
|
2959
|
-
if (!
|
2960
|
-
|
3000
|
+
if (!target_1.hasChild) {
|
3001
|
+
target_1.hasChild = !currItem.isFile;
|
3002
|
+
var targetItem = parent.fileSystemData
|
3003
|
+
.filter(function (item) { return String(item.id) === String(target_1.id); });
|
3004
|
+
if (targetItem.length > 0) {
|
3005
|
+
targetItem[0].hasChild = target_1.hasChild;
|
3006
|
+
}
|
2961
3007
|
}
|
2962
3008
|
if (!currItem.isFile) {
|
2963
3009
|
//Check whether the source folder include other sub folders or not.
|
2964
3010
|
var subItems = currItem.parentId !== 0
|
2965
|
-
? filterByParent(parent, currItem.
|
3011
|
+
? filterByParent(parent, currItem.parentId) : [];
|
2966
3012
|
var itemData = filterById(parent, currItem.parentId);
|
2967
3013
|
itemData.hasChild = subItems.length > 1 ? true : false;
|
2968
3014
|
}
|
@@ -2973,13 +3019,13 @@ function triggerMoveOrCopyOperation(parent, data, eventArgs) {
|
|
2973
3019
|
fileData.name = currItem.name;
|
2974
3020
|
parent.responseData.error = null;
|
2975
3021
|
parent.existingFileCount++;
|
2976
|
-
parent.dropData =
|
3022
|
+
parent.dropData = target_1;
|
2977
3023
|
parent.dropPath = args.path;
|
2978
3024
|
var pathArray = args.targetPath.replace(/^\/|\/$/g, '').split('/');
|
2979
|
-
|
3025
|
+
target_1 = filterById(parent, pathArray[pathArray.length - 1]);
|
2980
3026
|
}
|
2981
|
-
fileData.parentId =
|
2982
|
-
fileData.filterPath =
|
3027
|
+
fileData.parentId = target_1.id;
|
3028
|
+
fileData.filterPath = target_1.id === 0 ? '\\' : target_1.filterPath + target_1.name + '\\';
|
2983
3029
|
}
|
2984
3030
|
else {
|
2985
3031
|
file_1.push(currItem.name);
|
@@ -3085,7 +3131,6 @@ function createAjax(parent, data, fn, event, operation, targetPath) {
|
|
3085
3131
|
? getValue('path', data) : parent.path;
|
3086
3132
|
var pathArray = filePath.replace(/^\/|\/$/g, '').split('/');
|
3087
3133
|
var idValue = event === 'rename-end-parent' || (event === 'path-changed' && getValue('data', data).length !== 0 && isNullOrUndefined(parent.renamedItem))
|
3088
|
-
|| (event === 'paste-end' && (parent.targetModule === 'largeiconsview' || parent.targetModule === 'detailsview'))
|
3089
3134
|
? getValue('data', data)[0].id : pathArray[pathArray.length - 1];
|
3090
3135
|
var action = getValue('action', data);
|
3091
3136
|
var isFileOperation = (action === 'move' || action === 'rename' || action === 'copy' || action === 'delete' || action === 'search') && event !== 'rename-end';
|
@@ -3130,9 +3175,9 @@ function createAjax(parent, data, fn, event, operation, targetPath) {
|
|
3130
3175
|
var isMultipleFiles = itemData.length > 1;
|
3131
3176
|
var itemNames = itemData.map(function (item) { return item.name; });
|
3132
3177
|
var totalSize = isMultipleFiles ? getSize(itemData.reduce(function (accumulator, currentObject) { return accumulator + (currentObject.size || 0); }, 0)) : getSize(details.size);
|
3133
|
-
var path = (parent.pathNames.includes(details.name) ? parent.pathNames.join('/') : parent.pathNames.join('/') + '/' + details.name);
|
3178
|
+
var path = (parent.pathNames.includes(details.name) || isMultipleFiles ? parent.pathNames.join('/') : parent.pathNames.join('/') + '/' + details.name);
|
3134
3179
|
parent.responseData.details = Object.assign({
|
3135
|
-
location:
|
3180
|
+
location: path,
|
3136
3181
|
multipleFiles: isMultipleFiles,
|
3137
3182
|
name: itemNames.join(', '),
|
3138
3183
|
size: totalSize
|
@@ -3261,6 +3306,8 @@ function performReadOperation(parent, result, fn, data, event, operation, target
|
|
3261
3306
|
if ((getValue('path', data) === '/') || (parent.hasId && getValue('path', data).match(/[/]/g).length === 1)) {
|
3262
3307
|
if (getValue('names', data).length === 0) {
|
3263
3308
|
setValue('name', rootName, result.details);
|
3309
|
+
}
|
3310
|
+
if (location_1.indexOf('\\') === -1) {
|
3264
3311
|
location_1 = rootName;
|
3265
3312
|
}
|
3266
3313
|
else {
|
@@ -3479,7 +3526,8 @@ function renameSuccess(parent, result) {
|
|
3479
3526
|
var pathLevel = parent.pathId[parent.pathId.length - 1].split('_').length - 2;
|
3480
3527
|
parent.pathId.pop();
|
3481
3528
|
parent.itemData = [getValue(parent.pathId[parent.pathId.length - 1], parent.feParent)];
|
3482
|
-
|
3529
|
+
var renamePath = getTargetPath(parent, parent.renamedItem);
|
3530
|
+
read(parent, renameEndParent, renamePath);
|
3483
3531
|
if (!isNullOrUndefined(pathObject) && parent.pathNames.length > 1 && pathLevel <= parent.pathNames.length - 1) {
|
3484
3532
|
parent.pathNames[pathLevel] = parent.renameText;
|
3485
3533
|
if (!parent.hasId) {
|
@@ -4617,7 +4665,13 @@ function onReSubmit(parent) {
|
|
4617
4665
|
parent.dialogObj.hide();
|
4618
4666
|
return;
|
4619
4667
|
}
|
4620
|
-
var newPath =
|
4668
|
+
var newPath = '';
|
4669
|
+
if (parent.activeModule === 'navigationpane') {
|
4670
|
+
newPath = getTargetPath(parent, parent.itemData[0]);
|
4671
|
+
}
|
4672
|
+
else {
|
4673
|
+
newPath = parent.path;
|
4674
|
+
}
|
4621
4675
|
parent.renamedId = getValue('id', parent.itemData[0]);
|
4622
4676
|
if (parent.isFile) {
|
4623
4677
|
var oldExtension = (oIndex === -1) ? '' : parent.currentItemText.substr(oIndex);
|
@@ -5548,31 +5602,33 @@ var LargeIconsView = /** @__PURE__ @class */ (function () {
|
|
5548
5602
|
* @hidden
|
5549
5603
|
*/
|
5550
5604
|
LargeIconsView.prototype.doSelection = function (target, e) {
|
5605
|
+
var ctrlKey = this.parent.isMac ? e.metaKey : e.ctrlKey;
|
5606
|
+
var isMacRightClick = this.parent.isMac && e.ctrlKey && e.shiftKey;
|
5551
5607
|
var item = closest(target, '.' + LIST_ITEM);
|
5552
5608
|
var cList = target.classList;
|
5553
5609
|
this.parent.isFile = false;
|
5554
5610
|
var action = 'select';
|
5555
|
-
if (e.which === 3 && !isNullOrUndefined(item) && item.classList.contains(ACTIVE)) {
|
5611
|
+
if ((e.which === 3 || isMacRightClick) && !isNullOrUndefined(item) && item.classList.contains(ACTIVE)) {
|
5556
5612
|
this.addActive(item);
|
5557
5613
|
this.updateType(item);
|
5558
5614
|
return;
|
5559
5615
|
}
|
5560
5616
|
else if (!isNullOrUndefined(item)) {
|
5561
5617
|
if (this.parent.allowMultiSelection && item.classList.contains(ACTIVE)
|
5562
|
-
&& (
|
5618
|
+
&& (ctrlKey || target.classList.contains(CHECK))) {
|
5563
5619
|
action = 'unselect';
|
5564
5620
|
}
|
5565
|
-
if (e.ctrlKey && e.shiftKey) {
|
5621
|
+
if (e.ctrlKey && e.shiftKey && !isMacRightClick) {
|
5566
5622
|
this.isSelectAllCalled = true;
|
5567
5623
|
}
|
5568
5624
|
var fileSelectionArgs = this.triggerSelection(action, item);
|
5569
5625
|
if (fileSelectionArgs.cancel !== true) {
|
5570
|
-
if ((!this.parent.allowMultiSelection || (!this.multiSelect && (e && !
|
5626
|
+
if ((!this.parent.allowMultiSelection || (!this.multiSelect && (e && !ctrlKey)))
|
5571
5627
|
&& !cList.contains(FRAME)) {
|
5572
5628
|
this.updateType(item);
|
5573
5629
|
this.clearSelect();
|
5574
5630
|
}
|
5575
|
-
if (this.parent.allowMultiSelection && e.shiftKey) {
|
5631
|
+
if (this.parent.allowMultiSelection && e.shiftKey && !isMacRightClick) {
|
5576
5632
|
if (!(e && e.ctrlKey)) {
|
5577
5633
|
this.clearSelect();
|
5578
5634
|
}
|
@@ -6929,7 +6985,7 @@ var ContextMenu = /** @__PURE__ @class */ (function () {
|
|
6929
6985
|
else if (closest(target, '#' + this.parent.element.id + TREE_ID)) {
|
6930
6986
|
uid = closest(target, 'li').getAttribute('data-uid');
|
6931
6987
|
if (!isNullOrUndefined(uid)) {
|
6932
|
-
this.
|
6988
|
+
this.navUid = uid;
|
6933
6989
|
}
|
6934
6990
|
treeFolder = true;
|
6935
6991
|
}
|
@@ -7065,8 +7121,9 @@ var ContextMenu = /** @__PURE__ @class */ (function () {
|
|
7065
7121
|
this.contextMenu.items = this.getItemData(this.parent.contextMenuSettings.folder.map(function (item) { return item.trim(); }));
|
7066
7122
|
this.contextMenu.dataBind();
|
7067
7123
|
if (isTree) {
|
7068
|
-
var selectedTreeNode = select('[data-uid="' + this.
|
7069
|
-
if (
|
7124
|
+
var selectedTreeNode = select('[data-uid="' + this.navUid + '"]', this.parent.navigationpaneModule.treeObj.element);
|
7125
|
+
if (!isNullOrUndefined(selectedTreeNode) &&
|
7126
|
+
this.parent.pathNames[this.parent.pathNames.length - 1] === selectedTreeNode.querySelector('.e-list-text').innerHTML && this.parent.activeModule === 'navigationpane') {
|
7070
7127
|
this.disabledItems.push('Open');
|
7071
7128
|
}
|
7072
7129
|
else {
|
@@ -7953,11 +8010,14 @@ var FileManager = /** @__PURE__ @class */ (function (_super) {
|
|
7953
8010
|
dropArea: select('#' + this.element.id + CONTENT_ID, this.element),
|
7954
8011
|
asyncSettings: {
|
7955
8012
|
saveUrl: uploadUrl,
|
7956
|
-
removeUrl: uploadUrl
|
8013
|
+
removeUrl: uploadUrl,
|
8014
|
+
chunkSize: this.uploadSettings.chunkSize,
|
8015
|
+
retryCount: 0
|
7957
8016
|
},
|
7958
8017
|
locale: this.locale,
|
7959
8018
|
enableRtl: this.enableRtl,
|
7960
8019
|
uploading: this.onUploading.bind(this),
|
8020
|
+
chunkUploading: this.onChunkUploading.bind(this),
|
7961
8021
|
removing: this.onRemoving.bind(this),
|
7962
8022
|
canceling: this.onCancel.bind(this),
|
7963
8023
|
clearing: this.onClearing.bind(this),
|
@@ -8019,19 +8079,34 @@ var FileManager = /** @__PURE__ @class */ (function (_super) {
|
|
8019
8079
|
this.trigger('popupClose', args);
|
8020
8080
|
};
|
8021
8081
|
/* istanbul ignore next */
|
8082
|
+
FileManager.prototype.onChunkUploading = function (args) {
|
8083
|
+
var action = 'save';
|
8084
|
+
if ((this.retryArgs.length !== 0)) {
|
8085
|
+
for (var i = 0; i < this.retryArgs.length; i++) {
|
8086
|
+
if (args.fileData.name === this.retryArgs[i].file.name) {
|
8087
|
+
action = this.retryArgs[i].action;
|
8088
|
+
}
|
8089
|
+
}
|
8090
|
+
}
|
8091
|
+
var data = JSON.stringify(getValue(this.pathId[this.pathId.length - 1], this.feParent));
|
8092
|
+
args.customFormData = [{ 'path': this.path }, { 'size': args.fileData.size }, { 'action': action }, { 'data': data }, { 'filename': args.fileData.name }];
|
8093
|
+
};
|
8094
|
+
/* istanbul ignore next */
|
8022
8095
|
FileManager.prototype.onUploading = function (args) {
|
8023
8096
|
var action = 'save';
|
8024
8097
|
if ((this.retryArgs.length !== 0)) {
|
8025
8098
|
for (var i = 0; i < this.retryArgs.length; i++) {
|
8026
8099
|
if (args.fileData.name === this.retryArgs[i].file.name) {
|
8027
8100
|
action = this.retryArgs[i].action;
|
8028
|
-
this.
|
8029
|
-
|
8101
|
+
if (this.uploadSettings.chunkSize === 0) {
|
8102
|
+
this.retryArgs.splice(i, 1);
|
8103
|
+
i = this.retryArgs.length;
|
8104
|
+
}
|
8030
8105
|
}
|
8031
8106
|
}
|
8032
8107
|
}
|
8033
8108
|
var data = JSON.stringify(getValue(this.pathId[this.pathId.length - 1], this.feParent));
|
8034
|
-
args.customFormData = [{ 'path': this.path }, { 'action': action }, { 'data': data }, { 'filename': args.fileData.name }];
|
8109
|
+
args.customFormData = [{ 'path': this.path }, { 'size': args.fileData.size }, { 'action': action }, { 'data': data }, { 'filename': args.fileData.name }];
|
8035
8110
|
var uploadUrl = this.ajaxSettings.uploadUrl ? this.ajaxSettings.uploadUrl : this.ajaxSettings.url;
|
8036
8111
|
var ajaxSettings = {
|
8037
8112
|
url: uploadUrl,
|
@@ -8098,8 +8173,22 @@ var FileManager = /** @__PURE__ @class */ (function (_super) {
|
|
8098
8173
|
this.uploadDialogObj.hide();
|
8099
8174
|
}
|
8100
8175
|
};
|
8176
|
+
FileManager.prototype.onChunkUploadComplete = function (files) {
|
8177
|
+
if ((this.retryArgs.length !== 0)) {
|
8178
|
+
for (var i = 0; i < this.retryArgs.length; i++) {
|
8179
|
+
var uploadFile = !isNullOrUndefined(files) ? getValue('file', files).name : '';
|
8180
|
+
if (uploadFile === this.retryArgs[i].file.name) {
|
8181
|
+
this.retryArgs.splice(i, 1);
|
8182
|
+
i = this.retryArgs.length;
|
8183
|
+
}
|
8184
|
+
}
|
8185
|
+
}
|
8186
|
+
};
|
8101
8187
|
/* istanbul ignore next */
|
8102
8188
|
FileManager.prototype.onUploadSuccess = function (files) {
|
8189
|
+
if (this.uploadSettings.chunkSize > 0) {
|
8190
|
+
this.onChunkUploadComplete(files);
|
8191
|
+
}
|
8103
8192
|
var args = { action: 'Upload', result: files };
|
8104
8193
|
this.trigger('success', args);
|
8105
8194
|
this.itemData = [getValue(this.pathId[this.pathId.length - 1], this.feParent)];
|
@@ -8111,6 +8200,9 @@ var FileManager = /** @__PURE__ @class */ (function (_super) {
|
|
8111
8200
|
};
|
8112
8201
|
/* istanbul ignore next */
|
8113
8202
|
FileManager.prototype.onUploadFailure = function (files) {
|
8203
|
+
if (this.uploadSettings.chunkSize > 0) {
|
8204
|
+
this.onChunkUploadComplete(files);
|
8205
|
+
}
|
8114
8206
|
var response = getValue('response', files);
|
8115
8207
|
var statusText = getValue('statusText', response);
|
8116
8208
|
if (statusText !== '') {
|
@@ -10435,6 +10527,15 @@ var NavigationPane = /** @__PURE__ @class */ (function () {
|
|
10435
10527
|
this.removeChildNodes(e.selectedNode);
|
10436
10528
|
};
|
10437
10529
|
NavigationPane.prototype.onDragEnd = function (args) {
|
10530
|
+
if (isFileSystemData(this.parent)) {
|
10531
|
+
this.moveNames = [];
|
10532
|
+
var obj = this.parent.dragData;
|
10533
|
+
for (var i = 0; i < obj.length; i++) {
|
10534
|
+
if (getValue('isFile', obj[i]) === false) {
|
10535
|
+
this.moveNames.push(getValue('_fm_id', obj[i]));
|
10536
|
+
}
|
10537
|
+
}
|
10538
|
+
}
|
10438
10539
|
var moveNames = [];
|
10439
10540
|
if (this.parent.isPasteError || this.parent.isSearchDrag) {
|
10440
10541
|
moveNames = this.getMoveNames(args.files, this.parent.isSearchDrag, this.parent.dragPath);
|
@@ -10540,11 +10641,6 @@ var NavigationPane = /** @__PURE__ @class */ (function () {
|
|
10540
10641
|
if (isFileSystemData(this.parent) && (this.parent.path === this.parent.dropPath || this.parent.targetModule === 'navigationpane')) {
|
10541
10642
|
return;
|
10542
10643
|
}
|
10543
|
-
if (this.parent.hasId) {
|
10544
|
-
this.parent.isDropEnd = !this.parent.isPasteError;
|
10545
|
-
readDropPath(this.parent);
|
10546
|
-
return;
|
10547
|
-
}
|
10548
10644
|
if ((this.parent.dropPath.indexOf(getDirectoryPath(this.parent, args)) === -1)) {
|
10549
10645
|
this.parent.isDropEnd = false;
|
10550
10646
|
readDropPath(this.parent);
|
@@ -10862,6 +10958,16 @@ var DetailsView = /** @__PURE__ @class */ (function () {
|
|
10862
10958
|
/* istanbul ignore next */
|
10863
10959
|
DetailsView.prototype.render = function (args) {
|
10864
10960
|
var _this = this;
|
10961
|
+
if (this.parent.enablePersistence) {
|
10962
|
+
var gridPersistenceValue = window.localStorage.getItem('grid' + this.parent.element.id + '_grid');
|
10963
|
+
if (!isNullOrUndefined(gridPersistenceValue)) {
|
10964
|
+
var model = JSON.parse(gridPersistenceValue);
|
10965
|
+
if (!isNullOrUndefined(model) && Object.keys(model).length > 0 && 'sortSettings' in model) {
|
10966
|
+
delete model.sortSettings;
|
10967
|
+
window.localStorage.setItem('grid' + this.parent.element.id + '_grid', JSON.stringify(model));
|
10968
|
+
}
|
10969
|
+
}
|
10970
|
+
}
|
10865
10971
|
showSpinner(this.parent.element);
|
10866
10972
|
if (this.parent.view === 'Details') {
|
10867
10973
|
removeClass([this.parent.element], MULTI_SELECT);
|
@@ -12734,5 +12840,5 @@ var DetailsView = /** @__PURE__ @class */ (function () {
|
|
12734
12840
|
return DetailsView;
|
12735
12841
|
}());
|
12736
12842
|
|
12737
|
-
export { ACTIVE, ALT_DIALOG_ID, AjaxSettings, BLUR, BREADCRUMBBAR_ID, BREADCRUMBS, BreadCrumbBar, CB_WRAP, CHECK, CHECK_SELECT, CLONE, COLLAPSED, CONTENT_ID, CONTEXT_MENU_ID, CONTROL, Column, ContextMenu, ContextMenuSettings, DETAILS_LABEL, DIALOG_ID, DISPLAY_NONE, DROP_FILE, DROP_FOLDER, Delete, DetailsView, DetailsViewSettings, Download, EMPTY, EMPTY_CONTENT, EMPTY_INNER_CONTENT, ERROR_CONTENT, EXTN_DIALOG_ID, FILTER, FOCUS, FOCUSED, FOLDER, FRAME, FULLROW, FileManager, GRID_CONTENT, GRID_HEADER, GRID_ID, GRID_VIEW, GetDetails, HEADER_CHECK, HOVER, ICONS, ICON_BREADCRUMB, ICON_CLEAR, ICON_COLLAPSIBLE, ICON_COPY, ICON_CUT, ICON_DELETE, ICON_DETAILS, ICON_DOWNLOAD, ICON_DROP_IN, ICON_DROP_OUT, ICON_GRID, ICON_IMAGE, ICON_LARGE, ICON_MUSIC, ICON_NEWFOLDER, ICON_NO_DROP, ICON_OPEN, ICON_OPTIONS, ICON_PASTE, ICON_REFRESH, ICON_RENAME, ICON_SELECTALL, ICON_SHORTBY, ICON_UPLOAD, ICON_VIDEO, ICON_VIEW, IMG_DIALOG_ID, LARGEICON_ID, LARGE_EMPTY_FOLDER, LARGE_EMPTY_FOLDER_TWO, LARGE_ICON, LARGE_ICONS, LARGE_ICON_FOLDER, LAYOUT, LAYOUT_CONTENT, LAYOUT_ID, LIST_ITEM, LIST_PARENT, LIST_TEXT, LargeIconsView, MENU_ICON, MENU_ITEM, MOBILE, MOB_POPUP, MULTI_SELECT, NAVIGATION, NAVIGATION_ID, NavigationPane, NavigationPaneSettings, OVERLAY, RETRY_DIALOG_ID, RETRY_ID, ROOT, ROOT_POPUP, ROW, ROWCELL, RTL, SEARCH_ID, SELECTED_ITEMS, SORTBY_ID, SPLITTER_ID, SPLIT_BAR, STATUS, SUBMENU_ICON, Search, SearchSettings, TB_ITEM, TB_OPTION_DOT, TB_OPTION_TICK, TEMPLATE_CELL, TEXT_CONTENT, TOOLBAR_ID, TREE_ID, TREE_VIEW, Toolbar, ToolbarItem, ToolbarSettings, UPLOAD_DIALOG_ID, UPLOAD_ID, UploadSettings, VALUE, VIEW_ID, Virtualization, actionFailure, activeElement, addBlur, afterRequest, beforeDelete, beforeDownload, beforeRequest, clearAllInit, clearPathInit, closePopup, columnArray, copyFiles, createDeniedDialog, createDialog, createEmptyElement, createEnd, createExtDialog, createFolder, createImageDialog, createNewFolder, createVirtualDragElement, cutCopyInit, cutEnd, cutFiles, defaultToolbarItems, deleteEnd, deleteInit, destroy, detailsInit, doDeleteFiles, doDownload, doDownloadFiles, doPasteUpdate, doRename, download, downloadInit, dragCancel, dragEnd, dragHelper, dragStartHandler, dragStopHandler, dragging, draggingHandler, dropHandler, dropInit, dropPath, fileItems, fileType, filter, filterEnd, finalizeEnd, folderItems, generatePath, getAccessClass, getAccessDetails, getAllChildItems, getCssClass, getDirectories, getDirectoryPath, getDuplicateData, getFullPath, getImageUrl, getItemName, getLocaleText, getModule, getName, getObject, getParentPath, getParents, getPath, getPathId, getPathNames, getPathObject, getSortField, getSortedData, getTargetModule, hasContentAccess, hasDownloadAccess, hasEditAccess, hasReadAccess, hasUploadAccess, hideLayout, hidePaste, initialEnd, isFile, isFileSystemData, layoutChange, layoutItems, layoutRefresh, menuItemData, methodCall, modelChanged, nodeExpand, objectToString, openAction, openEnd, openInit, openSearchFolder, paste, pasteEnd, pasteHandler, pasteInit, pathChanged, pathColumn, pathDrag, permissionCopy, permissionDownload, permissionEdit, permissionEditContents, permissionRead, permissionUpload, read, readDropPath, refresh, refreshEnd, removeActive, removeBlur, removeDropTarget, removeItemClass, rename, renameEnd, renameEndParent, renameInit, resizeEnd, scrollHandler, search, searchTextChange, searchWordHandler, selectAllInit, selectedData, selectionChanged, setDateObject, setNextPath, setNodeId, showPaste, skipUpload, sortByChange, sortColumn, sortComparer, sortbyClickHandler, splitterResize, treeSelect, updateLayout, updatePath, updateRenamingData, updateSelectionData, updateTreeSelection, upload, uploadItem, validateSubFolder };
|
12843
|
+
export { ACTIVE, ALT_DIALOG_ID, AjaxSettings, BLUR, BREADCRUMBBAR_ID, BREADCRUMBS, BreadCrumbBar, CB_WRAP, CHECK, CHECK_SELECT, CLONE, COLLAPSED, CONTENT_ID, CONTEXT_MENU_ID, CONTROL, Column, ContextMenu, ContextMenuSettings, DETAILS_LABEL, DIALOG_ID, DISPLAY_NONE, DROP_FILE, DROP_FOLDER, Delete, DetailsView, DetailsViewSettings, Download, EMPTY, EMPTY_CONTENT, EMPTY_INNER_CONTENT, ERROR_CONTENT, EXTN_DIALOG_ID, FILTER, FOCUS, FOCUSED, FOLDER, FRAME, FULLROW, FileManager, GRID_CONTENT, GRID_HEADER, GRID_ID, GRID_VIEW, GetDetails, HEADER_CHECK, HOVER, ICONS, ICON_BREADCRUMB, ICON_CLEAR, ICON_COLLAPSIBLE, ICON_COPY, ICON_CUT, ICON_DELETE, ICON_DETAILS, ICON_DOWNLOAD, ICON_DROP_IN, ICON_DROP_OUT, ICON_GRID, ICON_IMAGE, ICON_LARGE, ICON_MUSIC, ICON_NEWFOLDER, ICON_NO_DROP, ICON_OPEN, ICON_OPTIONS, ICON_PASTE, ICON_REFRESH, ICON_RENAME, ICON_SELECTALL, ICON_SHORTBY, ICON_UPLOAD, ICON_VIDEO, ICON_VIEW, IMG_DIALOG_ID, LARGEICON_ID, LARGE_EMPTY_FOLDER, LARGE_EMPTY_FOLDER_TWO, LARGE_ICON, LARGE_ICONS, LARGE_ICON_FOLDER, LAYOUT, LAYOUT_CONTENT, LAYOUT_ID, LIST_ITEM, LIST_PARENT, LIST_TEXT, LargeIconsView, MENU_ICON, MENU_ITEM, MOBILE, MOB_POPUP, MULTI_SELECT, NAVIGATION, NAVIGATION_ID, NavigationPane, NavigationPaneSettings, OVERLAY, RETRY_DIALOG_ID, RETRY_ID, ROOT, ROOT_POPUP, ROW, ROWCELL, RTL, SEARCH_ID, SELECTED_ITEMS, SORTBY_ID, SPLITTER_ID, SPLIT_BAR, STATUS, SUBMENU_ICON, Search, SearchSettings, TB_ITEM, TB_OPTION_DOT, TB_OPTION_TICK, TEMPLATE_CELL, TEXT_CONTENT, TOOLBAR_ID, TREE_ID, TREE_VIEW, Toolbar, ToolbarItem, ToolbarSettings, UPLOAD_DIALOG_ID, UPLOAD_ID, UploadSettings, VALUE, VIEW_ID, Virtualization, actionFailure, activeElement, addBlur, afterRequest, beforeDelete, beforeDownload, beforeRequest, clearAllInit, clearPathInit, closePopup, columnArray, copyFiles, createDeniedDialog, createDialog, createEmptyElement, createEnd, createExtDialog, createFolder, createImageDialog, createNewFolder, createVirtualDragElement, cutCopyInit, cutEnd, cutFiles, defaultToolbarItems, deleteEnd, deleteInit, destroy, detailsInit, doDeleteFiles, doDownload, doDownloadFiles, doPasteUpdate, doRename, download, downloadInit, dragCancel, dragEnd, dragHelper, dragStartHandler, dragStopHandler, dragging, draggingHandler, dropHandler, dropInit, dropPath, fileItems, fileType, filter, filterEnd, finalizeEnd, folderItems, generatePath, getAccessClass, getAccessDetails, getAllChildItems, getCssClass, getDirectories, getDirectoryPath, getDuplicateData, getFullPath, getImageUrl, getItemName, getLocaleText, getModule, getName, getObject, getParentPath, getParents, getPath, getPathId, getPathNames, getPathObject, getSortField, getSortedData, getTargetModule, getTargetPath, hasContentAccess, hasDownloadAccess, hasEditAccess, hasReadAccess, hasUploadAccess, hideLayout, hidePaste, initialEnd, isFile, isFileSystemData, layoutChange, layoutItems, layoutRefresh, menuItemData, methodCall, modelChanged, nodeExpand, objectToString, openAction, openEnd, openInit, openSearchFolder, paste, pasteEnd, pasteHandler, pasteInit, pathChanged, pathColumn, pathDrag, permissionCopy, permissionDownload, permissionEdit, permissionEditContents, permissionRead, permissionUpload, read, readDropPath, refresh, refreshEnd, removeActive, removeBlur, removeDropTarget, removeItemClass, rename, renameEnd, renameEndParent, renameInit, resizeEnd, scrollHandler, search, searchTextChange, searchWordHandler, selectAllInit, selectedData, selectionChanged, setDateObject, setNextPath, setNodeId, showPaste, skipUpload, sortByChange, sortColumn, sortComparer, sortbyClickHandler, splitterResize, treeSelect, updateLayout, updatePath, updateRenamingData, updateSelectionData, updateTreeSelection, upload, uploadItem, validateSubFolder };
|
12738
12844
|
//# sourceMappingURL=ej2-filemanager.es5.js.map
|