@syncfusion/ej2-filemanager 28.2.9 → 28.2.11

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.
@@ -1247,7 +1247,7 @@ function getFullPath(parent, data, path) {
1247
1247
  const filePath = getValue(parent.hasId ? 'id' : 'name', data) + '/';
1248
1248
  const fPath = getValue(parent.hasId ? 'filterId' : 'filterPath', data);
1249
1249
  if (!isNullOrUndefined(fPath)) {
1250
- return fPath.replace(/\\/g, '/') + filePath;
1250
+ return fPath.replace(/\\/g, '/').replace(/^.*?(?=\/)/, '') + filePath;
1251
1251
  }
1252
1252
  else {
1253
1253
  return path + filePath;
@@ -7043,7 +7043,9 @@ class ContextMenu {
7043
7043
  this.parent.trigger('menuClick', eventArgs, (menuClickArgs) => {
7044
7044
  let sItems;
7045
7045
  if (!menuClickArgs.cancel) {
7046
- this.isMenuItemClicked = true;
7046
+ if (itemText !== 'cut' && itemText !== 'copy') {
7047
+ this.isMenuItemClicked = true;
7048
+ }
7047
7049
  switch (itemText) {
7048
7050
  case 'cut':
7049
7051
  cutFiles(this.parent);
@@ -10450,7 +10452,7 @@ class NavigationPane {
10450
10452
  this.updateItemData();
10451
10453
  }
10452
10454
  this.moveNames = [];
10453
- const obj = this.parent.isDragDrop || isFileSystemData(this.parent) ? this.parent.dragData : this.parent.actionRecords;
10455
+ const obj = this.parent.isDragDrop ? this.parent.dragData : this.parent.actionRecords;
10454
10456
  for (let i = 0; i < obj.length; i++) {
10455
10457
  if (getValue('isFile', obj[i]) === false) {
10456
10458
  this.moveNames.push(getValue('_fm_id', obj[i]));
@@ -10819,6 +10821,9 @@ class DetailsView {
10819
10821
  }
10820
10822
  this.gridObj.isStringTemplate = true;
10821
10823
  this.gridObj.appendTo('#' + this.parent.element.id + GRID_ID);
10824
+ if (this.parent.selectedItems.length !== 0 && this.parent.enableVirtualization && this.parent.enablePersistence) {
10825
+ this.isLoaded = true;
10826
+ }
10822
10827
  this.wireEvents();
10823
10828
  this.adjustHeight();
10824
10829
  this.emptyArgs = args;
@@ -11072,7 +11077,7 @@ class DetailsView {
11072
11077
  /* istanbul ignore next */
11073
11078
  onDataBound() {
11074
11079
  this.createDragObj();
11075
- if ((this.parent.selectedItems.length !== 0 && !this.parent.enableVirtualization)) {
11080
+ if ((this.parent.selectedItems.length !== 0 && !this.parent.enableVirtualization) || this.isLoaded) {
11076
11081
  this.selectRecords(this.parent.selectedItems);
11077
11082
  }
11078
11083
  if (this.isPasteOperation === true && (!isNullOrUndefined(this.gridObj.getDataRows()) && this.gridObj.getDataRows().length > 0)) {
@@ -11145,7 +11150,7 @@ class DetailsView {
11145
11150
  this.isLoaded = false;
11146
11151
  }
11147
11152
  selectRecords(nodes) {
11148
- const gridRecords = this.gridObj.getCurrentViewRecords();
11153
+ const gridRecords = this.gridObj.dataSource;
11149
11154
  const sRecords = [];
11150
11155
  for (let i = 0, len = gridRecords.length; i < len; i++) {
11151
11156
  const node = this.parent.hasId ? getValue('id', gridRecords[i]) : getName(this.parent, gridRecords[i]);