igniteui-angular 15.1.0 → 15.1.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.
@@ -3400,7 +3400,7 @@ class IgxBaseExporter {
3400
3400
  const ownerCols = this._ownersMap.get(owner).columns;
3401
3401
  if (record.type !== ExportRecordType.HeaderRecord) {
3402
3402
  const columns = ownerCols
3403
- .filter(c => c.headerType !== HeaderType.MultiColumnHeader && c.headerType !== HeaderType.RowHeader && c.headerType !== HeaderType.MultiRowHeader && !c.skip)
3403
+ .filter(c => c.headerType === HeaderType.ColumnHeader && !c.skip)
3404
3404
  .sort((a, b) => a.startIndex - b.startIndex)
3405
3405
  .sort((a, b) => a.pinnedIndex - b.pinnedIndex);
3406
3406
  record.data = columns.reduce((a, e) => {
@@ -3875,7 +3875,10 @@ class IgxBaseExporter {
3875
3875
  return;
3876
3876
  }
3877
3877
  let previousKey = '';
3878
- const firstCol = this._ownersMap.get(DEFAULT_OWNER).columns[0].field;
3878
+ const firstCol = this._ownersMap.get(DEFAULT_OWNER).columns
3879
+ .filter(c => c.headerType === HeaderType.ColumnHeader && !c.skip)
3880
+ .sort((a, b) => a.startIndex - b.startIndex)
3881
+ .sort((a, b) => a.pinnedIndex - b.pinnedIndex)[0].field;
3879
3882
  for (const record of records) {
3880
3883
  let recordVal = record.value;
3881
3884
  const hierarchicalOwner = setGridParent ? GRID_PARENT : `${GRID_CHILD}${++this.rowIslandCounter}`;
@@ -4926,7 +4929,7 @@ class WorksheetFile {
4926
4929
  }
4927
4930
  else {
4928
4931
  recordHeaders = worksheetData.owner.columns
4929
- .filter(c => c.headerType !== HeaderType.MultiColumnHeader && c.headerType !== HeaderType.MultiRowHeader && c.headerType !== HeaderType.RowHeader && !c.skip)
4932
+ .filter(c => c.headerType === HeaderType.ColumnHeader && !c.skip)
4930
4933
  .sort((a, b) => a.startIndex - b.startIndex)
4931
4934
  .sort((a, b) => a.pinnedIndex - b.pinnedIndex)
4932
4935
  .map(c => c.field);
@@ -36414,6 +36417,11 @@ class IgxChipComponent extends DisplayDensityBase {
36414
36417
  * @internal
36415
36418
  */
36416
36419
  this.hideBaseElement = false;
36420
+ /**
36421
+ * @hidden
36422
+ * @internal
36423
+ */
36424
+ this.destroy$ = new Subject();
36417
36425
  this._tabIndex = null;
36418
36426
  this._selected = false;
36419
36427
  this._selectedItemClass = 'igx-chip__item--selected';
@@ -36687,6 +36695,10 @@ class IgxChipComponent extends DisplayDensityBase {
36687
36695
  }
36688
36696
  }
36689
36697
  }
36698
+ ngOnDestroy() {
36699
+ this.destroy$.next();
36700
+ this.destroy$.complete();
36701
+ }
36690
36702
  }
36691
36703
  IgxChipComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0", ngImport: i0, type: IgxChipComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: DisplayDensityToken, optional: true }], target: i0.ɵɵFactoryTarget.Component });
36692
36704
  IgxChipComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.0", type: IgxChipComponent, selector: "igx-chip", inputs: { id: "id", tabIndex: "tabIndex", data: "data", draggable: "draggable", animateOnRelease: "animateOnRelease", hideBaseOnDrag: "hideBaseOnDrag", removable: "removable", removeIcon: "removeIcon", selectable: "selectable", selectIcon: "selectIcon", disabled: "disabled", selected: "selected", color: "color", resourceStrings: "resourceStrings" }, outputs: { selectedChange: "selectedChange", moveStart: "moveStart", moveEnd: "moveEnd", remove: "remove", chipClick: "chipClick", selectedChanging: "selectedChanging", selectedChanged: "selectedChanged", keyDown: "keyDown", dragEnter: "dragEnter", dragLeave: "dragLeave", dragOver: "dragOver", dragDrop: "dragDrop" }, host: { listeners: { "keydown": "keyEvent($event)" }, properties: { "attr.id": "this.id", "attr.role": "this.role", "attr.tabIndex": "this.tabIndex", "attr.aria-selected": "this.selected", "class": "this.hostClass" } }, viewQueries: [{ propertyName: "dragDirective", first: true, predicate: ["chipArea"], descendants: true, read: IgxDragDirective, static: true }, { propertyName: "chipArea", first: true, predicate: ["chipArea"], descendants: true, read: ElementRef, static: true }, { propertyName: "selectContainer", first: true, predicate: ["selectContainer"], descendants: true, read: ElementRef, static: true }, { propertyName: "defaultRemoveIcon", first: true, predicate: ["defaultRemoveIcon"], descendants: true, read: TemplateRef, static: true }, { propertyName: "defaultSelectIcon", first: true, predicate: ["defaultSelectIcon"], descendants: true, read: TemplateRef, static: true }], usesInheritance: true, ngImport: i0, template: "<div #chipArea class=\"igx-chip__item\"\n [igxDrag]=\"{chip: this}\"\n [style.visibility]='hideBaseElement ? \"hidden\" : \"visible\"'\n [ghostClass]=\"ghostClass\"\n (dragStart)=\"onChipDragStart($event)\"\n (ghostCreate)=\"onChipGhostCreate()\"\n (ghostDestroy)=\"onChipGhostDestroy()\"\n (dragEnd)=\"onChipDragEnd()\"\n (transitioned)=\"onChipMoveEnd($event)\"\n (dragClick)=\"onChipDragClicked($event)\"\n igxDrop\n (enter)=\"onChipDragEnterHandler($event)\"\n (leave)= \"onChipDragLeaveHandler($event)\"\n (over)=\"onChipOverHandler($event)\"\n (dropped)=\"onChipDrop($event)\">\n\n <div #selectContainer [ngClass]=\"selectClass(selected)\">\n <ng-container *ngTemplateOutlet=\"selectIconTemplate\"></ng-container>\n </div>\n\n <ng-content select=\"igx-prefix,[igxPrefix]\"></ng-content>\n\n <div class=\"igx-chip__content\">\n <ng-content></ng-content>\n </div>\n\n <ng-content select=\"igx-suffix,[igxSuffix]\"></ng-content>\n\n <div class=\"igx-chip__remove\" *ngIf=\"removable\"\n [attr.tabIndex]=\"tabIndex\"\n (keydown)=\"onRemoveBtnKeyDown($event)\"\n (pointerdown)=\"onRemoveMouseDown($event)\"\n (mousedown)=\"onRemoveMouseDown($event)\"\n (click)=\"onRemoveClick($event)\"\n (touchmove)=\"onRemoveTouchMove()\"\n (touchend)=\"onRemoveTouchEnd($event)\">\n <ng-container *ngTemplateOutlet=\"removeButtonTemplate\"></ng-container>\n </div>\n</div>\n\n<ng-template #defaultSelectIcon>\n <igx-icon [attr.aria-label]=\"resourceStrings.igx_chip_select\">done</igx-icon>\n</ng-template>\n\n<ng-template #defaultRemoveIcon>\n <igx-icon [attr.aria-label]=\"resourceStrings.igx_chip_remove\">cancel</igx-icon>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: IgxIconComponent, selector: "igx-icon", inputs: ["family", "active", "name"] }, { kind: "directive", type: IgxDragDirective, selector: "[igxDrag]", inputs: ["igxDrag", "dragTolerance", "dragDirection", "dragChannel", "ghost", "ghostClass", "ghostTemplate", "ghostHost", "scrollContainer", "ghostOffsetX", "ghostOffsetY"], outputs: ["dragStart", "dragMove", "dragEnd", "dragClick", "ghostCreate", "ghostDestroy", "transitioned"], exportAs: ["drag"] }, { kind: "directive", type: IgxDropDirective, selector: "[igxDrop]", inputs: ["igxDrop", "dropChannel", "dropStrategy"], outputs: ["enter", "over", "leave", "dropped"], exportAs: ["drop"] }] });
@@ -36908,20 +36920,20 @@ class IgxChipsAreaComponent {
36908
36920
  const changes = this._differ.diff(this.chipsList.toArray());
36909
36921
  if (changes) {
36910
36922
  changes.forEachAddedItem((addedChip) => {
36911
- addedChip.item.moveStart.pipe(takeUntil(this.destroy$)).subscribe((args) => {
36923
+ addedChip.item.moveStart.pipe(takeUntil(addedChip.item.destroy$)).subscribe((args) => {
36912
36924
  this.onChipMoveStart(args);
36913
36925
  });
36914
- addedChip.item.moveEnd.pipe(takeUntil(this.destroy$)).subscribe((args) => {
36926
+ addedChip.item.moveEnd.pipe(takeUntil(addedChip.item.destroy$)).subscribe((args) => {
36915
36927
  this.onChipMoveEnd(args);
36916
36928
  });
36917
- addedChip.item.dragEnter.pipe(takeUntil(this.destroy$)).subscribe((args) => {
36929
+ addedChip.item.dragEnter.pipe(takeUntil(addedChip.item.destroy$)).subscribe((args) => {
36918
36930
  this.onChipDragEnter(args);
36919
36931
  });
36920
- addedChip.item.keyDown.pipe(takeUntil(this.destroy$)).subscribe((args) => {
36932
+ addedChip.item.keyDown.pipe(takeUntil(addedChip.item.destroy$)).subscribe((args) => {
36921
36933
  this.onChipKeyDown(args);
36922
36934
  });
36923
36935
  if (addedChip.item.selectable) {
36924
- addedChip.item.selectedChanging.pipe(takeUntil(this.destroy$)).subscribe((args) => {
36936
+ addedChip.item.selectedChanging.pipe(takeUntil(addedChip.item.destroy$)).subscribe((args) => {
36925
36937
  this.onChipSelectionChange(args);
36926
36938
  });
36927
36939
  }
@@ -39684,13 +39696,7 @@ class IgxSimpleComboComponent extends IgxComboBaseDirective {
39684
39696
  return;
39685
39697
  }
39686
39698
  this.clearSelection(true);
39687
- if (this.collapsed) {
39688
- this.filterValue = '';
39689
- this.cdr.detectChanges();
39690
- this.open();
39691
- this.dropdown.navigateFirst();
39692
- }
39693
- else {
39699
+ if (!this.collapsed) {
39694
39700
  this.focusSearchInput(true);
39695
39701
  }
39696
39702
  event.stopPropagation();
@@ -57318,8 +57324,8 @@ class IgxQueryBuilderComponent extends DisplayDensityBase {
57318
57324
  const index = parent.children.indexOf(firstExpression);
57319
57325
  parent.children.splice(index, 0, groupItem);
57320
57326
  for (const expr of this.selectedExpressions) {
57321
- this.deleteItem(expr);
57322
57327
  groupItem.children.push(expr);
57328
+ this.deleteItem(expr);
57323
57329
  expr.parent = groupItem;
57324
57330
  }
57325
57331
  this.clearSelection();
@@ -59179,13 +59185,13 @@ class IgxGridFilteringRowComponent {
59179
59185
  return this.expression ? this.expression.searchVal : null;
59180
59186
  }
59181
59187
  set value(val) {
59182
- if (!val && val !== 0) {
59188
+ if (!val && val !== 0 && this.expression.searchVal) {
59183
59189
  this.expression.searchVal = null;
59184
59190
  const index = this.expressionsList.findIndex(item => item.expression === this.expression);
59185
59191
  if (index === 0 && this.expressionsList.length === 1) {
59186
59192
  this.filteringService.clearFilter(this.column.field);
59187
59193
  if (this.expression.condition.isUnary) {
59188
- this.resetExpression();
59194
+ this.resetExpression(this.expression.condition.name);
59189
59195
  }
59190
59196
  return;
59191
59197
  }
@@ -59746,7 +59752,7 @@ class IgxGridFilteringRowComponent {
59746
59752
  }
59747
59753
  this.showHideArrowButtons();
59748
59754
  }
59749
- resetExpression() {
59755
+ resetExpression(condition) {
59750
59756
  this.expression = {
59751
59757
  fieldName: this.column.field,
59752
59758
  condition: null,
@@ -59754,7 +59760,7 @@ class IgxGridFilteringRowComponent {
59754
59760
  ignoreCase: this.column.filteringIgnoreCase
59755
59761
  };
59756
59762
  if (this.column.dataType !== GridColumnDataType.Boolean) {
59757
- this.expression.condition = this.getCondition(this.conditions[0]);
59763
+ this.expression.condition = this.getCondition(condition ?? this.conditions[0]);
59758
59764
  }
59759
59765
  if (this.column.dataType === GridColumnDataType.Date && this.input) {
59760
59766
  this.input.nativeElement.value = null;
@@ -83131,6 +83137,9 @@ class IgxChildGridRowComponent {
83131
83137
  * @hidden
83132
83138
  */
83133
83139
  ngOnInit() {
83140
+ const ref = this.container.createComponent(IgxHierarchicalGridComponent, { injector: this.container.injector });
83141
+ this.hGrid = ref.instance;
83142
+ this.hGrid.data = this.data.childGridsData[this.layout.key];
83134
83143
  this.layout.layoutChange.subscribe((ch) => {
83135
83144
  this._handleLayoutChanges(ch);
83136
83145
  });
@@ -83196,10 +83205,10 @@ class IgxChildGridRowComponent {
83196
83205
  }
83197
83206
  }
83198
83207
  IgxChildGridRowComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.0", ngImport: i0, type: IgxChildGridRowComponent, deps: [{ token: IGX_GRID_SERVICE_BASE }, { token: i0.ElementRef }, { token: i0.ComponentFactoryResolver }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
83199
- IgxChildGridRowComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.0", type: IgxChildGridRowComponent, selector: "igx-child-grid-row", inputs: { layout: "layout", parentGridID: "parentGridID", data: "data", index: "index" }, host: { properties: { "attr.aria-level": "this.level" } }, viewQueries: [{ propertyName: "hGrid", first: true, predicate: ["hgrid"], descendants: true, static: true }], ngImport: i0, template: "<div class=\"igx-grid__hierarchical-indent\" [ngClass]=\"{'igx-grid__hierarchical-indent--scroll': parentHasScroll}\">\n <igx-hierarchical-grid #hgrid [data]='data.childGridsData[layout.key]'></igx-hierarchical-grid>\n</div>\n", dependencies: [{ kind: "directive", type: i0.forwardRef(function () { return i1$1.NgClass; }), selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i0.forwardRef(function () { return IgxHierarchicalGridComponent; }), selector: "igx-hierarchical-grid", inputs: ["id", "data", "expandChildren"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
83208
+ IgxChildGridRowComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.0", type: IgxChildGridRowComponent, selector: "igx-child-grid-row", inputs: { layout: "layout", parentGridID: "parentGridID", data: "data", index: "index" }, host: { properties: { "attr.aria-level": "this.level" } }, viewQueries: [{ propertyName: "container", first: true, predicate: ["container"], descendants: true, read: ViewContainerRef, static: true }], ngImport: i0, template: "<div class=\"igx-grid__hierarchical-indent\" [ngClass]=\"{'igx-grid__hierarchical-indent--scroll': parentHasScroll}\">\n <ng-container #container></ng-container>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
83200
83209
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0", ngImport: i0, type: IgxChildGridRowComponent, decorators: [{
83201
83210
  type: Component,
83202
- args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'igx-child-grid-row', template: "<div class=\"igx-grid__hierarchical-indent\" [ngClass]=\"{'igx-grid__hierarchical-indent--scroll': parentHasScroll}\">\n <igx-hierarchical-grid #hgrid [data]='data.childGridsData[layout.key]'></igx-hierarchical-grid>\n</div>\n" }]
83211
+ args: [{ changeDetection: ChangeDetectionStrategy.OnPush, selector: 'igx-child-grid-row', template: "<div class=\"igx-grid__hierarchical-indent\" [ngClass]=\"{'igx-grid__hierarchical-indent--scroll': parentHasScroll}\">\n <ng-container #container></ng-container>\n</div>\n" }]
83203
83212
  }], ctorParameters: function () { return [{ type: IgxHierarchicalGridAPIService, decorators: [{
83204
83213
  type: Inject,
83205
83214
  args: [IGX_GRID_SERVICE_BASE]
@@ -83211,9 +83220,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.0", ngImpor
83211
83220
  type: Input
83212
83221
  }], index: [{
83213
83222
  type: Input
83214
- }], hGrid: [{
83223
+ }], container: [{
83215
83224
  type: ViewChild,
83216
- args: ['hgrid', { static: true }]
83225
+ args: ['container', { read: ViewContainerRef, static: true }]
83217
83226
  }], level: [{
83218
83227
  type: HostBinding,
83219
83228
  args: ['attr.aria-level']