@syncfusion/ej2-filemanager 29.2.10 → 30.1.38

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.
Files changed (92) hide show
  1. package/.eslintrc.json +2 -0
  2. package/dist/ej2-filemanager.min.js +2 -2
  3. package/dist/ej2-filemanager.umd.min.js +2 -2
  4. package/dist/ej2-filemanager.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-filemanager.es2015.js +186 -21
  6. package/dist/es6/ej2-filemanager.es2015.js.map +1 -1
  7. package/dist/es6/ej2-filemanager.es5.js +186 -20
  8. package/dist/es6/ej2-filemanager.es5.js.map +1 -1
  9. package/dist/global/ej2-filemanager.min.js +2 -2
  10. package/dist/global/ej2-filemanager.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +11 -11
  13. package/src/file-manager/base/interface.d.ts +10 -0
  14. package/src/file-manager/common/operations.d.ts +18 -1
  15. package/src/file-manager/common/operations.js +59 -0
  16. package/src/file-manager/common/utility.d.ts +3 -3
  17. package/src/file-manager/common/utility.js +23 -6
  18. package/src/file-manager/layout/details-view.js +4 -3
  19. package/src/file-manager/layout/large-icons-view.d.ts +3 -0
  20. package/src/file-manager/layout/large-icons-view.js +67 -9
  21. package/src/file-manager/layout/navigation-pane.js +3 -0
  22. package/src/file-manager/pop-up/dialog.d.ts +3 -3
  23. package/src/file-manager/pop-up/dialog.js +34 -6
  24. package/styles/bds-lite.css +50 -1
  25. package/styles/bds.css +50 -1
  26. package/styles/bootstrap-dark-lite.css +50 -0
  27. package/styles/bootstrap-dark.css +50 -0
  28. package/styles/bootstrap-lite.css +50 -0
  29. package/styles/bootstrap.css +50 -0
  30. package/styles/bootstrap4-lite.css +50 -0
  31. package/styles/bootstrap4.css +50 -0
  32. package/styles/bootstrap5-dark-lite.css +50 -1
  33. package/styles/bootstrap5-dark.css +50 -1
  34. package/styles/bootstrap5-lite.css +50 -1
  35. package/styles/bootstrap5.3-lite.css +50 -0
  36. package/styles/bootstrap5.3.css +50 -0
  37. package/styles/bootstrap5.css +50 -1
  38. package/styles/fabric-dark-lite.css +50 -0
  39. package/styles/fabric-dark.css +50 -0
  40. package/styles/fabric-lite.css +50 -0
  41. package/styles/fabric.css +50 -0
  42. package/styles/file-manager/_bds-definition.scss +1 -0
  43. package/styles/file-manager/_bootstrap5-definition.scss +1 -0
  44. package/styles/file-manager/_layout.scss +46 -4
  45. package/styles/file-manager/_material3-definition.scss +2 -2
  46. package/styles/file-manager/_tailwind-definition.scss +1 -0
  47. package/styles/file-manager/_tailwind3-definition.scss +1 -0
  48. package/styles/file-manager/bds.css +50 -1
  49. package/styles/file-manager/bootstrap-dark.css +50 -0
  50. package/styles/file-manager/bootstrap.css +50 -0
  51. package/styles/file-manager/bootstrap4.css +50 -0
  52. package/styles/file-manager/bootstrap5-dark.css +50 -1
  53. package/styles/file-manager/bootstrap5.3.css +50 -0
  54. package/styles/file-manager/bootstrap5.css +50 -1
  55. package/styles/file-manager/fabric-dark.css +50 -0
  56. package/styles/file-manager/fabric.css +50 -0
  57. package/styles/file-manager/fluent-dark.css +50 -0
  58. package/styles/file-manager/fluent.css +50 -0
  59. package/styles/file-manager/fluent2.css +50 -0
  60. package/styles/file-manager/highcontrast-light.css +50 -0
  61. package/styles/file-manager/highcontrast.css +50 -0
  62. package/styles/file-manager/material-dark.css +50 -0
  63. package/styles/file-manager/material.css +50 -0
  64. package/styles/file-manager/material3-dark.css +52 -2
  65. package/styles/file-manager/material3.css +52 -2
  66. package/styles/file-manager/tailwind-dark.css +50 -1
  67. package/styles/file-manager/tailwind.css +50 -1
  68. package/styles/file-manager/tailwind3.css +50 -0
  69. package/styles/fluent-dark-lite.css +50 -0
  70. package/styles/fluent-dark.css +50 -0
  71. package/styles/fluent-lite.css +50 -0
  72. package/styles/fluent.css +50 -0
  73. package/styles/fluent2-lite.css +50 -0
  74. package/styles/fluent2.css +50 -0
  75. package/styles/highcontrast-light-lite.css +50 -0
  76. package/styles/highcontrast-light.css +50 -0
  77. package/styles/highcontrast-lite.css +50 -0
  78. package/styles/highcontrast.css +50 -0
  79. package/styles/material-dark-lite.css +50 -0
  80. package/styles/material-dark.css +50 -0
  81. package/styles/material-lite.css +50 -0
  82. package/styles/material.css +50 -0
  83. package/styles/material3-dark-lite.css +50 -0
  84. package/styles/material3-dark.css +52 -2
  85. package/styles/material3-lite.css +50 -0
  86. package/styles/material3.css +52 -2
  87. package/styles/tailwind-dark-lite.css +50 -1
  88. package/styles/tailwind-dark.css +50 -1
  89. package/styles/tailwind-lite.css +50 -1
  90. package/styles/tailwind.css +50 -1
  91. package/styles/tailwind3-lite.css +50 -0
  92. package/styles/tailwind3.css +50 -0
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * filename: index.d.ts
3
- * version : 29.2.10
3
+ * version : 30.1.38
4
4
  * Copyright Syncfusion Inc. 2001 - 2024. All rights reserved.
5
5
  * Use of this code is subject to the terms of our license.
6
6
  * A copy of the current license can be obtained at any time by e-mailing
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@syncfusion/ej2-filemanager",
3
- "version": "29.2.10",
3
+ "version": "30.1.38",
4
4
  "description": "Essential JS 2 FileManager Component",
5
5
  "author": "Syncfusion Inc.",
6
6
  "license": "SEE LICENSE IN license",
@@ -8,16 +8,16 @@
8
8
  "module": "./index.js",
9
9
  "es2015": "./dist/es6/ej2-filemanager.es5.js",
10
10
  "dependencies": {
11
- "@syncfusion/ej2-base": "~29.2.4",
12
- "@syncfusion/ej2-buttons": "~29.2.5",
13
- "@syncfusion/ej2-data": "~29.2.4",
14
- "@syncfusion/ej2-grids": "~29.2.10",
15
- "@syncfusion/ej2-inputs": "~29.2.5",
16
- "@syncfusion/ej2-layouts": "~29.2.4",
17
- "@syncfusion/ej2-lists": "~29.2.4",
18
- "@syncfusion/ej2-navigations": "~29.2.8",
19
- "@syncfusion/ej2-popups": "~29.2.8",
20
- "@syncfusion/ej2-splitbuttons": "~29.2.4"
11
+ "@syncfusion/ej2-base": "~30.1.38",
12
+ "@syncfusion/ej2-buttons": "~30.1.37",
13
+ "@syncfusion/ej2-data": "~30.1.38",
14
+ "@syncfusion/ej2-grids": "~30.1.38",
15
+ "@syncfusion/ej2-inputs": "~30.1.38",
16
+ "@syncfusion/ej2-layouts": "~30.1.37",
17
+ "@syncfusion/ej2-lists": "~30.1.37",
18
+ "@syncfusion/ej2-navigations": "~30.1.37",
19
+ "@syncfusion/ej2-popups": "~30.1.37",
20
+ "@syncfusion/ej2-splitbuttons": "~30.1.37"
21
21
  },
22
22
  "devDependencies": {},
23
23
  "keywords": [
@@ -328,6 +328,16 @@ export interface BeforeImageLoadEventArgs {
328
328
  * Specifies the URL along with custom attributes to be sent to server.
329
329
  */
330
330
  imageUrl?: string;
331
+ /**
332
+ * Returns the AJAX configuration details used when the `ajaxSettings` URL is specified.
333
+ */
334
+ ajaxSettings?: Object;
335
+ /**
336
+ * Specifies whether the image source should be represented as a URL or a Blob object.
337
+ * Set this property to <c>false</c> to render the image source as a Blob (e.g., via `URL.createObjectURL(file)`), which is useful in scenarios.
338
+ * where the File Manager must authenticate requests to access the images.
339
+ */
340
+ useImageAsUrl?: boolean;
331
341
  }
332
342
  /**
333
343
  * Interface for folder create event arguments.
@@ -1,4 +1,4 @@
1
- import { IFileManager } from '../base/interface';
1
+ import { IFileManager, ReadArgs } from '../base/interface';
2
2
  /**
3
3
  * Function to read the content from given path in File Manager.
4
4
  *
@@ -103,3 +103,20 @@ export declare function Search(parent: IFileManager, event: string, path: string
103
103
  * @private
104
104
  */
105
105
  export declare function Download(parent: IFileManager, path: string, items: string[]): void;
106
+ /**
107
+ * Function for trigger Fetch success in File Manager.
108
+ *
109
+ * @param {IFileManager} parent - specifies the parent element.
110
+ * @param {Object} ajaxSettings - specifies the ajax settings.
111
+ * @returns {void}
112
+ */
113
+ export declare function triggerFetchSuccess(parent: IFileManager, ajaxSettings: Object): void;
114
+ /**
115
+ * Function for trigger Fetch failure in File Manager.
116
+ *
117
+ * @param {IFileManager} parent - specifies the parent element.
118
+ * @param {Object} ajaxSettings - specifies the ajax settings.
119
+ * @param {ReadArgs} result - specifies the result.
120
+ * @returns {void}
121
+ */
122
+ export declare function triggerFetchFailure(parent: IFileManager, ajaxSettings: Object, result: ReadArgs): void;
@@ -226,6 +226,11 @@ function createNewItem(data, target, itemName, isCopy) {
226
226
  size: isCopy ? data.size : 0,
227
227
  type: isCopy ? data.type : ''
228
228
  });
229
+ if (!isNOU(target.filterId)) {
230
+ Object.assign(newItem, {
231
+ filterId: target.filterId + target.id + '/'
232
+ });
233
+ }
229
234
  return newItem;
230
235
  }
231
236
  /**
@@ -467,6 +472,12 @@ function triggerMoveOrCopyOperation(parent, data, eventArgs) {
467
472
  }
468
473
  fileData.parentId = target_1.id;
469
474
  fileData.filterPath = target_1.id === 0 ? '\\' : target_1.filterPath + target_1.name + '\\';
475
+ if (!isNOU(target_1.filterId)) {
476
+ fileData.filterId = target_1.filterId + target_1.id + '/';
477
+ }
478
+ if (!currItem.isFile) {
479
+ updateMovedItemChildren(parent, fileData);
480
+ }
470
481
  }
471
482
  else {
472
483
  file_1.push(currItem.name);
@@ -786,6 +797,26 @@ function copyFolderItems(parent, data, target, itemName) {
786
797
  copyFolderItems(parent, copiedItems[i], newObject, null);
787
798
  }
788
799
  }
800
+ /**
801
+ * Function to move operation.
802
+ *
803
+ * @param {IFileManager} parent - specifies the parent element.
804
+ * @param {Object} itemData - specifies the data.
805
+ * @returns {void}
806
+ * @private
807
+ */
808
+ function updateMovedItemChildren(parent, itemData) {
809
+ var childItems = filterByParent(parent, itemData.id);
810
+ childItems.forEach(function (childItem) {
811
+ childItem.filterPath = itemData.filterPath + itemData.name + '\\';
812
+ if (!isNOU(itemData.filterId)) {
813
+ childItem.filterId = itemData.filterId + itemData.id + '/';
814
+ }
815
+ if (!childItem.isFile) {
816
+ updateMovedItemChildren(parent, childItem);
817
+ }
818
+ });
819
+ }
789
820
  /**
790
821
  * Function for trigger Ajax failure in File Manager.
791
822
  *
@@ -1300,3 +1331,31 @@ function handleCatchError(parent, error, action) {
1300
1331
  };
1301
1332
  onFailure(parent, errorResult, action);
1302
1333
  }
1334
+ /**
1335
+ * Function for trigger Fetch success in File Manager.
1336
+ *
1337
+ * @param {IFileManager} parent - specifies the parent element.
1338
+ * @param {Object} ajaxSettings - specifies the ajax settings.
1339
+ * @returns {void}
1340
+ */
1341
+ export function triggerFetchSuccess(parent, ajaxSettings) {
1342
+ parent.notify(events.afterRequest, { action: 'success' });
1343
+ if (ajaxSettings && typeof getValue('onSuccess', ajaxSettings) === 'function') {
1344
+ getValue('onSuccess', ajaxSettings)();
1345
+ }
1346
+ }
1347
+ /**
1348
+ * Function for trigger Fetch failure in File Manager.
1349
+ *
1350
+ * @param {IFileManager} parent - specifies the parent element.
1351
+ * @param {Object} ajaxSettings - specifies the ajax settings.
1352
+ * @param {ReadArgs} result - specifies the result.
1353
+ * @returns {void}
1354
+ */
1355
+ export function triggerFetchFailure(parent, ajaxSettings, result) {
1356
+ parent.notify(events.afterRequest, { action: 'failure' });
1357
+ createDialog(parent, 'Error', result);
1358
+ if (typeof getValue('onFailure', ajaxSettings) === 'function') {
1359
+ getValue('onFailure', ajaxSettings)();
1360
+ }
1361
+ }
@@ -1,4 +1,4 @@
1
- import { IFileManager, ReadArgs, SearchArgs } from '../base/interface';
1
+ import { IFileManager, ReadArgs, SearchArgs, BeforeImageLoadEventArgs } from '../base/interface';
2
2
  import { Draggable } from '@syncfusion/ej2-base';
3
3
  import { DragEventArgs } from '@syncfusion/ej2-base';
4
4
  import { MenuEventArgs } from '@syncfusion/ej2-navigations';
@@ -202,10 +202,10 @@ export declare function fileType(file: Object): string;
202
202
  *
203
203
  * @param {IFileManager} parent - specifies the parent element.
204
204
  * @param {Object} item - specifies the item.
205
- * @returns {string} - returns the image url.
205
+ * @returns {BeforeImageLoadEventArgs} - returns the eventargs.
206
206
  * @private
207
207
  */
208
- export declare function getImageUrl(parent: IFileManager, item: Object): string;
208
+ export declare function getImageUrl(parent: IFileManager, item: Object): BeforeImageLoadEventArgs;
209
209
  /**
210
210
  * Gets the full path
211
211
  *
@@ -518,7 +518,7 @@ export function fileType(file) {
518
518
  *
519
519
  * @param {IFileManager} parent - specifies the parent element.
520
520
  * @param {Object} item - specifies the item.
521
- * @returns {string} - returns the image url.
521
+ * @returns {BeforeImageLoadEventArgs} - returns the eventargs.
522
522
  * @private
523
523
  */
524
524
  export function getImageUrl(parent, item) {
@@ -526,10 +526,11 @@ export function getImageUrl(parent, item) {
526
526
  if (isFileSystemData(parent)) {
527
527
  var eventArgs_1 = {
528
528
  fileDetails: [item],
529
- imageUrl: imgUrl
529
+ imageUrl: imgUrl,
530
+ useImageAsUrl: true
530
531
  };
531
532
  parent.trigger('beforeImageLoad', eventArgs_1);
532
- return eventArgs_1.imageUrl;
533
+ return eventArgs_1;
533
534
  }
534
535
  var baseUrl = parent.ajaxSettings.getImageUrl ? parent.ajaxSettings.getImageUrl : parent.ajaxSettings.url;
535
536
  var pathUrl = (baseUrl.indexOf('?') !== -1) ? '&path=' : '?path=';
@@ -546,12 +547,25 @@ export function getImageUrl(parent, item) {
546
547
  imgUrl = baseUrl + pathUrl + parent.path + fileName;
547
548
  }
548
549
  imgUrl = imgUrl + '&time=' + (new Date().getTime()).toString();
550
+ var data = { 'action': 'getImage', 'path': parent.path + fileName, 'id': getValue('id', item) };
551
+ var ajaxSettings = {
552
+ url: baseUrl,
553
+ type: 'POST',
554
+ contentType: 'application/json',
555
+ responseType: 'blob',
556
+ data: JSON.stringify(data),
557
+ onSuccess: null,
558
+ onFailure: null,
559
+ beforeSend: null
560
+ };
549
561
  var eventArgs = {
550
562
  fileDetails: [item],
551
- imageUrl: imgUrl
563
+ imageUrl: imgUrl,
564
+ useImageAsUrl: true,
565
+ ajaxSettings: ajaxSettings
552
566
  };
553
567
  parent.trigger('beforeImageLoad', eventArgs);
554
- return eventArgs.imageUrl;
568
+ return eventArgs;
555
569
  }
556
570
  /* istanbul ignore next */
557
571
  /**
@@ -673,7 +687,7 @@ export function createEmptyElement(parent, element, args) {
673
687
  }
674
688
  else {
675
689
  element.querySelector('.' + CLS.EMPTY_CONTENT).innerHTML = getLocaleText(parent, 'Folder-Empty');
676
- element.querySelector('.' + CLS.EMPTY_INNER_CONTENT).innerHTML = getLocaleText(parent, 'File-Upload');
690
+ element.querySelector('.' + CLS.EMPTY_INNER_CONTENT).innerHTML = parent.uploadObj.dropArea == null ? getLocaleText(parent, '') : getLocaleText(parent, 'File-Upload');
677
691
  }
678
692
  }
679
693
  var eDiv = select('.' + CLS.EMPTY, element);
@@ -1022,6 +1036,9 @@ export function getParentPath(oldPath) {
1022
1036
  export function getDirectoryPath(parent, args) {
1023
1037
  var filePath = getValue(parent.hasId ? 'id' : 'name', args.cwd) + '/';
1024
1038
  var fPath = getValue(parent.hasId && !isNullOrUndefined(parent.ajaxSettings.url) ? 'filterId' : 'filterPath', args.cwd);
1039
+ if (!isNOU(fPath) && isFileSystemData(parent) && fPath !== '' && fPath !== '\\') {
1040
+ fPath = '\\' + args.cwd.parentId + '\\';
1041
+ }
1025
1042
  if (!isNOU(fPath)) {
1026
1043
  if (fPath === '') {
1027
1044
  return '/';
@@ -435,7 +435,8 @@ var DetailsView = /** @class */ (function () {
435
435
  if (this.parent.layoutSelectedItems.length) {
436
436
  this.selectRecords(this.parent.layoutSelectedItems);
437
437
  }
438
- if (this.parent.renamedItem) {
438
+ if (this.parent.renamedItem && this.parent.selectedItems.length === 0) {
439
+ this.gridObj.clearSelection();
439
440
  this.addSelection(this.parent.renamedItem);
440
441
  this.parent.renamedItem = null;
441
442
  }
@@ -685,8 +686,8 @@ var DetailsView = /** @class */ (function () {
685
686
  if (getValue('isFile', data)) {
686
687
  var icon = fileType(data);
687
688
  if (icon === CLS.ICON_IMAGE) {
688
- var imgUrl = getImageUrl(_this.parent, data);
689
- createImageDialog(_this.parent, name_2, imgUrl);
689
+ var imageData = getImageUrl(_this.parent, data);
690
+ createImageDialog(_this.parent, name_2, imageData);
690
691
  }
691
692
  }
692
693
  else {
@@ -29,6 +29,8 @@ export declare class LargeIconsView {
29
29
  private isPasteOperation;
30
30
  private dragObj;
31
31
  private isInteracted;
32
+ private imageEventArgsMap;
33
+ private imageUrlCache;
32
34
  /**
33
35
  * Constructor for the LargeIcons module.
34
36
  *
@@ -37,6 +39,7 @@ export declare class LargeIconsView {
37
39
  */
38
40
  constructor(parent?: IFileManager);
39
41
  private render;
42
+ private loadImages;
40
43
  private comparer;
41
44
  private preventImgDrag;
42
45
  private createDragObj;
@@ -1,5 +1,5 @@
1
1
  import { ListBase } from '@syncfusion/ej2-lists';
2
- import { createElement, select, selectAll, EventHandler, KeyboardEvents, closest, Draggable } from '@syncfusion/ej2-base';
2
+ import { createElement, select, selectAll, EventHandler, KeyboardEvents, closest, Draggable, Fetch } from '@syncfusion/ej2-base';
3
3
  import { isNullOrUndefined as isNOU, addClass, removeClass, Touch, isVisible } from '@syncfusion/ej2-base';
4
4
  import { getValue, setValue, remove } from '@syncfusion/ej2-base';
5
5
  import { DataManager, Query, DataUtil } from '@syncfusion/ej2-data';
@@ -7,12 +7,12 @@ import { hideSpinner, showSpinner } from '@syncfusion/ej2-popups';
7
7
  import * as events from '../base/constant';
8
8
  import * as CLS from '../base/classes';
9
9
  import { createCheckBox } from '@syncfusion/ej2-buttons';
10
- import { read, GetDetails, Delete } from '../common/operations';
10
+ import { read, GetDetails, Delete, triggerFetchFailure, triggerFetchSuccess } from '../common/operations';
11
11
  import { doRename, getAccessClass, getPathObject, getFullPath, getDirectoryPath, rename, doDownload, getItemName } from '../common/index';
12
12
  import { removeBlur, cutFiles, copyFiles, addBlur, openSearchFolder, removeActive, pasteHandler } from '../common/index';
13
13
  import { createVirtualDragElement, dragStopHandler, dragStartHandler, draggingHandler, getModule } from '../common/index';
14
14
  import { updateRenamingData, doDeleteFiles, doDownloadFiles } from '../common/index';
15
- import { openAction, fileType, refresh, getImageUrl, getSortedData, createDeniedDialog, updateLayout } from '../common/utility';
15
+ import { openAction, fileType, refresh, getImageUrl, getSortedData, createDeniedDialog, updateLayout, getLocaleText } from '../common/utility';
16
16
  import { createEmptyElement, hasReadAccess, hasEditAccess } from '../common/utility';
17
17
  import { createDialog, createImageDialog } from '../pop-up/dialog';
18
18
  /**
@@ -34,6 +34,8 @@ var LargeIconsView = /** @class */ (function () {
34
34
  this.isSelectAllCalled = false;
35
35
  this.isPasteOperation = false;
36
36
  this.isInteracted = true;
37
+ this.imageEventArgsMap = new Map();
38
+ this.imageUrlCache = new Map();
37
39
  this.parent = parent;
38
40
  this.element = select('#' + this.parent.element.id + CLS.LARGEICON_ID, this.parent.element);
39
41
  addClass([this.element], CLS.LARGE_ICONS);
@@ -105,7 +107,7 @@ var LargeIconsView = /** @class */ (function () {
105
107
  groupItemRole: 'group', wrapperRole: ''
106
108
  },
107
109
  showIcon: true,
108
- fields: { text: 'name', iconCss: '_fm_icon', imageUrl: '_fm_imageUrl', htmlAttributes: '_fm_htmlAttr' },
110
+ fields: { text: 'name', iconCss: '_fm_icon', imageUrl: '_fm_imageUrl', imageAttributes: '_fm_imageAttr', htmlAttributes: '_fm_htmlAttr' },
109
111
  sortOrder: this.parent.sortOrder,
110
112
  itemCreated: this.onItemCreated.bind(this),
111
113
  enableHtmlSanitizer: this.parent.enableHtmlSanitizer
@@ -125,6 +127,9 @@ var LargeIconsView = /** @class */ (function () {
125
127
  this.listElements = ListBase.createListFromJson(createElement, this.items, this.listObj);
126
128
  this.itemList = Array.prototype.slice.call(selectAll('.' + CLS.LIST_ITEM, this.listElements));
127
129
  this.element.appendChild(this.listElements);
130
+ if (this.imageEventArgsMap.size > 0) {
131
+ this.loadImages();
132
+ }
128
133
  this.listElements.setAttribute('aria-label', 'listbox');
129
134
  this.preventImgDrag();
130
135
  this.createDragObj();
@@ -172,6 +177,51 @@ var LargeIconsView = /** @class */ (function () {
172
177
  }
173
178
  }
174
179
  };
180
+ LargeIconsView.prototype.loadImages = function () {
181
+ var _this = this;
182
+ var imageEle = this.parent.element.querySelectorAll('.e-list-img');
183
+ imageEle.forEach(function (imgElement) {
184
+ var imageKey = imgElement.getAttribute('data-image-key');
185
+ if (!imageKey) {
186
+ return;
187
+ }
188
+ if (_this.imageUrlCache.has(imageKey)) {
189
+ imgElement.setAttribute('src', _this.imageUrlCache.get(imageKey));
190
+ imgElement.classList.remove('image-blur');
191
+ return;
192
+ }
193
+ var imageDetails = _this.imageEventArgsMap.get(imageKey);
194
+ if (!imageDetails) {
195
+ return;
196
+ }
197
+ var fetch = new Fetch({
198
+ url: getValue('url', imageDetails.ajaxSettings),
199
+ type: getValue('type', imageDetails.ajaxSettings),
200
+ contentType: getValue('contentType', imageDetails.ajaxSettings),
201
+ responseType: getValue('responseType', imageDetails.ajaxSettings),
202
+ beforeSend: getValue('beforeSend', imageDetails.ajaxSettings),
203
+ onSuccess: function (blob) {
204
+ var blobUrl = URL.createObjectURL(blob);
205
+ _this.imageUrlCache.set(imageKey, blobUrl);
206
+ imgElement.setAttribute('src', blobUrl);
207
+ imgElement.classList.remove('image-blur');
208
+ triggerFetchSuccess(_this.parent, imageDetails.ajaxSettings);
209
+ },
210
+ onFailure: function (response) {
211
+ var result = {
212
+ files: null,
213
+ error: {
214
+ code: response.status ? response.status.toString() : '404',
215
+ message: getLocaleText(_this.parent, 'Network-Error') + ' ' + getValue('url', imageDetails.ajaxSettings),
216
+ fileExists: null
217
+ }
218
+ };
219
+ triggerFetchFailure(_this.parent, imageDetails.ajaxSettings, result);
220
+ }
221
+ });
222
+ fetch.send(getValue('data', imageDetails.ajaxSettings));
223
+ });
224
+ };
175
225
  LargeIconsView.prototype.comparer = function (x, y) {
176
226
  if (this.parent.sortOrder === 'Descending') {
177
227
  var z = x;
@@ -346,9 +396,17 @@ var LargeIconsView = /** @class */ (function () {
346
396
  className += ' ' + getAccessClass(items[i]);
347
397
  }
348
398
  if (icon === CLS.ICON_IMAGE && this.parent.showThumbnail && hasReadAccess(items[i])) {
349
- var imgUrl = getImageUrl(this.parent, items[i]);
350
- setValue('_fm_imageUrl', imgUrl, items[i]);
351
- setValue('_fm_imageAttr', { alt: name_1 }, items[i]);
399
+ var imageData = getImageUrl(this.parent, items[i]);
400
+ if (imageData.useImageAsUrl) {
401
+ setValue('_fm_imageUrl', imageData.imageUrl, items[i]);
402
+ setValue('_fm_imageAttr', { alt: name_1 }, items[i]);
403
+ }
404
+ else {
405
+ var uniqueKey = "img_" + name_1 + "_" + i;
406
+ this.imageEventArgsMap.set(uniqueKey, imageData);
407
+ setValue('_fm_imageUrl', '', items[i]);
408
+ setValue('_fm_imageAttr', { alt: name_1, class: 'e-list-img image-blur', 'data-image-key': uniqueKey }, items[i]);
409
+ }
352
410
  }
353
411
  else {
354
412
  setValue('_fm_icon', icon, items[i]);
@@ -894,8 +952,8 @@ var LargeIconsView = /** @class */ (function () {
894
952
  else {
895
953
  var icon = fileType(details_1);
896
954
  if (icon === CLS.ICON_IMAGE) {
897
- var imgUrl = getImageUrl(_this.parent, details_1);
898
- createImageDialog(_this.parent, text, imgUrl);
955
+ var imageData = getImageUrl(_this.parent, details_1);
956
+ createImageDialog(_this.parent, text, imageData);
899
957
  }
900
958
  }
901
959
  }
@@ -647,6 +647,9 @@ var NavigationPane = /** @class */ (function () {
647
647
  }
648
648
  this.moveNames = [];
649
649
  var obj = this.parent.isDragDrop ? this.parent.dragData : this.parent.actionRecords;
650
+ if (!obj || !Array.isArray(obj)) {
651
+ return;
652
+ }
650
653
  for (var i = 0; i < obj.length; i++) {
651
654
  if (getValue('isFile', obj[i]) === false) {
652
655
  this.moveNames.push(getValue('_fm_id', obj[i]));
@@ -1,4 +1,4 @@
1
- import { IFileManager, ReadArgs, FileDetails } from '../base/interface';
1
+ import { IFileManager, ReadArgs, FileDetails, BeforeImageLoadEventArgs } from '../base/interface';
2
2
  import { SelectedEventArgs } from '@syncfusion/ej2-inputs';
3
3
  /**
4
4
  *
@@ -24,8 +24,8 @@ export declare function createExtDialog(parent: IFileManager, text: string, repl
24
24
  *
25
25
  * @param {IFileManager} parent - specifies the parent element.
26
26
  * @param {string} header - specifies the header element.
27
- * @param {string} imageUrl - specifies the image URL.
27
+ * @param {BeforeImageLoadEventArgs} imageData - specifies the image eventargs.
28
28
  * @returns {void}
29
29
  * @private
30
30
  */
31
- export declare function createImageDialog(parent: IFileManager, header: string, imageUrl: string): void;
31
+ export declare function createImageDialog(parent: IFileManager, header: string, imageData: BeforeImageLoadEventArgs): void;
@@ -1,10 +1,10 @@
1
1
  import { Dialog } from '@syncfusion/ej2-popups';
2
- import { select, isNullOrUndefined as isNOU, createElement, Internationalization } from '@syncfusion/ej2-base';
2
+ import { select, isNullOrUndefined as isNOU, createElement, Internationalization, Fetch } from '@syncfusion/ej2-base';
3
3
  import { getValue, remove, selectAll } from '@syncfusion/ej2-base';
4
4
  import { createFolder } from '../common/operations';
5
5
  import * as CLS from '../base/classes';
6
6
  import * as events from '../base/constant';
7
- import { paste, rename } from '../common/operations';
7
+ import { paste, rename, triggerFetchFailure, triggerFetchSuccess } from '../common/operations';
8
8
  import { getLocaleText, getDuplicateData, objectToString, getCssClass, getTargetPath } from '../common/utility';
9
9
  import { Input } from '@syncfusion/ej2-inputs';
10
10
  import { CheckBox } from '@syncfusion/ej2-buttons';
@@ -917,14 +917,42 @@ function getKeyCode(e) {
917
917
  *
918
918
  * @param {IFileManager} parent - specifies the parent element.
919
919
  * @param {string} header - specifies the header element.
920
- * @param {string} imageUrl - specifies the image URL.
920
+ * @param {BeforeImageLoadEventArgs} imageData - specifies the image eventargs.
921
921
  * @returns {void}
922
922
  * @private
923
923
  */
924
- export function createImageDialog(parent, header, imageUrl) {
924
+ export function createImageDialog(parent, header, imageData) {
925
925
  var content = createElement('div', { className: 'e-image-wrap' });
926
- var image = createElement('img', { className: 'e-image', attrs: { src: imageUrl, alt: header } });
927
- content.appendChild(image);
926
+ if (imageData.useImageAsUrl) {
927
+ var image = createElement('img', { className: 'e-image', attrs: { src: imageData.imageUrl, alt: header } });
928
+ content.appendChild(image);
929
+ }
930
+ else {
931
+ var fetch_1 = new Fetch({
932
+ url: getValue('url', imageData.ajaxSettings),
933
+ type: getValue('type', imageData.ajaxSettings),
934
+ contentType: getValue('contentType', imageData.ajaxSettings),
935
+ responseType: getValue('responseType', imageData.ajaxSettings),
936
+ beforeSend: getValue('beforeSend', imageData.ajaxSettings),
937
+ onSuccess: function (e) {
938
+ var blobUrl = URL.createObjectURL(e);
939
+ var image = createElement('img', { className: 'e-image', attrs: { src: blobUrl, alt: header } });
940
+ content.appendChild(image);
941
+ triggerFetchSuccess(parent, imageData.ajaxSettings);
942
+ },
943
+ onFailure: function (e) {
944
+ var result = {
945
+ error: {
946
+ code: e.status.toString(),
947
+ message: getLocaleText(parent, 'Network-Error') + ' ' + getValue('url', imageData.ajaxSettings)
948
+ }
949
+ };
950
+ triggerFetchFailure(parent, imageData.ajaxSettings, result);
951
+ }
952
+ });
953
+ var data = getValue('data', imageData.ajaxSettings);
954
+ fetch_1.send(data);
955
+ }
928
956
  if (isNOU(parent.viewerObj)) {
929
957
  parent.viewerObj = new Dialog({
930
958
  header: header,
@@ -582,7 +582,6 @@ ejs-filemanager {
582
582
  margin: 5px;
583
583
  margin-right: 4px;
584
584
  padding: 3px;
585
- padding: 5px;
586
585
  position: absolute;
587
586
  z-index: 1;
588
587
  }
@@ -841,6 +840,10 @@ ejs-filemanager {
841
840
  position: relative;
842
841
  vertical-align: bottom;
843
842
  }
843
+ .e-filemanager .e-large-icons .image-blur {
844
+ -webkit-filter: blur(8px);
845
+ filter: blur(8px);
846
+ }
844
847
  .e-filemanager .e-large-icons .e-list-text {
845
848
  overflow: hidden;
846
849
  text-overflow: ellipsis;
@@ -1011,6 +1014,17 @@ ejs-filemanager {
1011
1014
  .e-filemanager .e-upload-drag-hover .e-fe-overlay {
1012
1015
  visibility: visible;
1013
1016
  }
1017
+ .e-filemanager .e-fm-view-container {
1018
+ display: -webkit-box;
1019
+ display: -ms-flexbox;
1020
+ display: flex;
1021
+ width: 100%;
1022
+ -webkit-box-orient: vertical;
1023
+ -webkit-box-direction: normal;
1024
+ -ms-flex-direction: column;
1025
+ flex-direction: column;
1026
+ height: 100%;
1027
+ }
1014
1028
 
1015
1029
  .e-fe-popup.e-dropdown-popup ul .e-item .e-fe-dot,
1016
1030
  .e-fe-popup.e-dropdown-popup ul .e-item .e-fe-tick, .e-fe-popup.e-contextmenu-wrapper ul .e-menu-item .e-fe-dot,
@@ -1126,6 +1140,41 @@ ejs-filemanager {
1126
1140
  width: 100%;
1127
1141
  }
1128
1142
 
1143
+ .e-filemanager-dialog {
1144
+ z-index: 1005;
1145
+ display: -webkit-box;
1146
+ display: -ms-flexbox;
1147
+ display: flex;
1148
+ position: absolute;
1149
+ }
1150
+
1151
+ .e-image-wrap-style {
1152
+ height: 100%;
1153
+ }
1154
+
1155
+ .e-fe-popup.e-dialog td.e-permission-content {
1156
+ white-space: unset;
1157
+ }
1158
+
1159
+ .e-large-icon-visible {
1160
+ visibility: visible;
1161
+ }
1162
+
1163
+ .e-large-icon-hidden {
1164
+ visibility: hidden;
1165
+ }
1166
+
1167
+ .e-filemanager .e-empty-state-container {
1168
+ display: -webkit-box;
1169
+ display: -ms-flexbox;
1170
+ display: flex;
1171
+ height: 100%;
1172
+ }
1173
+
1174
+ .e-filemanager .e-empty.e-view-container {
1175
+ margin: auto;
1176
+ }
1177
+
1129
1178
  .e-filemanager {
1130
1179
  background: transparent;
1131
1180
  border-color: var(--color-sf-border-secondary);