Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@syncfusion/ej2-treegrid

Package Overview
Dependencies
Maintainers
4
Versions
239
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@syncfusion/ej2-treegrid - npm Package Compare versions

Comparing version 17.2.51 to 17.3.9-beta

2

dist/global/index.d.ts
/*!
* filename: index.d.ts
* version : 17.2.51
* version : 17.3.9-beta
* Copyright Syncfusion Inc. 2001 - 2019. All rights reserved.

@@ -5,0 +5,0 @@ * Use of this code is subject to the terms of our license.

{
"_from": "@syncfusion/ej2-treegrid@*",
"_id": "@syncfusion/ej2-treegrid@17.2.51",
"_id": "@syncfusion/ej2-treegrid@17.2.48",
"_inBundle": false,
"_integrity": "sha512-LALKuiFZx0GZ4Tkkv/ehNqUTcFlRJB5PNAb3jB+HBWMaHnoBp3uMUeNJS2X0d4AZZ8pX8E1lBbzCWWykZFv94w==",
"_integrity": "sha512-it89UlpwoUwTFp7rOIDu0ASRmAjYF6cH1oe4//nrX1TfGIYHcD7z4ZEHUnol30rT+x4vP/V8t9tosRd6qc+PPA==",
"_location": "/@syncfusion/ej2-treegrid",

@@ -28,3 +28,3 @@ "_phantomChildren": {},

"_resolved": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-treegrid/-/ej2-treegrid-17.2.48.tgz",
"_shasum": "84020863e8a5f6eea25dea41e06dbf1a9d77bbf7",
"_shasum": "bdc9a353388446bbc6e7a3f3f1258cbef7992c95",
"_spec": "@syncfusion/ej2-treegrid@*",

@@ -40,6 +40,6 @@ "_where": "/jenkins/workspace/ation_hotfix_17.2.0.34_Vol2-DDPJ6C2YEWTWLLKKNA7AG2JBE6DYTCTNGMHGORWGAYAVCL6L7OLQ/packages/included",

"dependencies": {
"@syncfusion/ej2-base": "~17.2.49",
"@syncfusion/ej2-data": "~17.2.47",
"@syncfusion/ej2-grids": "~17.2.51",
"@syncfusion/ej2-popups": "~17.2.47"
"@syncfusion/ej2-base": "~17.3.9-beta",
"@syncfusion/ej2-data": "~17.3.9-beta",
"@syncfusion/ej2-grids": "~17.3.9-beta",
"@syncfusion/ej2-popups": "~17.3.9-beta"
},

@@ -65,4 +65,4 @@ "deprecated": false,

"typings": "index.d.ts",
"version": "17.2.51",
"version": "17.3.9-beta",
"sideEffects": false
}

@@ -113,3 +113,3 @@ import { Grid, Edit as GridEdit, getUid, getObject } from '@syncfusion/ej2-grids';

var adaptor = treeObj.dataSource.adaptor;
if ((isRemoteData(treeObj) || adaptor instanceof RemoteSaveAdaptor) &&
if ((isRemoteData(treeObj) || adaptor instanceof RemoteSaveAdaptor) && treeObj.getSelectedRowIndexes().length &&
(eventArgs.requestType === 'save' && eventArgs.action === 'add') &&

@@ -116,0 +116,0 @@ (treeObj.editSettings.newRowPosition === 'Child' || treeObj.editSettings.newRowPosition === 'Below'

@@ -6,3 +6,3 @@ import { Grid } from '@syncfusion/ej2-grids';

import { getValue, isNullOrUndefined, isBlazor } from '@syncfusion/ej2-base';
import { getExpandStatus } from '../utils';
import { getExpandStatus, isFilterChildHierarchy } from '../utils';
/**

@@ -133,5 +133,11 @@ * The `Page` module is used to render pager and handle paging action.

var parents_1 = dm_1.executeLocal(new Query().where(expanded));
var visualData = parents_1.filter(function (e) {
return getExpandStatus(_this.parent, e, parents_1);
});
var visualData = void 0;
if (isFilterChildHierarchy(this.parent)) {
visualData = parents_1;
}
else {
visualData = parents_1.filter(function (e) {
return getExpandStatus(_this.parent, e, parents_1);
});
}
pageingDetails.count = visualData.length;

@@ -138,0 +144,0 @@ var query = new Query();

import { Grid, RowDD as GridDragDrop, parentsUntil } from '@syncfusion/ej2-grids';
import { getObject, Scroll } from '@syncfusion/ej2-grids';
import { closest, isNullOrUndefined, classList, setValue, extend } from '@syncfusion/ej2-base';
import { DataManager } from '@syncfusion/ej2-data';
import { DataManager, RemoteSaveAdaptor, JsonAdaptor } from '@syncfusion/ej2-data';
import * as events from '../base/constant';
import { editAction } from './crud-actions';
import { getParentData, findChildrenRecords } from '../utils';
import { getParentData, findChildrenRecords, isRemoteData } from '../utils';
/**

@@ -31,3 +31,3 @@ * TreeGrid RowDragAndDrop module

var treeGridDataSource;
if (this.parent.dataSource instanceof DataManager) {
if (this.parent.dataSource instanceof DataManager && (!isRemoteData(this.parent))) {
if (this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.json) {

@@ -225,2 +225,3 @@ treeGridDataSource = this.parent.dataSource.dataSource.json;

this.dropPosition = undefined;
var rowPositionHeight = 0;
this.removeFirstrowBorder(rowEle);

@@ -246,3 +247,5 @@ this.removeLastrowBorder(rowEle);

var scrollTop = tObj.getContent().firstElementChild.scrollTop;
var rowPositionHeight = rowEle.offsetTop - scrollTop;
if (!isNullOrUndefined(rowEle)) {
rowPositionHeight = rowEle.offsetTop - scrollTop;
}
// let scrollTop = (tObj.grid.scrollModule as any).content.scrollTop;

@@ -506,3 +509,3 @@ if (tObj.allowTextWrap) {

var dropElement = parentsUntil(args.target, 'e-treegrid');
if (dropElement && dropElement.id === this.parent.rowDropSettings.targetID) {
if (dropElement && dropElement.id === this.parent.rowDropSettings.targetID && !isRemoteData(this.parent)) {
var srcControl = dropElement.ej2_instances[0];

@@ -549,3 +552,3 @@ var records = tObj.getSelectedRecords();

RowDD.prototype.dropRows = function (args, isByMethod) {
if (this.dropPosition !== 'Invalid') {
if (this.dropPosition !== 'Invalid' && !isRemoteData(this.parent)) {
var tObj = this.parent;

@@ -662,3 +665,2 @@ var draggedRecord = void 0;

this.parent.dataSource.splice(recordIndex1, 0, this.draggedRecord.taskData);
this.treeGridData.splice(recordIndex1, 0, this.draggedRecord);
}

@@ -721,3 +723,4 @@ this.draggedRecord.parentItem = this.treeGridData[recordIndex1].parentItem;

RowDD.prototype.deleteDragRow = function () {
if (this.parent.dataSource instanceof DataManager) {
if (this.parent.dataSource instanceof RemoteSaveAdaptor
|| this.parent.dataSource instanceof JsonAdaptor) {
this.treeGridData = this.parent.dataSource.dataSource.json;

@@ -877,3 +880,3 @@ }

draggedRecords.filter(function (e) {
if (e.hasChildRecords) {
if (e.hasChildRecords && !isNullOrUndefined(e.childRecords)) {
var valid = e.childRecords.indexOf(currentRecord);

@@ -915,3 +918,3 @@ if (valid === -1) {

RowDD.prototype.getModuleName = function () {
return 'rowDragandDrop';
return 'rowDragAndDrop';
};

@@ -918,0 +921,0 @@ return RowDD;

@@ -365,4 +365,4 @@ import { isNullOrUndefined, removeClass } from '@syncfusion/ej2-base';

this.selectedIndexes = [];
childData = (this.parent.filterModule.filteredResult.length > 0) ? this.parent.getCurrentViewRecords() :
this.parent.flatData;
childData = (!isNullOrUndefined(this.parent.filterModule) && this.parent.filterModule.filteredResult.length > 0) ?
this.parent.getCurrentViewRecords() : this.parent.flatData;
childData.forEach(function (record) {

@@ -369,0 +369,0 @@ if (record.hasChildRecords) {

@@ -74,3 +74,4 @@ var __extends = (this && this.__extends) || (function () {

};
getValue('grid.renderModule', this.parent).dataManagerSuccess(ret, { requestType: 'refresh' });
var requestType = getValue('isCollapseAll', this.parent) ? 'collapseAll' : 'refresh';
getValue('grid.renderModule', this.parent).dataManagerSuccess(ret, { requestType: requestType });
};

@@ -114,3 +115,3 @@ VirtualScroll.prototype.virtualPageAction = function (pageingDetails) {

var tempdata = visualData.slice(sIndex, sIndex + resourceCount.length);
if (tempdata.length < resourceCount.length) {
if (tempdata.length < resourceCount.length && sIndex >= 0) {
sIndex = visualData.length - resourceCount.length;

@@ -121,2 +122,7 @@ sIndex = sIndex > 0 ? sIndex : 0;

}
else if (getValue('isCollapseAll', this.parent)) {
startIndex = 0;
endIndex = this.parent.grid.pageSettings.pageSize - 1;
this.parent.grid.notify(events.virtualActionArgs, { setTop: true });
}
this.expandCollapseRec = null;

@@ -123,0 +129,0 @@ }

@@ -7,3 +7,2 @@ import { extend, isNullOrUndefined, setValue, getValue, isBlazor, addClass, removeClass } from '@syncfusion/ej2-base';

import * as events from './constant';
import { Sort } from '../actions/sort';
/**

@@ -192,2 +191,5 @@ * Internal dataoperations for tree grid

&& (isNullOrUndefined(records[rec].index))) {
records[rec].taskData = extend({}, records[rec]);
records[rec].uniqueID = getUid(this.parent.element.id + '_data_');
setValue('uniqueIDCollection.' + records[rec].uniqueID, records[rec], this.parent);
records[rec].level = 0;

@@ -258,6 +260,12 @@ records[rec].index = Math.ceil(Math.random() * 1000);

for (var r = 0; r < result.length; r++) {
result[r].taskData = extend({}, result[r]);
result[r].level = rowDetails.record.level + 1;
result[r].index = Math.ceil(Math.random() * 1000);
result[r].parentItem = rowDetails.record;
delete result[r].parentItem.childRecords;
var parentData = extend({}, rowDetails.record);
delete parentData.childRecords;
result[r].parentItem = parentData;
result[r].parentUniqueID = rowDetails.record.uniqueID;
result[r].uniqueID = getUid(_this.parent.element.id + '_data_');
setValue('uniqueIDCollection.' + result[r].uniqueID, result[r], _this.parent);
// delete result[r].parentItem.childRecords;
if ((result[r][_this.parent.hasChildMapping] || _this.parentItems.indexOf(result[r][_this.parent.idMapping]) !== -1)

@@ -267,4 +275,2 @@ && !(haveChild && !haveChild[r])) {

result[r].expanded = false;
result[r].uniqueID = getUid(_this.parent.element.id + '_data_');
setValue('uniqueIDCollection.' + result[r].uniqueID, result[r], _this.parent);
}

@@ -421,3 +427,2 @@ datas.splice(inx + r + 1, 0, result[r]);

var query = getObject('query', args);
this.parent.sortModule = new Sort(this.parent);
var srtQry = new Query();

@@ -424,0 +429,0 @@ for (var srt = this.parent.grid.sortSettings.columns.length - 1; srt >= 0; srt--) {

@@ -83,2 +83,3 @@ import { Component, ModuleDeclaration } from '@syncfusion/ej2-base';

private isExpandAll;
private isCollapseAll;
private isExpandRefresh;

@@ -1003,2 +1004,3 @@ private gridSettings;

private extendedGridEvents;
private bindGridDragEvents;
/**

@@ -1005,0 +1007,0 @@ * Renders TreeGrid component

@@ -1,2 +0,2 @@

import { ChildProperty, Property } from '@syncfusion/ej2-base';import { EditMode, RowPosition } from '../enum';
import { ChildProperty, Property } from '@syncfusion/ej2-base';import { EditMode, RowPosition } from '../enum';import { IDialogUI } from '@syncfusion/ej2-grids';

@@ -72,2 +72,8 @@ /**

/**
* Defines the dialog params to edit.
* @default {}
*/
dialog?: IDialogUI;
}
import { ChildProperty } from '@syncfusion/ej2-base';
import { EditMode, RowPosition } from '../enum';
import { IDialogUI } from '@syncfusion/ej2-grids';
/**

@@ -62,2 +63,7 @@ * Configures the edit behavior of the TreeGrid.

template: string;
/**
* Defines the dialog params to edit.
* @default {}
*/
dialog: IDialogUI;
}

@@ -56,4 +56,7 @@ var __extends = (this && this.__extends) || (function () {

], EditSettings.prototype, "template", void 0);
__decorate([
Property({})
], EditSettings.prototype, "dialog", void 0);
return EditSettings;
}(ChildProperty));
export { EditSettings };
import { getObject, appendChildren } from '@syncfusion/ej2-grids';
import { addClass, createElement, isNullOrUndefined, getValue } from '@syncfusion/ej2-base';
import * as events from '../base/constant';
import { isRemoteData, isOffline, getExpandStatus } from '../utils';
import { isRemoteData, isOffline, getExpandStatus, isFilterChildHierarchy } from '../utils';
/**

@@ -28,3 +28,3 @@ * TreeGrid render module

var index;
if (!isNullOrUndefined(data.parentItem) &&
if (!isNullOrUndefined(data.parentItem) && !isFilterChildHierarchy(this.parent) &&
(!(this.parent.allowPaging && !(this.parent.pageSettings.pageSizeMode === 'Root')) ||

@@ -31,0 +31,0 @@ (isRemoteData(this.parent) && !isOffline(this.parent)))) {

@@ -16,2 +16,3 @@ var __extends = (this && this.__extends) || (function () {

import * as events from '../base/constant';
import { isNullOrUndefined } from '@syncfusion/ej2-base';
/**

@@ -35,2 +36,5 @@ * RowModelGenerator is used to generate grid data rows.

TreeVirtualRowModelGenerator.prototype.generateRows = function (data, notifyArgs) {
if (!isNullOrUndefined(notifyArgs.requestType) && notifyArgs.requestType.toString() === 'collapseAll') {
notifyArgs.requestType = 'refresh';
}
var rows = _super.prototype.generateRows.call(this, data, notifyArgs);

@@ -37,0 +41,0 @@ for (var r = 0; r < rows.length; r++) {

@@ -75,2 +75,5 @@ var __extends = (this && this.__extends) || (function () {

}
if (!isNullOrUndefined(e.requestType) && e.requestType.toString() === 'collapseAll') {
this.contents.scrollTop = 0;
}
};

@@ -150,3 +153,3 @@ VirtualTreeContentRenderer.prototype.renderTable = function () {

this.getTable().querySelector('tbody')[replace](target);
if (!this.isExpandCollapse) {
if (!this.isExpandCollapse || this.translateY === 0) {
getValue('virtualEle', this).adjustTable(cOffset, this.translateY);

@@ -153,0 +156,0 @@ }

@@ -5,2 +5,3 @@ import { TreeGrid } from './base/treegrid';

export declare function isCountRequired(parent: TreeGrid): boolean;
export declare function isFilterChildHierarchy(parent: TreeGrid): boolean;
/**

@@ -7,0 +8,0 @@ * @hidden

@@ -20,2 +20,11 @@ import { getObject } from '@syncfusion/ej2-grids';

}
export function isFilterChildHierarchy(parent) {
if ((!isNullOrUndefined(parent.grid.searchSettings.key) && parent.grid.searchSettings.key !== '' &&
(parent.searchSettings.hierarchyMode === 'Child' || parent.searchSettings.hierarchyMode === 'None')) ||
(parent.allowFiltering && parent.grid.filterSettings.columns.length &&
(parent.filterSettings.hierarchyMode === 'Child' || parent.filterSettings.hierarchyMode === 'None'))) {
return true;
}
return false;
}
/**

@@ -22,0 +31,0 @@ * @hidden

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

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc