@syncfusion/ej2-filemanager 25.1.40 → 25.2.6

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.
@@ -144,7 +144,7 @@ var __decorate$3 = (undefined && undefined.__decorate) || function (decorators,
144
144
  */
145
145
  const columnArray = [
146
146
  {
147
- field: 'name', headerText: 'Name', minWidth: 120, isPrimaryKey: true,
147
+ field: 'name', headerText: 'Name', minWidth: 120,
148
148
  template: '<span class=\"e-fe-text\">${name}</span>',
149
149
  customAttributes: { class: 'e-fe-grid-name' }
150
150
  },
@@ -6262,15 +6262,29 @@ class ContextMenu$2 {
6262
6262
  this.disabledItems.push('Open');
6263
6263
  }
6264
6264
  }
6265
- else if (this.parent.selectedItems.length !== 1 && this.parent.activeModule !== 'navigationpane') {
6266
- this.disabledItems.push('Rename', 'Paste');
6265
+ else if (this.parent.activeModule !== 'navigationpane') {
6266
+ if (this.parent.selectedItems.length === 1) {
6267
+ const renameIndex = this.disabledItems.indexOf('Rename');
6268
+ if (renameIndex !== -1) {
6269
+ this.disabledItems.splice(renameIndex, 1);
6270
+ }
6271
+ }
6272
+ else {
6273
+ this.disabledItems.push('Rename', 'Paste');
6274
+ }
6267
6275
  }
6268
6276
  }
6269
6277
  setFileItem() {
6270
6278
  this.menuType = 'file';
6271
6279
  this.contextMenu.items = this.getItemData(this.parent.contextMenuSettings.file.map((item) => item.trim()));
6272
6280
  this.contextMenu.dataBind();
6273
- if (this.parent.selectedItems.length !== 1) {
6281
+ if (this.parent.selectedItems.length === 1) {
6282
+ const renameIndex = this.disabledItems.indexOf('Rename');
6283
+ if (renameIndex !== -1) {
6284
+ this.disabledItems.splice(renameIndex, 1);
6285
+ }
6286
+ }
6287
+ else {
6274
6288
  this.disabledItems.push('Rename');
6275
6289
  }
6276
6290
  }
@@ -6284,6 +6298,9 @@ class ContextMenu$2 {
6284
6298
  (closest(target, '#' + this.parent.element.id + GRID_ID).getElementsByClassName(EMPTY).length !== 0)))) {
6285
6299
  this.disabledItems.push('SelectAll');
6286
6300
  }
6301
+ else {
6302
+ this.disabledItems = this.disabledItems.filter(item => item !== 'SelectAll');
6303
+ }
6287
6304
  if (this.parent.selectedNodes.length === 0) {
6288
6305
  if (this.disabledItems.indexOf('Paste') === -1) {
6289
6306
  this.disabledItems.push('Paste');
@@ -8740,6 +8757,7 @@ class Virtualization {
8740
8757
  this.scrollPosition = scroll;
8741
8758
  // Update the list of items and the items property of the largeIconInstance
8742
8759
  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;
8743
8761
  this.largeIconInstance.items = this.largeIconInstance.allItems.slice(this.renderedCount -
8744
8762
  this.itemCount, this.renderedCount);
8745
8763
  }
@@ -9835,8 +9853,7 @@ class DetailsView {
9835
9853
  allowResizing: this.parent.detailsViewSettings.columnResizing,
9836
9854
  selectionSettings: {
9837
9855
  type: this.parent.allowMultiSelection ? 'Multiple' : 'Single',
9838
- checkboxMode: 'ResetOnRowClick',
9839
- persistSelection: (this.parent.enableVirtualization) ? true : false
9856
+ checkboxMode: 'ResetOnRowClick'
9840
9857
  },
9841
9858
  enableRtl: this.parent.enableRtl,
9842
9859
  pageSettings: { pageSize: 20 },