@syncfusion/ej2-filemanager 25.2.6 → 26.1.40

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 (104) hide show
  1. package/.eslintrc.json +3 -2
  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 +931 -462
  6. package/dist/es6/ej2-filemanager.es2015.js.map +1 -1
  7. package/dist/es6/ej2-filemanager.es5.js +975 -515
  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 +16 -16
  13. package/src/file-manager/actions/breadcrumb-bar.js +0 -4
  14. package/src/file-manager/actions/toolbar.js +1 -13
  15. package/src/file-manager/actions/virtualization.d.ts +28 -8
  16. package/src/file-manager/actions/virtualization.js +37 -13
  17. package/src/file-manager/base/file-manager-model.d.ts +107 -36
  18. package/src/file-manager/base/file-manager.d.ts +100 -25
  19. package/src/file-manager/base/file-manager.js +46 -20
  20. package/src/file-manager/base/interface.d.ts +224 -2
  21. package/src/file-manager/base/interface.js +0 -1
  22. package/src/file-manager/common/operations.d.ts +7 -0
  23. package/src/file-manager/common/operations.js +596 -94
  24. package/src/file-manager/common/utility.d.ts +22 -0
  25. package/src/file-manager/common/utility.js +117 -65
  26. package/src/file-manager/layout/details-view.d.ts +1 -1
  27. package/src/file-manager/layout/details-view.js +23 -68
  28. package/src/file-manager/layout/large-icons-view.js +24 -46
  29. package/src/file-manager/layout/navigation-pane.js +18 -41
  30. package/src/file-manager/models/column-model.d.ts +1 -3
  31. package/src/file-manager/models/default-locale.js +0 -1
  32. package/src/file-manager/models/details-view-settings.js +2 -1
  33. package/src/file-manager/pop-up/context-menu.js +25 -24
  34. package/src/file-manager/pop-up/dialog.d.ts +1 -2
  35. package/src/file-manager/pop-up/dialog.js +12 -35
  36. package/styles/bootstrap-dark.css +116 -105
  37. package/styles/bootstrap-dark.scss +16 -1
  38. package/styles/bootstrap.css +117 -106
  39. package/styles/bootstrap.scss +16 -1
  40. package/styles/bootstrap4.css +116 -105
  41. package/styles/bootstrap4.scss +16 -1
  42. package/styles/bootstrap5-dark.css +98 -98
  43. package/styles/bootstrap5-dark.scss +16 -1
  44. package/styles/bootstrap5.css +98 -98
  45. package/styles/bootstrap5.scss +16 -1
  46. package/styles/fabric-dark.css +116 -105
  47. package/styles/fabric-dark.scss +16 -1
  48. package/styles/fabric.css +116 -105
  49. package/styles/fabric.scss +16 -1
  50. package/styles/file-manager/_bds-definition.scss +1 -1
  51. package/styles/file-manager/_bootstrap5-definition.scss +2 -1
  52. package/styles/file-manager/_bootstrap5.3-definition.scss +240 -0
  53. package/styles/file-manager/_fluent-definition.scss +1 -1
  54. package/styles/file-manager/_fluent2-definition.scss +249 -0
  55. package/styles/file-manager/_layout.scss +260 -396
  56. package/styles/file-manager/_material-dark-definition.scss +1 -0
  57. package/styles/file-manager/_material-definition.scss +1 -0
  58. package/styles/file-manager/_material3-definition.scss +1 -27
  59. package/styles/file-manager/_tailwind-definition.scss +1 -1
  60. package/styles/file-manager/_theme.scss +37 -85
  61. package/styles/file-manager/bootstrap-dark.css +116 -105
  62. package/styles/file-manager/bootstrap.css +117 -106
  63. package/styles/file-manager/bootstrap4.css +116 -105
  64. package/styles/file-manager/bootstrap5-dark.css +98 -98
  65. package/styles/file-manager/bootstrap5.css +98 -98
  66. package/styles/file-manager/fabric-dark.css +116 -105
  67. package/styles/file-manager/fabric.css +116 -105
  68. package/styles/file-manager/fluent-dark.css +107 -102
  69. package/styles/file-manager/fluent.css +107 -102
  70. package/styles/file-manager/fluent2.css +2868 -0
  71. package/styles/file-manager/fluent2.scss +16 -0
  72. package/styles/file-manager/highcontrast-light.css +116 -105
  73. package/styles/file-manager/highcontrast.css +116 -105
  74. package/styles/file-manager/icons/_bootstrap5.3.scss +235 -0
  75. package/styles/file-manager/icons/_fluent2.scss +235 -0
  76. package/styles/file-manager/material-dark.css +140 -108
  77. package/styles/file-manager/material.css +156 -112
  78. package/styles/file-manager/material3-dark.css +134 -109
  79. package/styles/file-manager/material3.css +134 -109
  80. package/styles/file-manager/tailwind-dark.css +93 -95
  81. package/styles/file-manager/tailwind.css +93 -95
  82. package/styles/fluent-dark.css +107 -102
  83. package/styles/fluent-dark.scss +16 -1
  84. package/styles/fluent.css +107 -102
  85. package/styles/fluent.scss +16 -1
  86. package/styles/fluent2.css +2868 -0
  87. package/styles/fluent2.scss +16 -0
  88. package/styles/highcontrast-light.css +116 -105
  89. package/styles/highcontrast-light.scss +16 -1
  90. package/styles/highcontrast.css +116 -105
  91. package/styles/highcontrast.scss +16 -1
  92. package/styles/material-dark.css +140 -108
  93. package/styles/material-dark.scss +16 -1
  94. package/styles/material.css +156 -112
  95. package/styles/material.scss +16 -1
  96. package/styles/material3-dark.css +134 -109
  97. package/styles/material3-dark.scss +16 -1
  98. package/styles/material3.css +134 -109
  99. package/styles/material3.scss +16 -1
  100. package/styles/tailwind-dark.css +93 -95
  101. package/styles/tailwind-dark.scss +16 -1
  102. package/styles/tailwind.css +93 -95
  103. package/styles/tailwind.scss +16 -1
  104. package/CHANGELOG.md +0 -475
@@ -1,13 +1,13 @@
1
- import { Ajax, Browser, ChildProperty, Collection, Complex, Component, Draggable, Event, EventHandler, Fetch, Internationalization, KeyboardEvents, L10n, NotifyPropertyChanges, Property, SanitizeHtmlHelper, Touch, addClass, closest, createElement, detach, extend, formatUnit, getUniqueID, getValue, initializeCSPTemplate, isNullOrUndefined, isVisible, matches, remove, removeClass, select, selectAll, setStyleAttribute, setValue } from '@syncfusion/ej2-base';
1
+ import { ChildProperty, Property, initializeCSPTemplate, getValue, isNullOrUndefined, matches, select, closest, createElement, setValue, detach, extend, Ajax, Internationalization, Fetch, remove, selectAll, addClass, Draggable, KeyboardEvents, EventHandler, Touch, removeClass, isVisible, Component, getUniqueID, setStyleAttribute, formatUnit, Browser, L10n, Complex, Collection, Event, NotifyPropertyChanges, SanitizeHtmlHelper } from '@syncfusion/ej2-base';
2
2
  import { Splitter } from '@syncfusion/ej2-layouts';
3
- import { Dialog, createSpinner, hideSpinner, showSpinner } from '@syncfusion/ej2-popups';
4
- import { DataManager, DataUtil, Query } from '@syncfusion/ej2-data';
3
+ import { Dialog, showSpinner, hideSpinner, createSpinner } from '@syncfusion/ej2-popups';
4
+ import { DataManager, Query, DataUtil } from '@syncfusion/ej2-data';
5
+ import { getUid, Grid, Resize, ContextMenu as ContextMenu$2, Sort, VirtualScroll } from '@syncfusion/ej2-grids';
5
6
  import { Input, TextBox, Uploader } from '@syncfusion/ej2-inputs';
6
7
  import { CheckBox, createCheckBox } from '@syncfusion/ej2-buttons';
7
8
  import { ListBase } from '@syncfusion/ej2-lists';
8
9
  import { DropDownButton } from '@syncfusion/ej2-splitbuttons';
9
- import { ContextMenu, Toolbar, TreeView } from '@syncfusion/ej2-navigations';
10
- import { ContextMenu as ContextMenu$1, Grid, Resize, Sort, VirtualScroll } from '@syncfusion/ej2-grids';
10
+ import { ContextMenu as ContextMenu$1, Toolbar as Toolbar$1, TreeView } from '@syncfusion/ej2-navigations';
11
11
 
12
12
  var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
13
13
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
@@ -145,7 +145,7 @@ var __decorate$3 = (undefined && undefined.__decorate) || function (decorators,
145
145
  const columnArray = [
146
146
  {
147
147
  field: 'name', headerText: 'Name', minWidth: 120,
148
- template: '<span class=\"e-fe-text\">${name}</span>',
148
+ template: '<span class="e-fe-text">${name}</span>',
149
149
  customAttributes: { class: 'e-fe-grid-name' }
150
150
  },
151
151
  {
@@ -154,6 +154,7 @@ const columnArray = [
154
154
  },
155
155
  {
156
156
  field: 'size', headerText: 'Size', minWidth: 90, width: '110',
157
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
157
158
  template: initializeCSPTemplate(function (data) {
158
159
  return `<span class="e-fe-size">${data.size}</span>`;
159
160
  }), format: 'n2'
@@ -321,10 +322,6 @@ __decorate$7([
321
322
  Property(false)
322
323
  ], Column.prototype, "isPrimaryKey", void 0);
323
324
 
324
- /**
325
- * FileExplorer common modules
326
- */
327
-
328
325
  /**
329
326
  * Specifies the File Manager internal ID's
330
327
  */
@@ -697,25 +694,30 @@ const permissionDownload = 'download';
697
694
  */
698
695
  function sortComparer(reference, comparer) {
699
696
  // Check if reference and comparer are files or folders
700
- let referenceIsFile = /\.\S+/.test(reference);
701
- let comparerIsFile = /\.\S+/.test(comparer);
697
+ const referenceIsFile = /\.\S+/.test(reference);
698
+ const comparerIsFile = /\.\S+/.test(comparer);
702
699
  // If one is a file and the other is a folder, the folder should come first
703
- if (referenceIsFile && !comparerIsFile)
700
+ if (referenceIsFile && !comparerIsFile) {
704
701
  return 1;
705
- if (!referenceIsFile && comparerIsFile)
702
+ }
703
+ if (!referenceIsFile && comparerIsFile) {
706
704
  return -1;
707
- let referenceParts = [];
708
- let comparerParts = [];
709
- (reference + '').replace(/(\d+)|(\D+)/g, function (_, $1, $2) { referenceParts.push([$1 || Infinity, $2 || ""]); return ""; });
710
- (comparer + '').replace(/(\d+)|(\D+)/g, function (_, $1, $2) { comparerParts.push([$1 || Infinity, $2 || ""]); return ""; });
705
+ }
706
+ const referenceParts = [];
707
+ const comparerParts = [];
708
+ (reference + '').replace(/(\d+)|(\D+)/g, function (_, $1, $2) { referenceParts.push([$1 || Infinity, $2 || '']); return ''; });
709
+ (comparer + '').replace(/(\d+)|(\D+)/g, function (_, $1, $2) { comparerParts.push([$1 || Infinity, $2 || '']); return ''; });
711
710
  // Compare each part of reference and comparer
712
711
  while (referenceParts.length && comparerParts.length) {
713
- let referencePart = referenceParts.shift();
714
- let comparerPart = comparerParts.shift();
715
- let comparisonResult = referencePart[0] - comparerPart[0] ||
716
- referencePart[1].localeCompare(comparerPart[1]);
717
- if (comparisonResult)
718
- return comparisonResult;
712
+ const referencePart = referenceParts.shift();
713
+ const comparerPart = comparerParts.shift();
714
+ if (referencePart && comparerPart) {
715
+ const comparisonResult = referencePart[0] - comparerPart[0] ||
716
+ referencePart[1].localeCompare(comparerPart[1]);
717
+ if (comparisonResult) {
718
+ return comparisonResult;
719
+ }
720
+ }
719
721
  }
720
722
  return referenceParts.length - comparerParts.length;
721
723
  }
@@ -728,7 +730,6 @@ function sortComparer(reference, comparer) {
728
730
  * @returns {void}
729
731
  * @private
730
732
  */
731
- // eslint-disable-next-line
732
733
  function updatePath(node, data, instance) {
733
734
  const text = getValue('name', data);
734
735
  const id = node.getAttribute('data-id');
@@ -824,8 +825,7 @@ function generatePath(parent) {
824
825
  let newPath = '/';
825
826
  let i = 1;
826
827
  for (i; i < parent.pathId.length; i++) {
827
- // eslint-disable-next-line
828
- const data = getValue(parent.pathId[i], parent.feParent);
828
+ const data = getValue(parent.pathId[parseInt(i.toString(), 10)], parent.feParent);
829
829
  newPath += getValue(key, data) + '/';
830
830
  }
831
831
  parent.setProperties({ path: newPath }, true);
@@ -963,6 +963,22 @@ function searchWordHandler(parent, value, isLayoutChange) {
963
963
  if (value.length === 0 && !parent.isFiltered) {
964
964
  parent.notify(pathColumn, { args: parent });
965
965
  }
966
+ if (isFileSystemData(parent)) {
967
+ if (value === '') {
968
+ parent.itemData = parent.fileSystemData;
969
+ read(parent, layoutChange, parent.path);
970
+ }
971
+ else {
972
+ parent.searchSettings.filterType = isNullOrUndefined(parent.searchSettings.filterType) ? 'contains' : parent.searchSettings.filterType;
973
+ const filteredData = parent.fileSystemData.filter((obj) => obj.parentId !== null);
974
+ const data = new DataManager(filteredData).
975
+ executeLocal(new Query().where('name', parent.searchSettings.filterType, value, parent.searchSettings.ignoreCase));
976
+ const searchValue = parent.searchSettings.ignoreCase ? value.toLowerCase() : value;
977
+ parent.itemData = data;
978
+ Search(parent, isLayoutChange ? layoutChange : search, parent.path, searchValue, parent.showHiddenItems, !parent.searchSettings.ignoreCase);
979
+ }
980
+ return;
981
+ }
966
982
  if (parent.searchSettings.filterType === 'startsWith') {
967
983
  searchWord = value + '*';
968
984
  }
@@ -1080,7 +1096,6 @@ function openAction(parent) {
1080
1096
  * @returns {Object} - returns the path data.
1081
1097
  * @private
1082
1098
  */
1083
- // eslint-disable-next-line
1084
1099
  function getPathObject(parent) {
1085
1100
  return getValue(parent.pathId[parent.pathId.length - 1], parent.feParent);
1086
1101
  }
@@ -1122,10 +1137,9 @@ function cutFiles(parent) {
1122
1137
  * @returns {string} - returns the file type.
1123
1138
  * @private
1124
1139
  */
1125
- // eslint-disable-next-line
1126
1140
  function fileType(file) {
1127
- const isFile$$1 = getValue('isFile', file);
1128
- if (!isFile$$1) {
1141
+ const isFile = getValue('isFile', file);
1142
+ if (!isFile) {
1129
1143
  return FOLDER;
1130
1144
  }
1131
1145
  const imageFormat = ['bmp', 'dib', 'jpg', 'jpeg', 'jpe', 'jfif', 'gif', 'tif', 'tiff', 'png', 'ico'];
@@ -1165,11 +1179,18 @@ function fileType(file) {
1165
1179
  * @returns {string} - returns the image url.
1166
1180
  * @private
1167
1181
  */
1168
- // eslint-disable-next-line
1169
1182
  function getImageUrl(parent, item) {
1183
+ let imgUrl = isFileSystemData(parent) ? getValue('imageUrl', item) : '';
1184
+ if (isFileSystemData(parent)) {
1185
+ const eventArgs = {
1186
+ fileDetails: [item],
1187
+ imageUrl: imgUrl
1188
+ };
1189
+ parent.trigger('beforeImageLoad', eventArgs);
1190
+ return eventArgs.imageUrl;
1191
+ }
1170
1192
  const baseUrl = parent.ajaxSettings.getImageUrl ? parent.ajaxSettings.getImageUrl : parent.ajaxSettings.url;
1171
- let pathUrl = (baseUrl.indexOf('?') !== -1) ? '&path=' : '?path=';
1172
- let imgUrl;
1193
+ const pathUrl = (baseUrl.indexOf('?') !== -1) ? '&path=' : '?path=';
1173
1194
  const fileName = encodeURIComponent(getValue('name', item));
1174
1195
  const fPath = getValue('filterPath', item);
1175
1196
  if (parent.hasId) {
@@ -1200,7 +1221,6 @@ function getImageUrl(parent, item) {
1200
1221
  * @returns {string} - returns the image url.
1201
1222
  * @private
1202
1223
  */
1203
- // eslint-disable-next-line
1204
1224
  function getFullPath(parent, data, path) {
1205
1225
  const filePath = getValue(parent.hasId ? 'id' : 'name', data) + '/';
1206
1226
  const fPath = getValue(parent.hasId ? 'filterId' : 'filterPath', data);
@@ -1219,7 +1239,6 @@ function getFullPath(parent, data, path) {
1219
1239
  * @returns {string} - returns the name.
1220
1240
  * @private
1221
1241
  */
1222
- // eslint-disable-next-line
1223
1242
  function getName(parent, data) {
1224
1243
  let name = getValue('name', data);
1225
1244
  let fPath = getValue('filterPath', data);
@@ -1237,19 +1256,17 @@ function getName(parent, data) {
1237
1256
  * @returns {Object[]} - returns the sorted data.
1238
1257
  * @private
1239
1258
  */
1240
- // eslint-disable-next-line
1241
1259
  function getSortedData(parent, items) {
1242
1260
  if (items.length === 0) {
1243
1261
  return items;
1244
1262
  }
1245
1263
  let query;
1246
- if (parent.sortOrder !== 'None') {
1264
+ if (parent.sortOrder !== 'None' && !isNullOrUndefined(parent.sortOrder)) {
1247
1265
  query = new Query().sortBy(parent.sortBy, parent.sortOrder.toLowerCase(), true).group('isFile');
1248
1266
  }
1249
1267
  else {
1250
1268
  query = new Query().group('isFile');
1251
1269
  }
1252
- // eslint-disable-next-line
1253
1270
  const lists = new DataManager(items).executeLocal(query);
1254
1271
  return getValue('records', lists);
1255
1272
  }
@@ -1262,12 +1279,9 @@ function getSortedData(parent, items) {
1262
1279
  * @returns {Object} - returns the sorted data.
1263
1280
  * @private
1264
1281
  */
1265
- // eslint-disable-next-line
1266
1282
  function getObject(parent, key, value) {
1267
- // eslint-disable-next-line
1268
1283
  const currFiles = getValue(parent.pathId[parent.pathId.length - 1], parent.feFiles);
1269
1284
  const query = new Query().where(key, 'equal', value);
1270
- // eslint-disable-next-line
1271
1285
  const lists = new DataManager(currFiles).executeLocal(query);
1272
1286
  return lists[0];
1273
1287
  }
@@ -1332,7 +1346,6 @@ function createEmptyElement(parent, element, args) {
1332
1346
  * @returns {Object[]} - returns the sorted data.
1333
1347
  * @private
1334
1348
  */
1335
- // eslint-disable-next-line
1336
1349
  function getDirectories(files) {
1337
1350
  return new DataManager(files).executeLocal(new Query().where(isFile, 'equal', false, false));
1338
1351
  }
@@ -1345,7 +1358,6 @@ function getDirectories(files) {
1345
1358
  * @private
1346
1359
  */
1347
1360
  function setNodeId(result, rootId) {
1348
- // eslint-disable-next-line
1349
1361
  const dirs = getDirectories(result.files);
1350
1362
  for (let i = 0, len = dirs.length; i < len; i++) {
1351
1363
  setValue('_fm_id', rootId + '_' + i, dirs[i]);
@@ -1355,16 +1367,17 @@ function setNodeId(result, rootId) {
1355
1367
  * set the date object
1356
1368
  *
1357
1369
  * @param {Object[]} args - specifies the file object.
1370
+ * @param {Internationalization} localeString - The internationalization object for formatting dates.
1371
+ * @param {string} dateFormat - The date format string.
1358
1372
  * @returns {void}
1359
1373
  * @private
1360
1374
  */
1361
- // eslint-disable-next-line
1362
1375
  function setDateObject(args, localeString, dateFormat) {
1363
1376
  for (let i = 0; i < args.length; i++) {
1364
1377
  const createdDate = new Date(getValue('dateCreated', args[i]));
1365
1378
  const modifiedDate = new Date(getValue('dateModified', args[i]));
1366
1379
  if (isNullOrUndefined(dateFormat)) {
1367
- dateFormat = "MM/dd/yyyy";
1380
+ dateFormat = 'MM/dd/yyyy';
1368
1381
  }
1369
1382
  setValue('_fm_created', localeString.formatDate(createdDate, { format: dateFormat }), args[i]);
1370
1383
  setValue('_fm_modified', localeString.formatDate(modifiedDate, { format: dateFormat }), args[i]);
@@ -1437,6 +1450,7 @@ function sortbyClickHandler(parent, args) {
1437
1450
  * Gets the sorted fields
1438
1451
  *
1439
1452
  * @param {string} id - specifies the id.
1453
+ * @param {IFileManager} [parent] - optional parameter representing the parent IFileManager.
1440
1454
  * @returns {string} - returns the sorted fields
1441
1455
  * @private
1442
1456
  */
@@ -1482,14 +1496,12 @@ function getSortField(id, parent) {
1482
1496
  function setNextPath(parent, path) {
1483
1497
  const currfolders = path.split('/');
1484
1498
  const folders = parent.originalPath.split('/');
1485
- // eslint-disable-next-line
1486
1499
  const root = getValue(parent.pathId[0], parent.feParent);
1487
1500
  const key = isNullOrUndefined(getValue('id', root)) ? 'name' : 'id';
1488
1501
  for (let i = currfolders.length - 1, len = folders.length - 1; i < len; i++) {
1489
1502
  const eventName = (folders[i + 1] === '') ? finalizeEnd : initialEnd;
1490
1503
  const newPath = (folders[i] === '') ? '/' : (parent.path + folders[i] + '/');
1491
- // eslint-disable-next-line
1492
- const data = getObject(parent, key, folders[i]);
1504
+ const data = getObject(parent, key, folders[parseInt(i.toString(), 10)]);
1493
1505
  if (!isNullOrUndefined(data)) {
1494
1506
  const id = getValue('_fm_id', data);
1495
1507
  parent.setProperties({ path: newPath }, true);
@@ -1512,13 +1524,12 @@ function setNextPath(parent, path) {
1512
1524
  * @returns {void}
1513
1525
  * @private
1514
1526
  */
1515
- // eslint-disable-next-line
1516
1527
  function openSearchFolder(parent, data) {
1517
1528
  parent.originalPath = getFullPath(parent, data, parent.path);
1518
1529
  const root = getValue(parent.pathId[0], parent.feParent);
1519
- const isRoot = getValue('_fm_id', parent.itemData[0]) == 'fe_tree';
1530
+ const isRoot = getValue('_fm_id', parent.itemData[0]) === 'fe_tree';
1520
1531
  const key = isNullOrUndefined(getValue('id', root)) ? 'name' : 'id';
1521
- const searchData = getObject(parent, key, getValue('name', data));
1532
+ const searchData = getObject(parent, key, isFileSystemData(parent) ? getValue('id', data) : getValue('name', data));
1522
1533
  if (isNullOrUndefined(searchData)) {
1523
1534
  if (!isRoot) {
1524
1535
  parent.notify(clearPathInit, { selectedNode: parent.pathId[parent.pathId.length - 1] });
@@ -1548,7 +1559,6 @@ function pasteHandler(parent) {
1548
1559
  parent.isDragDrop = false;
1549
1560
  if (parent.selectedNodes.length !== 0 && parent.enablePaste) {
1550
1561
  const path = (parent.folderPath === '') ? parent.path : parent.folderPath;
1551
- // eslint-disable-next-line
1552
1562
  const subFolder = validateSubFolder(parent, parent.actionRecords, path, parent.path);
1553
1563
  if (!subFolder) {
1554
1564
  if ((parent.fileAction === 'move' && parent.targetPath !== path) || parent.fileAction === 'copy') {
@@ -1582,13 +1592,12 @@ function pasteHandler(parent) {
1582
1592
  * @returns {boolean} - returns the validated sub folder.
1583
1593
  * @private
1584
1594
  */
1585
- // eslint-disable-next-line
1586
- function validateSubFolder(parent, data, dropPath$$1, dragPath) {
1595
+ function validateSubFolder(parent, data, dropPath, dragPath) {
1587
1596
  let subFolder = false;
1588
1597
  for (let i = 0; i < data.length; i++) {
1589
1598
  if (!getValue('isFile', data[i])) {
1590
1599
  const tempTarget = getFullPath(parent, data[i], dragPath);
1591
- if (dropPath$$1.indexOf(tempTarget) === 0) {
1600
+ if (dropPath.indexOf(tempTarget) === 0) {
1592
1601
  const result = {
1593
1602
  files: null,
1594
1603
  error: {
@@ -1603,7 +1612,8 @@ function validateSubFolder(parent, data, dropPath$$1, dragPath) {
1603
1612
  }
1604
1613
  }
1605
1614
  else {
1606
- const srcData = parent.dragNodes[i];
1615
+ const name = parent.dragData[i] ? parent.dragData[i].name : null;
1616
+ const srcData = isFileSystemData(parent) ? name : parent.dragNodes[i];
1607
1617
  let len = 0;
1608
1618
  if (srcData) {
1609
1619
  len = srcData.lastIndexOf('/');
@@ -1612,7 +1622,7 @@ function validateSubFolder(parent, data, dropPath$$1, dragPath) {
1612
1622
  if (len > 0) {
1613
1623
  path = dragPath + srcData.substring(0, len + 1);
1614
1624
  }
1615
- if (path === dropPath$$1) {
1625
+ if (path === dropPath) {
1616
1626
  const result = {
1617
1627
  files: null,
1618
1628
  error: {
@@ -1674,15 +1684,15 @@ function getParentPath(oldPath) {
1674
1684
  */
1675
1685
  function getDirectoryPath(parent, args) {
1676
1686
  const filePath = getValue(parent.hasId ? 'id' : 'name', args.cwd) + '/';
1677
- const fPath = getValue(parent.hasId ? 'filterId' : 'filterPath', args.cwd);
1687
+ const fPath = getValue(parent.hasId && !isNullOrUndefined(parent.ajaxSettings.url) ? 'filterId' : 'filterPath', args.cwd);
1678
1688
  if (!isNullOrUndefined(fPath)) {
1679
1689
  if (fPath === '') {
1680
- return parent.hasId ? filePath : '/';
1690
+ return parent.hasId && !isNullOrUndefined(parent.ajaxSettings.url) ? filePath : '/';
1681
1691
  }
1682
1692
  return fPath.replace(/\\/g, '/') + filePath;
1683
1693
  }
1684
1694
  else {
1685
- return parent.path + filePath;
1695
+ return isFileSystemData(parent) ? filePath : parent.path + filePath;
1686
1696
  }
1687
1697
  }
1688
1698
  /**
@@ -1751,8 +1761,8 @@ function readDropPath(parent) {
1751
1761
  if (parent.navigationpaneModule) {
1752
1762
  let node = select('[data-uid="' + pathId + '"]', parent.navigationpaneModule.treeObj.element);
1753
1763
  if (!node) {
1754
- let liElement = document.querySelector('[data-id = "' + getValue('id', parent.dropData) + '"]');
1755
- pathId = liElement.getAttribute("data-uid");
1764
+ const liElement = document.querySelector('[data-id = "' + getValue('id', parent.dropData) + '"]');
1765
+ pathId = liElement.getAttribute('data-uid');
1756
1766
  node = select('[data-uid="' + pathId + '"]', parent.navigationpaneModule.treeObj.element);
1757
1767
  }
1758
1768
  updatePath(node, parent.dropData, parent);
@@ -1768,11 +1778,8 @@ function readDropPath(parent) {
1768
1778
  * @returns {object} - returns the duplicated path.
1769
1779
  * @private
1770
1780
  */
1771
- // eslint-disable-next-line
1772
1781
  function getDuplicateData(parent, name) {
1773
- // eslint-disable-next-line
1774
1782
  let data = null;
1775
- // eslint-disable-next-line
1776
1783
  const records = parent.isDragDrop ? parent.dragData : parent.actionRecords;
1777
1784
  for (let i = 0; i < records.length; i++) {
1778
1785
  if (getValue('name', records[i]) === name) {
@@ -1965,8 +1972,8 @@ function removeItemClass(parent, value) {
1965
1972
  */
1966
1973
  function scrollHandler(scrollParent, parent, nodeClass, screenY, clientY) {
1967
1974
  let position;
1968
- let elementData = scrollParent.getBoundingClientRect();
1969
- const node = select("." + nodeClass, scrollParent);
1975
+ const elementData = scrollParent.getBoundingClientRect();
1976
+ const node = select('.' + nodeClass, scrollParent);
1970
1977
  if ((screenY >= (elementData.top + scrollParent.clientHeight - 30)) && !isNullOrUndefined(node)) {
1971
1978
  position = (parent.targetModule === 'navigationpane' || parent.targetModule === 'detailsview') ? node.offsetHeight / 2.5 : node.offsetHeight / 4.5;
1972
1979
  scrollParent.scrollBy(0, position);
@@ -2044,7 +2051,6 @@ function draggingHandler(parent, args) {
2044
2051
  * @private
2045
2052
  */
2046
2053
  // Ignored the message key value in permission object
2047
- // eslint-disable-next-line
2048
2054
  function objectToString(data) {
2049
2055
  let str = '';
2050
2056
  const keys = Object.keys(data);
@@ -2063,7 +2069,6 @@ function objectToString(data) {
2063
2069
  * @returns {string} returns the item name.
2064
2070
  * @private
2065
2071
  */
2066
- // eslint-disable-next-line
2067
2072
  function getItemName(parent, data) {
2068
2073
  if (parent.hasId) {
2069
2074
  return getValue('id', data);
@@ -2078,7 +2083,6 @@ function getItemName(parent, data) {
2078
2083
  * @returns {void}
2079
2084
  * @private
2080
2085
  */
2081
- // eslint-disable-next-line
2082
2086
  function updateRenamingData(parent, data) {
2083
2087
  parent.itemData = [data];
2084
2088
  parent.currentItemText = getValue('name', data);
@@ -2109,7 +2113,6 @@ function doRename(parent) {
2109
2113
  * @private
2110
2114
  */
2111
2115
  function doDownload(parent) {
2112
- // eslint-disable-next-line
2113
2116
  const items = parent.itemData;
2114
2117
  for (let i = 0; i < items.length; i++) {
2115
2118
  if (!hasDownloadAccess(items[i])) {
@@ -2130,7 +2133,6 @@ function doDownload(parent) {
2130
2133
  * @returns {void}
2131
2134
  * @private
2132
2135
  */
2133
- // eslint-disable-next-line
2134
2136
  function doDeleteFiles(parent, data, newIds) {
2135
2137
  for (let i = 0; i < data.length; i++) {
2136
2138
  if (!hasEditAccess(data[i])) {
@@ -2151,7 +2153,6 @@ function doDeleteFiles(parent, data, newIds) {
2151
2153
  * @returns {void}
2152
2154
  * @private
2153
2155
  */
2154
- // eslint-disable-next-line
2155
2156
  function doDownloadFiles(parent, data, newIds) {
2156
2157
  for (let i = 0; i < data.length; i++) {
2157
2158
  if (!hasDownloadAccess(data[i])) {
@@ -2173,7 +2174,6 @@ function doDownloadFiles(parent, data, newIds) {
2173
2174
  * @returns {void}
2174
2175
  * @private
2175
2176
  */
2176
- // eslint-disable-next-line
2177
2177
  function createDeniedDialog(parent, data, action) {
2178
2178
  let message = getValue('message', getValue('permission', data));
2179
2179
  if (message === '') {
@@ -2195,7 +2195,6 @@ function createDeniedDialog(parent, data, action) {
2195
2195
  * @returns {string} - returns accesses classes.
2196
2196
  * @private
2197
2197
  */
2198
- // eslint-disable-next-line
2199
2198
  function getAccessClass(data) {
2200
2199
  return !hasReadAccess(data) ? 'e-fe-locked e-fe-hidden' : 'e-fe-locked';
2201
2200
  }
@@ -2206,9 +2205,7 @@ function getAccessClass(data) {
2206
2205
  * @returns {boolean} - returns read access.
2207
2206
  * @private
2208
2207
  */
2209
- // eslint-disable-next-line
2210
2208
  function hasReadAccess(data) {
2211
- // eslint-disable-next-line
2212
2209
  const permission = getValue('permission', data);
2213
2210
  return (permission && !getValue('read', permission)) ? false : true;
2214
2211
  }
@@ -2219,9 +2216,7 @@ function hasReadAccess(data) {
2219
2216
  * @returns {boolean} - returns edit access.
2220
2217
  * @private
2221
2218
  */
2222
- // eslint-disable-next-line
2223
2219
  function hasEditAccess(data) {
2224
- // eslint-disable-next-line
2225
2220
  const permission = getValue('permission', data);
2226
2221
  return permission ? ((getValue('read', permission) && getValue('write', permission))) : true;
2227
2222
  }
@@ -2232,9 +2227,7 @@ function hasEditAccess(data) {
2232
2227
  * @returns {boolean} - returns content access.
2233
2228
  * @private
2234
2229
  */
2235
- // eslint-disable-next-line
2236
2230
  function hasContentAccess(data) {
2237
- // eslint-disable-next-line
2238
2231
  const permission = getValue('permission', data);
2239
2232
  return permission ? ((getValue('read', permission) && getValue('writeContents', permission))) : true;
2240
2233
  }
@@ -2245,9 +2238,7 @@ function hasContentAccess(data) {
2245
2238
  * @returns {boolean} - returns upload access.
2246
2239
  * @private
2247
2240
  */
2248
- // eslint-disable-next-line
2249
2241
  function hasUploadAccess(data) {
2250
- // eslint-disable-next-line
2251
2242
  const permission = getValue('permission', data);
2252
2243
  return permission ? ((getValue('read', permission) && getValue('upload', permission))) : true;
2253
2244
  }
@@ -2258,9 +2249,7 @@ function hasUploadAccess(data) {
2258
2249
  * @returns {boolean} - returns download access.
2259
2250
  * @private
2260
2251
  */
2261
- // eslint-disable-next-line
2262
2252
  function hasDownloadAccess(data) {
2263
- // eslint-disable-next-line
2264
2253
  const permission = getValue('permission', data);
2265
2254
  return permission ? ((getValue('read', permission) && getValue('download', permission))) : true;
2266
2255
  }
@@ -2272,7 +2261,6 @@ function hasDownloadAccess(data) {
2272
2261
  * @private
2273
2262
  */
2274
2263
  function createNewFolder(parent) {
2275
- // eslint-disable-next-line
2276
2264
  const details = parent.itemData[0];
2277
2265
  if (!hasContentAccess(details)) {
2278
2266
  createDeniedDialog(parent, details, permissionEditContents);
@@ -2289,7 +2277,6 @@ function createNewFolder(parent) {
2289
2277
  * @private
2290
2278
  */
2291
2279
  function uploadItem(parent) {
2292
- // eslint-disable-next-line
2293
2280
  const details = parent.itemData[0];
2294
2281
  if (!hasUploadAccess(details)) {
2295
2282
  createDeniedDialog(parent, details, permissionUpload);
@@ -2300,7 +2287,70 @@ function uploadItem(parent) {
2300
2287
  uploadEle.click();
2301
2288
  }
2302
2289
  }
2290
+ /**
2291
+ * Close dialog popup handler
2292
+ *
2293
+ * @param {IFileManager} parent - specifies the parent.
2294
+ * @returns {void}
2295
+ * @private
2296
+ */
2297
+ function closePopup(parent) {
2298
+ if (!isNullOrUndefined(parent.dialogObj)) {
2299
+ parent.dialogObj.hide();
2300
+ }
2301
+ }
2302
+ /**
2303
+ * Access control handler
2304
+ *
2305
+ * @param {IFileManager} parent - specifies the parent.
2306
+ * @param {Object[]} itemData - specifies the item elements.
2307
+ * @param {string} action - specifies the action.
2308
+ * @param {boolean} isPathPermision - specifies the path permission.
2309
+ * @returns {string} returns the path.
2310
+ * @private
2311
+ */
2312
+ function getAccessDetails(parent, itemData, action, isPathPermision) {
2313
+ let accessMessage = '';
2314
+ for (let i = 0; i < itemData.length; i++) {
2315
+ let permission = getValue('permission', itemData[i]);
2316
+ if (permission == null) {
2317
+ permission = undefined;
2318
+ }
2319
+ if (isPathPermision) {
2320
+ if (permission && (!getValue('read', permission) || !getValue('writeContents', permission))) {
2321
+ accessMessage = getValue('message', getValue('permission', itemData[i]));
2322
+ if (accessMessage === '') {
2323
+ accessMessage = getLocaleText(parent, 'Access-Message').replace('{0}', getValue('name', itemData[i])).replace('{1}', 'writeContents');
2324
+ }
2325
+ }
2326
+ }
2327
+ else {
2328
+ const copyOrMovePermission = action === 'copy' ? getValue('copy', permission) : getValue('write', permission);
2329
+ if (permission && (!getValue('read', permission) || !copyOrMovePermission)) {
2330
+ accessMessage = getValue('message', getValue('permission', itemData[i]));
2331
+ if (accessMessage === '') {
2332
+ accessMessage = getLocaleText(parent, 'Access-Message').replace('{0}', getValue('name', itemData[i])).replace('{1}', action);
2333
+ }
2334
+ }
2335
+ }
2336
+ if (accessMessage !== '') {
2337
+ parent.responseData = {
2338
+ cwd: null,
2339
+ details: null,
2340
+ error: {
2341
+ code: '401',
2342
+ message: accessMessage,
2343
+ fileExists: null
2344
+ },
2345
+ files: null
2346
+ };
2347
+ break;
2348
+ }
2349
+ }
2350
+ return accessMessage;
2351
+ }
2303
2352
 
2353
+ /* eslint-disable @typescript-eslint/no-explicit-any */
2304
2354
  /**
2305
2355
  * Function to read the content from given path in File Manager.
2306
2356
  *
@@ -2311,14 +2361,12 @@ function uploadItem(parent) {
2311
2361
  * @private
2312
2362
  */
2313
2363
  function read(parent, event, path) {
2314
- // eslint-disable-next-line
2315
2364
  const itemData = parent.itemData;
2316
2365
  for (let i = 0; i < itemData.length; i++) {
2317
2366
  if (isNullOrUndefined(getValue('hasChild', itemData[i]))) {
2318
2367
  setValue('hasChild', false, itemData[i]);
2319
2368
  }
2320
2369
  }
2321
- // eslint-disable-next-line
2322
2370
  const data = { action: 'read', path: path, showHiddenItems: parent.showHiddenItems, data: itemData };
2323
2371
  createAjax(parent, data, readSuccess, event);
2324
2372
  }
@@ -2331,7 +2379,6 @@ function read(parent, event, path) {
2331
2379
  * @private
2332
2380
  */
2333
2381
  function createFolder(parent, itemName) {
2334
- // eslint-disable-next-line
2335
2382
  const data = { action: 'create', path: parent.path, name: itemName, data: parent.itemData };
2336
2383
  createAjax(parent, data, createSuccess, itemName);
2337
2384
  }
@@ -2344,11 +2391,8 @@ function createFolder(parent, itemName) {
2344
2391
  * @private
2345
2392
  */
2346
2393
  function filter(parent, event) {
2347
- // eslint-disable-next-line
2348
2394
  const data = { action: 'filter', path: parent.path, showHiddenItems: parent.showHiddenItems, data: [getPathObject(parent)] };
2349
- // eslint-disable-next-line
2350
2395
  let filterData;
2351
- // eslint-disable-next-line
2352
2396
  const filterDataVal = parent.filterData ? extend(filterData, data, parent.filterData) : data;
2353
2397
  createAjax(parent, filterDataVal, filterSuccess, event, getValue('action', filterDataVal));
2354
2398
  }
@@ -2380,7 +2424,6 @@ function rename(parent, path, itemNewName) {
2380
2424
  newName = fPath.replace(path, '') + itemNewName;
2381
2425
  }
2382
2426
  }
2383
- // eslint-disable-next-line
2384
2427
  const data = {
2385
2428
  action: 'rename', path: path, name: name, newName: newName, data: parent.itemData, showFileExtension: parent.showFileExtension
2386
2429
  };
@@ -2399,10 +2442,7 @@ function rename(parent, path, itemNewName) {
2399
2442
  * @returns {void}
2400
2443
  * @private
2401
2444
  */
2402
- function paste(parent, path, names, targetPath, pasteOperation,
2403
- // eslint-disable-next-line
2404
- renameItems, actionRecords) {
2405
- // eslint-disable-next-line
2445
+ function paste(parent, path, names, targetPath, pasteOperation, renameItems, actionRecords) {
2406
2446
  const data = {
2407
2447
  action: pasteOperation, path: path, targetData: parent.itemData[0],
2408
2448
  targetPath: targetPath, names: names, renameFiles: renameItems, data: actionRecords
@@ -2421,7 +2461,6 @@ renameItems, actionRecords) {
2421
2461
  * @private
2422
2462
  */
2423
2463
  function Delete(parent, items, path, operation) {
2424
- // eslint-disable-next-line
2425
2464
  const data = { action: operation, path: path, names: items, data: parent.itemData };
2426
2465
  createAjax(parent, data, deleteSuccess, path);
2427
2466
  }
@@ -2437,26 +2476,23 @@ function Delete(parent, items, path, operation) {
2437
2476
  * @private
2438
2477
  */
2439
2478
  function GetDetails(parent, names, path, operation) {
2440
- // eslint-disable-next-line
2441
2479
  const data = { action: operation, path: path, names: names, data: parent.itemData };
2442
2480
  createAjax(parent, data, detailsSuccess, path, operation);
2443
2481
  }
2444
2482
  /**
2445
- * Function for createAjax in File Manager.
2483
+ * Function for getDateFormat in File Manager.
2446
2484
  *
2447
2485
  * @param {IFileManager} parent - specifies the parent element.
2448
- * @param {Object} data - specifies the data.
2449
- * @param {Function} fn - specifies the fn.
2450
- * @param {string} event - specifies the event.
2451
- * @param {string} operation - specifies the operation.
2452
- * @param {string} targetPath - specifies the target path.
2453
2486
  * @returns {void}
2454
2487
  * @private
2455
2488
  */
2456
2489
  function getDateFormat(parent) {
2457
2490
  const columns = parent.detailsViewSettings.columns;
2458
2491
  let dateFormat;
2459
- for (var i = 0; i < columns.length; i++) {
2492
+ if (!columns) {
2493
+ return null;
2494
+ }
2495
+ for (let i = 0; i < columns.length; i++) {
2460
2496
  if (columns[i].field === '_fm_modified') {
2461
2497
  if (!isNullOrUndefined(columns[i].format)) {
2462
2498
  dateFormat = columns[i].format.toString();
@@ -2466,10 +2502,393 @@ function getDateFormat(parent) {
2466
2502
  }
2467
2503
  return dateFormat;
2468
2504
  }
2469
- function createAjax(
2470
- // eslint-disable-next-line
2471
- parent, data, fn, event, operation, targetPath) {
2472
- // eslint-disable-next-line
2505
+ /**
2506
+ * Checks whether fileSystemData is enabled.
2507
+ *
2508
+ * @param {IFileManager} parent - specifies the parent element.
2509
+ * @returns {boolean} - returns the boolean value.
2510
+ */
2511
+ function isFileSystemData(parent) {
2512
+ const isFileSystemData = parent.fileSystemData.length >= 0 && isNullOrUndefined(parent.ajaxSettings.url);
2513
+ return isFileSystemData;
2514
+ }
2515
+ /**
2516
+ * Function to check whether file already exist or not.
2517
+ *
2518
+ * @param {Record<string, any>} fileSystemData - specifies the file data.
2519
+ * @param {string} name - specifies the name.
2520
+ * @returns {boolean} - returns the boolean value.
2521
+ * @private
2522
+ */
2523
+ function isFileExists(fileSystemData, name) {
2524
+ const isExists = fileSystemData.some((item) => item.name === name);
2525
+ return isExists;
2526
+ }
2527
+ /**
2528
+ * Function to find the index value of a file or folder.
2529
+ *
2530
+ * @param {IFileManager} parent - specifies the parent element.
2531
+ * @param {number} id - specifies the id.
2532
+ * @returns {number} - returns the index value.
2533
+ * @private
2534
+ */
2535
+ function findIndexById(parent, id) {
2536
+ const index = parent.fileSystemData.findIndex((item) => String(item.id) === String(id));
2537
+ return index;
2538
+ }
2539
+ /**
2540
+ * Function to get the entire data of a file or folder using id value.
2541
+ *
2542
+ * @param {IFileManager} parent - specifies the parent element.
2543
+ * @param {number | string} id - specifies the id.
2544
+ * @returns {Object} - returns the data.
2545
+ * @private
2546
+ */
2547
+ function filterById(parent, id) {
2548
+ const data = parent.fileSystemData.filter((item) => String(item.id) === String(id))[0];
2549
+ return data;
2550
+ }
2551
+ /**
2552
+ * Function to get the entire data of a file or folder for a parent.
2553
+ *
2554
+ * @param {IFileManager} parent - specifies the parent element.
2555
+ * @param {number | string} parentId - specifies the parent id.
2556
+ * @returns {Object[]} - returns the data.
2557
+ * @private
2558
+ */
2559
+ function filterByParent(parent, parentId) {
2560
+ const data = parent.fileSystemData.filter((item) => String(item.parentId) === String(parentId));
2561
+ return data;
2562
+ }
2563
+ /**
2564
+ * Function to create a new copied file or folder.
2565
+ *
2566
+ * @param {Record<string, any>} data - specifies the file or folder data.
2567
+ * @param {Record<string, any>} target - specifies the target data.
2568
+ * @param {string} itemName - specifies the item name.
2569
+ * @param {boolean} isCopy - specifies the copy operation.
2570
+ * @returns {Record<string, Object>} - returns the data.
2571
+ * @private
2572
+ */
2573
+ function createNewItem(data, target, itemName, isCopy) {
2574
+ const newItem = {};
2575
+ //Construct the new folder details.
2576
+ for (const key in data) {
2577
+ if (Object.prototype.hasOwnProperty.call(data, key)) {
2578
+ newItem[key] = null;
2579
+ }
2580
+ }
2581
+ const currentDate = new Date();
2582
+ const folderPath = target.id !== 0 ? target.filterPath + target.name : '\\';
2583
+ Object.assign(newItem, {
2584
+ dateCreated: currentDate,
2585
+ dateModified: currentDate,
2586
+ filterPath: folderPath,
2587
+ hasChild: isCopy ? data.hasChild : false,
2588
+ id: getUid(itemName === null ? data.name : itemName),
2589
+ isFile: isCopy ? data.isFile : false,
2590
+ name: itemName === null ? data.name : itemName,
2591
+ parentId: target.id,
2592
+ size: isCopy ? data.size : 0,
2593
+ type: isCopy ? data.type : ''
2594
+ });
2595
+ return newItem;
2596
+ }
2597
+ /**
2598
+ * Function to create an error response.
2599
+ *
2600
+ * @param {IFileManager} parent - specifies the parent element.
2601
+ * @param {string} message - specifies the error message.
2602
+ * @param {string} code - specifies the error code.
2603
+ * @param {Object[]} fileName - specifies the file name.
2604
+ * @returns {void}
2605
+ * @private
2606
+ */
2607
+ function createErrorObject(parent, message, code, fileName) {
2608
+ parent.responseData = {
2609
+ cwd: null,
2610
+ details: null,
2611
+ error: {
2612
+ code: code,
2613
+ message: message,
2614
+ fileExists: fileName != null ? fileName : null
2615
+ },
2616
+ files: null
2617
+ };
2618
+ }
2619
+ /**
2620
+ * Function to trigger folder creation.
2621
+ *
2622
+ * @param {IFileManager} parent - specifies the parent element.
2623
+ * @param {Object} data - specifies the data.
2624
+ * @param {BeforeSendEventArgs} eventArgs - specifies the eventArgs.
2625
+ * @returns {void}
2626
+ * @private
2627
+ */
2628
+ function triggerFolderCreation(parent, data, eventArgs) {
2629
+ const createEventArgs = {
2630
+ folderName: getValue('name', data),
2631
+ cancel: false,
2632
+ path: getValue('path', data),
2633
+ parentFolder: getValue('data', data)
2634
+ };
2635
+ parent.trigger('beforeFolderCreate', createEventArgs, function (args) {
2636
+ if (args.cancel) {
2637
+ eventArgs.cancel = true;
2638
+ return;
2639
+ }
2640
+ if (isFileSystemData(parent)) {
2641
+ if (!isFileExists(parent.fileSystemData, args.folderName)) {
2642
+ const data = args.parentFolder[0];
2643
+ const newObject = createNewItem(data, data, args.folderName, false);
2644
+ parent.fileSystemData.push(newObject);
2645
+ }
2646
+ else {
2647
+ const message = 'A file or folder with the name ' + args.folderName + ' already exists.';
2648
+ createErrorObject(parent, message, '400', null);
2649
+ }
2650
+ }
2651
+ });
2652
+ }
2653
+ /**
2654
+ * Function to trigger delete operation.
2655
+ *
2656
+ * @param {IFileManager} parent - specifies the parent element.
2657
+ * @param {Object} data - specifies the data.
2658
+ * @param {BeforeSendEventArgs} eventArgs - specifies the eventArgs.
2659
+ * @returns {void}
2660
+ * @private
2661
+ */
2662
+ function triggerDeleteOperation(parent, data, eventArgs) {
2663
+ const deleteEventArgs = {
2664
+ cancel: false,
2665
+ itemData: getValue('data', data),
2666
+ path: getValue('path', data)
2667
+ };
2668
+ parent.trigger('beforeDelete', deleteEventArgs, function (args) {
2669
+ if (args.cancel) {
2670
+ eventArgs.cancel = true;
2671
+ return;
2672
+ }
2673
+ if (isFileSystemData(parent)) {
2674
+ args.itemData.forEach((itemData) => {
2675
+ const index = findIndexById(parent, itemData.id);
2676
+ if (index !== -1) {
2677
+ parent.fileSystemData.splice(index, 1);
2678
+ }
2679
+ if (!itemData.isFile) {
2680
+ const subItems = parent.fileSystemData.filter(function (obj) { return obj.filterPath.includes(itemData.name); });
2681
+ subItems.forEach((subItem) => {
2682
+ const index = findIndexById(parent, subItem.id);
2683
+ if (index !== -1) {
2684
+ parent.fileSystemData.splice(index, 1);
2685
+ }
2686
+ });
2687
+ }
2688
+ });
2689
+ }
2690
+ });
2691
+ }
2692
+ /**
2693
+ * Function to trigger rename operation.
2694
+ *
2695
+ * @param {IFileManager} parent - specifies the parent element.
2696
+ * @param {Object} data - specifies the data.
2697
+ * @param {BeforeSendEventArgs} eventArgs - specifies the eventArgs.
2698
+ * @returns {void}
2699
+ * @private
2700
+ */
2701
+ function triggerRenameOperation(parent, data, eventArgs) {
2702
+ const renameEventArgs = {
2703
+ cancel: false,
2704
+ newName: getValue('newName', data),
2705
+ itemData: getValue('data', data),
2706
+ path: getValue('path', data)
2707
+ };
2708
+ parent.trigger('beforeRename', renameEventArgs, function (args) {
2709
+ if (args.cancel) {
2710
+ eventArgs.cancel = true;
2711
+ return;
2712
+ }
2713
+ if (isFileSystemData(parent)) {
2714
+ if (!isFileExists(parent.fileSystemData, args.newName)) {
2715
+ const fileData = filterById(parent, args.itemData[0].id);
2716
+ fileData.name = args.newName;
2717
+ }
2718
+ else {
2719
+ const message = 'Cannot rename' + args.itemData[0].name + 'to' + args.newName + ': destination already exists.';
2720
+ createErrorObject(parent, message, '400', null);
2721
+ }
2722
+ }
2723
+ });
2724
+ }
2725
+ /**
2726
+ * Function to trigger move or copy operation.
2727
+ *
2728
+ * @param {IFileManager} parent - specifies the parent element.
2729
+ * @param {Object} data - specifies the data.
2730
+ * @param {BeforeSendEventArgs} eventArgs - specifies the eventArgs.
2731
+ * @returns {void}
2732
+ * @private
2733
+ */
2734
+ function triggerMoveOrCopyOperation(parent, data, eventArgs) {
2735
+ const moveEventArgs = {
2736
+ cancel: false,
2737
+ itemData: getValue('data', data),
2738
+ isCopy: getValue('action', data) === 'copy' ? true : false,
2739
+ path: getValue('path', data),
2740
+ targetData: getValue('targetData', data),
2741
+ targetPath: getValue('targetPath', data)
2742
+ };
2743
+ parent.trigger('beforeMove', moveEventArgs, function (args) {
2744
+ if (args.cancel) {
2745
+ eventArgs.cancel = true;
2746
+ return;
2747
+ }
2748
+ if (isFileSystemData(parent)) {
2749
+ const message = 'File Already Exists';
2750
+ const action = getValue('action', data);
2751
+ const itemPermission = getAccessDetails(parent, args.itemData, action, false);
2752
+ const pathPermission = getAccessDetails(parent, [args.targetData], action, true);
2753
+ const file = [];
2754
+ parent.pasteNodes = [];
2755
+ if (itemPermission === '' && pathPermission === '') {
2756
+ if (args.isCopy) {
2757
+ const folderSubItems = filterByParent(parent, args.targetData.id);
2758
+ const copiedFolders = args.itemData;
2759
+ copiedFolders.forEach((itemData) => {
2760
+ if (!isFileExists(folderSubItems, itemData.name) || getValue('renameFiles', data).length > 0) {
2761
+ if (getValue('renameFiles', data).length > 0) {
2762
+ const names = itemData.name.split('.');
2763
+ const name = itemData.name.includes('.') ? names[0] + '(' + parent.existingFileCount + ').' + names[1] : names[0] + '(' + parent.existingFileCount + ')';
2764
+ copyFolderItems(parent, itemData, args.targetData, name);
2765
+ parent.responseData.error = null;
2766
+ parent.existingFileCount++;
2767
+ return;
2768
+ }
2769
+ copyFolderItems(parent, itemData, args.targetData, null);
2770
+ }
2771
+ else {
2772
+ file.push(itemData.name);
2773
+ }
2774
+ });
2775
+ if (file.length > 0) {
2776
+ createErrorObject(parent, message, '400', file);
2777
+ }
2778
+ return;
2779
+ }
2780
+ let target = args.targetData;
2781
+ const getTargetFiles = filterByParent(parent, target.id);
2782
+ for (let i = 0; i < args.itemData.length; i++) {
2783
+ const currItem = args.itemData[i];
2784
+ if (!isFileExists(getTargetFiles, currItem.name) || getValue('renameFiles', data).length > 0) {
2785
+ if (!target.hasChild) {
2786
+ target.hasChild = !currItem.isFile;
2787
+ }
2788
+ if (!currItem.isFile) {
2789
+ //Check whether the source folder include other sub folders or not.
2790
+ const subItems = currItem.parentId !== 0
2791
+ ? filterByParent(parent, currItem.parentID) : [];
2792
+ const itemData = filterById(parent, currItem.parentId);
2793
+ itemData.hasChild = subItems.length > 1 ? true : false;
2794
+ }
2795
+ const fileData = filterById(parent, currItem.id);
2796
+ if (getValue('renameFiles', data).length > 0) {
2797
+ const names = currItem.name.split('.');
2798
+ currItem.name = currItem.name.includes('.') ? names[0] + '(' + parent.existingFileCount + ').' + names[1] : names[0] + '(' + parent.existingFileCount + ')';
2799
+ fileData.name = currItem.name;
2800
+ parent.responseData.error = null;
2801
+ parent.existingFileCount++;
2802
+ parent.dropData = target;
2803
+ parent.dropPath = args.path;
2804
+ const pathArray = args.targetPath.replace(/^\/|\/$/g, '').split('/');
2805
+ target = filterById(parent, pathArray[pathArray.length - 1]);
2806
+ }
2807
+ fileData.parentId = target.id;
2808
+ fileData.filterPath = target.id === 0 ? '\\' : target.filterPath + target.name + '\\';
2809
+ }
2810
+ else {
2811
+ file.push(currItem.name);
2812
+ }
2813
+ }
2814
+ if (file.length > 0) {
2815
+ createErrorObject(parent, message, '400', file);
2816
+ }
2817
+ }
2818
+ }
2819
+ });
2820
+ }
2821
+ /**
2822
+ * Function to trigger search operation.
2823
+ *
2824
+ * @param {IFileManager} parent - specifies the parent element.
2825
+ * @param {Object} data - specifies the data.
2826
+ * @param {BeforeSendEventArgs} eventArgs - specifies the eventArgs.
2827
+ * @returns {void}
2828
+ * @private
2829
+ */
2830
+ function triggerSearchOperation(parent, data, eventArgs) {
2831
+ const searchEventArgs = {
2832
+ searchResults: getValue('data', data),
2833
+ cancel: false,
2834
+ path: getValue('path', data),
2835
+ searchText: getValue('searchString', data),
2836
+ caseSensitive: getValue('caseSensitive', data),
2837
+ showHiddenItems: getValue('showHiddenItems', data)
2838
+ };
2839
+ parent.trigger('search', searchEventArgs, function (args) {
2840
+ if (args.cancel) {
2841
+ eventArgs.cancel = true;
2842
+ }
2843
+ });
2844
+ }
2845
+ /**
2846
+ * Function to trigger client side events.
2847
+ *
2848
+ * @param {IFileManager} parent - specifies the parent element.
2849
+ * @param {Object} data - specifies the data.
2850
+ * @param {BeforeSendEventArgs} eventArgs - specifies the eventArgs.
2851
+ * @returns {void}
2852
+ * @private
2853
+ */
2854
+ function triggerClientEvents(parent, data, eventArgs) {
2855
+ switch (getValue('action', data)) {
2856
+ case 'create': {
2857
+ triggerFolderCreation(parent, data, eventArgs);
2858
+ break;
2859
+ }
2860
+ case 'delete': {
2861
+ triggerDeleteOperation(parent, data, eventArgs);
2862
+ break;
2863
+ }
2864
+ case 'rename': {
2865
+ triggerRenameOperation(parent, data, eventArgs);
2866
+ break;
2867
+ }
2868
+ case 'move':
2869
+ case 'copy': {
2870
+ triggerMoveOrCopyOperation(parent, data, eventArgs);
2871
+ break;
2872
+ }
2873
+ case 'search': {
2874
+ triggerSearchOperation(parent, data, eventArgs);
2875
+ break;
2876
+ }
2877
+ }
2878
+ }
2879
+ /**
2880
+ * Creates an AJAX request for the file manager.
2881
+ *
2882
+ * @param {IFileManager} parent - The parent file manager instance.
2883
+ * @param {Object} data - The data object for the AJAX request.
2884
+ * @param {Function} fn - The callback function to be executed after the AJAX request.
2885
+ * @param {string} [event] - The event type for the AJAX request.
2886
+ * @param {string} [operation] - The operation type for the AJAX request.
2887
+ * @param {string} [targetPath] - The target path for the AJAX request.
2888
+ * @returns {void}
2889
+ * @private
2890
+ */
2891
+ function createAjax(parent, data, fn, event, operation, targetPath) {
2473
2892
  const ajaxSettings = {
2474
2893
  url: parent.ajaxSettings.url,
2475
2894
  type: 'POST',
@@ -2482,9 +2901,64 @@ parent, data, fn, event, operation, targetPath) {
2482
2901
  beforeSend: null
2483
2902
  };
2484
2903
  const eventArgs = { action: getValue('action', data), ajaxSettings: ajaxSettings, cancel: false };
2904
+ triggerClientEvents(parent, data, eventArgs);
2485
2905
  parent.trigger('beforeSend', eventArgs, (beforeSendArgs) => {
2486
2906
  if (!beforeSendArgs.cancel) {
2487
2907
  parent.notify(beforeRequest, {});
2908
+ if (isFileSystemData(parent)) {
2909
+ const filePath = event === 'node-expand' || event === 'finalize-end' ? getValue('path', data) : parent.path;
2910
+ const pathArray = filePath.replace(/^\/|\/$/g, '').split('/');
2911
+ const idValue = event === 'rename-end-parent' || (event === 'path-changed' && getValue('data', data).length !== 0)
2912
+ || (event === 'paste-end' && (parent.targetModule === 'largeiconsview' || parent.targetModule === 'detailsview'))
2913
+ ? getValue('data', data)[0].id : pathArray[pathArray.length - 1];
2914
+ const action = getValue('action', data);
2915
+ const isFileOperation = (action === 'move' || action === 'rename' || action === 'copy' || action === 'delete' || action === 'search') && event !== 'rename-end';
2916
+ if (action === 'read' || action === 'create' || event === 'rename-end') {
2917
+ parent.responseData = {
2918
+ cwd: filterById(parent, parent.path === '/' && event !== 'node-expand' && event !== 'rename-end-parent' ? 0 : idValue),
2919
+ details: null,
2920
+ error: null,
2921
+ files: filterByParent(parent, parent.path === '/' && event !== 'node-expand' && event !== 'rename-end-parent' ? 0 : idValue)
2922
+ };
2923
+ if (isNullOrUndefined(parent.responseData.cwd)) {
2924
+ const message = 'Cannot load empty data within the File Manager.';
2925
+ createErrorObject(parent, message, '400', null);
2926
+ }
2927
+ }
2928
+ else if (isFileOperation && parent.responseData.error === null) {
2929
+ let itemData = action === 'search' || action === 'delete' ? getValue('data', data) : [];
2930
+ if (itemData.length === 0) {
2931
+ itemData = getValue('data', data).map((item) => filterById(parent, item.id));
2932
+ }
2933
+ parent.responseData = {
2934
+ cwd: null,
2935
+ details: null,
2936
+ error: null,
2937
+ files: itemData
2938
+ };
2939
+ }
2940
+ else if (getValue('action', data) === 'details') {
2941
+ const itemData = getValue('data', data);
2942
+ const details = itemData[0];
2943
+ const isMultipleFiles = itemData.length > 1;
2944
+ const itemNames = itemData.map((item) => item.name);
2945
+ const totalSize = isMultipleFiles ? getSize(itemData.reduce((accumulator, currentObject) => accumulator + (currentObject.size || 0), 0)) : getSize(details.size);
2946
+ const path = (parent.pathNames.includes(details.name) ? parent.pathNames.join('/') : parent.pathNames.join('/') + '/' + details.name);
2947
+ parent.responseData.details = Object.assign({
2948
+ location: isMultipleFiles ? null : path,
2949
+ multipleFiles: isMultipleFiles,
2950
+ name: itemNames.join(', '),
2951
+ size: totalSize
2952
+ }, isMultipleFiles ? {} : {
2953
+ created: details.dateCreated,
2954
+ isFile: details.isFile,
2955
+ modified: details.dateModified,
2956
+ permission: details.permission
2957
+ });
2958
+ }
2959
+ performReadOperation(parent, parent.responseData, fn, data, event, operation, targetPath, beforeSendArgs);
2960
+ return;
2961
+ }
2488
2962
  const ajax = new Ajax({
2489
2963
  url: getValue('url', beforeSendArgs.ajaxSettings),
2490
2964
  type: getValue('type', beforeSendArgs.ajaxSettings),
@@ -2509,61 +2983,7 @@ parent, data, fn, event, operation, targetPath) {
2509
2983
  if (typeof (result) === 'string') {
2510
2984
  result = JSON.parse(result);
2511
2985
  }
2512
- parent.notify(afterRequest, { action: 'success' });
2513
- const id = parent.expandedId ? parent.expandedId : parent.pathId[parent.pathId.length - 1];
2514
- if (!isNullOrUndefined(result.cwd) && (getValue('action', data) === 'read')) {
2515
- result.cwd.name = (parent.pathId.length === 1) ? (parent.rootAliasName || result.cwd.name) : result.cwd.name;
2516
- setValue('_fm_id', id, result.cwd);
2517
- setValue(id, result.cwd, parent.feParent);
2518
- if (!isNullOrUndefined(result.files) || result.error.code === '401') {
2519
- if ((event === 'finalize-end' || event === 'initial-end') && parent.pathNames.length === 0) {
2520
- // eslint-disable-next-line
2521
- const root = getValue(parent.pathId[0], parent.feParent);
2522
- parent.pathNames[0] = getValue('name', root);
2523
- parent.hasId = !isNullOrUndefined(getValue('id', root));
2524
- }
2525
- if (event === 'finalize-end') {
2526
- generatePath(parent);
2527
- }
2528
- }
2529
- }
2530
- const intl = new Internationalization(parent.locale);
2531
- if (!isNullOrUndefined(result.files)) {
2532
- setDateObject(result.files, intl, getDateFormat(parent));
2533
- for (let i = 0, len = result.files.length; i < len; i++) {
2534
- // eslint-disable-next-line
2535
- const item = result.files[i];
2536
- setValue('_fm_iconClass', fileType(item), item);
2537
- }
2538
- if (getValue('action', data) === 'read') {
2539
- setNodeId(result, id);
2540
- setValue(id, result.files, parent.feFiles);
2541
- }
2542
- }
2543
- if (!isNullOrUndefined(result.details) && !isNullOrUndefined(parent.rootAliasName)) {
2544
- const rootName = parent.rootAliasName || getValue('name', result.details);
2545
- let location = getValue('location', result.details).replace(new RegExp('/', 'g'), '\\');
2546
- if ((getValue('path', data) === '/') || (parent.hasId && getValue('path', data).match(/[/]/g).length === 1)) {
2547
- if (getValue('names', data).length === 0) {
2548
- setValue('name', rootName, result.details);
2549
- location = rootName;
2550
- }
2551
- else {
2552
- location = location.replace(location.substring(0, location.indexOf('\\')), rootName);
2553
- }
2554
- }
2555
- else {
2556
- location = location.replace(location.substring(0, location.indexOf('\\')), rootName);
2557
- }
2558
- setValue('location', location, result.details);
2559
- }
2560
- fn(parent, result, event, operation, targetPath);
2561
- if (!isNullOrUndefined(result.files) && (event === 'path-changed' || event === 'finalize-end' || event === 'open-end' || event === 'drop-path')) {
2562
- parent.notify(searchTextChange, result);
2563
- }
2564
- if (typeof getValue('onSuccess', beforeSendArgs.ajaxSettings) === 'function') {
2565
- getValue('onSuccess', beforeSendArgs.ajaxSettings)();
2566
- }
2986
+ performReadOperation(parent, result, fn, data, event, operation, targetPath, beforeSendArgs);
2567
2987
  },
2568
2988
  onFailure: () => {
2569
2989
  const result = {
@@ -2581,6 +3001,117 @@ parent, data, fn, event, operation, targetPath) {
2581
3001
  }
2582
3002
  });
2583
3003
  }
3004
+ /**
3005
+ * Function to get file size.
3006
+ *
3007
+ * @param {number} size - specifies the size.
3008
+ * @returns {string} - returns the size.
3009
+ * @private
3010
+ */
3011
+ function getSize(size) {
3012
+ let hz;
3013
+ if (size < 1024) {
3014
+ hz = size + ' B';
3015
+ }
3016
+ else if (size < 1024 * 1024) {
3017
+ hz = (size / 1024).toFixed(2) + ' KB';
3018
+ }
3019
+ else if (size < 1024 * 1024 * 1024) {
3020
+ hz = (size / 1024 / 1024).toFixed(2) + ' MB';
3021
+ }
3022
+ else {
3023
+ hz = (size / 1024 / 1024 / 1024).toFixed(2) + ' GB';
3024
+ }
3025
+ return hz;
3026
+ }
3027
+ /**
3028
+ * Function to perform read operation.
3029
+ *
3030
+ * @param {IFileManager} parent - specifies the parent element.
3031
+ * @param {ReadArgs} result - specifies the result.
3032
+ * @param {Function} fn - specifies the function.
3033
+ * @param {Object} data - specifies the data.
3034
+ * @param {string} event - specifies the event.
3035
+ * @param {string} operation - specifies the operation.
3036
+ * @param {string} targetPath - specifies the targetPath.
3037
+ * @param {BeforeSendEventArgs} beforeSendArgs - specifies the eventArgs.
3038
+ * @returns {void}
3039
+ * @private
3040
+ */
3041
+ function performReadOperation(parent, result, fn, data, event, operation, targetPath, beforeSendArgs) {
3042
+ parent.notify(afterRequest, { action: 'success' });
3043
+ const id = parent.expandedId ? parent.expandedId : parent.pathId[parent.pathId.length - 1];
3044
+ if (!isNullOrUndefined(result.cwd) && (getValue('action', data) === 'read')) {
3045
+ result.cwd.name = (parent.pathId.length === 1) ? (parent.rootAliasName || result.cwd.name) : result.cwd.name;
3046
+ setValue('_fm_id', id, result.cwd);
3047
+ setValue(id, result.cwd, parent.feParent);
3048
+ if (!isNullOrUndefined(result.files) || result.error.code === '401') {
3049
+ if ((event === 'finalize-end' || event === 'initial-end') && parent.pathNames.length === 0) {
3050
+ const root = getValue(parent.pathId[0], parent.feParent);
3051
+ parent.pathNames[0] = getValue('name', root);
3052
+ parent.hasId = !isNullOrUndefined(getValue('id', root));
3053
+ }
3054
+ if (event === 'finalize-end') {
3055
+ generatePath(parent);
3056
+ }
3057
+ }
3058
+ }
3059
+ const intl = new Internationalization(parent.locale);
3060
+ if (!isNullOrUndefined(result.files)) {
3061
+ setDateObject(result.files, intl, getDateFormat(parent));
3062
+ for (let i = 0, len = result.files.length; i < len; i++) {
3063
+ const item = result.files[i];
3064
+ setValue('_fm_iconClass', fileType(item), item);
3065
+ }
3066
+ if (getValue('action', data) === 'read' || isFileSystemData(parent) && getValue('action', data) === 'search') {
3067
+ setNodeId(result, id);
3068
+ setValue(id, result.files, parent.feFiles);
3069
+ }
3070
+ }
3071
+ if (!isNullOrUndefined(result.details) && !isNullOrUndefined(parent.rootAliasName)) {
3072
+ const rootName = parent.rootAliasName || getValue('name', result.details);
3073
+ let location = getValue('location', result.details).replace(new RegExp('/', 'g'), '\\');
3074
+ if ((getValue('path', data) === '/') || (parent.hasId && getValue('path', data).match(/[/]/g).length === 1)) {
3075
+ if (getValue('names', data).length === 0) {
3076
+ setValue('name', rootName, result.details);
3077
+ location = rootName;
3078
+ }
3079
+ else {
3080
+ location = location.replace(location.substring(0, location.indexOf('\\')), rootName);
3081
+ }
3082
+ }
3083
+ else {
3084
+ location = location.replace(location.substring(0, location.indexOf('\\')), rootName);
3085
+ }
3086
+ setValue('location', location, result.details);
3087
+ }
3088
+ fn(parent, result, event, operation, targetPath);
3089
+ if (!isNullOrUndefined(result.files) && (event === 'path-changed' || event === 'finalize-end' || event === 'open-end' || event === 'drop-path')) {
3090
+ parent.notify(searchTextChange, result);
3091
+ }
3092
+ if (typeof getValue('onSuccess', beforeSendArgs.ajaxSettings) === 'function') {
3093
+ getValue('onSuccess', beforeSendArgs.ajaxSettings)();
3094
+ }
3095
+ }
3096
+ /**
3097
+ * Function to copy operation.
3098
+ *
3099
+ * @param {IFileManager} parent - specifies the parent element.
3100
+ * @param {Object} data - specifies the data.
3101
+ * @param {string} target - specifies the target.
3102
+ * @param {string} itemName - specifies the item name.
3103
+ * @returns {void}
3104
+ * @private
3105
+ */
3106
+ function copyFolderItems(parent, data, target, itemName) {
3107
+ const newObject = createNewItem(data, target, itemName, true);
3108
+ parent.fileSystemData.push(newObject);
3109
+ parent.pasteNodes.push(newObject.id);
3110
+ const copiedItems = filterByParent(parent, data.id);
3111
+ for (let i = 0; i < copiedItems.length; i++) {
3112
+ copyFolderItems(parent, copiedItems[i], newObject, null);
3113
+ }
3114
+ }
2584
3115
  /**
2585
3116
  * Function for trigger Ajax failure in File Manager.
2586
3117
  *
@@ -2594,9 +3125,7 @@ parent, data, fn, event, operation, targetPath) {
2594
3125
  * @returns {void}
2595
3126
  * @private
2596
3127
  */
2597
- function triggerAjaxFailure(
2598
- // eslint-disable-next-line
2599
- parent, beforeSendArgs, fn, result, event, operation, targetPath) {
3128
+ function triggerAjaxFailure(parent, beforeSendArgs, fn, result, event, operation, targetPath) {
2600
3129
  parent.notify(afterRequest, { action: 'failure' });
2601
3130
  fn(parent, result, event, operation, targetPath);
2602
3131
  if (typeof getValue('onFailure', beforeSendArgs.ajaxSettings) === 'function') {
@@ -2672,8 +3201,14 @@ function createSuccess(parent, result, itemName) {
2672
3201
  if (parent.dialogObj && parent.dialogObj.visible) {
2673
3202
  parent.dialogObj.hide();
2674
3203
  }
2675
- parent.createdItem = result.files[0];
3204
+ parent.createdItem = isFileSystemData(parent) ? result.files[result.files.length - 1] : result.files[0];
2676
3205
  parent.breadcrumbbarModule.searchObj.value = '';
3206
+ const createEventArgs = {
3207
+ folderName: itemName,
3208
+ path: parent.path,
3209
+ parentFolder: parent.itemData
3210
+ };
3211
+ parent.trigger('folderCreate', createEventArgs);
2677
3212
  const args = { action: 'create', result: result };
2678
3213
  parent.trigger('success', args);
2679
3214
  parent.itemData = [getPathObject(parent)];
@@ -2714,11 +3249,10 @@ function createSuccess(parent, result, itemName) {
2714
3249
  *
2715
3250
  * @param {IFileManager} parent - specifies the parent element.
2716
3251
  * @param {ReadArgs} result - specifies the result.
2717
- * @param {string} path - specifies the path
2718
3252
  * @returns {void}
2719
3253
  * @private
2720
3254
  */
2721
- function renameSuccess(parent, result, path) {
3255
+ function renameSuccess(parent, result) {
2722
3256
  if (!isNullOrUndefined(result.files)) {
2723
3257
  if (!isNullOrUndefined(parent.dialogObj)) {
2724
3258
  parent.dialogObj.hide();
@@ -2726,15 +3260,22 @@ function renameSuccess(parent, result, path) {
2726
3260
  const args = { action: 'rename', result: result };
2727
3261
  parent.trigger('success', args);
2728
3262
  parent.renamedItem = Array.isArray(result.files) ? result.files[0] : result.files;
3263
+ const renameEventArgs = {
3264
+ newName: parent.renamedItem.name,
3265
+ itemData: parent.renamedItem,
3266
+ path: parent.path
3267
+ };
3268
+ parent.trigger('rename', renameEventArgs);
2729
3269
  if (parent.activeModule === 'navigationpane') {
2730
3270
  parent.pathId.pop();
2731
3271
  parent.itemData = [getValue(parent.pathId[parent.pathId.length - 1], parent.feParent)];
2732
3272
  read(parent, renameEndParent, getValue('filterPath', parent.renamedItem).replace(/\\/g, '/'));
2733
3273
  parent.itemData[0] = parent.renamedItem;
2734
- read(parent, pathChanged, parent.path === '/' ? parent.path : getValue('filterPath', parent.renamedItem).replace(/\\/g, '/') + parent.renamedItem.name + '/');
2735
3274
  if (getValue('filterPath', parent.renamedItem) === getValue('filterPath', parent.itemData[0]) && parent.pathNames.length > 1) {
2736
3275
  parent.pathNames[parent.pathNames.length - 1] = parent.renameText;
2737
3276
  }
3277
+ read(parent, pathChanged, parent.path === '/' ? parent.path : getValue('filterPath', parent.renamedItem).replace(/\\/g, '/') + parent.renamedItem.name + '/');
3278
+ parent.renamedItem = null;
2738
3279
  }
2739
3280
  else {
2740
3281
  parent.itemData = [getPathObject(parent)];
@@ -2780,6 +3321,14 @@ function renameSuccess(parent, result, path) {
2780
3321
  * @private
2781
3322
  */
2782
3323
  function pasteSuccess(parent, result, path, operation) {
3324
+ const moveorcopyEventArgs = {
3325
+ itemData: result.files,
3326
+ isCopy: operation === 'copy' ? true : false,
3327
+ path: path,
3328
+ targetData: parent.itemData[0],
3329
+ targetPath: parent.path
3330
+ };
3331
+ parent.trigger('move', moveorcopyEventArgs);
2783
3332
  if (result.error && result.error.fileExists) {
2784
3333
  parent.fileLength = 0;
2785
3334
  if (!isNullOrUndefined(result.files)) {
@@ -2814,6 +3363,11 @@ function pasteSuccess(parent, result, path, operation) {
2814
3363
  * @private
2815
3364
  */
2816
3365
  function deleteSuccess(parent, result, path) {
3366
+ const deleteEventArgs = {
3367
+ itemData: result.files,
3368
+ path: path
3369
+ };
3370
+ parent.trigger('delete', deleteEventArgs);
2817
3371
  if (!isNullOrUndefined(result.files)) {
2818
3372
  parent.setProperties({ path: path }, true);
2819
3373
  parent.itemData = [getPathObject(parent)];
@@ -2878,10 +3432,7 @@ function onFailure(parent, result, action) {
2878
3432
  * @returns {void}
2879
3433
  * @private
2880
3434
  */
2881
- function Search(
2882
- // eslint:disable-next-line
2883
- parent, event, path, searchString, showHiddenItems, caseSensitive) {
2884
- // eslint-disable-next-line
3435
+ function Search(parent, event, path, searchString, showHiddenItems, caseSensitive) {
2885
3436
  const data = {
2886
3437
  action: 'search', path: path, searchString: searchString, showHiddenItems: showHiddenItems, caseSensitive: caseSensitive,
2887
3438
  data: parent.itemData
@@ -2920,7 +3471,6 @@ function searchSuccess(parent, result, event) {
2920
3471
  */
2921
3472
  function Download(parent, path, items) {
2922
3473
  const downloadUrl = parent.ajaxSettings.downloadUrl ? parent.ajaxSettings.downloadUrl : parent.ajaxSettings.url;
2923
- // eslint-disable-next-line
2924
3474
  const data = { 'action': 'download', 'path': path, 'names': items, 'data': parent.itemData };
2925
3475
  const ajaxSettings = {
2926
3476
  url: downloadUrl,
@@ -2984,12 +3534,12 @@ function Download(parent, path, items) {
2984
3534
  const result = {
2985
3535
  error: {
2986
3536
  code: e.status.toString(),
2987
- message: getLocaleText(parent, 'Network-Error') + ' ' + parent.ajaxSettings.downloadUrl,
2988
- },
3537
+ message: getLocaleText(parent, 'Network-Error') + ' ' + parent.ajaxSettings.downloadUrl
3538
+ }
2989
3539
  };
2990
3540
  createDialog(parent, 'Error', result);
2991
3541
  parent.trigger('failure', downloadArgs);
2992
- },
3542
+ }
2993
3543
  });
2994
3544
  fetch.send(JSON.stringify(downloadArgs.data));
2995
3545
  }
@@ -3003,12 +3553,11 @@ function Download(parent, path, items) {
3003
3553
  * @param {string} text - specifies the text string.
3004
3554
  * @param {ReadArgs | SelectedEventArgs} e - specifies the type of event args.
3005
3555
  * @param {FileDetails} details - specifies the file details.
3006
- * @param {string[]} replaceItems - specifies the replacement.
3007
3556
  * @returns {void}
3008
3557
  * @private
3009
3558
  */
3010
- function createDialog(parent, text, e, details, replaceItems) {
3011
- const options = getOptions(parent, text, e, details, replaceItems);
3559
+ function createDialog(parent, text, e, details) {
3560
+ const options = getOptions(parent, text, e, details);
3012
3561
  if (isNullOrUndefined(parent.dialogObj)) {
3013
3562
  parent.dialogObj = new Dialog({
3014
3563
  beforeOpen: keydownAction.bind(this, parent, options.dialogName),
@@ -3529,11 +4078,10 @@ function createInput(ele, placeholder) {
3529
4078
  * @param {string} text - specifies the text string.
3530
4079
  * @param {ReadArgs | SelectedEventArgs} e - specifies the event arguements.
3531
4080
  * @param {FileDetails} details - specifies the file details.
3532
- * @param {string[]} replaceItems - specifies the replacement items.
3533
4081
  * @returns {DialogOptions} - specifies the dialog options.
3534
4082
  * @private
3535
4083
  */
3536
- function getOptions(parent, text, e, details, replaceItems) {
4084
+ function getOptions(parent, text, e, details) {
3537
4085
  const options = {
3538
4086
  header: '', content: '', buttons: [], dialogName: ''
3539
4087
  };
@@ -3541,11 +4089,12 @@ function getOptions(parent, text, e, details, replaceItems) {
3541
4089
  let formattedString;
3542
4090
  let intl;
3543
4091
  let strArr;
3544
- let fileType$$1;
4092
+ let fileType;
3545
4093
  let location;
3546
4094
  options.open = () => { triggerPopupOpen(parent, parent.dialogObj, options.dialogName); };
3547
4095
  options.close = () => { triggerPopupClose(parent, parent.dialogObj, options.dialogName); };
3548
4096
  text = (details && details.multipleFiles === true) ? 'MultipleFileDetails' : text;
4097
+ let index;
3549
4098
  switch (text) {
3550
4099
  case 'NewFolder':
3551
4100
  options.dialogName = 'Create Folder';
@@ -3578,7 +4127,7 @@ function getOptions(parent, text, e, details, replaceItems) {
3578
4127
  options.buttons = [
3579
4128
  {
3580
4129
  buttonModel: { isPrimary: true, content: getLocaleText(parent, 'Button-Yes') },
3581
- click: (e) => {
4130
+ click: () => {
3582
4131
  onDeleteSubmit(parent);
3583
4132
  }
3584
4133
  },
@@ -3630,31 +4179,30 @@ function getOptions(parent, text, e, details, replaceItems) {
3630
4179
  options.buttons = [
3631
4180
  {
3632
4181
  buttonModel: { isPrimary: true, content: getLocaleText(parent, 'Button-Ok') },
3633
- click: (e) => {
4182
+ click: () => {
3634
4183
  parent.dialogObj.hide();
3635
4184
  }
3636
4185
  }
3637
4186
  ];
3638
4187
  break;
3639
4188
  case 'MultipleFileDetails':
3640
- let index;
3641
4189
  options.dialogName = 'File Details';
3642
4190
  strArr = parent.itemData.map((val) => {
3643
4191
  index = val.name.indexOf('.') + 1;
3644
4192
  return (index === 0 && (!val.isFile)) ? 'Folder' : ((index !== 0) ? val.name.substr(index).replace(' ', '') : 'undetermined');
3645
4193
  });
3646
- if (strArr[0] == undefined) {
4194
+ if (strArr[0] === undefined) {
3647
4195
  strArr = details.name.split(',').map((val) => {
3648
4196
  index = val.indexOf('.') + 1;
3649
4197
  return (index === 0) ? 'Folder' : val.substr(index).replace(' ', '');
3650
4198
  });
3651
4199
  }
3652
- fileType$$1 = strArr.every((val, i, arr) => val === arr[0]) ?
4200
+ fileType = strArr.every((val, i, arr) => val === arr[0]) ?
3653
4201
  ((strArr[0] === 'Folder') ? 'Folder' : strArr[0].toLocaleUpperCase() + ' Type') : 'Multiple Types';
3654
4202
  location = details.location;
3655
4203
  options.header = details.name;
3656
4204
  options.content = '<table><tr><td>' + getLocaleText(parent, 'Type')
3657
- + ':</td><td class="' + VALUE + '">' + fileType$$1 + '</td></tr>' +
4205
+ + ':</td><td class="' + VALUE + '">' + fileType + '</td></tr>' +
3658
4206
  '<tr><td>' + getLocaleText(parent, 'Size') + ':</td><td>' +
3659
4207
  details.size + '<span class="' + VALUE + '" title ="' + details.size
3660
4208
  + '"></span></td></tr>' + '<tr><td>' + getLocaleText(parent, 'Location') +
@@ -3686,7 +4234,7 @@ function getOptions(parent, text, e, details, replaceItems) {
3686
4234
  options.buttons = [
3687
4235
  {
3688
4236
  buttonModel: { isPrimary: true, content: getLocaleText(parent, 'Button-Ok') },
3689
- click: (e) => {
4237
+ click: () => {
3690
4238
  parent.dialogObj.hide();
3691
4239
  }
3692
4240
  }
@@ -3980,10 +4528,6 @@ function updateImage(parent) {
3980
4528
  imgWrap.style.height = (content.offsetHeight - paddingHeight) + 'px';
3981
4529
  }
3982
4530
 
3983
- /**
3984
- * File Manager common operations
3985
- */
3986
-
3987
4531
  /**
3988
4532
  * LargeIconsView module
3989
4533
  */
@@ -4094,11 +4638,10 @@ class LargeIconsView {
4094
4638
  }
4095
4639
  this.parent.virtualizationModule.setUIVirtualization();
4096
4640
  }
4097
- // eslint-disable-next-line
4098
4641
  this.listElements = ListBase.createListFromJson(createElement, this.items, this.listObj);
4099
4642
  this.itemList = Array.prototype.slice.call(selectAll('.' + LIST_ITEM, this.listElements));
4100
4643
  this.element.appendChild(this.listElements);
4101
- this.listElements.setAttribute("aria-label", "listbox");
4644
+ this.listElements.setAttribute('aria-label', 'listbox');
4102
4645
  this.preventImgDrag();
4103
4646
  this.createDragObj();
4104
4647
  if (this.itemList.length === 0) {
@@ -4146,7 +4689,7 @@ class LargeIconsView {
4146
4689
  }
4147
4690
  }
4148
4691
  }
4149
- comparer(x, y, xObj, yObj) {
4692
+ comparer(x, y) {
4150
4693
  if (this.parent.sortOrder === 'Descending') {
4151
4694
  const z = x;
4152
4695
  x = y;
@@ -4154,7 +4697,6 @@ class LargeIconsView {
4154
4697
  }
4155
4698
  return this.parent.sortComparer(x, y);
4156
4699
  }
4157
- ;
4158
4700
  preventImgDrag() {
4159
4701
  let i = 0;
4160
4702
  while (i < this.itemList.length) {
@@ -4205,8 +4747,7 @@ class LargeIconsView {
4205
4747
  this.parent.activeElements = [];
4206
4748
  this.parent.dragData = [];
4207
4749
  for (let i = 0; i < activeEle.length; i++) {
4208
- // eslint-disable-next-line
4209
- this.parent.dragData.push(this.getItemObject(activeEle[i]));
4750
+ this.parent.dragData.push(this.getItemObject(activeEle[parseInt(i.toString(), 10)]));
4210
4751
  this.parent.activeElements.push(activeEle[i]);
4211
4752
  }
4212
4753
  getModule(this.parent, dragLi);
@@ -4217,10 +4758,8 @@ class LargeIconsView {
4217
4758
  onDropInit(args) {
4218
4759
  if (this.parent.targetModule === this.getModuleName()) {
4219
4760
  const dropLi = closest(args.target, '.e-list-item');
4220
- // eslint-disable-next-line
4221
4761
  const cwdData = getValue(this.parent.pathId[this.parent.pathId.length - 1], this.parent.feParent);
4222
4762
  if (dropLi) {
4223
- // eslint-disable-next-line
4224
4763
  const info = this.getItemObject(dropLi);
4225
4764
  this.parent.dropPath = info.isFile ? this.parent.path : getFullPath(this.parent, info, this.parent.path);
4226
4765
  this.parent.dropData = info.isFile ? cwdData : info;
@@ -4312,10 +4851,8 @@ class LargeIconsView {
4312
4851
  }
4313
4852
  }
4314
4853
  }
4315
- // eslint-disable-next-line
4316
4854
  renderList(args) {
4317
4855
  let i = 0;
4318
- // eslint-disable-next-line
4319
4856
  const items = JSON.parse(JSON.stringify(args.files));
4320
4857
  while (i < items.length) {
4321
4858
  const icon = fileType(items[i]);
@@ -4397,7 +4934,6 @@ class LargeIconsView {
4397
4934
  if (this.parent.renamedItem) {
4398
4935
  this.clearSelect();
4399
4936
  this.addSelection(this.parent.renamedItem);
4400
- this.parent.renamedItem = null;
4401
4937
  }
4402
4938
  }
4403
4939
  }
@@ -4539,7 +5075,6 @@ class LargeIconsView {
4539
5075
  this.parent.on(filterEnd, this.onPathChanged, this);
4540
5076
  }
4541
5077
  onActionFailure() { this.isInteraction = true; this.isInteracted = true; }
4542
- // eslint-disable-next-line
4543
5078
  onMenuItemData(args) {
4544
5079
  if (this.parent.activeModule === this.getModuleName()) {
4545
5080
  const ele = closest(args.target, 'li');
@@ -4677,37 +5212,35 @@ class LargeIconsView {
4677
5212
  }
4678
5213
  wireClickEvent(toBind) {
4679
5214
  if (toBind) {
4680
- // eslint-disable-next-line
4681
- const proxy = this;
4682
5215
  this.clickObj = new Touch(this.element, {
4683
5216
  tap: (eve) => {
4684
5217
  eve.originalEvent.preventDefault();
4685
- if (proxy.parent.isDevice) {
4686
- proxy.tapCount = eve.tapCount;
4687
- proxy.tapEvent = eve;
5218
+ if (this.parent.isDevice) {
5219
+ this.tapCount = eve.tapCount;
5220
+ this.tapEvent = eve;
4688
5221
  setTimeout(() => {
4689
- if (proxy.tapCount > 0) {
4690
- proxy.doTapAction(proxy.tapEvent);
5222
+ if (this.tapCount > 0) {
5223
+ this.doTapAction(this.tapEvent);
4691
5224
  }
4692
- proxy.tapCount = 0;
5225
+ this.tapCount = 0;
4693
5226
  }, 350);
4694
5227
  }
4695
5228
  else {
4696
5229
  if (eve.tapCount === 2 && eve.originalEvent.which !== 3) {
4697
- proxy.dblClickHandler(eve);
5230
+ this.dblClickHandler(eve);
4698
5231
  }
4699
5232
  else {
4700
- proxy.clickHandler(eve);
5233
+ this.clickHandler(eve);
4701
5234
  }
4702
5235
  }
4703
5236
  },
4704
5237
  tapHold: (e) => {
4705
- if (proxy.parent.isDevice) {
4706
- proxy.multiSelect = proxy.parent.allowMultiSelection ? true : false;
4707
- if (proxy.parent.allowMultiSelection) {
4708
- addClass([proxy.parent.element], MULTI_SELECT);
5238
+ if (this.parent.isDevice) {
5239
+ this.multiSelect = this.parent.allowMultiSelection ? true : false;
5240
+ if (this.parent.allowMultiSelection) {
5241
+ addClass([this.parent.element], MULTI_SELECT);
4709
5242
  }
4710
- proxy.clickHandler(e);
5243
+ this.clickHandler(e);
4711
5244
  }
4712
5245
  }
4713
5246
  });
@@ -4758,6 +5291,7 @@ class LargeIconsView {
4758
5291
  this.parent.isFile = false;
4759
5292
  let action = 'select';
4760
5293
  if (e.which === 3 && !isNullOrUndefined(item) && item.classList.contains(ACTIVE)) {
5294
+ this.addActive(item);
4761
5295
  this.updateType(item);
4762
5296
  return;
4763
5297
  }
@@ -4847,7 +5381,6 @@ class LargeIconsView {
4847
5381
  this.parent.isFile = false;
4848
5382
  if (!isNullOrUndefined(item)) {
4849
5383
  this.updateType(item);
4850
- // eslint-disable-next-line
4851
5384
  const details = this.getItemObject(item);
4852
5385
  if (!hasReadAccess(details)) {
4853
5386
  createDeniedDialog(this.parent, details, permissionRead);
@@ -4891,7 +5424,6 @@ class LargeIconsView {
4891
5424
  this.parent.isFile = isNullOrUndefined(folder) ? true : false;
4892
5425
  }
4893
5426
  /* istanbul ignore next */
4894
- // eslint:disable-next-line
4895
5427
  keydownActionHandler(e) {
4896
5428
  if (!this.isRendered) {
4897
5429
  return;
@@ -4935,12 +5467,9 @@ class LargeIconsView {
4935
5467
  case 'ctrlD':
4936
5468
  e.preventDefault();
4937
5469
  break;
4938
- default:
4939
- break;
4940
5470
  }
4941
5471
  }
4942
5472
  /* istanbul ignore next */
4943
- // eslint:disable-next-line
4944
5473
  keyActionHandler(e) {
4945
5474
  if (!this.isRendered) {
4946
5475
  return;
@@ -5075,7 +5604,6 @@ class LargeIconsView {
5075
5604
  performDelete() {
5076
5605
  if (this.parent.selectedItems && this.parent.selectedItems.length > 0) {
5077
5606
  this.updateSelectedData();
5078
- // eslint-disable-next-line
5079
5607
  const data = this.parent.itemData;
5080
5608
  for (let i = 0; i < data.length; i++) {
5081
5609
  if (!hasEditAccess(data[i])) {
@@ -5094,7 +5622,6 @@ class LargeIconsView {
5094
5622
  }
5095
5623
  updateRenameData() {
5096
5624
  const item = select('.' + LIST_ITEM + '.' + ACTIVE, this.element);
5097
- // eslint-disable-next-line
5098
5625
  const data = this.getItemObject(item);
5099
5626
  updateRenamingData(this.parent, data);
5100
5627
  }
@@ -5310,7 +5837,6 @@ class LargeIconsView {
5310
5837
  }
5311
5838
  }
5312
5839
  getDataName(item) {
5313
- // eslint-disable-next-line
5314
5840
  const data = this.getItemObject(item);
5315
5841
  return getItemName(this.parent, data);
5316
5842
  }
@@ -5383,7 +5909,6 @@ class LargeIconsView {
5383
5909
  this.perRow = perRow;
5384
5910
  }
5385
5911
  triggerSelection(action, item) {
5386
- // eslint-disable-next-line
5387
5912
  const data = [];
5388
5913
  if (this.isSelectAllCalled) {
5389
5914
  for (let i = 0, len = this.itemList.length; i < len; i++) {
@@ -5393,15 +5918,15 @@ class LargeIconsView {
5393
5918
  else {
5394
5919
  data[0] = this.getItemObject(item);
5395
5920
  }
5396
- const eventArgs = {
5397
- action: action, fileDetails: data.length > 1 ? data : data[0], isInteracted: this.isInteraction, cancel: false, target: this.isSelectAllCalled ? null : item
5921
+ const eventArgs = { action: action, fileDetails: data.length > 1
5922
+ ? data : data[0], isInteracted: this.isInteraction, cancel: false, target: this.isSelectAllCalled ? null
5923
+ : item
5398
5924
  };
5399
5925
  this.parent.trigger('fileSelection', eventArgs);
5400
5926
  this.isInteraction = true;
5401
5927
  return eventArgs;
5402
5928
  }
5403
5929
  triggerSelect(action, item) {
5404
- // eslint-disable-next-line
5405
5930
  const data = [];
5406
5931
  if (this.isSelectAllCalled) {
5407
5932
  for (let i = 0, len = this.itemList.length; i < len; i++) {
@@ -5413,7 +5938,9 @@ class LargeIconsView {
5413
5938
  data[0] = this.getItemObject(item);
5414
5939
  }
5415
5940
  this.parent.visitedData = data.length > 1 ? data[data.length - 1] : data[0];
5416
- const eventArgs = { action: action, fileDetails: data.length > 1 ? data : data[0], isInteracted: this.isInteracted };
5941
+ const eventArgs = { action: action, fileDetails: data.length > 1
5942
+ ? data
5943
+ : data[0], isInteracted: this.isInteracted };
5417
5944
  this.parent.trigger('fileSelect', eventArgs);
5418
5945
  this.isInteracted = true;
5419
5946
  }
@@ -5426,29 +5953,25 @@ class LargeIconsView {
5426
5953
  }
5427
5954
  getIndexes(items, byId) {
5428
5955
  const indexes = [];
5429
- const filter$$1 = byId ? 'id' : 'name';
5956
+ const filter = byId ? 'id' : 'name';
5430
5957
  for (let i = 0, len = this.items.length; i < len; i++) {
5431
- if (items.indexOf(getValue(filter$$1, this.items[i])) !== -1) {
5958
+ if (items.indexOf(getValue(filter, this.items[i])) !== -1) {
5432
5959
  indexes.push(i);
5433
5960
  }
5434
5961
  }
5435
5962
  return indexes;
5436
5963
  }
5437
- // eslint-disable-next-line
5438
5964
  getItemObject(item) {
5439
5965
  const index = this.itemList.indexOf(item);
5440
5966
  return this.items[index];
5441
5967
  }
5442
- // eslint-disable-next-line
5443
5968
  addSelection(data) {
5444
- // eslint-disable-next-line
5445
5969
  let resultData = [];
5446
5970
  if (this.parent.hasId) {
5447
5971
  resultData = new DataManager(this.items).
5448
5972
  executeLocal(new Query().where('id', 'equal', this.parent.renamedId, false));
5449
5973
  }
5450
5974
  else {
5451
- // eslint-disable-next-line
5452
5975
  const newData = new DataManager(this.items).
5453
5976
  executeLocal(new Query().where('name', 'equal', getValue('name', data), false));
5454
5977
  if (newData.length > 0) {
@@ -5463,7 +5986,6 @@ class LargeIconsView {
5463
5986
  }
5464
5987
  }
5465
5988
  updateSelectedData() {
5466
- // eslint-disable-next-line
5467
5989
  const data = [];
5468
5990
  const items = selectAll('.' + LIST_ITEM + '.' + ACTIVE, this.element);
5469
5991
  for (let i = 0; i < items.length; i++) {
@@ -5471,7 +5993,6 @@ class LargeIconsView {
5471
5993
  }
5472
5994
  this.parent.itemData = data;
5473
5995
  }
5474
- // eslint-disable-next-line
5475
5996
  onMethodCall(args) {
5476
5997
  if (this.parent.view !== 'LargeIcons') {
5477
5998
  return;
@@ -5539,7 +6060,6 @@ class LargeIconsView {
5539
6060
  if (indexes.length === 0) {
5540
6061
  return;
5541
6062
  }
5542
- // eslint-disable-next-line
5543
6063
  const data = [];
5544
6064
  const newIds = [];
5545
6065
  for (let i = 0; i < indexes.length; i++) {
@@ -5557,7 +6077,6 @@ class LargeIconsView {
5557
6077
  if (index.length === 0) {
5558
6078
  return;
5559
6079
  }
5560
- // eslint-disable-next-line
5561
6080
  const data = [];
5562
6081
  const newIds = [];
5563
6082
  for (let i = 0; i < index.length; i++) {
@@ -5733,8 +6252,8 @@ class BreadCrumbBar {
5733
6252
  });
5734
6253
  this.searchObj.appendTo('#' + this.parent.element.id + SEARCH_ID);
5735
6254
  this.searchEventBind(this.parent.searchSettings.allowSearchOnTyping);
5736
- const search$$1 = this.searchObj.element.nextElementSibling;
5737
- EventHandler.add(search$$1, 'mousedown', this.searchChangeHandler.bind(this), this);
6255
+ const search = this.searchObj.element.nextElementSibling;
6256
+ EventHandler.add(search, 'mousedown', this.searchChangeHandler.bind(this), this);
5738
6257
  EventHandler.add(this.searchObj.element, 'keyup', this.onKeyUp.bind(this), this);
5739
6258
  }
5740
6259
  const searchWrap = this.parent.breadCrumbBarNavigation.querySelector('.e-search-wrap');
@@ -5748,7 +6267,6 @@ class BreadCrumbBar {
5748
6267
  breadCrumbBarWidth = diff;
5749
6268
  }
5750
6269
  else {
5751
- // eslint-disable-next-line
5752
6270
  const items = [];
5753
6271
  for (let j = 0; j <= i; j++) {
5754
6272
  const liElement = liElements[j];
@@ -5758,7 +6276,6 @@ class BreadCrumbBar {
5758
6276
  });
5759
6277
  }
5760
6278
  const subMenuLi = this.parent.createElement('li', { className: 'e-breadcrumb-menu' });
5761
- // eslint-disable-next-line
5762
6279
  const attributes = { className: 'e-breadcrumb-submenu' };
5763
6280
  const subMenuSpan = this.parent.createElement('button', attributes);
5764
6281
  subMenuLi.appendChild(subMenuSpan);
@@ -5799,7 +6316,6 @@ class BreadCrumbBar {
5799
6316
  }
5800
6317
  /* istanbul ignore next */
5801
6318
  subMenuSelectOperations(event) {
5802
- // eslint-disable-next-line
5803
6319
  const args = { target: event.element };
5804
6320
  this.addressPathClickHandler(args);
5805
6321
  }
@@ -5846,7 +6362,6 @@ class BreadCrumbBar {
5846
6362
  }
5847
6363
  }
5848
6364
  }
5849
- // eslint-disable-next-line
5850
6365
  triggerFileOpen(data) {
5851
6366
  const eventArgs = { cancel: false, fileDetails: data, module: 'BreadCrumbBar' };
5852
6367
  delete eventArgs.cancel;
@@ -6003,7 +6518,7 @@ class BreadCrumbBar {
6003
6518
  /**
6004
6519
  * ContextMenu module
6005
6520
  */
6006
- class ContextMenu$2 {
6521
+ class ContextMenu {
6007
6522
  /**
6008
6523
  * Constructor for the ContextMenu module
6009
6524
  *
@@ -6023,7 +6538,7 @@ class ContextMenu$2 {
6023
6538
  downarrow: 'downarrow',
6024
6539
  uparrow: 'uparrown'
6025
6540
  };
6026
- this.contextMenu = new ContextMenu({
6541
+ this.contextMenu = new ContextMenu$1({
6027
6542
  enableRtl: this.parent.enableRtl,
6028
6543
  locale: this.parent.locale,
6029
6544
  target: '#' + this.parent.element.id,
@@ -6055,12 +6570,13 @@ class ContextMenu$2 {
6055
6570
  }
6056
6571
  onBeforeClose() {
6057
6572
  this.menuTarget = null;
6058
- if (!this.isMenuItemClicked && this.parent.pathId.length > 1 && this.parent.activeModule == 'navigationpane') {
6573
+ if (!this.isMenuItemClicked && this.parent.pathId.length > 1 && this.parent.activeModule === 'navigationpane') {
6059
6574
  this.parent.pathId.pop();
6060
6575
  const parentKey = [];
6061
6576
  const itemKeys = Object.keys(this.parent.feParent);
6062
6577
  for (const item of itemKeys) {
6063
- var itemData = getValue(item, this.parent.feParent);
6578
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
6579
+ const itemData = getValue(item, this.parent.feParent);
6064
6580
  if (this.parent.pathNames.indexOf(itemData.name) !== -1) {
6065
6581
  parentKey.push(itemData._fm_id);
6066
6582
  }
@@ -6074,7 +6590,6 @@ class ContextMenu$2 {
6074
6590
  onBeforeOpen(args) {
6075
6591
  let selected = false;
6076
6592
  let uid;
6077
- // eslint-disable-next-line
6078
6593
  let data;
6079
6594
  let treeFolder = false;
6080
6595
  let target = args.event.target;
@@ -6086,7 +6601,7 @@ class ContextMenu$2 {
6086
6601
  }
6087
6602
  this.targetElement = this.parent.view === 'Details' ? closest(target, 'tr.e-row') : target;
6088
6603
  if (this.parent.enableVirtualization && (target.classList.contains('e-virtual-bottom') || target.classList.contains('e-virtualtable'))) {
6089
- target = target.parentElement.closest("div");
6604
+ target = target.parentElement.closest('div');
6090
6605
  }
6091
6606
  const view = this.getTargetView(target);
6092
6607
  this.updateActiveModule();
@@ -6095,7 +6610,6 @@ class ContextMenu$2 {
6095
6610
  (closest(target, '#' + this.parent.element.id + BREADCRUMBBAR_ID)) ||
6096
6611
  (closest(target, '#' + this.parent.element.id + TOOLBAR_ID))) {
6097
6612
  args.cancel = true;
6098
- // eslint:disable-next-line
6099
6613
  }
6100
6614
  else if (!(this.parent.view === 'LargeIcons') && this.targetElement &&
6101
6615
  this.targetElement.classList.contains('e-emptyrow')) {
@@ -6104,24 +6618,20 @@ class ContextMenu$2 {
6104
6618
  }
6105
6619
  else if (closest(target, '.' + EMPTY)) {
6106
6620
  this.setLayoutItem(target);
6107
- // eslint:disable-next-line
6108
6621
  }
6109
6622
  else if (!target.classList.contains(MENU_ITEM) &&
6110
6623
  !target.classList.contains(MENU_ICON) && !target.classList.contains(SUBMENU_ICON)) {
6111
6624
  /* istanbul ignore next */
6112
- // eslint:disable-next-line
6113
6625
  if (this.parent.view === 'LargeIcons' && !isNullOrUndefined(closest(target, 'li')) && !closest(target, '#' + this.parent.element.id + TREE_ID)) {
6114
6626
  const eveArgs = { ctrlKey: true, shiftKey: true };
6115
6627
  if (!closest(target, 'li').classList.contains('e-active')) {
6116
6628
  this.parent.largeiconsviewModule.doSelection(target, eveArgs);
6117
6629
  }
6118
- // eslint-disable-next-line
6119
6630
  data = this.parent.visitedData;
6120
6631
  selected = true;
6121
6632
  }
6122
6633
  else if (!isNullOrUndefined(closest(target, 'tr.e-row'))) {
6123
6634
  uid = this.targetElement.getAttribute('data-uid');
6124
- // eslint-disable-next-line
6125
6635
  data = this.parent.detailsviewModule.gridObj.getRowObjectFromUID(uid).data;
6126
6636
  if (isNullOrUndefined(this.targetElement.getAttribute('aria-selected'))) {
6127
6637
  /* istanbul ignore next */
@@ -6149,8 +6659,17 @@ class ContextMenu$2 {
6149
6659
  if (uid === this.parent.pathId[0]) {
6150
6660
  this.disabledItems.push('Delete', 'Rename', 'Cut', 'Copy');
6151
6661
  }
6662
+ else {
6663
+ const itemsToRemove = ['Delete', 'Rename', 'Cut', 'Copy'];
6664
+ for (let i = 0; i < this.disabledItems.length; i++) {
6665
+ const item = this.disabledItems[i];
6666
+ if (itemsToRemove.indexOf(item) !== -1) {
6667
+ this.disabledItems.splice(i, 1);
6668
+ i--;
6669
+ }
6670
+ }
6671
+ }
6152
6672
  /* istanbul ignore next */
6153
- // eslint:disable-next-line
6154
6673
  }
6155
6674
  else if (view === 'TreeView' || view === 'GridView' || view === 'LargeIcon') {
6156
6675
  this.setLayoutItem(target);
@@ -6261,6 +6780,18 @@ class ContextMenu$2 {
6261
6780
  if (this.parent.pathNames[this.parent.pathNames.length - 1] === selectedTreeNode.querySelector('.e-list-text').innerHTML && this.parent.activeModule === 'navigationpane') {
6262
6781
  this.disabledItems.push('Open');
6263
6782
  }
6783
+ else {
6784
+ const indexToRemove = this.disabledItems.indexOf('Open');
6785
+ if (indexToRemove !== -1) {
6786
+ this.disabledItems.splice(indexToRemove, 1);
6787
+ }
6788
+ }
6789
+ if (this.parent.selectedItems.length === 0) {
6790
+ const renameIndex = this.disabledItems.indexOf('Rename');
6791
+ if (renameIndex !== -1) {
6792
+ this.disabledItems.splice(renameIndex, 1);
6793
+ }
6794
+ }
6264
6795
  }
6265
6796
  else if (this.parent.activeModule !== 'navigationpane') {
6266
6797
  if (this.parent.selectedItems.length === 1) {
@@ -6299,7 +6830,7 @@ class ContextMenu$2 {
6299
6830
  this.disabledItems.push('SelectAll');
6300
6831
  }
6301
6832
  else {
6302
- this.disabledItems = this.disabledItems.filter(item => item !== 'SelectAll');
6833
+ this.disabledItems = this.disabledItems.filter((item) => item !== 'SelectAll');
6303
6834
  }
6304
6835
  if (this.parent.selectedNodes.length === 0) {
6305
6836
  if (this.disabledItems.indexOf('Paste') === -1) {
@@ -6319,13 +6850,11 @@ class ContextMenu$2 {
6319
6850
  return -1;
6320
6851
  }
6321
6852
  }
6322
- // eslint-disable-next-line
6323
6853
  getMenuItemData() {
6324
6854
  if (this.menuType === 'layout') {
6325
6855
  return getPathObject(this.parent);
6326
6856
  }
6327
6857
  else {
6328
- // eslint-disable-next-line
6329
6858
  const args = { target: this.menuTarget };
6330
6859
  this.parent.notify(menuItemData, args);
6331
6860
  return this.parent.itemData[0];
@@ -6337,7 +6866,6 @@ class ContextMenu$2 {
6337
6866
  return;
6338
6867
  }
6339
6868
  const itemText = args.item.id.substr((this.parent.element.id + '_cm_').length);
6340
- // eslint-disable-next-line
6341
6869
  let details;
6342
6870
  if (itemText === 'refresh' || itemText === 'newfolder' || itemText === 'upload') {
6343
6871
  details = [getPathObject(this.parent)];
@@ -6362,7 +6890,6 @@ class ContextMenu$2 {
6362
6890
  let sItems;
6363
6891
  if (!menuClickArgs.cancel) {
6364
6892
  this.isMenuItemClicked = true;
6365
- // eslint:disable-next-line
6366
6893
  switch (itemText) {
6367
6894
  case 'cut':
6368
6895
  cutFiles(this.parent);
@@ -6450,19 +6977,10 @@ class ContextMenu$2 {
6450
6977
  case 'upload':
6451
6978
  uploadItem(this.parent);
6452
6979
  break;
6453
- /* istanbul ignore next */
6454
6980
  case 'name':
6455
- /* istanbul ignore next */
6456
- // eslint-disable-next-line no-fallthrough
6457
6981
  case 'size':
6458
- /* istanbul ignore next */
6459
- // eslint-disable-next-line no-fallthrough
6460
6982
  case 'date':
6461
- /* istanbul ignore next */
6462
- // eslint-disable-next-line no-fallthrough
6463
6983
  case 'ascending':
6464
- /* istanbul ignore next */
6465
- // eslint-disable-next-line no-fallthrough
6466
6984
  case 'descending':
6467
6985
  /* istanbul ignore next */
6468
6986
  sortbyClickHandler(this.parent, args);
@@ -6473,12 +6991,10 @@ class ContextMenu$2 {
6473
6991
  sortbyClickHandler(this.parent, args);
6474
6992
  break;
6475
6993
  /* istanbul ignore next */
6476
- // eslint:disable-next-line
6477
6994
  case 'largeiconsview':
6478
6995
  updateLayout(this.parent, 'LargeIcons');
6479
6996
  break;
6480
6997
  /* istanbul ignore next */
6481
- // eslint:disable-next-line
6482
6998
  case 'detailsview':
6483
6999
  updateLayout(this.parent, 'Details');
6484
7000
  break;
@@ -6650,7 +7166,6 @@ class ContextMenu$2 {
6650
7166
  /**
6651
7167
  * Specifies the default locale of FileManager component
6652
7168
  */
6653
- // eslint-disable-next-line
6654
7169
  const defaultLocale = {
6655
7170
  'NewFolder': 'New folder',
6656
7171
  'Upload': 'Upload',
@@ -6771,14 +7286,13 @@ var FileManager_1;
6771
7286
  let FileManager = FileManager_1 = class FileManager extends Component {
6772
7287
  constructor(options, element) {
6773
7288
  super(options, element);
6774
- // eslint-disable-next-line
6775
7289
  this.filterData = null;
6776
7290
  this.selectedNodes = [];
6777
7291
  this.duplicateItems = [];
6778
- // eslint-disable-next-line
6779
7292
  this.duplicateRecords = [];
6780
7293
  this.previousPath = [];
6781
7294
  this.nextPath = [];
7295
+ this.existingFileCount = 0;
6782
7296
  this.isLayoutChange = false;
6783
7297
  this.layoutSelectedItems = [];
6784
7298
  this.renamedId = null;
@@ -6800,11 +7314,9 @@ let FileManager = FileManager_1 = class FileManager extends Component {
6800
7314
  this.isOpened = false;
6801
7315
  this.isRetryOpened = false;
6802
7316
  this.isPathDrag = false;
6803
- // eslint-disable-next-line
6804
7317
  this.searchedItems = [];
6805
7318
  this.retryFiles = [];
6806
7319
  this.isApplySame = false;
6807
- // eslint-disable-next-line
6808
7320
  this.dragData = [];
6809
7321
  this.dragNodes = [];
6810
7322
  this.dragPath = '';
@@ -6814,13 +7326,12 @@ let FileManager = FileManager_1 = class FileManager extends Component {
6814
7326
  this.dragCursorPosition = { left: 44, top: 18 };
6815
7327
  this.isDropEnd = false;
6816
7328
  this.dragCount = 0;
6817
- // eslint-disable-next-line
6818
7329
  this.droppedObjects = [];
6819
7330
  this.uploadingCount = 0;
6820
7331
  this.uploadedCount = 0;
6821
- //Specifies whether the operating system is MAC or not
7332
+ //Specifies whether the operating system is MAC or not
6822
7333
  this.isMac = false;
6823
- FileManager_1.Inject(BreadCrumbBar, LargeIconsView, ContextMenu$2);
7334
+ FileManager_1.Inject(BreadCrumbBar, LargeIconsView, ContextMenu);
6824
7335
  }
6825
7336
  /**
6826
7337
  * Get component name.
@@ -7210,7 +7721,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7210
7721
  const data = JSON.stringify(getValue(this.pathId[this.pathId.length - 1], this.feParent));
7211
7722
  args.customFormData = [{ 'path': this.path }, { 'action': action }, { 'data': data }, { 'filename': args.fileData.name }];
7212
7723
  const uploadUrl = this.ajaxSettings.uploadUrl ? this.ajaxSettings.uploadUrl : this.ajaxSettings.url;
7213
- // eslint-disable-next-line
7214
7724
  const ajaxSettings = {
7215
7725
  url: uploadUrl,
7216
7726
  type: 'POST',
@@ -7226,7 +7736,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7226
7736
  this.trigger('beforeSend', this.uploadEventArgs, (uploadEventArgs) => {
7227
7737
  args.customFormData = JSON.parse(getValue('data', uploadEventArgs.ajaxSettings));
7228
7738
  args.cancel = uploadEventArgs.cancel;
7229
- // eslint-disable-next-line
7230
7739
  const eventArgs = {
7231
7740
  cancel: false,
7232
7741
  httpRequest: args.currentRequest
@@ -7263,7 +7772,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7263
7772
  }
7264
7773
  this.uploadingCount = args.filesData.length;
7265
7774
  this.uploadedCount = 0;
7266
- // eslint-disable-next-line
7267
7775
  const details = getPathObject(this);
7268
7776
  if (!hasUploadAccess(details)) {
7269
7777
  args.cancel = true;
@@ -7272,7 +7780,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7272
7780
  }
7273
7781
  this.uploadDialogObj.show();
7274
7782
  }
7275
- // eslint-disable-next-line
7276
7783
  onFileUploadSuccess(args) {
7277
7784
  this.uploadedCount = this.uploadedCount + args.count;
7278
7785
  if (this.uploadSettings.autoClose && (this.uploadingCount === this.uploadedCount)) {
@@ -7280,7 +7787,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7280
7787
  }
7281
7788
  }
7282
7789
  /* istanbul ignore next */
7283
- // eslint-disable-next-line
7284
7790
  onUploadSuccess(files) {
7285
7791
  const args = { action: 'Upload', result: files };
7286
7792
  this.trigger('success', args);
@@ -7292,9 +7798,7 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7292
7798
  }
7293
7799
  }
7294
7800
  /* istanbul ignore next */
7295
- // eslint-disable-next-line
7296
7801
  onUploadFailure(files) {
7297
- // eslint-disable-next-line
7298
7802
  const response = getValue('response', files);
7299
7803
  const statusText = getValue('statusText', response);
7300
7804
  if (statusText !== '') {
@@ -7378,7 +7882,7 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7378
7882
  break;
7379
7883
  case 'ctrlU':
7380
7884
  e.preventDefault();
7381
- if (this.toolbarSettings.items.indexOf('Upload') != -1) {
7885
+ if (this.toolbarSettings.items.indexOf('Upload') !== -1) {
7382
7886
  uploadEle = select('#' + this.element.id + UPLOAD_ID, this.element);
7383
7887
  uploadEle.click();
7384
7888
  }
@@ -7412,7 +7916,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7412
7916
  * @private
7413
7917
  */
7414
7918
  /* istanbul ignore next */
7415
- // eslint:disable-next-line
7416
7919
  onPropertyChanged(newProp, oldProp) {
7417
7920
  let height;
7418
7921
  for (const prop of Object.keys(newProp)) {
@@ -7544,6 +8047,10 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7544
8047
  this.viewerObj.target = newProp.popupTarget;
7545
8048
  }
7546
8049
  break;
8050
+ case 'fileSystemData':
8051
+ this.fileSystemData = newProp.fileSystemData;
8052
+ this.refresh();
8053
+ break;
7547
8054
  }
7548
8055
  }
7549
8056
  }
@@ -7629,7 +8136,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7629
8136
  */
7630
8137
  createFolder(name) {
7631
8138
  this.notify(methodCall, { action: 'createFolder' });
7632
- // eslint-disable-next-line
7633
8139
  const details = [getPathObject(this)];
7634
8140
  this.itemData = details;
7635
8141
  if (name) {
@@ -7752,7 +8258,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7752
8258
  *
7753
8259
  * @returns {void}
7754
8260
  */
7755
- // eslint-disable-next-line
7756
8261
  filterFiles(filterData) {
7757
8262
  this.filterData = filterData ? filterData : null;
7758
8263
  this.setProperties({ selectedItems: [] }, true);
@@ -7768,7 +8273,6 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7768
8273
  *
7769
8274
  * @returns {Object[]} - returns selected files.
7770
8275
  */
7771
- // eslint-disable-next-line
7772
8276
  getSelectedFiles() {
7773
8277
  this.notify(updateSelectionData, {});
7774
8278
  return this.itemData;
@@ -7840,11 +8344,18 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7840
8344
  * @returns {void}
7841
8345
  */
7842
8346
  uploadFiles() {
7843
- // eslint-disable-next-line
7844
8347
  const details = [getPathObject(this)];
7845
8348
  this.itemData = details;
7846
8349
  uploadItem(this);
7847
8350
  }
8351
+ /**
8352
+ * Specifies the method which must be invoked to programmatically close the dialog popup in the file manager.
8353
+ *
8354
+ * @returns {void}
8355
+ */
8356
+ closeDialog() {
8357
+ closePopup(this);
8358
+ }
7848
8359
  /**
7849
8360
  * Specifies the direction of FileManager
7850
8361
  *
@@ -7867,6 +8378,9 @@ let FileManager = FileManager_1 = class FileManager extends Component {
7867
8378
  __decorate$8([
7868
8379
  Complex({}, AjaxSettings)
7869
8380
  ], FileManager.prototype, "ajaxSettings", void 0);
8381
+ __decorate$8([
8382
+ Property([])
8383
+ ], FileManager.prototype, "fileSystemData", void 0);
7870
8384
  __decorate$8([
7871
8385
  Property(false)
7872
8386
  ], FileManager.prototype, "allowDragAndDrop", void 0);
@@ -7972,9 +8486,36 @@ __decorate$8([
7972
8486
  __decorate$8([
7973
8487
  Event()
7974
8488
  ], FileManager.prototype, "created", void 0);
8489
+ __decorate$8([
8490
+ Event()
8491
+ ], FileManager.prototype, "beforeFolderCreate", void 0);
8492
+ __decorate$8([
8493
+ Event()
8494
+ ], FileManager.prototype, "folderCreate", void 0);
7975
8495
  __decorate$8([
7976
8496
  Event()
7977
8497
  ], FileManager.prototype, "destroyed", void 0);
8498
+ __decorate$8([
8499
+ Event()
8500
+ ], FileManager.prototype, "beforeDelete", void 0);
8501
+ __decorate$8([
8502
+ Event()
8503
+ ], FileManager.prototype, "delete", void 0);
8504
+ __decorate$8([
8505
+ Event()
8506
+ ], FileManager.prototype, "beforeRename", void 0);
8507
+ __decorate$8([
8508
+ Event()
8509
+ ], FileManager.prototype, "rename", void 0);
8510
+ __decorate$8([
8511
+ Event()
8512
+ ], FileManager.prototype, "beforeMove", void 0);
8513
+ __decorate$8([
8514
+ Event()
8515
+ ], FileManager.prototype, "move", void 0);
8516
+ __decorate$8([
8517
+ Event()
8518
+ ], FileManager.prototype, "search", void 0);
7978
8519
  __decorate$8([
7979
8520
  Event()
7980
8521
  ], FileManager.prototype, "fileDragStart", void 0);
@@ -8024,15 +8565,11 @@ FileManager = FileManager_1 = __decorate$8([
8024
8565
  NotifyPropertyChanges
8025
8566
  ], FileManager);
8026
8567
 
8027
- /**
8028
- * File Manager base modules
8029
- */
8030
-
8031
8568
  /* eslint-disable @typescript-eslint/no-explicit-any */
8032
8569
  /**
8033
8570
  * Toolbar module
8034
8571
  */
8035
- class Toolbar$1 {
8572
+ class Toolbar {
8036
8573
  /**
8037
8574
  * Constructor for the Toolbar module
8038
8575
  *
@@ -8054,7 +8591,7 @@ class Toolbar$1 {
8054
8591
  const eventArgs = { items: this.items };
8055
8592
  this.parent.trigger('toolbarCreate', eventArgs, (toolbarCreateArgs) => {
8056
8593
  this.items = toolbarCreateArgs.items;
8057
- this.toolbarObj = new Toolbar({
8594
+ this.toolbarObj = new Toolbar$1({
8058
8595
  items: this.items,
8059
8596
  created: this.toolbarCreateHandler.bind(this),
8060
8597
  overflowMode: 'Popup',
@@ -8092,7 +8629,6 @@ class Toolbar$1 {
8092
8629
  return;
8093
8630
  }
8094
8631
  const tool = args.item.id.substr((this.parent.element.id + '_tb_').length);
8095
- // eslint-disable-next-line
8096
8632
  let details;
8097
8633
  if (tool === 'refresh' || tool === 'newfolder' || tool === 'upload') {
8098
8634
  details = [getPathObject(this.parent)];
@@ -8630,6 +9166,8 @@ class Virtualization {
8630
9166
  }
8631
9167
  /**
8632
9168
  * Sets up UI virtualization for the large icon view.
9169
+ *
9170
+ * @returns {void}
8633
9171
  */
8634
9172
  setUIVirtualization() {
8635
9173
  // Get the current view data source
@@ -8655,6 +9193,8 @@ class Virtualization {
8655
9193
  /**
8656
9194
  * Sets the height of the top and bottom elements that are used for virtualization.
8657
9195
  * These elements are used to give the appearance of an infinitely scrolling list.
9196
+ *
9197
+ * @returns {void}
8658
9198
  */
8659
9199
  setUlElementHeight() {
8660
9200
  // Calculate the number of items in the last row
@@ -8662,10 +9202,10 @@ class Virtualization {
8662
9202
  (this.largeIconInstance.allItems.length - this.itemCount) % this.rowItemCount : this.rowItemCount;
8663
9203
  // Create top and bottom elements
8664
9204
  this.topElement = this.filemanagerInstance.createElement('div');
8665
- this.topElement.classList.add("e-virtual-top");
9205
+ this.topElement.classList.add('e-virtual-top');
8666
9206
  this.largeIconInstance.element.firstElementChild.insertBefore(this.topElement, this.largeIconInstance.element.firstElementChild.firstChild);
8667
9207
  this.bottomElement = this.filemanagerInstance.createElement('div');
8668
- this.bottomElement.classList.add("e-virtual-bottom");
9208
+ this.bottomElement.classList.add('e-virtual-bottom');
8669
9209
  this.largeIconInstance.element.firstElementChild.insertBefore(this.bottomElement, null);
8670
9210
  // Get the margin value for list items
8671
9211
  const marginValue = parseInt(window.getComputedStyle(this.largeIconInstance.itemList[0]).getPropertyValue('margin-top'), 10) +
@@ -8687,17 +9227,21 @@ class Virtualization {
8687
9227
  }
8688
9228
  /**
8689
9229
  * Calculates the number of items to display in the list based on the available width and height.
8690
- * @param dataSourceLength The length of the data source.
8691
- * @returns The number of items to display.
9230
+ *
9231
+ * @param {number} dataSourceLength The length of the data source.
9232
+ * @returns {number} The number of items to display.
8692
9233
  */
8693
9234
  getItemCount(dataSourceLength) {
8694
9235
  // Get the margin values for list items
8695
9236
  const widthMargin = parseInt(window.getComputedStyle(this.itemList[0]).getPropertyValue('margin-right'), 10) +
8696
9237
  parseInt(window.getComputedStyle(this.itemList[0]).getPropertyValue('margin-left'), 10);
8697
9238
  // Calculate the number of items that can fit in a single row
8698
- this.rowItemCount = Math.floor(parseFloat(formatUnit(this.largeIconInstance.element.firstElementChild.clientWidth)) / (this.itemList[0].offsetWidth + widthMargin));
9239
+ this.rowItemCount =
9240
+ Math.floor(parseFloat(formatUnit(this.largeIconInstance.element.firstElementChild.clientWidth)) /
9241
+ (this.itemList[0].offsetWidth + widthMargin));
8699
9242
  // Calculate the number of items that can fit in the available height
8700
- let itemCount = this.rowItemCount * (Math.round(parseFloat(formatUnit(this.largeIconInstance.element.clientHeight)) / this.itemList[0].offsetHeight));
9243
+ let itemCount = this.rowItemCount *
9244
+ (Math.round(parseFloat(formatUnit(this.largeIconInstance.element.clientHeight)) / this.itemList[0].offsetHeight));
8701
9245
  // If the calculated item count is greater than the data source length, set the item count to the data source length
8702
9246
  if (itemCount > dataSourceLength) {
8703
9247
  itemCount = dataSourceLength;
@@ -8706,7 +9250,9 @@ class Virtualization {
8706
9250
  }
8707
9251
  /**
8708
9252
  * Wires or un wires the scroll event for the list element.
8709
- * @param destroy - Set `true` to unwire the scroll event.
9253
+ *
9254
+ * @param {boolean} destroy - Set `true` to unwire the scroll event.
9255
+ * @returns {void}
8710
9256
  */
8711
9257
  wireScrollEvent(destroy) {
8712
9258
  if (!destroy) {
@@ -8721,6 +9267,9 @@ class Virtualization {
8721
9267
  /**
8722
9268
  * Handles the scroll event for the list element.
8723
9269
  * This method updates the top and bottom elements and the displayed items based on the scroll position.
9270
+ *
9271
+ * @returns {void}
9272
+ * @private
8724
9273
  */
8725
9274
  onVirtualUiScroll() {
8726
9275
  // Set the starting height to 0
@@ -8757,14 +9306,17 @@ class Virtualization {
8757
9306
  this.scrollPosition = scroll;
8758
9307
  // Update the list of items and the items property of the largeIconInstance
8759
9308
  this.largeIconInstance.itemList = Array.prototype.slice.call(selectAll('.' + LIST_ITEM, this.largeIconInstance.element));
8760
- this.itemCount = this.itemCount != this.largeIconInstance.itemList.length ? this.largeIconInstance.itemList.length : this.itemCount;
9309
+ this.itemCount = this.itemCount !== this.largeIconInstance.itemList.length ?
9310
+ this.largeIconInstance.itemList.length : this.itemCount;
8761
9311
  this.largeIconInstance.items = this.largeIconInstance.allItems.slice(this.renderedCount -
8762
9312
  this.itemCount, this.renderedCount);
8763
9313
  }
8764
9314
  /**
8765
9315
  * Calculates the current scroll position of the list element.
8766
- * @param startingHeight The starting height from which to calculate the scroll position.
8767
- * @returns The current scroll position.
9316
+ *
9317
+ * @param {number} startingHeight The starting height from which to calculate the scroll position.
9318
+ * @returns {number} The current scroll position.
9319
+ * @private
8768
9320
  */
8769
9321
  getscrollerHeight(startingHeight) {
8770
9322
  // If the scroll position is less than or equal to the starting height, return 0.
@@ -8774,8 +9326,11 @@ class Virtualization {
8774
9326
  }
8775
9327
  /**
8776
9328
  * This method updates the displayed items and the selection based on the scroll direction.
8777
- * @param listDiff The number of rows to update.
8778
- * @param isScrollingDown If set to true, the scroll direction is downward.
9329
+ *
9330
+ * @param {number} listDiff The number of rows to update.
9331
+ * @param {boolean} isScrollingDown If set to true, the scroll direction is downward.
9332
+ * @returns {void}
9333
+ * @private
8779
9334
  */
8780
9335
  onNormalScroll(listDiff, isScrollingDown) {
8781
9336
  // Update the displayed items
@@ -8785,7 +9340,10 @@ class Virtualization {
8785
9340
  }
8786
9341
  /**
8787
9342
  * Updates the items in the large icons view.
8788
- * @param isScrollingDown If set to true, the scroll direction is downward.
9343
+ *
9344
+ * @param {boolean} isScrollingDown - If set to true, the scroll direction is downward.
9345
+ * @returns {void}
9346
+ * @private
8789
9347
  */
8790
9348
  updateUI(isScrollingDown) {
8791
9349
  if (isScrollingDown) {
@@ -8858,6 +9416,8 @@ class Virtualization {
8858
9416
  }
8859
9417
  /**
8860
9418
  * Destroys the component.
9419
+ *
9420
+ * @returns {void}
8861
9421
  */
8862
9422
  destroy() {
8863
9423
  // If the file manager has already been destroyed, return immediately
@@ -8871,10 +9431,6 @@ class Virtualization {
8871
9431
  }
8872
9432
  }
8873
9433
 
8874
- /**
8875
- * File Manager actions modules
8876
- */
8877
-
8878
9434
  /**
8879
9435
  * NavigationPane module
8880
9436
  */
@@ -8921,10 +9477,8 @@ class NavigationPane {
8921
9477
  if (!isNullOrUndefined(this.treeObj)) {
8922
9478
  return;
8923
9479
  }
8924
- // eslint-disable-next-line
8925
9480
  const rootData = getValue(this.parent.pathId[0], this.parent.feParent);
8926
9481
  setValue('_fm_icon', 'e-fe-folder', rootData);
8927
- // eslint-disable-next-line
8928
9482
  const attr = {};
8929
9483
  const id = getValue('id', rootData);
8930
9484
  if (!isNullOrUndefined(id)) {
@@ -8995,7 +9549,6 @@ class NavigationPane {
8995
9549
  this.parent.activeElements = [dragLi];
8996
9550
  this.parent.dragNodes = [];
8997
9551
  getModule(this.parent, dragLi);
8998
- // eslint-disable-next-line
8999
9552
  this.parent.dragData = this.getTreeData(dragLi);
9000
9553
  this.parent.dragPath = this.getDragPath(dragLi, this.parent.dragData[0].name);
9001
9554
  this.parent.dragNodes.push(this.parent.dragData[0].name);
@@ -9019,19 +9572,20 @@ class NavigationPane {
9019
9572
  };
9020
9573
  this.parent.trigger('fileLoad', eventArgs);
9021
9574
  }
9022
- // eslint-disable-next-line
9023
9575
  addChild(files, target, prevent) {
9024
- // eslint-disable-next-line
9025
9576
  const directories = getDirectories(files);
9026
- if (directories.length > 0 &&
9027
- (directories[0].filterPath == null || this.getTreeData(target)[0].filterPath == null || directories[0].filterPath !== this.getTreeData(target)[0].filterPath)) {
9577
+ const targetDirectory = this.getTreeData(target);
9578
+ if (directories.length > 0 && targetDirectory.length > 0 &&
9579
+ (directories[0].filterPath == null ||
9580
+ isNullOrUndefined(targetDirectory[0])
9581
+ && targetDirectory[0].filterPath == null
9582
+ || directories[0].filterPath !==
9583
+ targetDirectory[0].filterPath)) {
9028
9584
  let length = 0;
9029
- // eslint-disable-next-line
9030
9585
  const folders = directories;
9031
9586
  while (length < directories.length) {
9032
- // eslint-disable-next-line
9033
- folders[length]._fm_icon = 'e-fe-folder';
9034
- // eslint-disable-next-line
9587
+ // eslint-disable-next-line camelcase
9588
+ folders[parseInt(length.toString(), 10)]._fm_icon = 'e-fe-folder';
9035
9589
  const attr = {};
9036
9590
  const id = getValue('id', folders[length]);
9037
9591
  if (!isNullOrUndefined(id)) {
@@ -9048,21 +9602,20 @@ class NavigationPane {
9048
9602
  const element = select('[data-uid="' + target + '"]', this.treeObj.element);
9049
9603
  const childElements = select('ul', element);
9050
9604
  if (isNullOrUndefined(childElements)) {
9051
- // eslint-disable-next-line
9052
9605
  this.treeObj.addNodes(directories, target, null, prevent);
9053
9606
  }
9054
9607
  }
9055
9608
  }
9056
9609
  // Node Selecting event handler
9057
9610
  onNodeSelecting(args) {
9058
- if (!args.isInteracted && !this.isRightClick && !this.isSameNodeClicked && !this.isPathDragged && !this.isRenameParent || this.restrictSelecting) {
9611
+ if (!args.isInteracted && !this.isRightClick &&
9612
+ !this.isSameNodeClicked && !this.isPathDragged && !this.isRenameParent || this.restrictSelecting) {
9059
9613
  this.restrictSelecting = false;
9060
9614
  this.isNodeClickCalled = false;
9061
9615
  return;
9062
9616
  }
9063
9617
  if (!this.renameParent) {
9064
9618
  this.parent.activeModule = 'navigationpane';
9065
- // eslint-disable-next-line
9066
9619
  const nodeData = this.getTreeData(getValue('id', args.nodeData));
9067
9620
  if (args.node.getAttribute('data-uid') !== this.parent.pathId[this.parent.pathId.length - 1] && !this.isRightClick && !this.isNodeClickCalled || this.isSameNodeClicked) {
9068
9621
  this.isNodeClickCalled = false;
@@ -9081,7 +9634,7 @@ class NavigationPane {
9081
9634
  this.isNodeClickCalled = true;
9082
9635
  this.isSameNodeClicked = false;
9083
9636
  this.previousSelected = this.treeObj.selectedNodes;
9084
- this.treeObj.selectedNodes = [args.node.getAttribute("data-uid")];
9637
+ this.treeObj.selectedNodes = [args.node.getAttribute('data-uid')];
9085
9638
  }
9086
9639
  }
9087
9640
  else if (this.previousSelected[0] !== args.node.getAttribute('data-uid')) {
@@ -9093,7 +9646,6 @@ class NavigationPane {
9093
9646
  // Opens the folder while clicking open context menu item in the treeview.
9094
9647
  openFileOnContextMenuClick(node) {
9095
9648
  const data = this.treeObj.getTreeData(node);
9096
- // eslint-disable-next-line
9097
9649
  this.parent.selectedItems = [];
9098
9650
  this.parent.itemData = data;
9099
9651
  this.activeNode = node;
@@ -9122,7 +9674,6 @@ class NavigationPane {
9122
9674
  }
9123
9675
  this.activeNode = args.node;
9124
9676
  this.parent.activeModule = 'navigationpane';
9125
- // eslint-disable-next-line
9126
9677
  const nodeData = this.getTreeData(getValue('id', args.nodeData));
9127
9678
  this.parent.selectedItems = [];
9128
9679
  this.parent.itemData = nodeData;
@@ -9147,7 +9698,6 @@ class NavigationPane {
9147
9698
  this.isPathDragged = this.isRenameParent = this.isRightClick = this.isSameNodeClicked = false;
9148
9699
  }
9149
9700
  /* istanbul ignore next */
9150
- // eslint-disable-next-line
9151
9701
  onPathDrag(args) {
9152
9702
  this.isPathDragged = true;
9153
9703
  this.selectResultNode(args[0]);
@@ -9158,6 +9708,7 @@ class NavigationPane {
9158
9708
  return;
9159
9709
  }
9160
9710
  if (args.node.querySelector('.' + LIST_ITEM) === null) {
9711
+ this.isNodeExpandCalled = true;
9161
9712
  const text = getValue('text', args.nodeData);
9162
9713
  const id = args.node.getAttribute('data-id');
9163
9714
  const isId = isNullOrUndefined(id) ? false : true;
@@ -9168,7 +9719,6 @@ class NavigationPane {
9168
9719
  this.parent.itemData = this.getTreeData(getValue('id', args.nodeData));
9169
9720
  this.parent.pathId.push(getValue('id', args.nodeData));
9170
9721
  read(this.parent, nodeExpand, path);
9171
- this.isNodeExpandCalled = true;
9172
9722
  }
9173
9723
  }
9174
9724
  /* istanbul ignore next */
@@ -9208,7 +9758,6 @@ class NavigationPane {
9208
9758
  }
9209
9759
  onPathChanged(args) {
9210
9760
  this.parent.isCut = false;
9211
- // eslint-disable-next-line
9212
9761
  const currFiles = getValue(this.parent.pathId[this.parent.pathId.length - 1], this.parent.feFiles);
9213
9762
  if (this.expandNodeTarget === 'add') {
9214
9763
  const sNode = select('[data-uid="' + this.treeObj.selectedNodes[0] + '"]', this.treeObj.element);
@@ -9313,14 +9862,12 @@ class NavigationPane {
9313
9862
  this.renameParent = null;
9314
9863
  }
9315
9864
  else {
9316
- // eslint-disable-next-line
9317
9865
  let resultData = [];
9318
9866
  if (this.parent.hasId) {
9319
9867
  resultData = new DataManager(this.treeObj.getTreeData()).
9320
9868
  executeLocal(new Query().where('id', 'equal', this.parent.renamedId, false));
9321
9869
  }
9322
9870
  else {
9323
- // eslint-disable-next-line
9324
9871
  const nData = new DataManager(this.treeObj.getTreeData()).
9325
9872
  executeLocal(new Query().where(this.treeObj.fields.text, 'equal', this.parent.renameText, false));
9326
9873
  if (nData.length > 0) {
@@ -9341,16 +9888,13 @@ class NavigationPane {
9341
9888
  this.updateTree(args);
9342
9889
  }
9343
9890
  else {
9344
- // eslint-disable-next-line
9345
9891
  const data = this.treeObj.getTreeData();
9346
- // eslint-disable-next-line
9347
9892
  let resultData = [];
9348
9893
  if (this.parent.hasId) {
9349
9894
  resultData = new DataManager(data).
9350
9895
  executeLocal(new Query().where('id', 'equal', this.parent.renamedId, false));
9351
9896
  }
9352
9897
  else {
9353
- // eslint-disable-next-line
9354
9898
  const nData = new DataManager(data).
9355
9899
  executeLocal(new Query().where(this.treeObj.fields.text, 'equal', this.parent.currentItemText, false));
9356
9900
  if (nData.length > 0) {
@@ -9405,7 +9949,6 @@ class NavigationPane {
9405
9949
  }
9406
9950
  this.treeObj.removeNodes(moveNames);
9407
9951
  }
9408
- // eslint-disable-next-line
9409
9952
  getMoveNames(files, flag, path) {
9410
9953
  const moveNames = [];
9411
9954
  for (let i = 0; i < files.length; i++) {
@@ -9418,7 +9961,6 @@ class NavigationPane {
9418
9961
  name = path.substring(index + 1);
9419
9962
  path = path.substring(0, index + 1);
9420
9963
  }
9421
- // eslint-disable-next-line
9422
9964
  const resultData = new DataManager(this.treeObj.getTreeData()).
9423
9965
  executeLocal(new Query().where(this.treeObj.fields.text, 'equal', name, false));
9424
9966
  for (let j = 0; j < resultData.length; j++) {
@@ -9445,16 +9987,13 @@ class NavigationPane {
9445
9987
  this.treeObj.removeNodes(moveNames);
9446
9988
  }
9447
9989
  /* istanbul ignore next */
9448
- // eslint-disable-next-line
9449
9990
  selectResultNode(resultObj) {
9450
9991
  if (!this.parent.hasId) {
9451
9992
  const path = getValue('filterPath', resultObj);
9452
9993
  const itemname = getValue('name', resultObj);
9453
- // eslint-disable-next-line
9454
9994
  const data = new DataManager(this.treeObj.getTreeData()).
9455
9995
  executeLocal(new Query().where(this.treeObj.fields.text, 'equal', itemname, false));
9456
9996
  if (data.length > 0) {
9457
- // eslint-disable-next-line
9458
9997
  const resultData = new DataManager(data).
9459
9998
  executeLocal(new Query().where('filterPath', 'equal', path, false));
9460
9999
  if (resultData.length > 0) {
@@ -9476,14 +10015,12 @@ class NavigationPane {
9476
10015
  this.parent.isDropEnd = !this.parent.isPasteError;
9477
10016
  }
9478
10017
  onpasteEnd(args) {
9479
- // eslint-disable-next-line
9480
10018
  let resultData = [];
9481
10019
  if (this.parent.hasId) {
9482
10020
  resultData = new DataManager(this.treeObj.getTreeData()).
9483
10021
  executeLocal(new Query().where('id', 'equal', getValue('id', args.cwd), false));
9484
10022
  }
9485
10023
  else {
9486
- // eslint-disable-next-line
9487
10024
  const nData = new DataManager(this.treeObj.getTreeData()).
9488
10025
  executeLocal(new Query().where(this.treeObj.fields.text, 'equal', getValue('name', args.cwd), false));
9489
10026
  if (nData.length > 0) {
@@ -9505,6 +10042,9 @@ class NavigationPane {
9505
10042
  }
9506
10043
  /* istanbul ignore next */
9507
10044
  checkDropPath(args) {
10045
+ if (isFileSystemData(this.parent) && this.parent.path === this.parent.dropPath || this.parent.targetModule === 'navigationpane') {
10046
+ return;
10047
+ }
9508
10048
  if (this.parent.hasId) {
9509
10049
  this.parent.isDropEnd = !this.parent.isPasteError;
9510
10050
  readDropPath(this.parent);
@@ -9523,8 +10063,7 @@ class NavigationPane {
9523
10063
  this.updateItemData();
9524
10064
  }
9525
10065
  this.moveNames = [];
9526
- // eslint-disable-next-line
9527
- const obj = this.parent.isDragDrop ? this.parent.dragData : this.parent.actionRecords;
10066
+ const obj = this.parent.isDragDrop || isFileSystemData(this.parent) ? this.parent.dragData : this.parent.actionRecords;
9528
10067
  for (let i = 0; i < obj.length; i++) {
9529
10068
  if (getValue('isFile', obj[i]) === false) {
9530
10069
  this.moveNames.push(getValue('_fm_id', obj[i]));
@@ -9604,12 +10143,10 @@ class NavigationPane {
9604
10143
  /* istanbul ignore next */
9605
10144
  onDetailsInit() {
9606
10145
  if (this.parent.activeModule === this.getModuleName()) {
9607
- // eslint-disable-next-line
9608
10146
  const dataobj = this.getTreeData(this.treeObj.selectedNodes[0]);
9609
10147
  this.parent.itemData = dataobj;
9610
10148
  }
9611
10149
  }
9612
- // eslint-disable-next-line
9613
10150
  onMenuItemData(args) {
9614
10151
  if (this.parent.activeModule === this.getModuleName()) {
9615
10152
  const liEle = closest(args.target, 'li');
@@ -9707,7 +10244,6 @@ class NavigationPane {
9707
10244
  break;
9708
10245
  case 'f2':
9709
10246
  if (this.parent.selectedItems.length === 0) {
9710
- // eslint-disable-next-line
9711
10247
  const data = this.getTreeData(this.treeObj.selectedNodes[0])[0];
9712
10248
  if (!hasEditAccess(data)) {
9713
10249
  createDeniedDialog(this.parent, data, permissionEdit);
@@ -9720,9 +10256,7 @@ class NavigationPane {
9720
10256
  break;
9721
10257
  }
9722
10258
  }
9723
- // eslint-disable-next-line
9724
10259
  getTreeData(args) {
9725
- // eslint-disable-next-line
9726
10260
  const data = this.treeObj.getTreeData(args);
9727
10261
  for (let i = 0; i < data.length; i++) {
9728
10262
  if (isNullOrUndefined(getValue('hasChild', data[i]))) {
@@ -9736,7 +10270,6 @@ class NavigationPane {
9736
10270
  this.parent.currentItemText = getValue('name', this.parent.itemData[0]);
9737
10271
  }
9738
10272
  updateItemData() {
9739
- // eslint-disable-next-line
9740
10273
  const data = this.getTreeData(this.treeObj.selectedNodes[0])[0];
9741
10274
  this.parent.itemData = [data];
9742
10275
  this.parent.isFile = false;
@@ -9757,6 +10290,7 @@ class NavigationPane {
9757
10290
  }
9758
10291
  }
9759
10292
 
10293
+ /* eslint-disable @typescript-eslint/no-explicit-any */
9760
10294
  /**
9761
10295
  * DetailsView module
9762
10296
  */
@@ -9783,7 +10317,7 @@ class DetailsView {
9783
10317
  this.isNameWidth = false;
9784
10318
  this.pasteOperation = false;
9785
10319
  this.uploadOperation = false;
9786
- Grid.Inject(Resize, ContextMenu$1, Sort, VirtualScroll);
10320
+ Grid.Inject(Resize, ContextMenu$2, Sort, VirtualScroll);
9787
10321
  this.parent = parent;
9788
10322
  this.element = select('#' + this.parent.element.id + GRID_ID, this.parent.element);
9789
10323
  this.addEventListener();
@@ -9830,7 +10364,6 @@ class DetailsView {
9830
10364
  showSpinner(this.parent.element);
9831
10365
  if (this.parent.view === 'Details') {
9832
10366
  removeClass([this.parent.element], MULTI_SELECT);
9833
- // eslint-disable-next-line
9834
10367
  const items = getSortedData(this.parent, args.files);
9835
10368
  this.checkNameWidth();
9836
10369
  const columns = this.getColumns();
@@ -9871,8 +10404,7 @@ class DetailsView {
9871
10404
  width: '100%',
9872
10405
  height: (this.parent.enableVirtualization) ? this.getGridHeight() : 'auto',
9873
10406
  beforeCopy: (args) => { args.cancel = true; },
9874
- // eslint-disable-next-line
9875
- load: function (args) {
10407
+ load: function () {
9876
10408
  this.focusModule.destroy();
9877
10409
  },
9878
10410
  locale: this.parent.locale
@@ -9890,18 +10422,18 @@ class DetailsView {
9890
10422
  }
9891
10423
  }
9892
10424
  reactTemplateRender(args) {
9893
- this.parent[`portals`] = args;
10425
+ this.parent['portals'] = args;
9894
10426
  if (this.parent.portals && this.parent.toolbarModule && this.parent.toolbarModule.toolbarObj &&
9895
10427
  this.parent.toolbarModule.toolbarObj.portals) {
9896
- this.parent[`portals`] = this.parent[`portals`].concat(this.parent.toolbarModule.toolbarObj.portals);
10428
+ this.parent['portals'] = this.parent['portals'].concat(this.parent.toolbarModule.toolbarObj.portals);
9897
10429
  }
9898
- this.parent.notify('renderReactTemplate', this.parent[`portals`]);
9899
- this.parent[`renderReactTemplates`]();
10430
+ this.parent.notify('renderReactTemplate', this.parent['portals']);
10431
+ this.parent['renderReactTemplates']();
9900
10432
  }
9901
10433
  /**
9902
10434
  * Gets the grid height.
9903
10435
  *
9904
- * @returns The grid height.
10436
+ * @returns {number} - The grid height.
9905
10437
  * @private
9906
10438
  */
9907
10439
  getGridHeight() {
@@ -9942,7 +10474,7 @@ class DetailsView {
9942
10474
  }
9943
10475
  getColumns() {
9944
10476
  let columns;
9945
- let enableHtmlSanitizer = this.parent.enableHtmlSanitizer;
10477
+ const enableHtmlSanitizer = this.parent.enableHtmlSanitizer;
9946
10478
  if (this.parent.isMobile) {
9947
10479
  columns = [
9948
10480
  {
@@ -9975,7 +10507,7 @@ class DetailsView {
9975
10507
  return `<span class="e-fe-icon ${data._fm_iconClass}"></span>`;
9976
10508
  }), allowResizing: false, allowSorting: true, customAttributes: { class: 'e-fe-grid-icon' },
9977
10509
  headerTemplate: initializeCSPTemplate(function () {
9978
- return `<span class="e-fe-icon e-fe-folder"></span>`;
10510
+ return '<span class=\'e-fe-icon e-fe-folder\'></span>';
9979
10511
  })
9980
10512
  };
9981
10513
  columns.unshift(icon);
@@ -10034,7 +10566,8 @@ class DetailsView {
10034
10566
  }
10035
10567
  }
10036
10568
  if (!this.parent.showFileExtension && getValue('isFile', args.data)) {
10037
- const textEle = args.row.querySelector('.e-fe-text');
10569
+ const text = getValue('name', args.data);
10570
+ const textEle = args.row.querySelector('[title= "' + text + '"]');
10038
10571
  if (textEle) {
10039
10572
  const name = getValue('name', args.data);
10040
10573
  const type = getValue('type', args.data);
@@ -10068,7 +10601,6 @@ class DetailsView {
10068
10601
  const dateEle = args.row.querySelector('.e-fe-date');
10069
10602
  const intl = new Internationalization(this.parent.locale);
10070
10603
  const columns = this.parent.detailsViewSettings.columns;
10071
- // eslint-disable-next-line
10072
10604
  let format;
10073
10605
  for (let i = 0; i < columns.length; i++) {
10074
10606
  if (columns[i].field === 'dateModified') {
@@ -10104,7 +10636,6 @@ class DetailsView {
10104
10636
  let len = rows.length;
10105
10637
  this.sortSelectedNodes = [];
10106
10638
  while (len > 0) {
10107
- // eslint-disable-next-line
10108
10639
  const data = this.gridObj.getRowsObject()[rows[len - 1]].data;
10109
10640
  this.sortSelectedNodes.push(getValue(this.parent.hasId ? 'id' : 'name', data));
10110
10641
  len--;
@@ -10121,10 +10652,11 @@ class DetailsView {
10121
10652
  }
10122
10653
  onBeforeDataBound(args) {
10123
10654
  showSpinner(this.parent.element);
10124
- let nameColumn = this.parent.detailsViewSettings.columns.find((column) => column.field === this.parent.sortBy);
10655
+ const nameColumn = this.parent.detailsViewSettings.columns.find((column) => column.field === this.parent.sortBy);
10125
10656
  if (nameColumn && !('sortComparer' in nameColumn)) {
10126
- // eslint-disable-next-line
10127
- const items = getSortedData(this.parent, (this.parent.enableVirtualization) ? args.result : this.gridObj.dataSource);
10657
+ const items = getSortedData(this.parent, (this.parent.enableVirtualization)
10658
+ ? args.result
10659
+ : this.gridObj.dataSource);
10128
10660
  args.result = items;
10129
10661
  }
10130
10662
  }
@@ -10133,7 +10665,7 @@ class DetailsView {
10133
10665
  this.createDragObj();
10134
10666
  if ((this.parent.selectedItems.length !== 0 && !this.parent.enableVirtualization) ||
10135
10667
  ((this.parent.selectedItems.length !== 0 && this.parent.enableVirtualization &&
10136
- this.element.querySelector('.e-content').scrollTop == 0))) {
10668
+ this.element.querySelector('.e-content').scrollTop === 0))) {
10137
10669
  this.selectRecords(this.parent.selectedItems);
10138
10670
  }
10139
10671
  if (this.isPasteOperation === true) {
@@ -10206,7 +10738,6 @@ class DetailsView {
10206
10738
  this.isLoaded = false;
10207
10739
  }
10208
10740
  selectRecords(nodes) {
10209
- // eslint-disable-next-line
10210
10741
  const gridRecords = this.gridObj.getCurrentViewRecords();
10211
10742
  const sRecords = [];
10212
10743
  for (let i = 0, len = gridRecords.length; i < len; i++) {
@@ -10214,7 +10745,7 @@ class DetailsView {
10214
10745
  if (nodes.indexOf(node) !== -1) {
10215
10746
  sRecords.push(i);
10216
10747
  }
10217
- else if (!this.parent.showFileExtension && node.includes('.')) {
10748
+ else if (!this.parent.showFileExtension && !this.parent.hasId && node.includes('.')) {
10218
10749
  const Str2 = node.split('.').slice(0, -1).join('.');
10219
10750
  if (nodes.indexOf(Str2) !== -1) {
10220
10751
  sRecords.push(i);
@@ -10226,18 +10757,14 @@ class DetailsView {
10226
10757
  this.addFocus(this.gridObj.selectedRowIndex);
10227
10758
  }
10228
10759
  }
10229
- // eslint-disable-next-line
10230
10760
  addSelection(data) {
10231
- // eslint-disable-next-line
10232
10761
  const items = this.gridObj.getCurrentViewRecords();
10233
- // eslint-disable-next-line
10234
10762
  let rData = [];
10235
10763
  if (this.parent.hasId) {
10236
10764
  rData = new DataManager(items).
10237
10765
  executeLocal(new Query().where('id', 'equal', this.parent.renamedId, false));
10238
10766
  }
10239
10767
  else {
10240
- // eslint-disable-next-line
10241
10768
  const nData = new DataManager(items).
10242
10769
  executeLocal(new Query().where('name', 'equal', getValue('name', data), false));
10243
10770
  if (nData.length > 0) {
@@ -10255,7 +10782,6 @@ class DetailsView {
10255
10782
  this.gridObj.sortModule.sortColumn(this.parent.sortBy, this.parent.sortOrder);
10256
10783
  }
10257
10784
  else {
10258
- // eslint-disable-next-line
10259
10785
  this.gridObj.dataSource = getSortedData(this.parent, this.gridObj.dataSource);
10260
10786
  }
10261
10787
  if (this.element.querySelector('.e-content').scrollTop !== 0) {
@@ -10351,10 +10877,10 @@ class DetailsView {
10351
10877
  const len = this.gridObj.columns.length;
10352
10878
  const columnData = JSON.parse(JSON.stringify(this.gridObj.columns));
10353
10879
  if (columnData[len - 1].field && columnData[len - 1].field !== 'filterPath' && !this.parent.isMobile) {
10354
- const pathColumn$$1 = {
10880
+ const pathColumn = {
10355
10881
  field: 'filterPath', headerText: getLocaleText(this.parent, 'Path'), minWidth: 180, width: 'auto'
10356
10882
  };
10357
- this.gridObj.columns.push(pathColumn$$1);
10883
+ this.gridObj.columns.push(pathColumn);
10358
10884
  this.adjustWidth(this.gridObj.columns, 'filterPath');
10359
10885
  this.adjustWidth(this.gridObj.columns, 'name');
10360
10886
  this.isColumnRefresh = true;
@@ -10362,7 +10888,6 @@ class DetailsView {
10362
10888
  }
10363
10889
  }
10364
10890
  checkEmptyDiv(args) {
10365
- // eslint-disable-next-line
10366
10891
  const items = getSortedData(this.parent, args.files);
10367
10892
  if (items.length === 0 && !isNullOrUndefined(this.element.querySelector('.' + GRID_VIEW))) {
10368
10893
  createEmptyElement(this.parent, this.element, args);
@@ -10379,21 +10904,18 @@ class DetailsView {
10379
10904
  }
10380
10905
  onOpenInit() {
10381
10906
  if (this.parent.activeModule === 'detailsview') {
10382
- // eslint-disable-next-line
10383
10907
  const data = this.gridObj.getSelectedRecords()[0];
10384
10908
  this.openContent(data);
10385
10909
  }
10386
10910
  }
10387
10911
  DblClickEvents(args) {
10388
10912
  this.gridObj.selectRows([args.rowIndex]);
10389
- // eslint-disable-next-line
10390
10913
  let data;
10391
10914
  if (args.rowData) {
10392
10915
  data = JSON.parse(JSON.stringify(args.rowData));
10393
10916
  this.openContent(data);
10394
10917
  }
10395
10918
  }
10396
- // eslint-disable-next-line
10397
10919
  openContent(data) {
10398
10920
  if (!hasReadAccess(data)) {
10399
10921
  createDeniedDialog(this.parent, data, permissionRead);
@@ -10489,7 +11011,6 @@ class DetailsView {
10489
11011
  this.gridObj.sortColumn('name', this.parent.sortOrder);
10490
11012
  }
10491
11013
  else {
10492
- // eslint-disable-next-line
10493
11014
  this.gridObj.dataSource = getSortedData(this.parent, this.gridObj.dataSource);
10494
11015
  }
10495
11016
  this.parent.notify(sortByChange, {});
@@ -10678,7 +11199,6 @@ class DetailsView {
10678
11199
  this.parent.off(updateSelectionData, this.onUpdateSelectionData);
10679
11200
  }
10680
11201
  onActionFailure() { this.interaction = true; }
10681
- // eslint-disable-next-line
10682
11202
  onMenuItemData(args) {
10683
11203
  if (this.parent.activeModule === this.getModuleName()) {
10684
11204
  this.parent.itemData = [this.gridObj.getRowInfo(args.target).rowData];
@@ -10719,7 +11239,6 @@ class DetailsView {
10719
11239
  getModule(this.parent, dragLi);
10720
11240
  this.parent.activeElements = [];
10721
11241
  this.parent.dragData = [];
10722
- // eslint-disable-next-line
10723
11242
  this.parent.dragData = this.gridObj.getSelectedRecords();
10724
11243
  let dragRow;
10725
11244
  if (this.parent.dragData.length === 0 && dragLi) {
@@ -10807,16 +11326,13 @@ class DetailsView {
10807
11326
  onDropInit(args) {
10808
11327
  if (this.parent.targetModule === this.getModuleName()) {
10809
11328
  /* istanbul ignore next */
10810
- // eslint-disable-next-line
10811
11329
  const cwdData = getValue(this.parent.pathId[this.parent.pathId.length - 1], this.parent.feParent);
10812
11330
  if (!args.target.closest('tr')) {
10813
11331
  this.parent.dropPath = this.parent.path;
10814
11332
  this.parent.dropData = cwdData;
10815
11333
  }
10816
11334
  else {
10817
- // eslint-disable-next-line
10818
11335
  let info = null;
10819
- // eslint-disable-next-line
10820
11336
  info = this.gridObj.getRowInfo(args.target).rowData;
10821
11337
  this.parent.dropPath = info.isFile ? this.parent.path : getFullPath(this.parent, info, this.parent.path);
10822
11338
  this.parent.dropData = info.isFile ? cwdData : info;
@@ -10918,7 +11434,6 @@ class DetailsView {
10918
11434
  this.parent.currentItemText = getValue('name', args.data);
10919
11435
  }
10920
11436
  else if (len > 0) {
10921
- // eslint-disable-next-line
10922
11437
  const data = this.gridObj.getRowsObject()[rows[len - 1]].data;
10923
11438
  this.parent.currentItemText = getValue('name', data);
10924
11439
  }
@@ -10948,7 +11463,6 @@ class DetailsView {
10948
11463
  }
10949
11464
  selectedRecords() {
10950
11465
  this.parent.setProperties({ selectedItems: [] }, true);
10951
- // eslint-disable-next-line
10952
11466
  const selectedRecords = this.gridSelectNodes();
10953
11467
  let selectSize = 0;
10954
11468
  while (selectSize < selectedRecords.length) {
@@ -11013,27 +11527,25 @@ class DetailsView {
11013
11527
  }
11014
11528
  wireClickEvent(toBind) {
11015
11529
  if (toBind) {
11016
- // eslint-disable-next-line
11017
- const proxy = this;
11018
11530
  const ele = this.gridObj.getContent();
11019
11531
  this.clickObj = new Touch(ele, {
11020
11532
  tap: (eve) => {
11021
11533
  if (eve.tapCount === 1 && eve.originalEvent.target.classList.contains('e-content')) {
11022
- proxy.onClearAllInit();
11534
+ this.onClearAllInit();
11023
11535
  }
11024
11536
  },
11025
11537
  tapHold: (e) => {
11026
- if (proxy.parent.isDevice) {
11538
+ if (this.parent.isDevice) {
11027
11539
  e.originalEvent.preventDefault();
11028
- if (proxy.parent.allowMultiSelection) {
11029
- setValue('enableSelectMultiTouch', proxy.parent.allowMultiSelection, proxy.gridObj.selectionModule);
11030
- addClass([proxy.parent.element], MULTI_SELECT);
11540
+ if (this.parent.allowMultiSelection) {
11541
+ setValue('enableSelectMultiTouch', this.parent.allowMultiSelection, this.gridObj.selectionModule);
11542
+ addClass([this.parent.element], MULTI_SELECT);
11031
11543
  }
11032
11544
  const target = e.originalEvent.target;
11033
11545
  if (target) {
11034
11546
  const row = closest(target, '.' + ROW);
11035
- const index = proxy.gridObj.getRows().indexOf(row);
11036
- proxy.gridObj.selectRow(index);
11547
+ const index = this.gridObj.getRows().indexOf(row);
11548
+ this.gridObj.selectRow(index);
11037
11549
  }
11038
11550
  }
11039
11551
  }
@@ -11077,7 +11589,6 @@ class DetailsView {
11077
11589
  parseInt(this.getFocusedItem().getAttribute('data-rowindex'), 10) : null;
11078
11590
  }
11079
11591
  /* istanbul ignore next */
11080
- // eslint:disable-next-line
11081
11592
  keydownHandler(e) {
11082
11593
  if (!this.isRendered) {
11083
11594
  return;
@@ -11116,26 +11627,20 @@ class DetailsView {
11116
11627
  case 'ctrlD':
11117
11628
  e.preventDefault();
11118
11629
  break;
11119
- default:
11120
- break;
11121
11630
  }
11122
11631
  }
11123
11632
  /* istanbul ignore next */
11124
- // eslint:disable-next-line
11125
11633
  keyupHandler(e) {
11126
11634
  if (!this.isRendered) {
11127
11635
  return;
11128
11636
  }
11129
11637
  e.preventDefault();
11130
11638
  const action = e.action;
11131
- // eslint-disable-next-line
11132
11639
  const gridItems = getSortedData(this.parent, this.gridObj.dataSource);
11133
11640
  const gridLength = gridItems.length;
11134
- const focItem = this.getFocusedItem();
11135
11641
  const focIndex = this.getFocusedItemIndex();
11136
11642
  const selIndex = this.gridObj.selectedRowIndex;
11137
11643
  const selRowIndeces = this.gridObj.getSelectedRowIndexes();
11138
- // eslint-disable-next-line
11139
11644
  let rowData;
11140
11645
  let firstItem;
11141
11646
  let lastItem;
@@ -11165,7 +11670,6 @@ class DetailsView {
11165
11670
  }
11166
11671
  rowData = this.gridObj.getRowsObject()[this.gridObj.selectedRowIndex].data;
11167
11672
  if (rowData) {
11168
- // eslint-disable-next-line
11169
11673
  const data = JSON.parse(JSON.stringify(rowData));
11170
11674
  this.openContent(data);
11171
11675
  }
@@ -11282,14 +11786,12 @@ class DetailsView {
11282
11786
  break;
11283
11787
  }
11284
11788
  }
11285
- // eslint-disable-next-line
11286
11789
  gridSelectNodes() {
11287
11790
  return this.gridObj.getSelectedRecords();
11288
11791
  }
11289
11792
  doDownload() {
11290
11793
  if (this.parent.selectedItems.length !== 0) {
11291
11794
  this.parent.itemData = this.gridObj.getSelectedRecords();
11292
- // eslint-disable-next-line
11293
11795
  const items = this.parent.itemData;
11294
11796
  for (let i = 0; i < items.length; i++) {
11295
11797
  if (!hasDownloadAccess(items[i])) {
@@ -11303,7 +11805,6 @@ class DetailsView {
11303
11805
  performDelete() {
11304
11806
  if (this.parent.selectedItems && this.parent.selectedItems.length > 0) {
11305
11807
  this.parent.itemData = this.gridObj.getSelectedRecords();
11306
- // eslint-disable-next-line
11307
11808
  const items = this.parent.itemData;
11308
11809
  for (let i = 0; i < items.length; i++) {
11309
11810
  if (!hasEditAccess(items[i])) {
@@ -11321,11 +11822,9 @@ class DetailsView {
11321
11822
  }
11322
11823
  }
11323
11824
  updateRenameData() {
11324
- // eslint-disable-next-line
11325
11825
  const data = this.gridSelectNodes()[0];
11326
11826
  updateRenamingData(this.parent, data);
11327
11827
  }
11328
- // eslint-disable-next-line
11329
11828
  shiftMoveMethod(gridItems, selIndex, focIndex, selRowIndeces, e) {
11330
11829
  if (!this.parent.allowMultiSelection) {
11331
11830
  this.moveFunction(gridItems, e, selIndex);
@@ -11343,7 +11842,6 @@ class DetailsView {
11343
11842
  }
11344
11843
  }
11345
11844
  }
11346
- // eslint-disable-next-line
11347
11845
  moveFunction(selectedItems, e, rowIndex) {
11348
11846
  if (!isNullOrUndefined(this.getFocusedItem()) && this.parent.allowMultiSelection) {
11349
11847
  if (e.action === 'moveDown') {
@@ -11390,7 +11888,6 @@ class DetailsView {
11390
11888
  this.gridObj.selectRow(selIndex);
11391
11889
  }
11392
11890
  }
11393
- // eslint-disable-next-line
11394
11891
  ctrlMoveFunction(items, e, rowIndex) {
11395
11892
  let nextItem;
11396
11893
  if (!isNullOrUndefined(this.getFocusedItem())) {
@@ -11409,7 +11906,6 @@ class DetailsView {
11409
11906
  }
11410
11907
  this.addFocus(nextItem);
11411
11908
  }
11412
- // eslint-disable-next-line
11413
11909
  checkRowsKey(items, indexValue, focIndex, e) {
11414
11910
  if (this.gridObj.checkAllRows === 'Uncheck' || this.gridObj.checkAllRows === 'Intermediate') {
11415
11911
  if (e.action !== 'csHome' && e.action !== 'csEnd') {
@@ -11533,7 +12029,6 @@ class DetailsView {
11533
12029
  }
11534
12030
  return check;
11535
12031
  }
11536
- // eslint-disable-next-line
11537
12032
  shiftSelectedItem(selIndex, selRowIndexes, gridItems, e) {
11538
12033
  if (selIndex === -1) {
11539
12034
  this.gridObj.selectRow(0);
@@ -11582,7 +12077,6 @@ class DetailsView {
11582
12077
  }
11583
12078
  }
11584
12079
  }
11585
- // eslint-disable-next-line
11586
12080
  onMethodCall(e) {
11587
12081
  if (this.parent.view !== 'Details') {
11588
12082
  return;
@@ -11615,17 +12109,14 @@ class DetailsView {
11615
12109
  break;
11616
12110
  }
11617
12111
  }
11618
- // eslint-disable-next-line
11619
12112
  getRecords(nodes) {
11620
- // eslint-disable-next-line
11621
12113
  const gridRecords = this.gridObj.getCurrentViewRecords();
11622
- // eslint-disable-next-line
11623
12114
  const records = [];
11624
12115
  const hasFilter = (this.parent.breadcrumbbarModule.searchObj.element.value !== '' || this.parent.isFiltered) ? true : false;
11625
- const filter$$1 = this.parent.hasId ? 'id' : 'name';
12116
+ const filter = this.parent.hasId ? 'id' : 'name';
11626
12117
  if (this.parent.hasId || !hasFilter) {
11627
12118
  for (let i = 0, len = gridRecords.length; i < len; i++) {
11628
- if (nodes.indexOf(getValue(filter$$1, gridRecords[i])) !== -1) {
12119
+ if (nodes.indexOf(getValue(filter, gridRecords[i])) !== -1) {
11629
12120
  records.push(gridRecords[i]);
11630
12121
  }
11631
12122
  }
@@ -11646,12 +12137,10 @@ class DetailsView {
11646
12137
  this.performDelete();
11647
12138
  return;
11648
12139
  }
11649
- // eslint-disable-next-line
11650
12140
  const records = this.getRecords(ids);
11651
12141
  if (records.length === 0) {
11652
12142
  return;
11653
12143
  }
11654
- // eslint-disable-next-line
11655
12144
  const data = [];
11656
12145
  const newIds = [];
11657
12146
  for (let i = 0; i < records.length; i++) {
@@ -11665,12 +12154,10 @@ class DetailsView {
11665
12154
  this.doDownload();
11666
12155
  return;
11667
12156
  }
11668
- // eslint-disable-next-line
11669
12157
  const dRecords = this.getRecords(ids);
11670
12158
  if (dRecords.length === 0) {
11671
12159
  return;
11672
12160
  }
11673
- // eslint-disable-next-line
11674
12161
  const data = [];
11675
12162
  const newIds = [];
11676
12163
  for (let i = 0; i < dRecords.length; i++) {
@@ -11683,7 +12170,6 @@ class DetailsView {
11683
12170
  if (isNullOrUndefined(id)) {
11684
12171
  return;
11685
12172
  }
11686
- // eslint-disable-next-line
11687
12173
  const records = this.getRecords([id]);
11688
12174
  if (records.length > 0) {
11689
12175
  this.openContent(records[0]);
@@ -11695,7 +12181,6 @@ class DetailsView {
11695
12181
  this.performRename();
11696
12182
  return;
11697
12183
  }
11698
- // eslint-disable-next-line
11699
12184
  const records = this.getRecords([id]);
11700
12185
  if (records.length > 0) {
11701
12186
  updateRenamingData(this.parent, records[0]);
@@ -11714,21 +12199,5 @@ class DetailsView {
11714
12199
  }
11715
12200
  }
11716
12201
 
11717
- /**
11718
- * File Manager layout modules
11719
- */
11720
-
11721
- /**
11722
- * File Manager pop-up modules
11723
- */
11724
-
11725
- /**
11726
- * File Manager modules
11727
- */
11728
-
11729
- /**
11730
- * File Manager all modules
11731
- */
11732
-
11733
- export { AjaxSettings, defaultToolbarItems, ToolbarSettings, ToolbarItem, SearchSettings, columnArray, DetailsViewSettings, fileItems, folderItems, layoutItems, ContextMenuSettings, NavigationPaneSettings, UploadSettings, Column, TOOLBAR_ID, LAYOUT_ID, NAVIGATION_ID, TREE_ID, GRID_ID, LARGEICON_ID, DIALOG_ID, ALT_DIALOG_ID, IMG_DIALOG_ID, EXTN_DIALOG_ID, UPLOAD_DIALOG_ID, RETRY_DIALOG_ID, CONTEXT_MENU_ID, SORTBY_ID, VIEW_ID, SPLITTER_ID, CONTENT_ID, BREADCRUMBBAR_ID, UPLOAD_ID, RETRY_ID, SEARCH_ID, ROOT, CONTROL, CHECK_SELECT, ROOT_POPUP, MOBILE, MOB_POPUP, MULTI_SELECT, FILTER, LAYOUT, NAVIGATION, LAYOUT_CONTENT, LARGE_ICONS, TB_ITEM, LIST_ITEM, LIST_TEXT, LIST_PARENT, TB_OPTION_TICK, TB_OPTION_DOT, BLUR, ACTIVE, HOVER, FOCUS, FOCUSED, CHECK, FRAME, CB_WRAP, ROW, ROWCELL, EMPTY, EMPTY_CONTENT, EMPTY_INNER_CONTENT, CLONE, DROP_FOLDER, DROP_FILE, FOLDER, ICON_IMAGE, ICON_MUSIC, ICON_VIDEO, LARGE_ICON, LARGE_EMPTY_FOLDER, LARGE_EMPTY_FOLDER_TWO, LARGE_ICON_FOLDER, SELECTED_ITEMS, TEXT_CONTENT, GRID_HEADER, TEMPLATE_CELL, TREE_VIEW, MENU_ITEM, MENU_ICON, SUBMENU_ICON, GRID_VIEW, GRID_CONTENT, ICON_VIEW, ICON_OPEN, ICON_UPLOAD, ICON_CUT, ICON_COPY, ICON_PASTE, ICON_DELETE, ICON_RENAME, ICON_NEWFOLDER, ICON_DETAILS, ICON_SHORTBY, ICON_REFRESH, ICON_SELECTALL, ICON_DOWNLOAD, ICON_OPTIONS, ICON_GRID, ICON_LARGE, ICON_BREADCRUMB, ICON_CLEAR, ICON_DROP_IN, ICON_DROP_OUT, ICON_NO_DROP, ICONS, DETAILS_LABEL, ERROR_CONTENT, STATUS, BREADCRUMBS, RTL, DISPLAY_NONE, COLLAPSED, FULLROW, ICON_COLLAPSIBLE, SPLIT_BAR, HEADER_CHECK, OVERLAY, VALUE, isFile, modelChanged, initialEnd, finalizeEnd, createEnd, filterEnd, beforeDelete, pathDrag, deleteInit, deleteEnd, refreshEnd, resizeEnd, splitterResize, pathChanged, destroy, beforeRequest, upload, skipUpload, afterRequest, download, layoutRefresh, actionFailure, search, openInit, openEnd, selectionChanged, selectAllInit, clearAllInit, clearPathInit, layoutChange, sortByChange, nodeExpand, detailsInit, menuItemData, renameInit, renameEndParent, renameEnd, showPaste, hidePaste, selectedData, cutCopyInit, pasteInit, pasteEnd, cutEnd, hideLayout, updateTreeSelection, treeSelect, sortColumn, pathColumn, searchTextChange, beforeDownload, downloadInit, dropInit, dragEnd, dropPath, dragHelper, dragging, updateSelectionData, methodCall, permissionRead, permissionEdit, permissionEditContents, permissionCopy, permissionUpload, permissionDownload, FileManager, Toolbar$1 as Toolbar, BreadCrumbBar, Virtualization, NavigationPane, DetailsView, LargeIconsView, createDialog, createExtDialog, createImageDialog, ContextMenu$2 as ContextMenu, read, createFolder, filter, rename, paste, Delete, GetDetails, Search, Download, sortComparer, updatePath, getPath, getPathId, getPathNames, getParents, generatePath, removeActive, activeElement, addBlur, removeBlur, getModule, searchWordHandler, updateLayout, getTargetModule, refresh, openAction, getPathObject, copyFiles, cutFiles, fileType, getImageUrl, getFullPath, getName, getSortedData, getObject, createEmptyElement, getDirectories, setNodeId, setDateObject, getLocaleText, getCssClass, sortbyClickHandler, getSortField, setNextPath, openSearchFolder, pasteHandler, validateSubFolder, dropHandler, getParentPath, getDirectoryPath, doPasteUpdate, readDropPath, getDuplicateData, createVirtualDragElement, dragStopHandler, dragStartHandler, dragCancel, removeDropTarget, removeItemClass, scrollHandler, draggingHandler, objectToString, getItemName, updateRenamingData, doRename, doDownload, doDeleteFiles, doDownloadFiles, createDeniedDialog, getAccessClass, hasReadAccess, hasEditAccess, hasContentAccess, hasUploadAccess, hasDownloadAccess, createNewFolder, uploadItem };
12202
+ 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, 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 };
11734
12203
  //# sourceMappingURL=ej2-filemanager.es2015.js.map