@syncfusion/ej2-filemanager
Advanced tools
Comparing version 21.1.35 to 21.1.37
@@ -7,2 +7,10 @@ # Changelog | ||
#### Bug fixes | ||
- `#I442564` - The issue with `fileOpen` event in File Manager component has been resolved. | ||
## 21.1.35 (2023-03-23) | ||
### File Manager | ||
#### New Features | ||
@@ -9,0 +17,0 @@ |
/*! | ||
* filename: index.d.ts | ||
* version : 21.1.35 | ||
* version : 21.1.37 | ||
* Copyright Syncfusion Inc. 2001 - 2020. All rights reserved. | ||
@@ -5,0 +5,0 @@ * Use of this code is subject to the terms of our license. |
{ | ||
"_from": "@syncfusion/ej2-filemanager@*", | ||
"_id": "@syncfusion/ej2-filemanager@18.20.1", | ||
"_id": "@syncfusion/ej2-filemanager@21.1.35", | ||
"_inBundle": false, | ||
"_integrity": "sha512-aWF002IK3S7gXmugPv1V7vnx88KCzVk1ndOj7yJyj8cu11Q/4Lk4B8azq2R8+1Mlyra1qHCFRFoS+RB38D6oIg==", | ||
"_integrity": "sha512-b8o3DLdPrFmsp2eE1LBmHWO/D3qousnaq+rQHbMtWK3naYPMhtJ0q6CfnUgWDaz3nhpFdwt9M6NTwII8fy5xIQ==", | ||
"_location": "/@syncfusion/ej2-filemanager", | ||
@@ -28,4 +28,4 @@ "_phantomChildren": {}, | ||
], | ||
"_resolved": "https://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-filemanager/-/ej2-filemanager-18.20.1.tgz", | ||
"_shasum": "6115759f03937e73d38d4967b9e9ce8507850442", | ||
"_resolved": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-filemanager/-/ej2-filemanager-21.1.35.tgz", | ||
"_shasum": "9d1b9e84738e6bac0e265695df0c843f4937e01c", | ||
"_spec": "@syncfusion/ej2-filemanager@*", | ||
@@ -41,12 +41,12 @@ "_where": "/jenkins/workspace/elease-automation_release_21.1.1/packages/included", | ||
"dependencies": { | ||
"@syncfusion/ej2-base": "~21.1.35", | ||
"@syncfusion/ej2-buttons": "~21.1.35", | ||
"@syncfusion/ej2-data": "~21.1.35", | ||
"@syncfusion/ej2-grids": "~21.1.35", | ||
"@syncfusion/ej2-inputs": "~21.1.35", | ||
"@syncfusion/ej2-layouts": "~21.1.35", | ||
"@syncfusion/ej2-lists": "~21.1.35", | ||
"@syncfusion/ej2-navigations": "~21.1.35", | ||
"@syncfusion/ej2-popups": "~21.1.35", | ||
"@syncfusion/ej2-splitbuttons": "~21.1.35" | ||
"@syncfusion/ej2-base": "~21.1.37", | ||
"@syncfusion/ej2-buttons": "~21.1.37", | ||
"@syncfusion/ej2-data": "~21.1.37", | ||
"@syncfusion/ej2-grids": "~21.1.37", | ||
"@syncfusion/ej2-inputs": "~21.1.37", | ||
"@syncfusion/ej2-layouts": "~21.1.37", | ||
"@syncfusion/ej2-lists": "~21.1.37", | ||
"@syncfusion/ej2-navigations": "~21.1.37", | ||
"@syncfusion/ej2-popups": "~21.1.37", | ||
"@syncfusion/ej2-splitbuttons": "~21.1.37" | ||
}, | ||
@@ -81,4 +81,4 @@ "deprecated": false, | ||
"typings": "index.d.ts", | ||
"version": "21.1.35", | ||
"version": "21.1.37", | ||
"sideEffects": false | ||
} |
@@ -23,2 +23,3 @@ import { TreeView as BaseTreeView } from '@syncfusion/ej2-navigations'; | ||
private isRightClick; | ||
private isSameNodeClicked; | ||
private renameParent; | ||
@@ -25,0 +26,0 @@ private previousSelected; |
@@ -32,2 +32,3 @@ import { TreeView as BaseTreeView } from '@syncfusion/ej2-navigations'; | ||
this.isRightClick = false; | ||
this.isSameNodeClicked = false; | ||
this.renameParent = null; | ||
@@ -188,3 +189,3 @@ // Specifies the previously selected nodes in the treeview control. | ||
NavigationPane.prototype.onNodeSelecting = function (args) { | ||
if (!args.isInteracted && !this.isRightClick && !this.isPathDragged && !this.isRenameParent || this.restrictSelecting) { | ||
if (!args.isInteracted && !this.isRightClick && !this.isSameNodeClicked && !this.isPathDragged && !this.isRenameParent || this.restrictSelecting) { | ||
this.restrictSelecting = false; | ||
@@ -198,15 +199,26 @@ this.isNodeClickCalled = false; | ||
var nodeData = this.getTreeData(getValue('id', args.nodeData)); | ||
var eventArgs = { cancel: false, fileDetails: nodeData[0], module: 'NavigationPane' }; | ||
this.parent.trigger('fileOpen', eventArgs); | ||
var selecEventArgs = { action: args.action, fileDetails: nodeData[0], isInteracted: args.isInteracted }; | ||
this.parent.trigger('fileSelect', selecEventArgs); | ||
args.cancel = eventArgs.cancel; | ||
if (args.cancel) { | ||
this.restrictSelecting = this.isNodeClickCalled ? this.previousSelected[0] !== args.node.getAttribute('data-uid') : false; | ||
this.previousSelected = this.treeObj.selectedNodes; | ||
this.treeObj.selectedNodes = [args.node.getAttribute("data-uid")]; | ||
if (!isNOU(this.parent) && !isNOU(this.parent.contextmenuModule)) { | ||
this.parent.contextmenuModule.contextMenu.enableItems(['Open'], true); | ||
if (args.node.getAttribute('data-uid') !== this.parent.pathId[this.parent.pathId.length - 1] && !this.isRightClick && !this.isNodeClickCalled || this.isSameNodeClicked) { | ||
this.isNodeClickCalled = false; | ||
if (!this.isSameNodeClicked) { | ||
this.isSameNodeClicked = true; | ||
var selecEventArgs = { action: args.action, fileDetails: nodeData[0], isInteracted: args.isInteracted }; | ||
this.parent.trigger('fileSelect', selecEventArgs); | ||
} | ||
if (!this.isRightClick) { | ||
var eventArgs = { cancel: false, fileDetails: nodeData[0], module: 'NavigationPane' }; | ||
this.parent.trigger('fileOpen', eventArgs); | ||
args.cancel = eventArgs.cancel; | ||
} | ||
if (args.cancel) { | ||
this.restrictSelecting = this.isNodeClickCalled ? this.previousSelected[0] !== args.node.getAttribute('data-uid') : false; | ||
this.isNodeClickCalled = true; | ||
this.isSameNodeClicked = false; | ||
this.previousSelected = this.treeObj.selectedNodes; | ||
this.treeObj.selectedNodes = [args.node.getAttribute("data-uid")]; | ||
} | ||
} | ||
else if (this.previousSelected[0] !== args.node.getAttribute('data-uid')) { | ||
var selecEventArgs = { action: args.action, fileDetails: nodeData[0], isInteracted: args.isInteracted }; | ||
this.parent.trigger('fileSelect', selecEventArgs); | ||
} | ||
} | ||
@@ -222,7 +234,12 @@ }; | ||
this.parent.activeModule = 'navigationpane'; | ||
updatePath(node, this.parent.itemData[0], this.parent); | ||
read(this.parent, this.isPathDragged ? events.pasteEnd : events.pathChanged, this.parent.path); | ||
this.parent.visitedItem = node; | ||
this.isPathDragged = this.isRenameParent = this.isRightClick = false; | ||
this.treeObj.selectedNodes = [node.getAttribute('data-uid')]; | ||
var eventArgs = { cancel: false, fileDetails: data[0], module: 'NavigationPane' }; | ||
this.parent.trigger('fileOpen', eventArgs); | ||
this.isNodeClickCalled = true; | ||
if (!eventArgs.cancel) { | ||
updatePath(node, this.parent.itemData[0], this.parent); | ||
read(this.parent, this.isPathDragged ? events.pasteEnd : events.pathChanged, this.parent.path); | ||
this.parent.visitedItem = node; | ||
this.isPathDragged = this.isRenameParent = this.isRightClick = false; | ||
this.treeObj.selectedNodes = [node.getAttribute('data-uid')]; | ||
} | ||
}; | ||
@@ -233,5 +250,6 @@ NavigationPane.prototype.onNodeSelected = function (args) { | ||
this.parent.isFiltered = false; | ||
this.isNodeClickCalled = false; | ||
} | ||
this.parent.searchedItems = []; | ||
if (!args.isInteracted && !this.isRightClick && !this.isPathDragged && !this.isRenameParent) { | ||
if (!args.isInteracted && !this.isRightClick && !this.isSameNodeClicked && !this.isPathDragged && !this.isRenameParent) { | ||
this.parent.pathId = getPathId(args.node); | ||
@@ -247,3 +265,4 @@ return; | ||
var previousPath = this.parent.path; | ||
if (!this.isRightClick) { | ||
var sNode = select('[data-uid="' + this.treeObj.selectedNodes[0] + '"]', this.treeObj.element); | ||
if (!this.isRightClick && this.isSameNodeClicked && sNode.querySelector('.e-list-text').innerHTML !== this.parent.pathNames[this.parent.pathNames.length - 1]) { | ||
updatePath(args.node, this.parent.itemData[0], this.parent); | ||
@@ -260,8 +279,9 @@ } | ||
} | ||
if (!this.isRightClick) { | ||
if (!this.isRightClick && this.isSameNodeClicked) { | ||
read(this.parent, this.isPathDragged ? events.pasteEnd : events.pathChanged, this.parent.path); | ||
this.isNodeClickCalled = true; | ||
} | ||
this.parent.visitedItem = args.node; | ||
} | ||
this.isPathDragged = this.isRenameParent = this.isRightClick = false; | ||
this.isPathDragged = this.isRenameParent = this.isRightClick = this.isSameNodeClicked = false; | ||
}; | ||
@@ -310,2 +330,10 @@ /* istanbul ignore next */ | ||
} | ||
else if (args.node.getAttribute('data-uid') === this.treeObj.selectedNodes[0] && !this.isNodeClickCalled) { | ||
if (args.event.which === 3) { | ||
this.isRightClick = true; | ||
} | ||
this.isSameNodeClicked = true; | ||
this.isNodeClickCalled = true; | ||
this.treeObj.selectedNodes = [args.node.getAttribute('data-uid')]; | ||
} | ||
}; | ||
@@ -312,0 +340,0 @@ /* istanbul ignore next */ |
@@ -246,6 +246,7 @@ import { ContextMenu as Menu } from '@syncfusion/ej2-navigations'; | ||
this.contextMenu.dataBind(); | ||
if (isTree) { | ||
var selectedTreeNode = select('[data-uid="' + this.parent.navigationpaneModule.treeObj.selectedNodes[0] + '"]', this.parent.navigationpaneModule.treeObj.element); | ||
if (this.parent.pathNames[this.parent.pathNames.length - 1] === selectedTreeNode.querySelector('.e-list-text').innerHTML && this.parent.activeModule === 'navigationpane') { | ||
this.disabledItems.push('Open'); | ||
} | ||
else if (this.parent.selectedItems.length !== 1) { | ||
else if (this.parent.selectedItems.length !== 1 && this.parent.activeModule !== 'navigationpane') { | ||
this.disabledItems.push('Rename', 'Paste'); | ||
@@ -394,6 +395,9 @@ } | ||
case 'open': | ||
if (_this.parent.visitedItem) { | ||
if (_this.parent.visitedItem && _this.parent.activeModule !== 'navigationpane') { | ||
_this.parent.notify(events.openInit, { target: _this.parent.visitedItem }); | ||
} | ||
else if (_this.parent.activeModule === 'navigationpane') { | ||
if (_this.parent.visitedItem) { | ||
_this.parent.notify(events.openInit, { target: _this.parent.visitedItem }); | ||
} | ||
_this.parent.navigationpaneModule.openFileOnContextMenuClick(closest(_this.targetNodeElement, 'li')); | ||
@@ -400,0 +404,0 @@ } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11265863
97876
161
4
11
1
36