@progress/kendo-angular-grid 18.1.0-develop.19 → 18.1.0-develop.2

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.
@@ -455,10 +455,6 @@ const recursiveFlatMap = (item) => isGroupResult(item) ? item.items.flatMap(recu
455
455
  const isGroupResult = (obj) => {
456
456
  return 'aggregates' in obj && 'items' in obj && 'field' in obj && 'value' in obj;
457
457
  };
458
- /**
459
- * @hidden
460
- */
461
- const roundDown = (value) => Math.floor(value * 100) / 100;
462
458
 
463
459
  /**
464
460
  * @hidden
@@ -2092,18 +2088,6 @@ const isColumnContainer = column => column.isColumnGroup || isSpanColumn(column)
2092
2088
  */
2093
2089
  class ColumnBase {
2094
2090
  parent;
2095
- /**
2096
- * @hidden
2097
- */
2098
- isReordered;
2099
- /**
2100
- * @hidden
2101
- */
2102
- initialMaxResizableWidth;
2103
- /**
2104
- * @hidden
2105
- */
2106
- initialMinResizableWidth;
2107
2091
  /**
2108
2092
  * @hidden
2109
2093
  */
@@ -2771,10 +2755,6 @@ class ColumnComponent extends ColumnBase {
2771
2755
  get displayTitle() {
2772
2756
  return this.title === undefined ? this.field : this.title;
2773
2757
  }
2774
- ngAfterViewInit() {
2775
- this.initialMaxResizableWidth = this.maxResizableWidth;
2776
- this.initialMinResizableWidth = this.minResizableWidth;
2777
- }
2778
2758
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColumnComponent, deps: [{ token: ColumnBase, host: true, optional: true, skipSelf: true }, { token: IdService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
2779
2759
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ColumnComponent, isStandalone: true, selector: "kendo-grid-column", inputs: { field: "field", format: "format", sortable: "sortable", groupable: "groupable", editor: "editor", filter: "filter", filterable: "filterable", editable: "editable" }, providers: [
2780
2760
  {
@@ -3103,10 +3083,8 @@ class ColumnResizingService {
3103
3083
  areColumnsReordered = false;
3104
3084
  isShiftPressed = false;
3105
3085
  originalWidth;
3106
- draggedGroupColumn;
3107
- resizedColumns;
3108
- autoFitResize = false;
3109
3086
  column;
3087
+ resizedColumns;
3110
3088
  tables = [];
3111
3089
  batch = null;
3112
3090
  start(column) {
@@ -3142,10 +3120,7 @@ class ColumnResizingService {
3142
3120
  resizedColumns: this.resizedColumns,
3143
3121
  type: 'end'
3144
3122
  });
3145
- this.restoreInitialMaxMinWidths();
3146
3123
  this.adjacentColumn = null;
3147
- this.draggedGroupColumn = null;
3148
- this.autoFitResize = false;
3149
3124
  }
3150
3125
  registerTable(tableMetadata) {
3151
3126
  this.tables.push(tableMetadata);
@@ -3218,16 +3193,6 @@ class ColumnResizingService {
3218
3193
  });
3219
3194
  this.batch = null;
3220
3195
  }
3221
- restoreInitialMaxMinWidths() {
3222
- if (this.adjacentColumn) {
3223
- this.adjacentColumn.maxResizableWidth = this.adjacentColumn.initialMaxResizableWidth;
3224
- this.adjacentColumn.minResizableWidth = this.adjacentColumn.initialMinResizableWidth;
3225
- }
3226
- if (this.column) {
3227
- this.column.maxResizableWidth = this.column.initialMaxResizableWidth;
3228
- this.column.minResizableWidth = this.column.initialMinResizableWidth;
3229
- }
3230
- }
3231
3196
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColumnResizingService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
3232
3197
  static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColumnResizingService });
3233
3198
  }
@@ -3339,25 +3304,7 @@ class NavigationService {
3339
3304
  }
3340
3305
  }
3341
3306
  get isColumnResizable() {
3342
- const allColumns = Array.from(this.ctx.grid.columnsContainer.allColumns);
3343
- const column = allColumns.find((col) => col.level === this.activeCell.rowIndex && col.leafIndex === this.activeCell.colIndex);
3344
- if (!column.parent) {
3345
- if (column.isColumnGroup) {
3346
- return this.activeCell.colIndex + this.activeCell.colSpan !== this.ctx.grid.columnsContainer.leafColumnsToRender.length;
3347
- }
3348
- else {
3349
- return this.activeCell.colIndex !== this.ctx.grid.columnsContainer.leafColumnsToRender.length - 1;
3350
- }
3351
- }
3352
- else {
3353
- const columnGroup = column.parent;
3354
- const columnGroupChildren = Array.from(columnGroup.children).sort((a, b) => a.orderIndex - b.orderIndex);
3355
- const columnIndexInsideGroup = columnGroupChildren.indexOf(column);
3356
- if (column.isReordered || column.orderIndex > 0 || (column.isReordered && column.orderIndex === 0)) {
3357
- return (column.orderIndex - columnGroupChildren[0]['orderIndex']) !== columnGroupChildren.length - 1;
3358
- }
3359
- return columnIndexInsideGroup !== columnGroupChildren.length - 1;
3360
- }
3307
+ return this.activeCell.colIndex !== this.ctx.grid.columnsContainer.leafColumnsToRender.length - 1;
3361
3308
  }
3362
3309
  viewport;
3363
3310
  columnViewport;
@@ -3799,7 +3746,8 @@ class NavigationService {
3799
3746
  }
3800
3747
  }
3801
3748
  columnResize(onRightArrow) {
3802
- const column = this.ctx.grid.columnsContainer.allColumns.find((col) => col.level === this.activeCell.rowIndex && col.leafIndex === this.activeCell.colIndex);
3749
+ const column = this.ctx.grid.columnsContainer.leafColumnsToRender[this.activeCell.colIndex];
3750
+ column.resizeStartWidth = Array.from(this.ctx.grid.wrapper.nativeElement.querySelectorAll('.k-grid-header th.k-header'))[this.activeCell.colIndex]['offsetWidth'];
3803
3751
  this.resizeService.start(column);
3804
3752
  this.resizeService.resizeColumns(onRightArrow ? resizeStep : -1 * resizeStep);
3805
3753
  if (this.resizeService.resizeColumns.length > 0) {
@@ -14658,20 +14606,11 @@ const toPercentage = (value, whole) => (value / whole) * 100;
14658
14606
  /**
14659
14607
  * @hidden
14660
14608
  */
14661
- const headerWidth = (handle) => handle.nativeElement.parentElement.getBoundingClientRect().width;
14609
+ const headerWidth = (handle) => handle.nativeElement.parentElement.offsetWidth;
14662
14610
  /**
14663
14611
  * @hidden
14664
14612
  */
14665
- const adjacentColumnWidth = (handle) => handle.nativeElement.parentElement.nextElementSibling?.getBoundingClientRect().width;
14666
- /**
14667
- * @hidden
14668
- */
14669
- const adjacentColumnInGroupWidth = (handle, rowIndex, colIndex) => {
14670
- const tableElement = handle.nativeElement.closest('.k-grid-header-table');
14671
- const selector = (rowAttribute) => `tr[${rowAttribute}="${rowIndex}"] th[aria-colindex="${colIndex}"]`;
14672
- const thElement = tableElement.querySelector([selector('aria-rowindex'), selector('data-kendo-grid-row-index')]);
14673
- return thElement.getBoundingClientRect().width;
14674
- };
14613
+ const adjacentColumnWidth = (handle) => handle.nativeElement.parentElement.nextElementSibling?.offsetWidth;
14675
14614
  /**
14676
14615
  * @hidden
14677
14616
  */
@@ -14731,7 +14670,7 @@ class ColumnHandleDirective {
14731
14670
  columns = [];
14732
14671
  column;
14733
14672
  get visible() {
14734
- if (this.isConstrainedMode && (this.isLast || this.isLastInGroup(this.column))) {
14673
+ if (this.isConstrainedMode && this.isLast) {
14735
14674
  return 'none';
14736
14675
  }
14737
14676
  return this.column.resizable ? 'block' : 'none';
@@ -14751,12 +14690,7 @@ class ColumnHandleDirective {
14751
14690
  }
14752
14691
  subscriptions = new Subscription();
14753
14692
  rtl = false;
14754
- totalChildrenSum = 0;
14755
- childrenColumns = [];
14756
- minWidthTotal = 0;
14757
- foundColumn;
14758
14693
  autoFit() {
14759
- this.service.autoFitResize = true;
14760
14694
  const allLeafs = allLeafColumns(this.columns);
14761
14695
  const currentLeafs = leafColumns([this.column]).filter(column => isTruthy(column.resizable));
14762
14696
  const columnInfo = currentLeafs.map(column => {
@@ -14814,19 +14748,35 @@ class ColumnHandleDirective {
14814
14748
  }
14815
14749
  shouldUpdate() {
14816
14750
  return !allLeafColumns(this.columns)
14817
- .map(column => column.width || (this.isConstrainedMode && !column.width && column.implicitWidth))
14751
+ .map(column => column.width)
14818
14752
  .some(isBlank);
14819
14753
  }
14820
14754
  initColumnWidth() {
14821
14755
  this.column.width = headerWidth(this.element);
14822
- if (this.isConstrainedMode) {
14823
- this.column.resizeStartWidth = this.column.width;
14824
- }
14825
14756
  }
14826
14757
  initState() {
14827
14758
  this.column.resizeStartWidth = headerWidth(this.element);
14828
- if (this.isConstrainedMode && !this.service.adjacentColumn) {
14829
- this.setAdjacentColumn();
14759
+ let columns = [];
14760
+ if (this.ctx.grid?.columns) {
14761
+ columns = Array.from(this.ctx.grid?.columns) || [];
14762
+ }
14763
+ if (this.isConstrainedMode) {
14764
+ if (this.service.areColumnsReordered) {
14765
+ this.service.adjacentColumn = columns.find(c => c.orderIndex === this.column.orderIndex + 1);
14766
+ this.service.adjacentColumn.resizeStartWidth = adjacentColumnWidth(this.element);
14767
+ this.service.resizedColumn({
14768
+ column: this.service.adjacentColumn,
14769
+ oldWidth: this.service.adjacentColumn.resizeStartWidth
14770
+ });
14771
+ }
14772
+ else {
14773
+ this.service.adjacentColumn = columns[this.column.leafIndex + 1];
14774
+ this.service.adjacentColumn.resizeStartWidth = adjacentColumnWidth(this.element);
14775
+ this.service.resizedColumn({
14776
+ column: this.service.adjacentColumn,
14777
+ oldWidth: this.service.adjacentColumn.resizeStartWidth
14778
+ });
14779
+ }
14830
14780
  }
14831
14781
  this.service.resizedColumn({
14832
14782
  column: this.column,
@@ -14843,7 +14793,12 @@ class ColumnHandleDirective {
14843
14793
  newWidth = Math.min(newWidth, this.column.maxResizableWidth);
14844
14794
  }
14845
14795
  if (this.isConstrainedMode) {
14846
- newWidth = this.calcNewColumnWidth(newWidth);
14796
+ const maxAllowedResizableWidth = this.column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - this.service.adjacentColumn.minResizableWidth;
14797
+ newWidth = Math.min(newWidth, maxAllowedResizableWidth);
14798
+ }
14799
+ if (this.isConstrainedMode && isPresent(this.service.adjacentColumn.maxResizableWidth)) {
14800
+ const maxAllowedResizableWidth = this.column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - this.service.adjacentColumn.maxResizableWidth;
14801
+ newWidth = Math.max(newWidth, maxAllowedResizableWidth);
14847
14802
  }
14848
14803
  const tableDelta = this.getTableDelta(newWidth, delta);
14849
14804
  this.updateWidth(this.column, newWidth);
@@ -14857,8 +14812,11 @@ class ColumnHandleDirective {
14857
14812
  this.service.resizeTable(this.column, tableDelta);
14858
14813
  }
14859
14814
  updateWidth(column, width) {
14860
- if (this.isConstrainedMode && this.service.adjacentColumn && !this.service.autoFitResize) {
14861
- this.updateWidthsOfResizedColumns(column, width);
14815
+ if (this.isConstrainedMode && this.service.adjacentColumn) {
14816
+ const adjacentColumnNewWidth = column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - width;
14817
+ if (adjacentColumnNewWidth < (column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth)) {
14818
+ this.service.adjacentColumn.width = adjacentColumnNewWidth;
14819
+ }
14862
14820
  }
14863
14821
  column.width = width;
14864
14822
  this.columnInfoService.hiddenColumns.forEach((col) => {
@@ -14870,188 +14828,9 @@ class ColumnHandleDirective {
14870
14828
  });
14871
14829
  this.cdr.markForCheck(); //force CD cycle
14872
14830
  }
14873
- updateWidthsOfResizedColumns(column, width) {
14874
- let adjacentColumnNewWidth = column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - width;
14875
- if (this.service.draggedGroupColumn && column.parent) {
14876
- this.updateWidthOfDraggedColumn(column, width);
14877
- this.setGroupWidths(this.service.draggedGroupColumn);
14878
- }
14879
- else if (!this.service.draggedGroupColumn && !column.parent && this.service.adjacentColumn.parent) {
14880
- this.service.adjacentColumn.parent.width = column.width + this.service.adjacentColumn.parent.width - width;
14881
- this.service.adjacentColumn.width = adjacentColumnNewWidth;
14882
- }
14883
- else if (!this.service.draggedGroupColumn && column.parent && this.service.adjacentColumn.parent) {
14884
- adjacentColumnNewWidth = column.width + this.service.adjacentColumn.width - width;
14885
- this.service.adjacentColumn.width = adjacentColumnNewWidth;
14886
- const filteredColumns = this.service.adjacentColumn.parent.children.filter(c => c !== this.service.adjacentColumn);
14887
- const filteredColumnsWidth = filteredColumns.reduce((acc, c) => acc + c.width, 0);
14888
- this.service.adjacentColumn.parent.width = adjacentColumnNewWidth + filteredColumnsWidth;
14889
- this.setGroupWidths(this.service.adjacentColumn.parent);
14890
- }
14891
- else if (adjacentColumnNewWidth > this.service.adjacentColumn.minResizableWidth) {
14892
- this.service.adjacentColumn.width = adjacentColumnNewWidth;
14893
- }
14894
- }
14895
- calcNewColumnWidth(newWidth) {
14896
- let maxAllowedResizableWidth;
14897
- if (!this.service.adjacentColumn.parent) {
14898
- maxAllowedResizableWidth = this.column.width + this.service.adjacentColumn.width - this.service.adjacentColumn.minResizableWidth;
14899
- if (!this.column.parent) {
14900
- maxAllowedResizableWidth = this.column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - this.service.adjacentColumn.minResizableWidth;
14901
- if (this.service.adjacentColumn.maxResizableWidth) {
14902
- const minResizableWidth = this.column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - this.service.adjacentColumn.maxResizableWidth;
14903
- maxAllowedResizableWidth = this.column.resizeStartWidth + this.service.adjacentColumn.resizeStartWidth - this.service.adjacentColumn.minResizableWidth;
14904
- this.column.minResizableWidth = minResizableWidth;
14905
- this.column.maxResizableWidth = maxAllowedResizableWidth;
14906
- }
14907
- }
14908
- }
14909
- else {
14910
- maxAllowedResizableWidth = this.column.width + this.service.adjacentColumn.width;
14911
- newWidth = Math.min(newWidth, maxAllowedResizableWidth);
14912
- this.minWidthTotal = 0;
14913
- const minResizableWidth = this.minAdjacentColumnWidth(this.service.adjacentColumn);
14914
- maxAllowedResizableWidth -= minResizableWidth;
14915
- }
14916
- return Math.min(newWidth, maxAllowedResizableWidth - 1);
14917
- }
14918
- setAdjacentColumn() {
14919
- const columnsForLevel = this.columnsForLevel(this.column.level);
14920
- if (this.column.parent) {
14921
- if (this.column.isReordered) {
14922
- this.service.adjacentColumn = columnsForLevel.find(c => c.orderIndex === this.column.orderIndex + 1);
14923
- this.service.adjacentColumn.resizeStartWidth = this.service.adjacentColumn.width;
14924
- }
14925
- else {
14926
- const columnIndex = columnsForLevel.indexOf(this.column);
14927
- this.service.adjacentColumn = columnsForLevel[columnIndex + 1];
14928
- this.service.adjacentColumn.resizeStartWidth = adjacentColumnWidth(this.element);
14929
- const parentColumnChildren = Array.from(this.column.parent.children);
14930
- const indexOfCurrentColumn = parentColumnChildren.indexOf(this.column);
14931
- let adjacentColumn;
14932
- if (indexOfCurrentColumn + 1 <= parentColumnChildren.length - 1) {
14933
- adjacentColumn = parentColumnChildren[indexOfCurrentColumn + 1];
14934
- if (adjacentColumn?.isColumnGroup) {
14935
- this.service.adjacentColumn = adjacentColumn;
14936
- }
14937
- }
14938
- }
14939
- if (this.service.adjacentColumn.isColumnGroup) {
14940
- this.foundColumn = null;
14941
- this.service.adjacentColumn = this.firstGroupChild(this.service.adjacentColumn);
14942
- }
14943
- if (this.column.isColumnGroup) {
14944
- this.service.draggedGroupColumn = this.column;
14945
- }
14946
- }
14947
- else if (this.column.isColumnGroup) {
14948
- if (this.column.isReordered) {
14949
- this.service.adjacentColumn = columnsForLevel.find(c => c.orderIndex === this.column.orderIndex + 1);
14950
- }
14951
- else {
14952
- this.service.adjacentColumn = columnsForLevel[columnsForLevel.indexOf(this.column) + 1];
14953
- }
14954
- this.service.adjacentColumn.resizeStartWidth = adjacentColumnWidth(this.element);
14955
- if (this.service.adjacentColumn.isColumnGroup) {
14956
- this.foundColumn = null;
14957
- this.service.adjacentColumn = this.firstGroupChild(this.service.adjacentColumn);
14958
- }
14959
- this.service.adjacentColumn.resizeStartWidth = this.service.adjacentColumn.width;
14960
- this.service.draggedGroupColumn = this.column;
14961
- }
14962
- else {
14963
- if (this.column.isReordered) {
14964
- this.service.adjacentColumn = columnsForLevel.find(col => col.orderIndex === this.column.orderIndex + 1);
14965
- }
14966
- else {
14967
- let adjacentColumn = columnsForLevel.find(c => c.leafIndex === this.column.leafIndex + 1);
14968
- if (!adjacentColumn) {
14969
- const indexOfCurrentColumn = columnsForLevel.indexOf(this.column);
14970
- adjacentColumn = columnsForLevel[indexOfCurrentColumn + 1];
14971
- }
14972
- this.service.adjacentColumn = adjacentColumn;
14973
- }
14974
- if (!this.service.adjacentColumn.parent) {
14975
- this.service.adjacentColumn.resizeStartWidth = adjacentColumnWidth(this.element);
14976
- }
14977
- if (this.service.adjacentColumn.isColumnGroup) {
14978
- this.foundColumn = null;
14979
- this.service.adjacentColumn = this.firstGroupChild(this.service.adjacentColumn);
14980
- const rowIndex = this.service.adjacentColumn.level + 1;
14981
- const colIndex = this.service.adjacentColumn.leafIndex + 1;
14982
- this.service.adjacentColumn.resizeStartWidth = adjacentColumnInGroupWidth(this.element, rowIndex, colIndex);
14983
- }
14984
- }
14985
- this.service.resizedColumn({
14986
- column: this.service.adjacentColumn,
14987
- oldWidth: this.service.adjacentColumn.resizeStartWidth
14988
- });
14989
- }
14990
- firstGroupChild(column) {
14991
- Array.from(column.children).sort((a, b) => a.orderIndex - b.orderIndex).forEach((c, idx) => {
14992
- if (idx === 0 && !c.isColumnGroup) {
14993
- if (!this.foundColumn) {
14994
- this.foundColumn = c;
14995
- }
14996
- }
14997
- else if (c.isColumnGroup) {
14998
- this.firstGroupChild(c);
14999
- }
15000
- });
15001
- return this.foundColumn;
15002
- }
15003
- setGroupWidths(column) {
15004
- const childrenWidths = column.children.reduce((acc, c) => acc + c.width, 0);
15005
- column.width = childrenWidths;
15006
- column.children.forEach(c => {
15007
- if (c.isColumnGroup) {
15008
- this.setGroupWidths(c);
15009
- }
15010
- });
15011
- }
15012
- updateWidthOfDraggedColumn(column, width) {
15013
- this.totalChildrenSum = 0;
15014
- this.childrenColumns = [];
15015
- this.calcChildrenWidth(this.service.draggedGroupColumn);
15016
- const childrenWidthNotIncludingColumn = this.childrenColumns.reduce((acc, col) => {
15017
- return col !== column ? acc + col.width : acc;
15018
- }, 0);
15019
- this.service.draggedGroupColumn.width = childrenWidthNotIncludingColumn + width;
15020
- if (this.service.adjacentColumn.minResizableWidth <= this.totalChildrenSum + this.service.adjacentColumn.resizeStartWidth - width - childrenWidthNotIncludingColumn) {
15021
- this.service.adjacentColumn.width = this.totalChildrenSum + this.service.adjacentColumn.resizeStartWidth - width - childrenWidthNotIncludingColumn;
15022
- }
15023
- }
15024
- calcChildrenWidth(column) {
15025
- const columnChildren = Array.from(column.children);
15026
- const childrenNoGroups = columnChildren.filter(c => !c.isColumnGroup);
15027
- const childrenGroups = columnChildren.filter(c => c.isColumnGroup);
15028
- childrenNoGroups.forEach(col => {
15029
- if (this.childrenColumns.indexOf(col) === -1) {
15030
- this.childrenColumns.push(col);
15031
- }
15032
- });
15033
- this.totalChildrenSum += childrenNoGroups.reduce((acc, col) => acc + col.resizeStartWidth, 0);
15034
- childrenGroups.forEach((col) => {
15035
- this.calcChildrenWidth(col);
15036
- });
15037
- }
15038
14831
  columnsForLevel(level) {
15039
14832
  return columnsToRender(this.columns ? this.columns.filter(column => column.level === level) : []);
15040
14833
  }
15041
- minAdjacentColumnWidth(column) {
15042
- if (column.isColumnGroup) {
15043
- Array.from(column.children).forEach(c => {
15044
- this.minAdjacentColumnWidth(c);
15045
- });
15046
- }
15047
- else {
15048
- this.minWidthTotal += column.minResizableWidth;
15049
- if (column.width < column.minResizableWidth) {
15050
- column.width = column.minResizableWidth;
15051
- }
15052
- }
15053
- return this.minWidthTotal;
15054
- }
15055
14834
  getTableDelta(newWidth, delta) {
15056
14835
  const minWidth = this.column.minResizableWidth;
15057
14836
  const maxWidth = this.column.maxResizableWidth;
@@ -15076,18 +14855,6 @@ class ColumnHandleDirective {
15076
14855
  event.stopPropagation();
15077
14856
  event.preventDefault();
15078
14857
  };
15079
- isLastInGroup(column) {
15080
- if (column.parent) {
15081
- const groupChildren = Array.from(column.parent.children);
15082
- const indexOfCurrentColumn = groupChildren.indexOf(column);
15083
- if (column.isReordered || column.orderIndex > 0 || (column.isReordered && column.orderIndex === 0)) {
15084
- return (column.orderIndex - groupChildren[0].orderIndex) === groupChildren.length - 1;
15085
- }
15086
- else {
15087
- return indexOfCurrentColumn === groupChildren.length - 1;
15088
- }
15089
- }
15090
- }
15091
14858
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColumnHandleDirective, deps: [{ token: i1$3.DraggableDirective, host: true }, { token: i0.ElementRef }, { token: ColumnResizingService }, { token: i0.NgZone }, { token: i0.ChangeDetectorRef }, { token: ContextService }, { token: ColumnInfoService }], target: i0.ɵɵFactoryTarget.Directive });
15092
14859
  static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: ColumnHandleDirective, isStandalone: true, selector: "[kendoGridColumnHandle]", inputs: { isLast: "isLast", columns: "columns", column: "column" }, host: { listeners: { "dblclick": "autoFit()" }, properties: { "style.display": "this.visible", "style.left": "this.leftStyle", "style.right": "this.rightStyle" } }, ngImport: i0 });
15093
14860
  }
@@ -16508,6 +16275,9 @@ class HeaderComponent {
16508
16275
  isCheckboxColumn(column) {
16509
16276
  return isCheckboxColumn(column) && !column.templateRef;
16510
16277
  }
16278
+ trackByIndex(index) {
16279
+ return index;
16280
+ }
16511
16281
  addStickyStyles(column) {
16512
16282
  const stickyStyles = this.columnInfoService.stickyColumnsStyles(column);
16513
16283
  return { ...column.headerStyle, ...stickyStyles };
@@ -16646,7 +16416,7 @@ class HeaderComponent {
16646
16416
  *ngIf="detailTemplate?.templateRef"
16647
16417
  >
16648
16418
  </th>
16649
- <ng-container *ngFor="let column of columnsForLevel(levelIndex); let columnIndex = index; let last = last;">
16419
+ <ng-container *ngFor="let column of columnsForLevel(levelIndex); trackBy: trackByIndex; let columnIndex = index; let last = last;">
16650
16420
  <th *ngIf="!isColumnGroupComponent(column)"
16651
16421
  kendoGridLogicalCell
16652
16422
  [logicalRowIndex]="levelIndex"
@@ -16873,7 +16643,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
16873
16643
  *ngIf="detailTemplate?.templateRef"
16874
16644
  >
16875
16645
  </th>
16876
- <ng-container *ngFor="let column of columnsForLevel(levelIndex); let columnIndex = index; let last = last;">
16646
+ <ng-container *ngFor="let column of columnsForLevel(levelIndex); trackBy: trackByIndex; let columnIndex = index; let last = last;">
16877
16647
  <th *ngIf="!isColumnGroupComponent(column)"
16878
16648
  kendoGridLogicalCell
16879
16649
  [logicalRowIndex]="levelIndex"
@@ -19710,8 +19480,8 @@ const packageMetadata = {
19710
19480
  productName: 'Kendo UI for Angular',
19711
19481
  productCode: 'KENDOUIANGULAR',
19712
19482
  productCodes: ['KENDOUIANGULAR'],
19713
- publishDate: 1738834037,
19714
- version: '18.1.0-develop.19',
19483
+ publishDate: 1738227350,
19484
+ version: '18.1.0-develop.2',
19715
19485
  licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/'
19716
19486
  };
19717
19487
 
@@ -21671,7 +21441,7 @@ class TableDirective {
21671
21441
  const constrainedModeNoShift = this.ctx.grid?.resizable === 'constrained' && !this.service.isShiftPressed;
21672
21442
  const unconstrainedModeShift = (this.ctx.grid?.resizable === true || this.ctx.grid?.resizable === 'unconstrained') && this.service.isShiftPressed;
21673
21443
  const isConstrainedMode = constrainedModeNoShift || unconstrainedModeShift;
21674
- if (isConstrainedMode && !this.service.autoFitResize) {
21444
+ if (isConstrainedMode) {
21675
21445
  this.renderer.setStyle(this.element.nativeElement, 'width', this.service.originalWidth + 'px');
21676
21446
  }
21677
21447
  else {
@@ -23700,11 +23470,6 @@ class GridComponent {
23700
23470
  * @default false
23701
23471
  */
23702
23472
  groupable = false;
23703
- /**
23704
- * Determines whether the Grid can be resized.
23705
- * @default false
23706
- */
23707
- gridResizable = false;
23708
23473
  /**
23709
23474
  * Enables the [row reordering]({% slug reordering_rows_grid %}) of the Grid.
23710
23475
  * @default false
@@ -24042,21 +23807,6 @@ class GridComponent {
24042
23807
  get noScrollbarClass() {
24043
23808
  return this.scrollbarWidth === 0;
24044
23809
  }
24045
- get isResizable() {
24046
- return Boolean(this.gridResizable);
24047
- }
24048
- get minWidth() {
24049
- return this.gridResizable.minWidth;
24050
- }
24051
- get maxWidth() {
24052
- return this.gridResizable.maxWidth;
24053
- }
24054
- get minHeight() {
24055
- return this.gridResizable.minHeight;
24056
- }
24057
- get maxHeight() {
24058
- return this.gridResizable.maxHeight;
24059
- }
24060
23810
  detailTemplateChildren;
24061
23811
  get detailTemplate() {
24062
23812
  if (this._customDetailTemplate) {
@@ -25016,19 +24766,16 @@ class GridComponent {
25016
24766
  }
25017
24767
  else if (column === source) {
25018
24768
  i += toSkip;
25019
- column.isReordered = true;
25020
24769
  continue;
25021
24770
  }
25022
24771
  else {
25023
24772
  column.orderIndex = nextIndex;
25024
24773
  }
25025
- column.isReordered = true;
25026
24774
  nextIndex++;
25027
24775
  i++;
25028
24776
  }
25029
24777
  for (i = sourceColumnIndex; i < sourceColumnIndex + toSkip; i++) {
25030
24778
  expandedColumns[i].orderIndex = nextSourceIndex++;
25031
- expandedColumns[i].isReordered = true;
25032
24779
  }
25033
24780
  this.updateIndicesForLevel(source.level + 1);
25034
24781
  this.columnResizingService.areColumnsReordered = true;
@@ -25041,11 +24788,7 @@ class GridComponent {
25041
24788
  colsForLevel.push(...c.childrenArray.sort((a, b) => a.orderIndex - b.orderIndex));
25042
24789
  }
25043
24790
  });
25044
- expandColumnsWithSpan(colsForLevel).map((c, i) => {
25045
- c.orderIndex = i;
25046
- c.isReordered = true;
25047
- return c;
25048
- });
24791
+ expandColumnsWithSpan(colsForLevel).map((c, i) => c.orderIndex = i);
25049
24792
  if (level < this.columnList.totalColumnLevels()) {
25050
24793
  this.updateIndicesForLevel(level + 1);
25051
24794
  }
@@ -25363,8 +25106,8 @@ class GridComponent {
25363
25106
  .filter(item => isTruthy(item.column.resizable) && !item.column.isColumnGroup)
25364
25107
  .map(item => ({
25365
25108
  column: item.column,
25366
- newWidth: roundDown(item.column.width),
25367
- oldWidth: roundDown(item.oldWidth)
25109
+ newWidth: item.column.width,
25110
+ oldWidth: item.oldWidth
25368
25111
  }));
25369
25112
  this.columnResize.emit(args);
25370
25113
  }
@@ -25485,7 +25228,7 @@ class GridComponent {
25485
25228
  this.dropTargetContainer?.notify();
25486
25229
  }
25487
25230
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: GridComponent, deps: [{ token: BrowserSupportService }, { token: SelectionService }, { token: CellSelectionService }, { token: i0.ElementRef }, { token: GroupInfoService }, { token: GroupsService }, { token: ChangeNotificationService }, { token: DetailsService }, { token: EditService }, { token: FilterService }, { token: PDFService }, { token: ResponsiveService }, { token: i0.Renderer2 }, { token: ExcelService }, { token: i0.NgZone }, { token: ScrollSyncService }, { token: DomEventsService }, { token: ColumnResizingService }, { token: i0.ChangeDetectorRef }, { token: ColumnReorderService }, { token: ColumnInfoService }, { token: NavigationService }, { token: SortService }, { token: ScrollRequestService }, { token: i1$2.LocalizationService }, { token: ContextService }, { token: SizingOptionsService }, { token: RowReorderService }], target: i0.ɵɵFactoryTarget.Component });
25488
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: GridComponent, isStandalone: true, selector: "kendo-grid", inputs: { data: "data", pageSize: "pageSize", height: "height", rowHeight: "rowHeight", detailRowHeight: "detailRowHeight", skip: "skip", scrollable: "scrollable", selectable: "selectable", sort: "sort", size: "size", trackBy: "trackBy", filter: "filter", group: "group", virtualColumns: "virtualColumns", filterable: "filterable", sortable: "sortable", pageable: "pageable", groupable: "groupable", gridResizable: "gridResizable", rowReorderable: "rowReorderable", navigable: "navigable", navigatable: "navigatable", autoSize: "autoSize", rowClass: "rowClass", rowSticky: "rowSticky", rowSelected: "rowSelected", isRowSelectable: "isRowSelectable", cellSelected: "cellSelected", resizable: "resizable", reorderable: "reorderable", loading: "loading", columnMenu: "columnMenu", hideHeader: "hideHeader", isDetailExpanded: "isDetailExpanded", isGroupExpanded: "isGroupExpanded" }, outputs: { filterChange: "filterChange", pageChange: "pageChange", groupChange: "groupChange", sortChange: "sortChange", selectionChange: "selectionChange", rowReorder: "rowReorder", dataStateChange: "dataStateChange", groupExpand: "groupExpand", groupCollapse: "groupCollapse", detailExpand: "detailExpand", detailCollapse: "detailCollapse", edit: "edit", cancel: "cancel", save: "save", remove: "remove", add: "add", cellClose: "cellClose", cellClick: "cellClick", pdfExport: "pdfExport", excelExport: "excelExport", columnResize: "columnResize", columnReorder: "columnReorder", columnVisibilityChange: "columnVisibilityChange", columnLockedChange: "columnLockedChange", columnStickyChange: "columnStickyChange", scrollBottom: "scrollBottom", contentScroll: "contentScroll" }, host: { properties: { "attr.dir": "this.dir", "class.k-grid": "this.hostClass", "class.k-grid-sm": "this.sizeSmallClass", "class.k-grid-md": "this.sizeMediumClass", "class.k-grid-lockedcolumns": "this.lockedClasses", "class.k-grid-virtual": "this.virtualClasses", "class.k-grid-no-scrollbar": "this.noScrollbarClass", "class.k-grid-resizable": "this.isResizable", "style.minWidth": "this.minWidth", "style.maxWidth": "this.maxWidth", "style.minHeight": "this.minHeight", "style.maxHeight": "this.maxHeight" } }, providers: [
25231
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: GridComponent, isStandalone: true, selector: "kendo-grid", inputs: { data: "data", pageSize: "pageSize", height: "height", rowHeight: "rowHeight", detailRowHeight: "detailRowHeight", skip: "skip", scrollable: "scrollable", selectable: "selectable", sort: "sort", size: "size", trackBy: "trackBy", filter: "filter", group: "group", virtualColumns: "virtualColumns", filterable: "filterable", sortable: "sortable", pageable: "pageable", groupable: "groupable", rowReorderable: "rowReorderable", navigable: "navigable", navigatable: "navigatable", autoSize: "autoSize", rowClass: "rowClass", rowSticky: "rowSticky", rowSelected: "rowSelected", isRowSelectable: "isRowSelectable", cellSelected: "cellSelected", resizable: "resizable", reorderable: "reorderable", loading: "loading", columnMenu: "columnMenu", hideHeader: "hideHeader", isDetailExpanded: "isDetailExpanded", isGroupExpanded: "isGroupExpanded" }, outputs: { filterChange: "filterChange", pageChange: "pageChange", groupChange: "groupChange", sortChange: "sortChange", selectionChange: "selectionChange", rowReorder: "rowReorder", dataStateChange: "dataStateChange", groupExpand: "groupExpand", groupCollapse: "groupCollapse", detailExpand: "detailExpand", detailCollapse: "detailCollapse", edit: "edit", cancel: "cancel", save: "save", remove: "remove", add: "add", cellClose: "cellClose", cellClick: "cellClick", pdfExport: "pdfExport", excelExport: "excelExport", columnResize: "columnResize", columnReorder: "columnReorder", columnVisibilityChange: "columnVisibilityChange", columnLockedChange: "columnLockedChange", columnStickyChange: "columnStickyChange", scrollBottom: "scrollBottom", contentScroll: "contentScroll" }, host: { properties: { "attr.dir": "this.dir", "class.k-grid": "this.hostClass", "class.k-grid-sm": "this.sizeSmallClass", "class.k-grid-md": "this.sizeMediumClass", "class.k-grid-lockedcolumns": "this.lockedClasses", "class.k-grid-virtual": "this.virtualClasses", "class.k-grid-no-scrollbar": "this.noScrollbarClass" } }, providers: [
25489
25232
  BrowserSupportService,
25490
25233
  LocalizationService,
25491
25234
  ColumnInfoService,
@@ -26942,8 +26685,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
26942
26685
  type: Input
26943
26686
  }], groupable: [{
26944
26687
  type: Input
26945
- }], gridResizable: [{
26946
- type: Input
26947
26688
  }], rowReorderable: [{
26948
26689
  type: Input
26949
26690
  }], navigable: [{
@@ -27050,21 +26791,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
27050
26791
  }], noScrollbarClass: [{
27051
26792
  type: HostBinding,
27052
26793
  args: ['class.k-grid-no-scrollbar']
27053
- }], isResizable: [{
27054
- type: HostBinding,
27055
- args: ['class.k-grid-resizable']
27056
- }], minWidth: [{
27057
- type: HostBinding,
27058
- args: ['style.minWidth']
27059
- }], maxWidth: [{
27060
- type: HostBinding,
27061
- args: ['style.maxWidth']
27062
- }], minHeight: [{
27063
- type: HostBinding,
27064
- args: ['style.minHeight']
27065
- }], maxHeight: [{
27066
- type: HostBinding,
27067
- args: ['style.maxHeight']
27068
26794
  }], detailTemplateChildren: [{
27069
26795
  type: ContentChildren,
27070
26796
  args: [DetailTemplateDirective]
@@ -80,7 +80,6 @@ import { DragTargetContainerDirective, DragTargetDataFn, DropTargetContainerDire
80
80
  import { RowReorderService } from './row-reordering/row-reorder.service';
81
81
  import { StatusBarTemplateDirective } from './aggregates/status-bar-template.directive';
82
82
  import { PagerTemplateDirective } from '@progress/kendo-angular-pager';
83
- import { GridResizableSettings } from './common/resizable-settings';
84
83
  import * as i0 from "@angular/core";
85
84
  /**
86
85
  * Represents the Kendo UI for Angular Data Grid component.
@@ -272,11 +271,6 @@ export declare class GridComponent implements AfterContentInit, AfterViewInit, O
272
271
  * @default false
273
272
  */
274
273
  groupable: GroupableSettings | boolean;
275
- /**
276
- * Determines whether the Grid can be resized.
277
- * @default false
278
- */
279
- gridResizable: GridResizableSettings | boolean;
280
274
  /**
281
275
  * Enables the [row reordering]({% slug reordering_rows_grid %}) of the Grid.
282
276
  * @default false
@@ -522,11 +516,6 @@ export declare class GridComponent implements AfterContentInit, AfterViewInit, O
522
516
  get lockedClasses(): boolean;
523
517
  get virtualClasses(): boolean;
524
518
  get noScrollbarClass(): boolean;
525
- get isResizable(): boolean;
526
- get minWidth(): string;
527
- get maxWidth(): string;
528
- get minHeight(): string;
529
- get maxHeight(): string;
530
519
  detailTemplateChildren: QueryList<DetailTemplateDirective>;
531
520
  get detailTemplate(): DetailTemplateDirective;
532
521
  set detailTemplate(detailTemplate: DetailTemplateDirective);
@@ -945,5 +934,5 @@ export declare class GridComponent implements AfterContentInit, AfterViewInit, O
945
934
  private shouldResetSelection;
946
935
  private notifyReorderContainers;
947
936
  static ɵfac: i0.ɵɵFactoryDeclaration<GridComponent, never>;
948
- static ɵcmp: i0.ɵɵComponentDeclaration<GridComponent, "kendo-grid", ["kendoGrid"], { "data": { "alias": "data"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "height": { "alias": "height"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "detailRowHeight": { "alias": "detailRowHeight"; "required": false; }; "skip": { "alias": "skip"; "required": false; }; "scrollable": { "alias": "scrollable"; "required": false; }; "selectable": { "alias": "selectable"; "required": false; }; "sort": { "alias": "sort"; "required": false; }; "size": { "alias": "size"; "required": false; }; "trackBy": { "alias": "trackBy"; "required": false; }; "filter": { "alias": "filter"; "required": false; }; "group": { "alias": "group"; "required": false; }; "virtualColumns": { "alias": "virtualColumns"; "required": false; }; "filterable": { "alias": "filterable"; "required": false; }; "sortable": { "alias": "sortable"; "required": false; }; "pageable": { "alias": "pageable"; "required": false; }; "groupable": { "alias": "groupable"; "required": false; }; "gridResizable": { "alias": "gridResizable"; "required": false; }; "rowReorderable": { "alias": "rowReorderable"; "required": false; }; "navigable": { "alias": "navigable"; "required": false; }; "navigatable": { "alias": "navigatable"; "required": false; }; "autoSize": { "alias": "autoSize"; "required": false; }; "rowClass": { "alias": "rowClass"; "required": false; }; "rowSticky": { "alias": "rowSticky"; "required": false; }; "rowSelected": { "alias": "rowSelected"; "required": false; }; "isRowSelectable": { "alias": "isRowSelectable"; "required": false; }; "cellSelected": { "alias": "cellSelected"; "required": false; }; "resizable": { "alias": "resizable"; "required": false; }; "reorderable": { "alias": "reorderable"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "columnMenu": { "alias": "columnMenu"; "required": false; }; "hideHeader": { "alias": "hideHeader"; "required": false; }; "isDetailExpanded": { "alias": "isDetailExpanded"; "required": false; }; "isGroupExpanded": { "alias": "isGroupExpanded"; "required": false; }; }, { "filterChange": "filterChange"; "pageChange": "pageChange"; "groupChange": "groupChange"; "sortChange": "sortChange"; "selectionChange": "selectionChange"; "rowReorder": "rowReorder"; "dataStateChange": "dataStateChange"; "groupExpand": "groupExpand"; "groupCollapse": "groupCollapse"; "detailExpand": "detailExpand"; "detailCollapse": "detailCollapse"; "edit": "edit"; "cancel": "cancel"; "save": "save"; "remove": "remove"; "add": "add"; "cellClose": "cellClose"; "cellClick": "cellClick"; "pdfExport": "pdfExport"; "excelExport": "excelExport"; "columnResize": "columnResize"; "columnReorder": "columnReorder"; "columnVisibilityChange": "columnVisibilityChange"; "columnLockedChange": "columnLockedChange"; "columnStickyChange": "columnStickyChange"; "scrollBottom": "scrollBottom"; "contentScroll": "contentScroll"; }, ["columns", "detailTemplateChildren", "cellLoadingTemplateChildren", "loadingTemplateChildren", "statusBarTemplateChildren", "noRecordsTemplateChildren", "pagerTemplateChildren", "toolbarTemplateChildren", "columnMenuTemplates"], ["kendo-toolbar"], true, never>;
937
+ static ɵcmp: i0.ɵɵComponentDeclaration<GridComponent, "kendo-grid", ["kendoGrid"], { "data": { "alias": "data"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "height": { "alias": "height"; "required": false; }; "rowHeight": { "alias": "rowHeight"; "required": false; }; "detailRowHeight": { "alias": "detailRowHeight"; "required": false; }; "skip": { "alias": "skip"; "required": false; }; "scrollable": { "alias": "scrollable"; "required": false; }; "selectable": { "alias": "selectable"; "required": false; }; "sort": { "alias": "sort"; "required": false; }; "size": { "alias": "size"; "required": false; }; "trackBy": { "alias": "trackBy"; "required": false; }; "filter": { "alias": "filter"; "required": false; }; "group": { "alias": "group"; "required": false; }; "virtualColumns": { "alias": "virtualColumns"; "required": false; }; "filterable": { "alias": "filterable"; "required": false; }; "sortable": { "alias": "sortable"; "required": false; }; "pageable": { "alias": "pageable"; "required": false; }; "groupable": { "alias": "groupable"; "required": false; }; "rowReorderable": { "alias": "rowReorderable"; "required": false; }; "navigable": { "alias": "navigable"; "required": false; }; "navigatable": { "alias": "navigatable"; "required": false; }; "autoSize": { "alias": "autoSize"; "required": false; }; "rowClass": { "alias": "rowClass"; "required": false; }; "rowSticky": { "alias": "rowSticky"; "required": false; }; "rowSelected": { "alias": "rowSelected"; "required": false; }; "isRowSelectable": { "alias": "isRowSelectable"; "required": false; }; "cellSelected": { "alias": "cellSelected"; "required": false; }; "resizable": { "alias": "resizable"; "required": false; }; "reorderable": { "alias": "reorderable"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "columnMenu": { "alias": "columnMenu"; "required": false; }; "hideHeader": { "alias": "hideHeader"; "required": false; }; "isDetailExpanded": { "alias": "isDetailExpanded"; "required": false; }; "isGroupExpanded": { "alias": "isGroupExpanded"; "required": false; }; }, { "filterChange": "filterChange"; "pageChange": "pageChange"; "groupChange": "groupChange"; "sortChange": "sortChange"; "selectionChange": "selectionChange"; "rowReorder": "rowReorder"; "dataStateChange": "dataStateChange"; "groupExpand": "groupExpand"; "groupCollapse": "groupCollapse"; "detailExpand": "detailExpand"; "detailCollapse": "detailCollapse"; "edit": "edit"; "cancel": "cancel"; "save": "save"; "remove": "remove"; "add": "add"; "cellClose": "cellClose"; "cellClick": "cellClick"; "pdfExport": "pdfExport"; "excelExport": "excelExport"; "columnResize": "columnResize"; "columnReorder": "columnReorder"; "columnVisibilityChange": "columnVisibilityChange"; "columnLockedChange": "columnLockedChange"; "columnStickyChange": "columnStickyChange"; "scrollBottom": "scrollBottom"; "contentScroll": "contentScroll"; }, ["columns", "detailTemplateChildren", "cellLoadingTemplateChildren", "loadingTemplateChildren", "statusBarTemplateChildren", "noRecordsTemplateChildren", "pagerTemplateChildren", "toolbarTemplateChildren", "columnMenuTemplates"], ["kendo-toolbar"], true, never>;
949
938
  }