angular-slickgrid 5.6.0 → 5.6.3
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.
- package/app/modules/angular-slickgrid/components/angular-slickgrid.component.d.ts +1 -0
- package/esm2020/app/modules/angular-slickgrid/components/angular-slickgrid.component.mjs +33 -14
- package/esm2020/app/modules/angular-slickgrid/modules/angular-slickgrid.module.mjs +5 -5
- package/esm2020/app/modules/angular-slickgrid/services/angularUtil.service.mjs +4 -4
- package/esm2020/app/modules/angular-slickgrid/services/container.service.mjs +4 -4
- package/esm2020/app/modules/angular-slickgrid/services/translater.service.mjs +4 -4
- package/fesm2015/angular-slickgrid.mjs +46 -26
- package/fesm2015/angular-slickgrid.mjs.map +1 -1
- package/fesm2020/angular-slickgrid.mjs +45 -26
- package/fesm2020/angular-slickgrid.mjs.map +1 -1
- package/package.json +11 -11
- package/test/cypress/node_modules/debug/README.md +27 -1
|
@@ -57,9 +57,9 @@ class AngularUtilService {
|
|
|
57
57
|
return componentOutput;
|
|
58
58
|
}
|
|
59
59
|
}
|
|
60
|
-
AngularUtilService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.
|
|
61
|
-
AngularUtilService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.
|
|
62
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.
|
|
60
|
+
AngularUtilService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularUtilService, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ApplicationRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
61
|
+
AngularUtilService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularUtilService });
|
|
62
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularUtilService, decorators: [{
|
|
63
63
|
type: Injectable
|
|
64
64
|
}], ctorParameters: function () { return [{ type: i0.ComponentFactoryResolver }, { type: i0.ApplicationRef }, { type: i0.Injector }]; } });
|
|
65
65
|
|
|
@@ -84,9 +84,9 @@ class ContainerService {
|
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
|
-
ContainerService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.
|
|
88
|
-
ContainerService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.
|
|
89
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.
|
|
87
|
+
ContainerService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ContainerService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
88
|
+
ContainerService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ContainerService });
|
|
89
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ContainerService, decorators: [{
|
|
90
90
|
type: Injectable
|
|
91
91
|
}], ctorParameters: function () { return []; } });
|
|
92
92
|
|
|
@@ -122,9 +122,9 @@ class TranslaterService {
|
|
|
122
122
|
return this.translateService?.instant?.(translationKey || ' ');
|
|
123
123
|
}
|
|
124
124
|
}
|
|
125
|
-
TranslaterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.
|
|
126
|
-
TranslaterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.
|
|
127
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.
|
|
125
|
+
TranslaterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TranslaterService, deps: [{ token: i1.TranslateService, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
126
|
+
TranslaterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TranslaterService });
|
|
127
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TranslaterService, decorators: [{
|
|
128
128
|
type: Injectable
|
|
129
129
|
}], ctorParameters: function () { return [{ type: i1.TranslateService, decorators: [{
|
|
130
130
|
type: Optional
|
|
@@ -1632,25 +1632,44 @@ class AngularSlickgridComponent {
|
|
|
1632
1632
|
});
|
|
1633
1633
|
}
|
|
1634
1634
|
}
|
|
1635
|
+
insertDynamicPresetColumns(columnId, gridPresetColumns) {
|
|
1636
|
+
if (this._columnDefinitions) {
|
|
1637
|
+
const columnPosition = this._columnDefinitions.findIndex(c => c.id === columnId);
|
|
1638
|
+
if (columnPosition >= 0) {
|
|
1639
|
+
const dynColumn = this._columnDefinitions[columnPosition];
|
|
1640
|
+
if (dynColumn?.id === columnId && !gridPresetColumns.some(c => c.id === columnId)) {
|
|
1641
|
+
columnPosition > 0
|
|
1642
|
+
? gridPresetColumns.splice(columnPosition, 0, dynColumn)
|
|
1643
|
+
: gridPresetColumns.unshift(dynColumn);
|
|
1644
|
+
}
|
|
1645
|
+
}
|
|
1646
|
+
}
|
|
1647
|
+
}
|
|
1635
1648
|
/** Load any possible Columns Grid Presets */
|
|
1636
1649
|
loadColumnPresetsWhenDatasetInitialized() {
|
|
1637
1650
|
// if user entered some Columns "presets", we need to reflect them all in the grid
|
|
1638
1651
|
if (this.gridOptions.presets && Array.isArray(this.gridOptions.presets.columns) && this.gridOptions.presets.columns.length > 0) {
|
|
1639
|
-
const
|
|
1640
|
-
if (
|
|
1641
|
-
// make sure that the
|
|
1652
|
+
const gridPresetColumns = this.gridStateService.getAssociatedGridColumns(this.slickGrid, this.gridOptions.presets.columns);
|
|
1653
|
+
if (gridPresetColumns && Array.isArray(gridPresetColumns) && gridPresetColumns.length > 0 && Array.isArray(this._columnDefinitions)) {
|
|
1654
|
+
// make sure that the dynamic columns are included in presets (1.Row Move, 2. Row Selection, 3. Row Detail)
|
|
1655
|
+
if (this.gridOptions.enableRowMoveManager) {
|
|
1656
|
+
const rmmColId = this.gridOptions?.rowMoveManager?.columnId ?? '_move';
|
|
1657
|
+
this.insertDynamicPresetColumns(rmmColId, gridPresetColumns);
|
|
1658
|
+
}
|
|
1642
1659
|
if (this.gridOptions.enableCheckboxSelector) {
|
|
1643
|
-
const
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1660
|
+
const chkColId = this.gridOptions?.checkboxSelector?.columnId ?? '_checkbox_selector';
|
|
1661
|
+
this.insertDynamicPresetColumns(chkColId, gridPresetColumns);
|
|
1662
|
+
}
|
|
1663
|
+
if (this.gridOptions.enableRowDetailView) {
|
|
1664
|
+
const rdvColId = this.gridOptions?.rowDetailView?.columnId ?? '_detail_selector';
|
|
1665
|
+
this.insertDynamicPresetColumns(rdvColId, gridPresetColumns);
|
|
1647
1666
|
}
|
|
1648
1667
|
// keep copy the original optional `width` properties optionally provided by the user.
|
|
1649
1668
|
// We will use this when doing a resize by cell content, if user provided a `width` it won't override it.
|
|
1650
|
-
|
|
1669
|
+
gridPresetColumns.forEach(col => col.originalWidth = col.width);
|
|
1651
1670
|
// finally set the new presets columns (including checkbox selector if need be)
|
|
1652
|
-
this.slickGrid.setColumns(
|
|
1653
|
-
this.sharedService.visibleColumns =
|
|
1671
|
+
this.slickGrid.setColumns(gridPresetColumns);
|
|
1672
|
+
this.sharedService.visibleColumns = gridPresetColumns;
|
|
1654
1673
|
}
|
|
1655
1674
|
}
|
|
1656
1675
|
}
|
|
@@ -1899,14 +1918,14 @@ class AngularSlickgridComponent {
|
|
|
1899
1918
|
}
|
|
1900
1919
|
}
|
|
1901
1920
|
}
|
|
1902
|
-
AngularSlickgridComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.
|
|
1903
|
-
AngularSlickgridComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.
|
|
1921
|
+
AngularSlickgridComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularSlickgridComponent, deps: [{ token: AngularUtilService }, { token: i0.ApplicationRef }, { token: i0.ChangeDetectorRef }, { token: ContainerService }, { token: i0.ElementRef }, { token: i1.TranslateService, optional: true }, { token: TranslaterService, optional: true }, { token: 'config' }, { token: 'externalService' }], target: i0.ɵɵFactoryTarget.Component });
|
|
1922
|
+
AngularSlickgridComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: AngularSlickgridComponent, selector: "angular-slickgrid", inputs: { customDataView: "customDataView", gridId: "gridId", gridOptions: "gridOptions", paginationOptions: "paginationOptions", columnDefinitions: "columnDefinitions", dataset: "dataset", datasetHierarchical: "datasetHierarchical" }, outputs: { columnDefinitionsChange: "columnDefinitionsChange" }, providers: [
|
|
1904
1923
|
// make everything transient (non-singleton)
|
|
1905
1924
|
AngularUtilService,
|
|
1906
1925
|
ApplicationRef,
|
|
1907
1926
|
TranslaterService,
|
|
1908
1927
|
], ngImport: i0, template: "<div id=\"slickGridContainer-{{gridId}}\" class=\"gridPane\">\n <div attr.id='{{gridId}}' class=\"slickgrid-container\" style=\"width: 100%\">\n </div>\n</div>" });
|
|
1909
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.
|
|
1928
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularSlickgridComponent, decorators: [{
|
|
1910
1929
|
type: Component,
|
|
1911
1930
|
args: [{ selector: 'angular-slickgrid', providers: [
|
|
1912
1931
|
// make everything transient (non-singleton)
|
|
@@ -1955,12 +1974,12 @@ class AngularSlickgridModule {
|
|
|
1955
1974
|
};
|
|
1956
1975
|
}
|
|
1957
1976
|
}
|
|
1958
|
-
AngularSlickgridModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.
|
|
1959
|
-
AngularSlickgridModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.
|
|
1977
|
+
AngularSlickgridModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularSlickgridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1978
|
+
AngularSlickgridModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: AngularSlickgridModule, declarations: [AngularSlickgridComponent], imports: [CommonModule,
|
|
1960
1979
|
TranslateModule], exports: [AngularSlickgridComponent] });
|
|
1961
|
-
AngularSlickgridModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.
|
|
1980
|
+
AngularSlickgridModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularSlickgridModule, imports: [CommonModule,
|
|
1962
1981
|
TranslateModule] });
|
|
1963
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.
|
|
1982
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: AngularSlickgridModule, decorators: [{
|
|
1964
1983
|
type: NgModule,
|
|
1965
1984
|
args: [{
|
|
1966
1985
|
imports: [
|