diff --git a/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.html b/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.html
index 4a018a09576..8a1718cf1d2 100644
--- a/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.html
+++ b/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.html
@@ -1,4 +1,6 @@
-
-
- {{ litRender(container, templateFunc, context) }}
-
+@for (templateFunc of templateFunctions; track templateFunc) {
+
+
+ {{ litRender(container, templateFunc, context) }}
+
+}
diff --git a/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.ts b/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.ts
index 4faa7636907..35ba746cd94 100644
--- a/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.ts
+++ b/projects/igniteui-angular-elements/src/app/wrapper/wrapper.component.ts
@@ -1,4 +1,3 @@
-import { NgFor } from '@angular/common';
import { ChangeDetectorRef, Component, QueryList, TemplateRef, ViewChildren } from '@angular/core';
import { TemplateRefWrapper } from './template-ref-wrapper';
@@ -10,7 +9,7 @@ type TemplateFunction = (arg: any) => TemplateResult;
selector: 'igx-template-wrapper',
templateUrl: './wrapper.component.html',
styleUrls: ['./wrapper.component.scss'],
- imports: [NgFor]
+ imports: []
})
export class TemplateWrapperComponent {
@@ -18,7 +17,8 @@ export class TemplateWrapperComponent {
/**
* All template refs
- * Warning: the first is always the root `ngFor` template. TODO(D.P.): filter it out?
+ * Warning: the first is always the root `@for` template
+ * (internally creates one like the old `>;
diff --git a/projects/igniteui-angular/src/lib/accordion/accordion.component.spec.ts b/projects/igniteui-angular/src/lib/accordion/accordion.component.spec.ts
index 9589affe459..0e3a5a85b6b 100644
--- a/projects/igniteui-angular/src/lib/accordion/accordion.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/accordion/accordion.component.spec.ts
@@ -1,5 +1,4 @@
import { useAnimation } from '@angular/animations';
-import { NgIf } from '@angular/common';
import { Component, ViewChild } from '@angular/core';
import { waitForAsync, TestBed, fakeAsync, ComponentFixture, tick } from '@angular/core/testing';
import { By } from '@angular/platform-browser';
@@ -401,10 +400,12 @@ describe('Rendering Tests', () => {
-
+ @if (divChild) {
+
+ }
`,
- imports: [IgxAccordionComponent, IgxExpansionPanelComponent, IgxExpansionPanelHeaderComponent, IgxExpansionPanelBodyComponent, IgxExpansionPanelTitleDirective, NgIf]
+ imports: [IgxAccordionComponent, IgxExpansionPanelComponent, IgxExpansionPanelHeaderComponent, IgxExpansionPanelBodyComponent, IgxExpansionPanelTitleDirective]
})
export class IgxAccordionSampleTestComponent {
@ViewChild(IgxAccordionComponent) public accordion: IgxAccordionComponent;
diff --git a/projects/igniteui-angular/src/lib/action-strip/action-strip.component.html b/projects/igniteui-angular/src/lib/action-strip/action-strip.component.html
index 6369fb0bcb1..65566b3f7aa 100644
--- a/projects/igniteui-angular/src/lib/action-strip/action-strip.component.html
+++ b/projects/igniteui-angular/src/lib/action-strip/action-strip.component.html
@@ -1,6 +1,6 @@
- 0">
+ @if (menuItems.length > 0) {
-
+ }
-
+ @for (item of menuItems; track trackMenuItem(item)) {
+
+ }
diff --git a/projects/igniteui-angular/src/lib/action-strip/action-strip.component.ts b/projects/igniteui-angular/src/lib/action-strip/action-strip.component.ts
index d4a2a56f4eb..56bfdf2c6f4 100644
--- a/projects/igniteui-angular/src/lib/action-strip/action-strip.component.ts
+++ b/projects/igniteui-angular/src/lib/action-strip/action-strip.component.ts
@@ -24,10 +24,11 @@ import { IgxIconComponent } from '../icon/icon.component';
import { IgxDropDownItemNavigationDirective } from '../drop-down/drop-down-navigation.directive';
import { IgxToggleActionDirective } from '../directives/toggle/toggle.directive';
import { IgxRippleDirective } from '../directives/ripple/ripple.directive';
-import { NgIf, NgFor, NgTemplateOutlet } from '@angular/common';
+import { NgTemplateOutlet } from '@angular/common';
import { getCurrentResourceStrings } from '../core/i18n/resources';
import { IgxIconButtonDirective } from '../directives/button/icon-button.directive';
import { IgxActionStripToken } from './token';
+import { trackByIdentity } from '../core/utils';
@Directive({
selector: '[igxActionStripMenuItem]',
@@ -73,8 +74,6 @@ export class IgxActionStripMenuItemDirective {
selector: 'igx-action-strip',
templateUrl: 'action-strip.component.html',
imports: [
- NgIf,
- NgFor,
NgTemplateOutlet,
IgxIconButtonDirective,
IgxRippleDirective,
@@ -314,6 +313,9 @@ export class IgxActionStripComponent implements IgxActionStripToken, AfterConten
}
}
+ /** pin swapping w/ unpin resets the menuItems collection */
+ protected trackMenuItem = trackByIdentity;
+
/**
* Close the menu if opened
*
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.html b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.html
index 6cd2a12345e..6eafb5e80b0 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.html
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.html
@@ -1,16 +1,24 @@
-
+@if (!asMenuItem) {
-
+}
-
+ @if (asMenuItem) {
- {{iconName}}
- {{iconName}}
+ @if (iconSet) {
+ {{iconName}}
+ }
+ @if (!iconSet) {
+ {{iconName}}
+ }
-
+ }
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.ts b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.ts
index 545b9065410..64771bd15f4 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.ts
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-action-button.component.ts
@@ -1,7 +1,6 @@
import { Component, Input, TemplateRef, ViewChild, Output, EventEmitter, ElementRef, booleanAttribute } from '@angular/core';
import { IgxIconComponent } from '../../icon/icon.component';
import { IgxRippleDirective } from '../../directives/ripple/ripple.directive';
-import { NgIf } from '@angular/common';
import { IgxIconButtonDirective } from '../../directives/button/icon-button.directive';
/* blazorElement */
@@ -10,7 +9,7 @@ import { IgxIconButtonDirective } from '../../directives/button/icon-button.dire
@Component({
selector: 'igx-grid-action-button',
templateUrl: 'grid-action-button.component.html',
- imports: [NgIf, IgxRippleDirective, IgxIconComponent, IgxIconButtonDirective]
+ imports: [IgxRippleDirective, IgxIconComponent, IgxIconButtonDirective]
})
export class IgxGridActionButtonComponent {
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.html b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.html
index 0448b22086f..b68cf39486d 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.html
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.html
@@ -1,8 +1,16 @@
-
-
-
-
-
-
+@if (isRowContext) {
+ @if (!disabled && editRow) {
+
+ }
+ @if (addRow && isRootRow) {
+
+ }
+ @if (addChild && hasChildren) {
+
+ }
+ @if (!disabled && deleteRow) {
+
+ }
+}
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.spec.ts b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.spec.ts
index d763d414e6e..1abfd40b3b6 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.spec.ts
@@ -1,7 +1,6 @@
import { Component, ViewChild, OnInit } from '@angular/core';
import { TestBed, waitForAsync } from '@angular/core/testing';
import { By } from '@angular/platform-browser';
-import { NgFor } from '@angular/common';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { configureTestSuite } from '../../test-utils/configure-suite';
@@ -391,16 +390,18 @@ describe('igxGridEditingActions #grid ', () => {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
`,
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent]
})
class IgxActionStripTestingComponent implements OnInit {
@ViewChild('actionStrip', { read: IgxActionStripComponent, static: true })
@@ -468,9 +469,11 @@ class IgxActionStripTestingComponent implements OnInit {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
@@ -479,7 +482,7 @@ class IgxActionStripTestingComponent implements OnInit {
`,
selector: 'igx-action-strip-pin-edit-component',
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridPinningActionsComponent, IgxGridEditingActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridPinningActionsComponent, IgxGridEditingActionsComponent]
})
class IgxActionStripPinEditComponent extends IgxActionStripTestingComponent {
}
@@ -488,9 +491,11 @@ class IgxActionStripPinEditComponent extends IgxActionStripTestingComponent {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
@@ -498,7 +503,7 @@ class IgxActionStripPinEditComponent extends IgxActionStripTestingComponent {
`,
selector: 'igx-action-strip-edit-menu-component',
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent]
})
class IgxActionStripEditMenuComponent extends IgxActionStripTestingComponent {
}
@@ -507,9 +512,11 @@ class IgxActionStripEditMenuComponent extends IgxActionStripTestingComponent {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
@@ -518,7 +525,7 @@ class IgxActionStripEditMenuComponent extends IgxActionStripTestingComponent {
`,
selector: 'igx-action-strip-one-row-component',
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent, IgxGridPinningActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent, IgxGridPinningActionsComponent]
})
class IgxActionStripOneRowComponent extends IgxActionStripTestingComponent {
}
@@ -527,9 +534,11 @@ class IgxActionStripOneRowComponent extends IgxActionStripTestingComponent {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
@@ -537,7 +546,7 @@ class IgxActionStripOneRowComponent extends IgxActionStripTestingComponent {
`,
selector: 'igx-action-strip-menu-one-row-component',
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridEditingActionsComponent]
})
class IgxActionStripMenuOneRowComponent extends IgxActionStripTestingComponent {
}
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.ts b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.ts
index 61f5fa39544..e48ec8745f2 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.ts
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-editing-actions.component.ts
@@ -3,7 +3,6 @@ import { IgxGridActionsBaseDirective } from './grid-actions-base.directive';
import { showMessage } from '../../core/utils';
import { addRow, addChild } from '@igniteui/material-icons-extended';
import { IgxGridActionButtonComponent } from './grid-action-button.component';
-import { NgIf } from '@angular/common';
/* blazorElement */
@@ -19,7 +18,7 @@ import { NgIf } from '@angular/common';
selector: 'igx-grid-editing-actions',
templateUrl: 'grid-editing-actions.component.html',
providers: [{ provide: IgxGridActionsBaseDirective, useExisting: IgxGridEditingActionsComponent }],
- imports: [NgIf, IgxGridActionButtonComponent]
+ imports: [IgxGridActionButtonComponent]
})
export class IgxGridEditingActionsComponent extends IgxGridActionsBaseDirective {
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.html b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.html
index 139553d1444..bdfde5466cb 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.html
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.html
@@ -1,6 +1,14 @@
-
-
-
-
-
-
+@if (isRowContext) {
+ @if (inPinnedArea && pinnedTop) {
+
+ }
+ @if (inPinnedArea && !pinnedTop) {
+
+ }
+ @if (!pinned) {
+
+ }
+ @if (pinned) {
+
+ }
+}
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.spec.ts b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.spec.ts
index f33e55996e9..2d9efab5b96 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.spec.ts
@@ -7,7 +7,6 @@ import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { By } from '@angular/platform-browser';
import { wait } from '../../test-utils/ui-interactions.spec';
import { IgxGridPinningActionsComponent } from './grid-pinning-actions.component';
-import { NgFor } from '@angular/common';
import { IgxColumnComponent } from '../../grids/public_api';
@@ -103,16 +102,18 @@ describe('igxGridPinningActions #grid ', () => {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
`,
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridPinningActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridPinningActionsComponent]
})
class IgxActionStripTestingComponent implements OnInit {
@ViewChild('actionStrip', { read: IgxActionStripComponent, static: true })
@@ -175,16 +176,18 @@ class IgxActionStripTestingComponent implements OnInit {
template: `
-
-
+ @for (c of columns; track c) {
+
+
+ }
`,
- imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridPinningActionsComponent, NgFor]
+ imports: [IgxGridComponent, IgxColumnComponent, IgxActionStripComponent, IgxGridPinningActionsComponent]
})
class IgxActionStripPinMenuComponent extends IgxActionStripTestingComponent {
}
diff --git a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.ts b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.ts
index 6bee97ae647..86c19ba569d 100644
--- a/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.ts
+++ b/projects/igniteui-angular/src/lib/action-strip/grid-actions/grid-pinning-actions.component.ts
@@ -2,7 +2,6 @@ import { Component, HostBinding } from '@angular/core';
import { IgxGridActionsBaseDirective } from './grid-actions-base.directive';
import { pinLeft, unpinLeft, jumpDown, jumpUp } from '@igniteui/material-icons-extended';
import { IgxGridActionButtonComponent } from './grid-action-button.component';
-import { NgIf } from '@angular/common';
/* blazorElement */
/* wcElementTag: igc-grid-pinning-actions */
@@ -17,7 +16,7 @@ import { NgIf } from '@angular/common';
selector: 'igx-grid-pinning-actions',
templateUrl: 'grid-pinning-actions.component.html',
providers: [{ provide: IgxGridActionsBaseDirective, useExisting: IgxGridPinningActionsComponent }],
- imports: [NgIf, IgxGridActionButtonComponent]
+ imports: [IgxGridActionButtonComponent]
})
export class IgxGridPinningActionsComponent extends IgxGridActionsBaseDirective {
diff --git a/projects/igniteui-angular/src/lib/badge/badge.component.html b/projects/igniteui-angular/src/lib/badge/badge.component.html
index 57461614232..14451e6100d 100644
--- a/projects/igniteui-angular/src/lib/badge/badge.component.html
+++ b/projects/igniteui-angular/src/lib/badge/badge.component.html
@@ -1,4 +1,10 @@
-{{value}}
-{{icon}}
-{{icon}}
+@if (value || value === 0 && !icon) {
+ {{value}}
+}
+@if (icon && !iconSet) {
+ {{icon}}
+}
+@if (icon && iconSet) {
+ {{icon}}
+}
diff --git a/projects/igniteui-angular/src/lib/badge/badge.component.ts b/projects/igniteui-angular/src/lib/badge/badge.component.ts
index 5275adb98f9..a891c1fcc85 100644
--- a/projects/igniteui-angular/src/lib/badge/badge.component.ts
+++ b/projects/igniteui-angular/src/lib/badge/badge.component.ts
@@ -1,4 +1,3 @@
-import { NgIf } from '@angular/common';
import { booleanAttribute, Component, HostBinding, Input } from '@angular/core';
import { mkenum } from '../core/utils';
import { IgxIconComponent } from '../icon/icon.component';
@@ -41,7 +40,7 @@ export type IgxBadgeType = (typeof IgxBadgeType)[keyof typeof IgxBadgeType];
@Component({
selector: 'igx-badge',
templateUrl: 'badge.component.html',
- imports: [NgIf, IgxIconComponent]
+ imports: [IgxIconComponent]
})
export class IgxBadgeComponent {
diff --git a/projects/igniteui-angular/src/lib/banner/banner.component.html b/projects/igniteui-angular/src/lib/banner/banner.component.html
index c49ac46f2da..d8cf0bb0adf 100644
--- a/projects/igniteui-angular/src/lib/banner/banner.component.html
+++ b/projects/igniteui-angular/src/lib/banner/banner.component.html
@@ -3,22 +3,23 @@
-
-
-
+ @if (bannerIcon) {
+
+
+
+ }
-
+ @if (useDefaultTemplate) {
-
-
+ } @else {
-
+ }
diff --git a/projects/igniteui-angular/src/lib/banner/banner.component.ts b/projects/igniteui-angular/src/lib/banner/banner.component.ts
index 08fc743b568..b6055d350a1 100644
--- a/projects/igniteui-angular/src/lib/banner/banner.component.ts
+++ b/projects/igniteui-angular/src/lib/banner/banner.component.ts
@@ -14,7 +14,6 @@ import { IToggleView } from '../core/navigation';
import { IgxButtonDirective } from '../directives/button/button.directive';
import { IgxRippleDirective } from '../directives/ripple/ripple.directive';
import { IgxBannerActionsDirective } from './banner.directives';
-import { NgIf } from '@angular/common';
import { CancelableEventArgs, IBaseEventArgs } from '../core/utils';
import { ToggleAnimationSettings } from '../expansion-panel/toggle-animation-component';
import { IgxExpansionPanelBodyComponent } from '../expansion-panel/expansion-panel-body.component';
@@ -49,7 +48,7 @@ export interface BannerCancelEventArgs extends BannerEventArgs, CancelableEventA
@Component({
selector: 'igx-banner',
templateUrl: 'banner.component.html',
- imports: [IgxExpansionPanelComponent, IgxExpansionPanelBodyComponent, NgIf, IgxButtonDirective, IgxRippleDirective]
+ imports: [IgxExpansionPanelComponent, IgxExpansionPanelBodyComponent, IgxButtonDirective, IgxRippleDirective]
})
export class IgxBannerComponent implements IToggleView {
/**
diff --git a/projects/igniteui-angular/src/lib/buttonGroup/buttonGroup.component.ts b/projects/igniteui-angular/src/lib/buttonGroup/buttonGroup.component.ts
index 5b2af8ee886..8b768bcb5b8 100644
--- a/projects/igniteui-angular/src/lib/buttonGroup/buttonGroup.component.ts
+++ b/projects/igniteui-angular/src/lib/buttonGroup/buttonGroup.component.ts
@@ -1,4 +1,3 @@
-import { NgFor, NgIf } from '@angular/common';
import {
AfterViewInit,
Component,
@@ -58,7 +57,7 @@ let NEXT_ID = 0;
@Component({
selector: 'igx-buttongroup',
templateUrl: 'buttongroup-content.component.html',
- imports: [NgFor, IgxButtonDirective, IgxRippleDirective, NgIf, IgxIconComponent]
+ imports: [IgxButtonDirective, IgxRippleDirective, IgxIconComponent]
})
export class IgxButtonGroupComponent implements AfterViewInit, OnDestroy {
/**
diff --git a/projects/igniteui-angular/src/lib/buttonGroup/buttongroup-content.component.html b/projects/igniteui-angular/src/lib/buttonGroup/buttongroup-content.component.html
index e86c985d859..58f674c856a 100644
--- a/projects/igniteui-angular/src/lib/buttonGroup/buttongroup-content.component.html
+++ b/projects/igniteui-angular/src/lib/buttonGroup/buttongroup-content.component.html
@@ -1,17 +1,23 @@
-
+ @for (button of values; track button) {
+
+ }
diff --git a/projects/igniteui-angular/src/lib/buttonGroup/buttongroup.component.spec.ts b/projects/igniteui-angular/src/lib/buttonGroup/buttongroup.component.spec.ts
index 2e1b9157c24..e73de82221c 100644
--- a/projects/igniteui-angular/src/lib/buttonGroup/buttongroup.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/buttonGroup/buttongroup.component.spec.ts
@@ -5,7 +5,6 @@ import { configureTestSuite } from '../test-utils/configure-suite';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { UIInteractions, wait } from '../test-utils/ui-interactions.spec';
import { IgxButtonDirective } from '../directives/button/button.directive';
-import { NgFor } from '@angular/common';
import { IgxRadioGroupDirective } from '../directives/radio/radio-group.directive';
import { IgxRadioComponent } from '../radio/radio.component';
@@ -585,10 +584,12 @@ class ButtonGroupWithSelectedButtonComponent {
@Component({
template: `
-
+ @for (item of items; track item) {
+
+ }
`,
- imports: [IgxButtonGroupComponent, IgxButtonDirective, NgFor]
+ imports: [IgxButtonGroupComponent, IgxButtonDirective]
})
class ButtonGroupButtonWithBoundSelectedOutputComponent {
@ViewChild(IgxButtonGroupComponent, { static: true }) public buttonGroup: IgxButtonGroupComponent;
@@ -605,9 +606,11 @@ class ButtonGroupButtonWithBoundSelectedOutputComponent {
@Component({
template: `
-
- {{ item }}
-
+ @for (item of ['Foo', 'Bar']; track item) {
+
+ {{ item }}
+
+ }
@@ -623,7 +626,7 @@ class ButtonGroupButtonWithBoundSelectedOutputComponent {
`,
- imports: [IgxButtonGroupComponent, IgxButtonDirective, NgFor, IgxRadioGroupDirective, IgxRadioComponent]
+ imports: [IgxButtonGroupComponent, IgxButtonDirective, IgxRadioGroupDirective, IgxRadioComponent]
})
class ButtonGroupSelectionBoundToAnotherComponent {
@ViewChild('radioGroup', { read: IgxRadioGroupDirective, static: true }) public radioGroup: IgxRadioGroupDirective;
diff --git a/projects/igniteui-angular/src/lib/calendar/calendar.component.html b/projects/igniteui-angular/src/lib/calendar/calendar.component.html
index ff3575059ab..96410be5472 100644
--- a/projects/igniteui-angular/src/lib/calendar/calendar.component.html
+++ b/projects/igniteui-angular/src/lib/calendar/calendar.component.html
@@ -1,22 +1,22 @@
-
+ @if (selection === 'single') {
{{ resourceStrings.igx_calendar_select_date }}
-
-
+ }
+ @if (selection === 'range') {
{{ resourceStrings.igx_calendar_range_placeholder }}
-
+ }
-
+ @if (selection === 'single') {
{{ getFormattedDate().weekday }},
{{ getFormattedDate().monthday }}
-
-
+ }
+ @if (selection === 'range') {
{{ selectedDates.length === 0 ? 'Start' : getFormattedRange().start}}
-
{{ selectedDates.length <= 1 ? 'End' : getFormattedRange().end}}
-
+ }
@@ -35,7 +35,9 @@
- {{ formattedYear(obj.date) }}
+ @if (activeView === 'year') {
+ {{ formattedYear(obj.date) }}
+ }
-
+ @if (monthsViewNumber < 2 || obj.index < 1) {
+
{{ monthsViewNumber > 1 ?
- (resourceStrings.igx_calendar_first_picker_of.replace('{0}', monthsViewNumber.toString()) + ' ' +
+ (resourceStrings.igx_calendar_first_picker_of.replace('{0}', monthsViewNumber.toString()) + ' ' +
(obj.date | date: 'LLLL yyyy')) :
- resourceStrings.igx_calendar_selected_month_is + (obj.date | date: 'LLLL yyyy')}}
-
+ resourceStrings.igx_calendar_selected_month_is + (obj.date | date: 'LLLL yyyy')}}
+
+ }
@@ -116,16 +120,15 @@
+ *ngTemplateOutlet="subheaderTemplate ? subheaderTemplate : defaultMonthYear; context: getContext(i)">
-
-
-
-
+ @if (this.orientation === 'horizontal' ? i === monthsViewNumber - 1 : i === 0) {
+
+
+
+
+ }
@@ -149,7 +152,7 @@
+ *ngTemplateOutlet="subheaderTemplate ? subheaderTemplate : defaultDecade;">
@@ -160,18 +163,20 @@
-
+@if (selection === 'single' && hasHeader || selection === 'range' && hasHeader) {
+
+}
diff --git a/projects/igniteui-angular/src/lib/calendar/calendar.component.ts b/projects/igniteui-angular/src/lib/calendar/calendar.component.ts
index b7f21eaa3dc..528bc28db3a 100644
--- a/projects/igniteui-angular/src/lib/calendar/calendar.component.ts
+++ b/projects/igniteui-angular/src/lib/calendar/calendar.component.ts
@@ -13,7 +13,7 @@ import {
booleanAttribute,
HostListener,
} from '@angular/core';
-import { NgIf, NgTemplateOutlet, NgFor, DatePipe } from '@angular/common';
+import { NgTemplateOutlet, DatePipe } from '@angular/common';
import { NG_VALUE_ACCESSOR } from '@angular/forms';
import {
@@ -71,7 +71,7 @@ let NEXT_ID = 0;
],
selector: 'igx-calendar',
templateUrl: 'calendar.component.html',
- imports: [NgIf, NgTemplateOutlet, IgxCalendarScrollPageDirective, IgxIconComponent, NgFor, IgxDaysViewComponent, IgxMonthsViewComponent, IgxYearsViewComponent, DatePipe, IgxMonthViewSlotsCalendar, IgxGetViewDateCalendar]
+ imports: [NgTemplateOutlet, IgxCalendarScrollPageDirective, IgxIconComponent, IgxDaysViewComponent, IgxMonthsViewComponent, IgxYearsViewComponent, DatePipe, IgxMonthViewSlotsCalendar, IgxGetViewDateCalendar]
})
export class IgxCalendarComponent extends IgxCalendarBaseDirective implements AfterViewInit, OnDestroy {
/**
diff --git a/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.html b/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.html
index e613c31623d..96a403d93b3 100644
--- a/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.html
+++ b/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.html
@@ -3,86 +3,86 @@
class="igx-days-view__row"
[title]="weekNumberHeader.long | titlecase"
>
-
-
- {{ weekNumberHeader.short | titlecase }}
-
-
-
-
- {{ dayName.formatted | titlecase }}
+ @if (showWeekNumbers) {
+
+
+ {{ weekNumberHeader.short | titlecase }}
+
+
+ }
+ @for (dayName of weekHeaderLabels; track dayName.long) {
+
+
+ {{ dayName.formatted | titlecase }}
+
-
+ }
-
+@for (
+ week of monthWeeks; track rowTracker(i, week);
+ let isLast = $last; let i = $index
+) {
-
- {{ getWeekNumber(week[0]) }}
-
+ @if (showWeekNumbers) {
+
+
+ {{ getWeekNumber(week[0]) }}
+
+
+ }
+ @for (day of week; track dateTracker($index, day)) {
+
+ {{ formattedDate(day.native) }}
+
+ }
-
-
- {{ formattedDate(day.native) }}
-
-
+}
diff --git a/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.ts b/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.ts
index 35151a58f37..cba03ba1379 100644
--- a/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.ts
+++ b/projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.ts
@@ -15,7 +15,7 @@ import {
ChangeDetectionStrategy,
} from '@angular/core';
import { NG_VALUE_ACCESSOR } from '@angular/forms';
-import { NgIf, NgFor, TitleCasePipe } from '@angular/common';
+import { TitleCasePipe } from '@angular/common';
import { CalendarSelection, ScrollDirection } from '../../calendar/calendar';
import { IgxDayItemComponent } from './day-item.component';
import { DateRangeType } from '../../core/dates';
@@ -45,7 +45,7 @@ let NEXT_ID = 0;
selector: 'igx-days-view',
templateUrl: 'days-view.component.html',
changeDetection: ChangeDetectionStrategy.OnPush,
- imports: [NgIf, NgFor, IgxDayItemComponent, TitleCasePipe]
+ imports: [IgxDayItemComponent, TitleCasePipe]
})
export class IgxDaysViewComponent extends IgxCalendarBaseDirective {
#standalone = true;
@@ -430,8 +430,8 @@ export class IgxDaysViewComponent extends IgxCalendarBaseDirective {
/**
* @hidden
*/
- public rowTracker(index: number, item: CalendarDay[]): string {
- return `${item[index].month}${item[index].date}`;
+ public rowTracker(_: number, item: CalendarDay[]): string {
+ return `${item[0].month}${item[0].date}`;
}
/**
diff --git a/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.html b/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.html
index 60928d5fa04..e13738c8de4 100644
--- a/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.html
+++ b/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.html
@@ -44,7 +44,9 @@
- {{ formattedYear(obj.date) }}
+ @if (activeView === 'year') {
+ {{ formattedYear(obj.date) }}
+ }
-
+ @if (isDefaultView) {
-
+ }
-
+ @if (isDecadeView) {
-
+ }
-
+ @if (isDefaultView) {
>
-
+ }
-
+ @if (isDecadeView) {
-
+ }
diff --git a/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.ts b/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.ts
index 6c3e4691c49..6bda0564ec4 100644
--- a/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.ts
+++ b/projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.ts
@@ -9,7 +9,7 @@ import {
OnDestroy,
OnInit,
} from "@angular/core";
-import { NgIf, NgTemplateOutlet, DatePipe } from "@angular/common";
+import { NgTemplateOutlet, DatePipe } from "@angular/common";
import { NG_VALUE_ACCESSOR } from "@angular/forms";
import { IgxMonthsViewComponent } from "../months-view/months-view.component";
@@ -38,7 +38,6 @@ let NEXT_ID = 0;
selector: "igx-month-picker",
templateUrl: "month-picker.component.html",
imports: [
- NgIf,
NgTemplateOutlet,
DatePipe,
IgxIconComponent,
diff --git a/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.html b/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.html
index aeca84c201d..8fcda69dff5 100644
--- a/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.html
+++ b/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.html
@@ -1,21 +1,22 @@
-
-
- {{ formattedMonth(month).formatted | titlecase }}
+ @for (month of range; track monthTracker($index, month)) {
+
+
+ {{ formattedMonth(month).formatted | titlecase }}
+
-
+ }
diff --git a/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.ts b/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.ts
index f41f532facf..956e7acc000 100644
--- a/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.ts
+++ b/projects/igniteui-angular/src/lib/calendar/months-view/months-view.component.ts
@@ -7,7 +7,7 @@ import {
Inject,
} from "@angular/core";
import { IgxCalendarMonthDirective } from "../calendar.directives";
-import { NgFor, TitleCasePipe } from "@angular/common";
+import { TitleCasePipe } from "@angular/common";
import {
IgxCalendarViewDirective,
DAY_INTERVAL_TOKEN,
@@ -33,7 +33,7 @@ let NEXT_ID = 0;
],
selector: "igx-months-view",
templateUrl: "months-view.component.html",
- imports: [NgFor, IgxCalendarMonthDirective, TitleCasePipe]
+ imports: [IgxCalendarMonthDirective, TitleCasePipe]
})
export class IgxMonthsViewComponent extends IgxCalendarViewDirective implements ControlValueAccessor {
#standalone = true;
diff --git a/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.html b/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.html
index 28082a19ab9..2f83bea48d9 100644
--- a/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.html
+++ b/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.html
@@ -1,22 +1,23 @@
-
-
- {{ formattedYear(year).formatted }}
+ @for (year of range; track yearTracker($index, year)) {
+
+
+ {{ formattedYear(year).formatted }}
+
-
+ }
diff --git a/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.ts b/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.ts
index ccdc538e67c..07fd46a8de5 100644
--- a/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.ts
+++ b/projects/igniteui-angular/src/lib/calendar/years-view/years-view.component.ts
@@ -6,7 +6,6 @@ import {
Inject,
} from "@angular/core";
import { IgxCalendarYearDirective } from "../calendar.directives";
-import { NgFor } from "@angular/common";
import {
IgxCalendarViewDirective,
DAY_INTERVAL_TOKEN,
@@ -30,7 +29,7 @@ import { calendarRange } from "../common/helpers";
],
selector: "igx-years-view",
templateUrl: "years-view.component.html",
- imports: [NgFor, IgxCalendarYearDirective]
+ imports: [IgxCalendarYearDirective]
})
export class IgxYearsViewComponent extends IgxCalendarViewDirective implements ControlValueAccessor {
#standalone = true;
diff --git a/projects/igniteui-angular/src/lib/carousel/carousel.component.html b/projects/igniteui-angular/src/lib/carousel/carousel.component.html
index b6e038359da..d79dc110577 100644
--- a/projects/igniteui-angular/src/lib/carousel/carousel.component.html
+++ b/projects/igniteui-angular/src/lib/carousel/carousel.component.html
@@ -16,43 +16,53 @@
-
+@if (navigation && slides.length) {
+
+}
-
+@if (navigation && slides.length) {
+
+}
-
-
-
+@if (showIndicators) {
+
+ @for (slide of slides; track slide) {
+
+
+
+ }
-
+}
-
- {{getCarouselLabel}}
-
+@if (showIndicatorsLabel) {
+
+ {{getCarouselLabel}}
+
+}
diff --git a/projects/igniteui-angular/src/lib/carousel/carousel.component.spec.ts b/projects/igniteui-angular/src/lib/carousel/carousel.component.spec.ts
index f0fa7cca10a..30b1a13437a 100644
--- a/projects/igniteui-angular/src/lib/carousel/carousel.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/carousel/carousel.component.spec.ts
@@ -10,7 +10,6 @@ import { configureTestSuite } from '../test-utils/configure-suite';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { IgxSlideComponent } from './slide.component';
import { IgxCarouselIndicatorDirective, IgxCarouselNextButtonDirective, IgxCarouselPrevButtonDirective } from './carousel.directives';
-import { NgFor, NgIf } from '@angular/common';
import { CarouselIndicatorsOrientation, CarouselAnimationType } from './enums';
describe('Carousel', () => {
@@ -108,22 +107,22 @@ describe('Carousel', () => {
});
it('add/remove slides tests', () => {
- let currentSlide = carousel.get(carousel.current);
- carousel.remove(currentSlide);
+ const slide1 = carousel.get(carousel.current);
+ carousel.remove(slide1);
fixture.detectChanges();
expect(carousel.slides.length).toEqual(3);
expect(carousel.total).toEqual(3);
- currentSlide = carousel.get(carousel.current);
- carousel.remove(currentSlide);
+ const slide2 = carousel.get(carousel.current);
+ carousel.remove(slide2);
fixture.detectChanges();
expect(carousel.slides.length).toEqual(2);
expect(carousel.total).toEqual(2);
- carousel.add(currentSlide);
- carousel.add(currentSlide);
+ carousel.add(slide1);
+ carousel.add(slide2);
fixture.detectChanges();
expect(carousel.slides.length).toEqual(4);
@@ -187,11 +186,12 @@ describe('Carousel', () => {
expect(carousel.slideChanged.emit).toHaveBeenCalledTimes(3);
spyOn(carousel.slideAdded, 'emit');
- carousel.add(carousel.get(carousel.current));
+ const newSlide = new IgxSlideComponent(null, null);
+ carousel.add(newSlide);
fixture.detectChanges();
args = {
carousel,
- slide: carousel.get(carousel.current)
+ slide: newSlide
};
expect(carousel.slideAdded.emit).toHaveBeenCalledWith(args);
@@ -1213,8 +1213,12 @@ class CarouselTemplateSetInMarkupTestComponent {
- {{slide.index}}
- {{slide.index}}: Active
+ @if (!slide.active) {
+ {{slide.index}}
+ }
+ @if (slide.active) {
+ {{slide.index}}: Active
+ }
@@ -1232,7 +1236,7 @@ class CarouselTemplateSetInMarkupTestComponent {
Slide4
`,
- imports: [IgxCarouselComponent, IgxSlideComponent, NgIf]
+ imports: [IgxCarouselComponent, IgxSlideComponent]
})
class CarouselTemplateSetInTypescriptTestComponent {
@ViewChild('carousel', { static: true }) public carousel: IgxCarouselComponent;
@@ -1249,12 +1253,14 @@ class CarouselTemplateSetInTypescriptTestComponent {
@Component({
template: `
-
- {{slide.text}}
-
+ @for (slide of slides; track slide) {
+
+ {{slide.text}}
+
+ }
`,
- imports: [IgxCarouselComponent, IgxSlideComponent, NgFor]
+ imports: [IgxCarouselComponent, IgxSlideComponent]
})
class CarouselDynamicSlidesComponent {
@ViewChild('carousel', { static: true }) public carousel: IgxCarouselComponent;
diff --git a/projects/igniteui-angular/src/lib/carousel/carousel.component.ts b/projects/igniteui-angular/src/lib/carousel/carousel.component.ts
index 50f472a4a00..fe2adf1d118 100644
--- a/projects/igniteui-angular/src/lib/carousel/carousel.component.ts
+++ b/projects/igniteui-angular/src/lib/carousel/carousel.component.ts
@@ -1,4 +1,4 @@
-import { NgIf, NgClass, NgFor, NgTemplateOutlet, DOCUMENT } from '@angular/common';
+import { NgClass, NgTemplateOutlet, DOCUMENT } from '@angular/common';
import {
AfterContentInit,
ChangeDetectorRef,
@@ -85,7 +85,7 @@ export class CarouselHammerConfig extends HammerGestureConfig {
display: block;
outline-style: none;
}`],
- imports: [IgxButtonDirective, IgxIconComponent, NgIf, NgClass, NgFor, NgTemplateOutlet]
+ imports: [IgxButtonDirective, IgxIconComponent, NgClass, NgTemplateOutlet]
})
export class IgxCarouselComponent extends IgxCarouselComponentBase implements ICarouselComponentBase, OnDestroy, AfterContentInit {
diff --git a/projects/igniteui-angular/src/lib/chips/chip.component.html b/projects/igniteui-angular/src/lib/chips/chip.component.html
index 1a2f23622dc..27958ceca06 100644
--- a/projects/igniteui-angular/src/lib/chips/chip.component.html
+++ b/projects/igniteui-angular/src/lib/chips/chip.component.html
@@ -16,9 +16,11 @@
(dropped)="onChipDrop($event)">
-
-
-
+ @if (selected) {
+
+
+
+ }
@@ -30,16 +32,18 @@
-
-
-
+ @if (removable) {
+
+
+
+ }
diff --git a/projects/igniteui-angular/src/lib/chips/chip.component.ts b/projects/igniteui-angular/src/lib/chips/chip.component.ts
index 8cdcdae3cb3..06690bdc2b6 100644
--- a/projects/igniteui-angular/src/lib/chips/chip.component.ts
+++ b/projects/igniteui-angular/src/lib/chips/chip.component.ts
@@ -20,7 +20,7 @@ import { IBaseEventArgs, mkenum } from '../core/utils';
import { ChipResourceStringsEN, IChipResourceStrings } from '../core/i18n/chip-resources';
import { Subject } from 'rxjs';
import { IgxIconComponent } from '../icon/icon.component';
-import { NgClass, NgTemplateOutlet, NgIf, DOCUMENT } from '@angular/common';
+import { NgClass, NgTemplateOutlet, DOCUMENT } from '@angular/common';
import { getCurrentResourceStrings } from '../core/i18n/resources';
import { Size } from '../grids/common/enums';
@@ -83,7 +83,7 @@ let CHIP_ID = 0;
@Component({
selector: 'igx-chip',
templateUrl: 'chip.component.html',
- imports: [IgxDropDirective, IgxDragDirective, NgClass, NgTemplateOutlet, NgIf, IgxIconComponent]
+ imports: [IgxDropDirective, IgxDragDirective, NgClass, NgTemplateOutlet, IgxIconComponent]
})
export class IgxChipComponent implements OnInit, OnDestroy {
diff --git a/projects/igniteui-angular/src/lib/chips/chip.spec.ts b/projects/igniteui-angular/src/lib/chips/chip.spec.ts
index ce2820051f4..e518735693d 100644
--- a/projects/igniteui-angular/src/lib/chips/chip.spec.ts
+++ b/projects/igniteui-angular/src/lib/chips/chip.spec.ts
@@ -10,19 +10,20 @@ import { UIInteractions, wait } from '../test-utils/ui-interactions.spec';
import { configureTestSuite } from '../test-utils/configure-suite';
import { ControlsFunction } from '../test-utils/controls-functions.spec';
import { IgxIconComponent } from '../icon/icon.component';
-import { NgFor } from '@angular/common';
import { getComponentSize } from '../core/utils';
@Component({
template: `
-
- {{chip.text}}
- drag_indicator
-
+ @for (chip of chipList; track chip) {
+
+ {{chip.text}}
+ drag_indicator
+
+ }
Tab Chip
@@ -40,7 +41,7 @@ import { getComponentSize } from '../core/utils';
`,
- imports: [IgxChipComponent, IgxChipsAreaComponent, IgxIconComponent, IgxPrefixDirective, NgFor]
+ imports: [IgxChipComponent, IgxChipsAreaComponent, IgxIconComponent, IgxPrefixDirective]
})
class TestChipComponent {
@@ -68,13 +69,15 @@ class TestChipComponent {
@Component({
template: `
-
- label
- suf
-
+ @for (chip of chipList; track chip) {
+
+ label
+ suf
+
+ }
`,
- imports: [IgxChipsAreaComponent, IgxChipComponent, IgxLabelDirective, IgxSuffixDirective, NgFor]
+ imports: [IgxChipsAreaComponent, IgxChipComponent, IgxLabelDirective, IgxSuffixDirective]
})
class TestChipsLabelAndSuffixComponent {
diff --git a/projects/igniteui-angular/src/lib/chips/chips-area.spec.ts b/projects/igniteui-angular/src/lib/chips/chips-area.spec.ts
index a3ce7260c12..54e5916d107 100644
--- a/projects/igniteui-angular/src/lib/chips/chips-area.spec.ts
+++ b/projects/igniteui-angular/src/lib/chips/chips-area.spec.ts
@@ -7,19 +7,20 @@ import { configureTestSuite } from '../test-utils/configure-suite';
import { wait, UIInteractions } from '../test-utils/ui-interactions.spec';
import { IgxIconComponent } from '../icon/icon.component';
import { IgxPrefixDirective } from './public_api';
-import { NgFor } from '@angular/common';
@Component({
template: `
-
- drag_indicator
- {{chip.text}}
-
+ @for (chip of chipList; track chip) {
+
+ drag_indicator
+ {{chip.text}}
+
+ }
`,
- imports: [IgxChipsAreaComponent, IgxChipComponent, IgxIconComponent, IgxPrefixDirective, NgFor]
+ imports: [IgxChipsAreaComponent, IgxChipComponent, IgxIconComponent, IgxPrefixDirective]
})
class TestChipComponent {
@ViewChild('chipsArea', { read: IgxChipsAreaComponent, static: true })
@@ -58,14 +59,16 @@ class TestChipSelectComponent extends TestChipComponent {
@Component({
template: `
-
- drag_indicator
- {{chip.text}}
-
+ @for (chip of chipList; track chip) {
+
+ drag_indicator
+ {{chip.text}}
+
+ }
`,
- imports: [IgxChipsAreaComponent, IgxChipComponent, IgxIconComponent, IgxPrefixDirective, NgFor]
+ imports: [IgxChipsAreaComponent, IgxChipComponent, IgxIconComponent, IgxPrefixDirective]
})
class TestChipReorderComponent {
@ViewChild('chipsArea', { read: IgxChipsAreaComponent, static: true })
diff --git a/projects/igniteui-angular/src/lib/combo/combo-dropdown.component.ts b/projects/igniteui-angular/src/lib/combo/combo-dropdown.component.ts
index bb2452ce6da..733995846f3 100644
--- a/projects/igniteui-angular/src/lib/combo/combo-dropdown.component.ts
+++ b/projects/igniteui-angular/src/lib/combo/combo-dropdown.component.ts
@@ -10,7 +10,7 @@ import { IgxComboAPIService } from './combo.api';
import { IgxDropDownItemBaseDirective } from '../drop-down/drop-down-item.base';
import { IgxSelectionAPIService } from '../core/selection';
import { IgxComboItemComponent } from './combo-item.component';
-import { DOCUMENT, NgIf } from '@angular/common';
+import { DOCUMENT } from '@angular/common';
import { IgxToggleDirective } from '../directives/toggle/toggle.directive';
/** @hidden */
@@ -18,7 +18,7 @@ import { IgxToggleDirective } from '../directives/toggle/toggle.directive';
selector: 'igx-combo-drop-down',
templateUrl: '../drop-down/drop-down.component.html',
providers: [{ provide: IGX_DROPDOWN_BASE, useExisting: IgxComboDropDownComponent }],
- imports: [IgxToggleDirective, NgIf]
+ imports: [IgxToggleDirective]
})
export class IgxComboDropDownComponent extends IgxDropDownComponent implements IDropDownBase, OnDestroy, AfterViewInit {
/** @hidden @internal */
diff --git a/projects/igniteui-angular/src/lib/combo/combo-item.component.html b/projects/igniteui-angular/src/lib/combo/combo-item.component.html
index 3849092698e..b467360ae0d 100644
--- a/projects/igniteui-angular/src/lib/combo/combo-item.component.html
+++ b/projects/igniteui-angular/src/lib/combo/combo-item.component.html
@@ -1,5 +1,5 @@
-
+@if (!isHeader && !singleMode) {
-
+}
diff --git a/projects/igniteui-angular/src/lib/combo/combo-item.component.ts b/projects/igniteui-angular/src/lib/combo/combo-item.component.ts
index 1c9b4dd39de..ff74a3ebf3f 100644
--- a/projects/igniteui-angular/src/lib/combo/combo-item.component.ts
+++ b/projects/igniteui-angular/src/lib/combo/combo-item.component.ts
@@ -12,13 +12,12 @@ import { IgxComboAPIService } from './combo.api';
import { IgxSelectionAPIService } from '../core/selection';
import { rem } from '../core/utils';
import { IgxCheckboxComponent } from '../checkbox/checkbox.component';
-import { NgIf } from '@angular/common';
/** @hidden */
@Component({
selector: 'igx-combo-item',
templateUrl: 'combo-item.component.html',
- imports: [NgIf, IgxCheckboxComponent]
+ imports: [IgxCheckboxComponent]
})
export class IgxComboItemComponent extends IgxDropDownItemComponent {
diff --git a/projects/igniteui-angular/src/lib/combo/combo.component.html b/projects/igniteui-angular/src/lib/combo/combo.component.html
index cde01b8b3ce..03fd08b909f 100644
--- a/projects/igniteui-angular/src/lib/combo/combo.component.html
+++ b/projects/igniteui-angular/src/lib/combo/combo.component.html
@@ -9,49 +9,59 @@
+ [attr.placeholder]="placeholder" [disabled]="disabled"
+ role="combobox" aria-haspopup="listbox"
+ [attr.aria-expanded]="!dropdown.collapsed" [attr.aria-controls]="dropdown.listId"
+ [attr.aria-labelledby]="ariaLabelledBy || label?.id || placeholder"
+ (blur)="onBlur()" />
-
-
-
-
-
-
+ @if (displayValue) {
+
+ @if (clearIconTemplate) {
+
+ }
+ @if (!clearIconTemplate) {
+
+ }
+
+ }
-
+ @if (toggleIconTemplate) {
-
-
+ }
+ @if (!toggleIconTemplate) {
+
+ }
-
-
-
-
-
-
-
-
-
-
-
+ @if (displaySearchInput) {
+
+
+
+ @if (showSearchCaseIcon) {
+
+
+
+
+
+
+ }
+
+
+ }
-
+ @if (item?.isHeader) {
-
+ }
-
+ @if (!item?.isHeader) {
-
+ }
-
-
-
-
+ @if (filteredData.length === 0 || isAddButtonVisible()) {
+
+ @if (filteredData.length === 0) {
+
+
+
+
+ }
+ @if (isAddButtonVisible()) {
+
+
+
+
+ }
-
-
-
-
-
+ }
diff --git a/projects/igniteui-angular/src/lib/combo/combo.component.ts b/projects/igniteui-angular/src/lib/combo/combo.component.ts
index 76543666a22..92756f24369 100644
--- a/projects/igniteui-angular/src/lib/combo/combo.component.ts
+++ b/projects/igniteui-angular/src/lib/combo/combo.component.ts
@@ -1,4 +1,4 @@
-import { DOCUMENT, NgClass, NgIf, NgTemplateOutlet } from '@angular/common';
+import { DOCUMENT, NgClass, NgTemplateOutlet } from '@angular/common';
import {
AfterViewInit, ChangeDetectorRef, Component, ElementRef, OnInit, OnDestroy,
Optional, Inject, Injector, ViewChild, Input, Output, EventEmitter, HostListener, DoCheck, booleanAttribute
@@ -101,7 +101,6 @@ const diffInSets = (set1: Set
, set2: Set): any[] => {
{ provide: NG_VALUE_ACCESSOR, useExisting: IgxComboComponent, multi: true }
],
imports: [
- NgIf,
NgTemplateOutlet,
NgClass,
FormsModule,
diff --git a/projects/igniteui-angular/src/lib/core/utils.ts b/projects/igniteui-angular/src/lib/core/utils.ts
index 487dce78d8d..55404e32fe2 100644
--- a/projects/igniteui-angular/src/lib/core/utils.ts
+++ b/projects/igniteui-angular/src/lib/core/utils.ts
@@ -656,9 +656,9 @@ export function getComponentCssSizeVar(size: string) {
* @param path - The URI path to be normalized.
* @returns string encoded using the encodeURI function.
*/
- export function normalizeURI(path: string) {
+export function normalizeURI(path: string) {
return path?.split('/').map(encodeURI).join('/');
- }
+}
export function getComponentTheme(el: Element) {
return globalThis.window
@@ -666,3 +666,16 @@ export function getComponentTheme(el: Element) {
.getPropertyValue('--theme')
.trim() as IgxTheme;
}
+
+/**
+ * Collection re-created w/ the built in track by identity will always log
+ * warning even for valid cases of recalculating all collection items.
+ * See https://github.com/angular/angular/blob/55581b4181639568fb496e91055142a1b489e988/packages/core/src/render3/instructions/control_flow.ts#L393-L409
+ * Current solution explicit track function doing the same as suggested in:
+ * https://github.com/angular/angular/issues/56471#issuecomment-2180315803
+ * This should be used with moderation and when necessary.
+ * @internal
+ */
+export function trackByIdentity(item: T): T {
+ return item;
+}
diff --git a/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.html b/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.html
index f9929eab2da..0d54b8105b3 100644
--- a/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.html
+++ b/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.html
@@ -1,39 +1,44 @@
-
-
-
-
+ @if (closeButtonLabel || todayButtonLabel) {
+
+ @if (closeButtonLabel) {
+
+ }
+ @if (todayButtonLabel) {
+
+ }
+
+ }
-
-
-
-
-
+@if (pickerActions?.template || (closeButtonLabel || todayButtonLabel)) {
+
+}
+@if (pickerActions?.template || (closeButtonLabel || todayButtonLabel)) {
+
+
+
+
+}
diff --git a/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.ts b/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.ts
index 3f8cd15202a..510be7214f1 100644
--- a/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.ts
+++ b/projects/igniteui-angular/src/lib/date-common/calendar-container/calendar-container.component.ts
@@ -1,4 +1,4 @@
-import { NgIf, NgTemplateOutlet } from '@angular/common';
+import { NgTemplateOutlet } from '@angular/common';
import {
Component,
ViewChild,
@@ -20,7 +20,6 @@ import { IgxDividerDirective } from "../../directives/divider/divider.directive"
styles: [':host {display: block;}'],
templateUrl: 'calendar-container.component.html',
imports: [
- NgIf,
IgxButtonDirective,
IgxRippleDirective,
IgxCalendarComponent,
diff --git a/projects/igniteui-angular/src/lib/date-picker/date-picker.component.html b/projects/igniteui-angular/src/lib/date-picker/date-picker.component.html
index ebcfec861f4..81159a032bd 100644
--- a/projects/igniteui-angular/src/lib/date-picker/date-picker.component.html
+++ b/projects/igniteui-angular/src/lib/date-picker/date-picker.component.html
@@ -1,16 +1,18 @@
-
-
+
-
-
+
+
+ }
-
-
-
+ @if (!clearComponents.length && value) {
+
+
+
+ }
diff --git a/projects/igniteui-angular/src/lib/date-picker/date-picker.component.spec.ts b/projects/igniteui-angular/src/lib/date-picker/date-picker.component.spec.ts
index 6638292d7cc..a85061000d8 100644
--- a/projects/igniteui-angular/src/lib/date-picker/date-picker.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/date-picker/date-picker.component.spec.ts
@@ -21,7 +21,7 @@ import { DateRangeDescriptor, DateRangeType } from '../core/dates';
import { IgxOverlayOutletDirective } from '../directives/toggle/toggle.directive';
import { IgxPickerClearComponent, IgxPickerToggleComponent } from '../date-common/public_api';
import { DateTimeUtil } from '../date-common/util/date-time.util';
-import { NgIf, registerLocaleData } from "@angular/common";
+import { registerLocaleData } from "@angular/common";
import localeES from "@angular/common/locales/es";
import localeBg from "@angular/common/locales/bg";
import { IgxDateTimeEditorDirective } from '../directives/date-time-editor/public_api';
@@ -1552,13 +1552,17 @@ export class IgxDatePickerTestKbrdComponent {
template: `
- CustomToggle
+ @if (showCustomToggle) {
+ CustomToggle
+ }
Prefix
- CustomClear
+ @if (showCustomClear) {
+ CustomClear
+ }
Suffix
Hint
`,
- imports: [IgxDatePickerComponent, IgxPickerToggleComponent, IgxPrefixDirective, IgxPickerClearComponent, IgxLabelDirective, IgxSuffixDirective, IgxHintDirective, NgIf]
+ imports: [IgxDatePickerComponent, IgxPickerToggleComponent, IgxPrefixDirective, IgxPickerClearComponent, IgxLabelDirective, IgxSuffixDirective, IgxHintDirective]
})
export class IgxDatePickerWithProjectionsComponent {
@ViewChild(IgxDatePickerComponent) public datePicker: IgxDatePickerComponent;
diff --git a/projects/igniteui-angular/src/lib/date-picker/date-picker.component.ts b/projects/igniteui-angular/src/lib/date-picker/date-picker.component.ts
index d1348e1afbd..a3a6935af7d 100644
--- a/projects/igniteui-angular/src/lib/date-picker/date-picker.component.ts
+++ b/projects/igniteui-angular/src/lib/date-picker/date-picker.component.ts
@@ -25,7 +25,6 @@ import {
ViewContainerRef,
booleanAttribute
} from '@angular/core';
-import { NgIf } from '@angular/common';
import {
AbstractControl,
ControlValueAccessor,
@@ -93,7 +92,6 @@ let NEXT_ID = 0;
templateUrl: 'date-picker.component.html',
styles: [':host { display: block; }'],
imports: [
- NgIf,
IgxInputGroupComponent,
IgxPrefixDirective,
IgxIconComponent,
diff --git a/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker-inputs.common.ts b/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker-inputs.common.ts
index e08cf779ed5..8cccd6a2275 100644
--- a/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker-inputs.common.ts
+++ b/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker-inputs.common.ts
@@ -10,7 +10,7 @@ import { IgxIconComponent } from '../icon/icon.component';
import { IgxSuffixDirective } from '../directives/suffix/suffix.directive';
import { IgxButtonDirective } from '../directives/button/button.directive';
import { IgxPrefixDirective } from '../directives/prefix/prefix.directive';
-import { NgIf, NgTemplateOutlet, NgClass, NgSwitch, NgSwitchCase, NgSwitchDefault } from '@angular/common';
+import { NgTemplateOutlet, NgClass } from '@angular/common';
/** Represents a range between two dates. */
export interface DateRange {
@@ -126,7 +126,7 @@ export class IgxDateRangeInputsBaseComponent extends IgxInputGroupComponent {
{ provide: IgxInputGroupBase, useExisting: IgxDateRangeStartComponent },
{ provide: IgxDateRangeInputsBaseComponent, useExisting: IgxDateRangeStartComponent }
],
- imports: [NgIf, NgTemplateOutlet, IgxPrefixDirective, IgxButtonDirective, NgClass, IgxSuffixDirective, IgxIconComponent, NgSwitch, NgSwitchCase, NgSwitchDefault]
+ imports: [NgTemplateOutlet, IgxPrefixDirective, IgxButtonDirective, NgClass, IgxSuffixDirective, IgxIconComponent]
})
export class IgxDateRangeStartComponent extends IgxDateRangeInputsBaseComponent { }
@@ -161,7 +161,7 @@ export class IgxDateRangeStartComponent extends IgxDateRangeInputsBaseComponent
{ provide: IgxInputGroupBase, useExisting: IgxDateRangeEndComponent },
{ provide: IgxDateRangeInputsBaseComponent, useExisting: IgxDateRangeEndComponent }
],
- imports: [NgIf, NgTemplateOutlet, IgxPrefixDirective, IgxButtonDirective, NgClass, IgxSuffixDirective, IgxIconComponent, NgSwitch, NgSwitchCase, NgSwitchDefault]
+ imports: [NgTemplateOutlet, IgxPrefixDirective, IgxButtonDirective, NgClass, IgxSuffixDirective, IgxIconComponent]
})
export class IgxDateRangeEndComponent extends IgxDateRangeInputsBaseComponent { }
diff --git a/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.html b/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.html
index 79359e0cd14..6ea322900a2 100644
--- a/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.html
+++ b/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.html
@@ -28,9 +28,11 @@
role="combobox" aria-haspopup="grid" [attr.aria-expanded]="!collapsed" [attr.aria-labelledby]="label?.id"
[value]="value | dateRange: appliedFormat : locale : formatter" />
-
-
-
+ @if (!toggleComponents.length) {
+
+
+
+ }
diff --git a/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.ts b/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.ts
index 4a5ec190653..e6b5edca0ba 100644
--- a/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.ts
+++ b/projects/igniteui-angular/src/lib/date-range-picker/date-range-picker.component.ts
@@ -4,7 +4,7 @@ import {
OnChanges, OnDestroy, OnInit, Optional, Output, QueryList,
SimpleChanges, TemplateRef, ViewChild, ViewContainerRef
} from '@angular/core';
-import { NgTemplateOutlet, NgIf, getLocaleFirstDayOfWeek } from '@angular/common';
+import { NgTemplateOutlet, getLocaleFirstDayOfWeek } from '@angular/common';
import {
AbstractControl, ControlValueAccessor, NgControl,
NG_VALIDATORS, NG_VALUE_ACCESSOR, ValidationErrors, Validator
@@ -68,7 +68,6 @@ const SingleInputDatesConcatenationString = ' - ';
{ provide: NG_VALIDATORS, useExisting: IgxDateRangePickerComponent, multi: true }
],
imports: [
- NgIf,
NgTemplateOutlet,
IgxIconComponent,
IgxInputGroupComponent,
diff --git a/projects/igniteui-angular/src/lib/dialog/dialog-content.component.html b/projects/igniteui-angular/src/lib/dialog/dialog-content.component.html
index f92bfab185e..efe481f28d9 100644
--- a/projects/igniteui-angular/src/lib/dialog/dialog-content.component.html
+++ b/projects/igniteui-angular/src/lib/dialog/dialog-content.component.html
@@ -12,49 +12,54 @@
[attr.role]="role"
[attr.aria-labelledby]="titleId"
>
-
- {{ title }}
-
-
+ @if (title) {
+
+ {{ title }}
+
+ }
+ @if (!title) {
+
+ }
- {{
- message
- }}
-
+ @if (message) {
+
+ {{ message }}
+
+ }
+ @if (!message) {
+
+ }
-
-
-
-
-
+ @if (leftButtonLabel || rightButtonLabel) {
+
+ @if (leftButtonLabel) {
+
+ }
+ @if (rightButtonLabel) {
+
+ }
+
+ }
+ @if (!leftButtonLabel && !rightButtonLabel) {
+
+ }
diff --git a/projects/igniteui-angular/src/lib/dialog/dialog.component.ts b/projects/igniteui-angular/src/lib/dialog/dialog.component.ts
index cb6fc430cc9..09c76ecfdd5 100644
--- a/projects/igniteui-angular/src/lib/dialog/dialog.component.ts
+++ b/projects/igniteui-angular/src/lib/dialog/dialog.component.ts
@@ -1,4 +1,3 @@
-import { NgIf } from '@angular/common';
import {
Component,
ElementRef,
@@ -56,7 +55,7 @@ let DIALOG_ID = 0;
@Component({
selector: 'igx-dialog',
templateUrl: 'dialog-content.component.html',
- imports: [IgxToggleDirective, IgxFocusTrapDirective, NgIf, IgxFocusDirective, IgxButtonDirective, IgxRippleDirective]
+ imports: [IgxToggleDirective, IgxFocusTrapDirective, IgxFocusDirective, IgxButtonDirective, IgxRippleDirective]
})
export class IgxDialogComponent implements IToggleView, OnInit, OnDestroy, AfterContentInit {
private static NEXT_ID = 1;
diff --git a/projects/igniteui-angular/src/lib/directives/autocomplete/autocomplete.directive.spec.ts b/projects/igniteui-angular/src/lib/directives/autocomplete/autocomplete.directive.spec.ts
index 2d71a3871aa..5d4fac049d4 100644
--- a/projects/igniteui-angular/src/lib/directives/autocomplete/autocomplete.directive.spec.ts
+++ b/projects/igniteui-angular/src/lib/directives/autocomplete/autocomplete.directive.spec.ts
@@ -10,7 +10,6 @@ import { IgxInputGroupComponent, IgxLabelDirective, IgxPrefixDirective, IgxSuffi
import { IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective } from '../../drop-down/public_api';
import { FormsModule, ReactiveFormsModule, UntypedFormGroup, UntypedFormBuilder, Validators } from '@angular/forms';
import { ConnectedPositioningStrategy, VerticalAlignment, HorizontalAlignment } from '../../services/public_api';
-import { NgFor } from '@angular/common';
import { IgxRippleDirective } from '../ripple/ripple.directive';
import { IgxIconComponent } from '../../icon/icon.component';
@@ -949,9 +948,11 @@ export class IgxAutocompletePipeStartsWith implements PipeTransform {
clear
-
- {{town}}
-
+ @for (town of towns | startsWith:townSelected; track town+$index) {
+
+ {{town}}
+
+ }
`,
imports: [
FormsModule,
@@ -964,7 +965,6 @@ export class IgxAutocompletePipeStartsWith implements PipeTransform {
IgxIconComponent,
IgxAutocompleteDirective,
IgxAutocompletePipeStartsWith,
- NgFor
]
})
class AutocompleteComponent {
@@ -979,7 +979,7 @@ class AutocompleteComponent {
constructor() {
this.towns = [
- 'Sofia', 'Plovdiv', 'Varna', 'Burgas', 'Ruse', 'Stara Zagora', 'Pleven', 'Dobrich', 'Sliven', 'Shumen', 'Pernik', 'Haskovo', 'Yambol', 'Pazardzhik', 'Blagoevgrad', 'Veliko Tarnovo', 'Vratsa', 'Gabrovo', 'Asenovgrad', 'Vidin', 'Kazanlak', 'Kyustendil', 'Kardzhali', 'Montana', 'Dimitrovgrad', 'Targovishte', 'Lovech', 'Silistra', 'Dupnitsa', 'Svishtov', 'Razgrad', 'Gorna Oryahovitsa', 'Smolyan', 'Petrich', 'Sandanski', 'Samokov', 'Sevlievo', 'Lom', 'Karlovo', 'Velingrad', 'Nova Zagora', 'Troyan', 'Aytos', 'Botevgrad', 'Gotse Delchev', 'Peshtera', 'Harmanli', 'Karnobat', 'Svilengrad', 'Panagyurishte', 'Chirpan', 'Popovo', 'Rakovski', 'Radomir', 'Novi Iskar', 'Kozloduy', 'Parvomay', 'Berkovitsa', 'Cherven Bryag', 'Pomorie', 'Ihtiman', 'Radnevo', 'Provadiya', 'Novi Pazar', 'Razlog', 'Byala Slatina', 'Nesebar', 'Balchik', 'Kostinbrod', 'Stamboliyski', 'Kavarna', 'Knezha', 'Pavlikeni', 'Mezdra', 'Etropole', 'Levski', 'Teteven', 'Elhovo', 'Bankya', 'Tryavna', 'Lukovit', 'Tutrakan', 'Sredets', 'Sopot', 'Byala', 'Veliki Preslav', 'Isperih', 'Belene', 'Omurtag', 'Bansko', 'Krichim', 'Galabovo', 'Devnya', 'Septemvri', 'Rakitovo', 'Lyaskovets', 'Svoge', 'Aksakovo', 'Kubrat', 'Dryanovo', 'Beloslav', 'Pirdop', 'Lyubimets', 'Momchilgrad', 'Slivnitsa', 'Hisarya', 'Zlatograd', 'Kostenets', 'Devin', 'General Toshevo', 'Simeonovgrad', 'Simitli', 'Elin Pelin', 'Dolni Chiflik', 'Tervel', 'Dulovo', 'Varshets', 'Kotel', 'Madan', 'Straldzha', 'Saedinenie', 'Bobov Dol', 'Tsarevo', 'Kuklen', 'Tvarditsa', 'Yakoruda', 'Elena', 'Topolovgrad', 'Bozhurishte', 'Chepelare', 'Oryahovo', 'Sozopol', 'Belogradchik', 'Perushtitsa', 'Zlatitsa', 'Strazhitsa', 'Krumovgrad', 'Kameno', 'Dalgopol', 'Vetovo', 'Suvorovo', 'Dolni Dabnik', 'Dolna Banya', 'Pravets', 'Nedelino', 'Polski Trambesh', 'Trastenik', 'Bratsigovo', 'Koynare', 'Godech', 'Slavyanovo', 'Dve Mogili', 'Kostandovo', 'Debelets', 'Strelcha', 'Sapareva Banya', 'Ignatievo', 'Smyadovo', 'Breznik', 'Sveti Vlas', 'Nikopol', 'Shivachevo', 'Belovo', 'Tsar Kaloyan', 'Ivaylovgrad', 'Valchedram', 'Marten', 'Glodzhevo', 'Sarnitsa', 'Letnitsa', 'Varbitsa', 'Iskar', 'Ardino', 'Shabla', 'Rudozem', 'Vetren', 'Kresna', 'Banya', 'Batak', 'Maglizh', 'Valchi Dol', 'Gulyantsi', 'Dragoman', 'Zavet', 'Kran', 'Miziya', 'Primorsko', 'Sungurlare', 'Dolna Mitropoliya', 'Krivodol', 'Kula', 'Kalofer', 'Slivo Pole', 'Kaspichan', 'Apriltsi', 'Belitsa', 'Roman', 'Dzhebel', 'Dolna Oryahovitsa', 'Buhovo', 'Gurkovo', 'Pavel Banya', 'Nikolaevo', 'Yablanitsa', 'Kableshkovo', 'Opaka', 'Rila', 'Ugarchin', 'Dunavtsi', 'Dobrinishte', 'Hadzhidimovo', 'Bregovo', 'Byala Cherkva', 'Zlataritsa', 'Kocherinovo', 'Dospat', 'Tran', 'Sadovo', 'Laki', 'Koprivshtitsa', 'Malko Tarnovo', 'Loznitsa', 'Obzor', 'Kilifarevo', 'Borovo', 'Batanovtsi', 'Chernomorets', 'Aheloy', 'Byala', 'Pordim', 'Suhindol', 'Merichleri', 'Glavinitsa', 'Chiprovtsi', 'Kermen', 'Brezovo', 'Plachkovtsi', 'Zemen', 'Balgarovo', 'Alfatar', 'Boychinovtsi', 'Gramada', 'Senovo', 'Momin Prohod', 'Kaolinovo', 'Shipka', 'Antonovo', 'Ahtopol', 'Boboshevo', 'Bolyarovo', 'Brusartsi', 'Klisura', 'Dimovo', 'Kiten', 'Pliska', 'Madzharovo', 'Melnik'
+ 'Sofia', 'Plovdiv', 'Varna', 'Burgas', 'Ruse', 'Stara Zagora', 'Pleven', 'Dobrich', 'Sliven', 'Shumen', 'Pernik', 'Haskovo', 'Yambol', 'Pazardzhik', 'Blagoevgrad', 'Veliko Tarnovo', 'Vratsa', 'Gabrovo', 'Asenovgrad', 'Vidin', 'Kazanlak', 'Kyustendil', 'Kardzhali', 'Montana', 'Dimitrovgrad', 'Targovishte', 'Lovech', 'Silistra', 'Dupnitsa', 'Svishtov', 'Razgrad', 'Gorna Oryahovitsa', 'Smolyan', 'Petrich', 'Sandanski', 'Samokov', 'Sevlievo', 'Lom', 'Karlovo', 'Velingrad', 'Nova Zagora', 'Troyan', 'Aytos', 'Botevgrad', 'Gotse Delchev', 'Peshtera', 'Harmanli', 'Karnobat', 'Svilengrad', 'Panagyurishte', 'Chirpan', 'Popovo', 'Rakovski', 'Radomir', 'Novi Iskar', 'Kozloduy', 'Parvomay', 'Berkovitsa', 'Cherven Bryag', 'Pomorie', 'Ihtiman', 'Radnevo', 'Provadiya', 'Novi Pazar', 'Razlog', 'Byala Slatina', 'Nesebar', 'Balchik', 'Kostinbrod', 'Stamboliyski', 'Kavarna', 'Knezha', 'Pavlikeni', 'Mezdra', 'Etropole', 'Levski', 'Teteven', 'Elhovo', 'Bankya', 'Tryavna', 'Lukovit', 'Tutrakan', 'Sredets', 'Sopot', 'Byala', 'Veliki Preslav', 'Isperih', 'Belene', 'Omurtag', 'Bansko', 'Krichim', 'Galabovo', 'Devnya', 'Septemvri', 'Rakitovo', 'Lyaskovets', 'Svoge', 'Aksakovo', 'Kubrat', 'Dryanovo', 'Beloslav', 'Pirdop', 'Lyubimets', 'Momchilgrad', 'Slivnitsa', 'Hisarya', 'Zlatograd', 'Kostenets', 'Devin', 'General Toshevo', 'Simeonovgrad', 'Simitli', 'Elin Pelin', 'Dolni Chiflik', 'Tervel', 'Dulovo', 'Varshets', 'Kotel', 'Madan', 'Straldzha', 'Saedinenie', 'Bobov Dol', 'Tsarevo', 'Kuklen', 'Tvarditsa', 'Yakoruda', 'Elena', 'Topolovgrad', 'Bozhurishte', 'Chepelare', 'Oryahovo', 'Sozopol', 'Belogradchik', 'Perushtitsa', 'Zlatitsa', 'Strazhitsa', 'Krumovgrad', 'Kameno', 'Dalgopol', 'Vetovo', 'Suvorovo', 'Dolni Dabnik', 'Dolna Banya', 'Pravets', 'Nedelino', 'Polski Trambesh', 'Trastenik', 'Bratsigovo', 'Koynare', 'Godech', 'Slavyanovo', 'Dve Mogili', 'Kostandovo', 'Debelets', 'Strelcha', 'Sapareva Banya', 'Ignatievo', 'Smyadovo', 'Breznik', 'Sveti Vlas', 'Nikopol', 'Shivachevo', 'Belovo', 'Tsar Kaloyan', 'Ivaylovgrad', 'Valchedram', 'Marten', 'Glodzhevo', 'Sarnitsa', 'Letnitsa', 'Varbitsa', 'Iskar', 'Ardino', 'Shabla', 'Rudozem', 'Vetren', 'Kresna', 'Banya', 'Batak', 'Maglizh', 'Valchi Dol', 'Gulyantsi', 'Dragoman', 'Zavet', 'Kran', 'Miziya', 'Primorsko', 'Sungurlare', 'Dolna Mitropoliya', 'Krivodol', 'Kula', 'Kalofer', 'Slivo Pole', 'Kaspichan', 'Apriltsi', 'Belitsa', 'Roman', 'Dzhebel', 'Dolna Oryahovitsa', 'Buhovo', 'Gurkovo', 'Pavel Banya', 'Nikolaevo', 'Yablanitsa', 'Kableshkovo', 'Opaka', 'Rila', 'Ugarchin', 'Dunavtsi', 'Dobrinishte', 'Hadzhidimovo', 'Bregovo', 'Byala Cherkva', 'Zlataritsa', 'Kocherinovo', 'Dospat', 'Tran', 'Sadovo', 'Laki', 'Koprivshtitsa', 'Malko Tarnovo', 'Loznitsa', 'Obzor', 'Kilifarevo', 'Borovo', 'Batanovtsi', 'Chernomorets', 'Aheloy', 'Pordim', 'Suhindol', 'Merichleri', 'Glavinitsa', 'Chiprovtsi', 'Kermen', 'Brezovo', 'Plachkovtsi', 'Zemen', 'Balgarovo', 'Alfatar', 'Boychinovtsi', 'Gramada', 'Senovo', 'Momin Prohod', 'Kaolinovo', 'Shipka', 'Antonovo', 'Ahtopol', 'Boboshevo', 'Bolyarovo', 'Brusartsi', 'Klisura', 'Dimovo', 'Kiten', 'Pliska', 'Madzharovo', 'Melnik'
];
}
public selectionChanging() { }
@@ -997,9 +997,11 @@ class AutocompleteComponent {
[igxAutocomplete]='townsPanel' #textarea>
-
- {{town}}
-
+ @for (town of towns | startsWith:townSelected; track town+$index) {
+
+ {{town}}
+
+ }
`,
imports: [
FormsModule,
@@ -1008,7 +1010,6 @@ class AutocompleteComponent {
IgxDropDownComponent,
IgxDropDownItemComponent,
IgxAutocompletePipeStartsWith,
- NgFor
]
})
class AutocompleteInputComponent extends AutocompleteComponent {
@@ -1028,9 +1029,11 @@ class AutocompleteInputComponent extends AutocompleteComponent {
clear
-
- {{town}}
-
+ @for (town of towns | startsWith:townSelected; track town+$index) {
+
+ {{town}}
+
+ }
@@ -1048,7 +1051,6 @@ class AutocompleteInputComponent extends AutocompleteComponent {
IgxIconComponent,
IgxAutocompleteDirective,
IgxAutocompletePipeStartsWith,
- NgFor
]
})
@@ -1065,7 +1067,7 @@ class AutocompleteFormComponent {
constructor(fb: UntypedFormBuilder) {
this.towns = [
- 'Sofia', 'Plovdiv', 'Varna', 'Burgas', 'Ruse', 'Stara Zagora', 'Pleven', 'Dobrich', 'Sliven', 'Shumen', 'Pernik', 'Haskovo', 'Yambol', 'Pazardzhik', 'Blagoevgrad', 'Veliko Tarnovo', 'Vratsa', 'Gabrovo', 'Asenovgrad', 'Vidin', 'Kazanlak', 'Kyustendil', 'Kardzhali', 'Montana', 'Dimitrovgrad', 'Targovishte', 'Lovech', 'Silistra', 'Dupnitsa', 'Svishtov', 'Razgrad', 'Gorna Oryahovitsa', 'Smolyan', 'Petrich', 'Sandanski', 'Samokov', 'Sevlievo', 'Lom', 'Karlovo', 'Velingrad', 'Nova Zagora', 'Troyan', 'Aytos', 'Botevgrad', 'Gotse Delchev', 'Peshtera', 'Harmanli', 'Karnobat', 'Svilengrad', 'Panagyurishte', 'Chirpan', 'Popovo', 'Rakovski', 'Radomir', 'Novi Iskar', 'Kozloduy', 'Parvomay', 'Berkovitsa', 'Cherven Bryag', 'Pomorie', 'Ihtiman', 'Radnevo', 'Provadiya', 'Novi Pazar', 'Razlog', 'Byala Slatina', 'Nesebar', 'Balchik', 'Kostinbrod', 'Stamboliyski', 'Kavarna', 'Knezha', 'Pavlikeni', 'Mezdra', 'Etropole', 'Levski', 'Teteven', 'Elhovo', 'Bankya', 'Tryavna', 'Lukovit', 'Tutrakan', 'Sredets', 'Sopot', 'Byala', 'Veliki Preslav', 'Isperih', 'Belene', 'Omurtag', 'Bansko', 'Krichim', 'Galabovo', 'Devnya', 'Septemvri', 'Rakitovo', 'Lyaskovets', 'Svoge', 'Aksakovo', 'Kubrat', 'Dryanovo', 'Beloslav', 'Pirdop', 'Lyubimets', 'Momchilgrad', 'Slivnitsa', 'Hisarya', 'Zlatograd', 'Kostenets', 'Devin', 'General Toshevo', 'Simeonovgrad', 'Simitli', 'Elin Pelin', 'Dolni Chiflik', 'Tervel', 'Dulovo', 'Varshets', 'Kotel', 'Madan', 'Straldzha', 'Saedinenie', 'Bobov Dol', 'Tsarevo', 'Kuklen', 'Tvarditsa', 'Yakoruda', 'Elena', 'Topolovgrad', 'Bozhurishte', 'Chepelare', 'Oryahovo', 'Sozopol', 'Belogradchik', 'Perushtitsa', 'Zlatitsa', 'Strazhitsa', 'Krumovgrad', 'Kameno', 'Dalgopol', 'Vetovo', 'Suvorovo', 'Dolni Dabnik', 'Dolna Banya', 'Pravets', 'Nedelino', 'Polski Trambesh', 'Trastenik', 'Bratsigovo', 'Koynare', 'Godech', 'Slavyanovo', 'Dve Mogili', 'Kostandovo', 'Debelets', 'Strelcha', 'Sapareva Banya', 'Ignatievo', 'Smyadovo', 'Breznik', 'Sveti Vlas', 'Nikopol', 'Shivachevo', 'Belovo', 'Tsar Kaloyan', 'Ivaylovgrad', 'Valchedram', 'Marten', 'Glodzhevo', 'Sarnitsa', 'Letnitsa', 'Varbitsa', 'Iskar', 'Ardino', 'Shabla', 'Rudozem', 'Vetren', 'Kresna', 'Banya', 'Batak', 'Maglizh', 'Valchi Dol', 'Gulyantsi', 'Dragoman', 'Zavet', 'Kran', 'Miziya', 'Primorsko', 'Sungurlare', 'Dolna Mitropoliya', 'Krivodol', 'Kula', 'Kalofer', 'Slivo Pole', 'Kaspichan', 'Apriltsi', 'Belitsa', 'Roman', 'Dzhebel', 'Dolna Oryahovitsa', 'Buhovo', 'Gurkovo', 'Pavel Banya', 'Nikolaevo', 'Yablanitsa', 'Kableshkovo', 'Opaka', 'Rila', 'Ugarchin', 'Dunavtsi', 'Dobrinishte', 'Hadzhidimovo', 'Bregovo', 'Byala Cherkva', 'Zlataritsa', 'Kocherinovo', 'Dospat', 'Tran', 'Sadovo', 'Laki', 'Koprivshtitsa', 'Malko Tarnovo', 'Loznitsa', 'Obzor', 'Kilifarevo', 'Borovo', 'Batanovtsi', 'Chernomorets', 'Aheloy', 'Byala', 'Pordim', 'Suhindol', 'Merichleri', 'Glavinitsa', 'Chiprovtsi', 'Kermen', 'Brezovo', 'Plachkovtsi', 'Zemen', 'Balgarovo', 'Alfatar', 'Boychinovtsi', 'Gramada', 'Senovo', 'Momin Prohod', 'Kaolinovo', 'Shipka', 'Antonovo', 'Ahtopol', 'Boboshevo', 'Bolyarovo', 'Brusartsi', 'Klisura', 'Dimovo', 'Kiten', 'Pliska', 'Madzharovo', 'Melnik'
+ 'Sofia', 'Plovdiv', 'Varna', 'Burgas', 'Ruse', 'Stara Zagora', 'Pleven', 'Dobrich', 'Sliven', 'Shumen', 'Pernik', 'Haskovo', 'Yambol', 'Pazardzhik', 'Blagoevgrad', 'Veliko Tarnovo', 'Vratsa', 'Gabrovo', 'Asenovgrad', 'Vidin', 'Kazanlak', 'Kyustendil', 'Kardzhali', 'Montana', 'Dimitrovgrad', 'Targovishte', 'Lovech', 'Silistra', 'Dupnitsa', 'Svishtov', 'Razgrad', 'Gorna Oryahovitsa', 'Smolyan', 'Petrich', 'Sandanski', 'Samokov', 'Sevlievo', 'Lom', 'Karlovo', 'Velingrad', 'Nova Zagora', 'Troyan', 'Aytos', 'Botevgrad', 'Gotse Delchev', 'Peshtera', 'Harmanli', 'Karnobat', 'Svilengrad', 'Panagyurishte', 'Chirpan', 'Popovo', 'Rakovski', 'Radomir', 'Novi Iskar', 'Kozloduy', 'Parvomay', 'Berkovitsa', 'Cherven Bryag', 'Pomorie', 'Ihtiman', 'Radnevo', 'Provadiya', 'Novi Pazar', 'Razlog', 'Byala Slatina', 'Nesebar', 'Balchik', 'Kostinbrod', 'Stamboliyski', 'Kavarna', 'Knezha', 'Pavlikeni', 'Mezdra', 'Etropole', 'Levski', 'Teteven', 'Elhovo', 'Bankya', 'Tryavna', 'Lukovit', 'Tutrakan', 'Sredets', 'Sopot', 'Byala', 'Veliki Preslav', 'Isperih', 'Belene', 'Omurtag', 'Bansko', 'Krichim', 'Galabovo', 'Devnya', 'Septemvri', 'Rakitovo', 'Lyaskovets', 'Svoge', 'Aksakovo', 'Kubrat', 'Dryanovo', 'Beloslav', 'Pirdop', 'Lyubimets', 'Momchilgrad', 'Slivnitsa', 'Hisarya', 'Zlatograd', 'Kostenets', 'Devin', 'General Toshevo', 'Simeonovgrad', 'Simitli', 'Elin Pelin', 'Dolni Chiflik', 'Tervel', 'Dulovo', 'Varshets', 'Kotel', 'Madan', 'Straldzha', 'Saedinenie', 'Bobov Dol', 'Tsarevo', 'Kuklen', 'Tvarditsa', 'Yakoruda', 'Elena', 'Topolovgrad', 'Bozhurishte', 'Chepelare', 'Oryahovo', 'Sozopol', 'Belogradchik', 'Perushtitsa', 'Zlatitsa', 'Strazhitsa', 'Krumovgrad', 'Kameno', 'Dalgopol', 'Vetovo', 'Suvorovo', 'Dolni Dabnik', 'Dolna Banya', 'Pravets', 'Nedelino', 'Polski Trambesh', 'Trastenik', 'Bratsigovo', 'Koynare', 'Godech', 'Slavyanovo', 'Dve Mogili', 'Kostandovo', 'Debelets', 'Strelcha', 'Sapareva Banya', 'Ignatievo', 'Smyadovo', 'Breznik', 'Sveti Vlas', 'Nikopol', 'Shivachevo', 'Belovo', 'Tsar Kaloyan', 'Ivaylovgrad', 'Valchedram', 'Marten', 'Glodzhevo', 'Sarnitsa', 'Letnitsa', 'Varbitsa', 'Iskar', 'Ardino', 'Shabla', 'Rudozem', 'Vetren', 'Kresna', 'Banya', 'Batak', 'Maglizh', 'Valchi Dol', 'Gulyantsi', 'Dragoman', 'Zavet', 'Kran', 'Miziya', 'Primorsko', 'Sungurlare', 'Dolna Mitropoliya', 'Krivodol', 'Kula', 'Kalofer', 'Slivo Pole', 'Kaspichan', 'Apriltsi', 'Belitsa', 'Roman', 'Dzhebel', 'Dolna Oryahovitsa', 'Buhovo', 'Gurkovo', 'Pavel Banya', 'Nikolaevo', 'Yablanitsa', 'Kableshkovo', 'Opaka', 'Rila', 'Ugarchin', 'Dunavtsi', 'Dobrinishte', 'Hadzhidimovo', 'Bregovo', 'Byala Cherkva', 'Zlataritsa', 'Kocherinovo', 'Dospat', 'Tran', 'Sadovo', 'Laki', 'Koprivshtitsa', 'Malko Tarnovo', 'Loznitsa', 'Obzor', 'Kilifarevo', 'Borovo', 'Batanovtsi', 'Chernomorets', 'Aheloy', 'Pordim', 'Suhindol', 'Merichleri', 'Glavinitsa', 'Chiprovtsi', 'Kermen', 'Brezovo', 'Plachkovtsi', 'Zemen', 'Balgarovo', 'Alfatar', 'Boychinovtsi', 'Gramada', 'Senovo', 'Momin Prohod', 'Kaolinovo', 'Shipka', 'Antonovo', 'Ahtopol', 'Boboshevo', 'Bolyarovo', 'Brusartsi', 'Klisura', 'Dimovo', 'Kiten', 'Pliska', 'Madzharovo', 'Melnik'
];
this.reactiveForm = fb.group({
towns: ['', Validators.required]
diff --git a/projects/igniteui-angular/src/lib/directives/drag-drop/drag-drop.spec.ts b/projects/igniteui-angular/src/lib/directives/drag-drop/drag-drop.spec.ts
index cb0001c7d44..de893b9bd94 100644
--- a/projects/igniteui-angular/src/lib/directives/drag-drop/drag-drop.spec.ts
+++ b/projects/igniteui-angular/src/lib/directives/drag-drop/drag-drop.spec.ts
@@ -15,7 +15,6 @@ import {
IgxDragIgnoreDirective
} from './drag-drop.directive';
import { IgxIconComponent } from '../../icon/icon.component';
-import { NgFor } from '@angular/common';
describe('General igxDrag/igxDrop', () => {
let fix: ComponentFixture;
@@ -2108,21 +2107,25 @@ class TestDragDropStrategiesComponent extends TestDragDropLinkedSingleComponent
drag_indicator
Movies list
-
-
- drag_indicator
- {{category.text}}
-
-
+ @for (category of categoriesNotes; track category) {
+
drag_indicator
- {{note.text}}
+ {{category.text}}
+ @for (note of getCategoryMovies(category.text); track note) {
+
+
+ drag_indicator
+ {{note.text}}
+
+
+ }
-
+ }
`,
- imports: [NgFor, IgxIconComponent, IgxDragDirective, IgxDragHandleDirective]
+ imports: [IgxIconComponent, IgxDragDirective, IgxDragHandleDirective]
})
class TestDragDropNestedComponent extends TestDragDropComponent {
public categoriesNotes = [
diff --git a/projects/igniteui-angular/src/lib/directives/filter/filter.directive.spec.ts b/projects/igniteui-angular/src/lib/directives/filter/filter.directive.spec.ts
index d8ea891bfa5..49ddf007b6f 100644
--- a/projects/igniteui-angular/src/lib/directives/filter/filter.directive.spec.ts
+++ b/projects/igniteui-angular/src/lib/directives/filter/filter.directive.spec.ts
@@ -5,7 +5,6 @@ import { IgxListComponent } from '../../list/list.component';
import { IgxFilterDirective, IgxFilterOptions, IgxFilterPipe } from './filter.directive';
import { configureTestSuite } from '../../test-utils/configure-suite';
-import { NgFor } from '@angular/common';
describe('Filter', () => {
configureTestSuite();
@@ -214,11 +213,11 @@ class DeclarativeListTestComponent {
@Component({
template: `
-
- {{item.text}}
-
+ @for (item of dataSourceItems | igxFilter: fo; track item) {
+ {{item.text}}
+ }
`,
- imports: [IgxListComponent, IgxListItemComponent, IgxFilterPipe, NgFor]
+ imports: [IgxListComponent, IgxListItemComponent, IgxFilterPipe]
})
class DynamicListTestComponent {
@ViewChild(IgxListComponent, { static: true }) public list: IgxListComponent;
diff --git a/projects/igniteui-angular/src/lib/directives/focus-trap/focus-trap.directive.spec.ts b/projects/igniteui-angular/src/lib/directives/focus-trap/focus-trap.directive.spec.ts
index bfd3f55b919..e960b7b34e6 100644
--- a/projects/igniteui-angular/src/lib/directives/focus-trap/focus-trap.directive.spec.ts
+++ b/projects/igniteui-angular/src/lib/directives/focus-trap/focus-trap.directive.spec.ts
@@ -6,7 +6,6 @@ import { IgxFocusTrapDirective } from './focus-trap.directive';
import { configureTestSuite } from '../../test-utils/configure-suite';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { UIInteractions } from '../../test-utils/ui-interactions.spec';
-import { NgIf } from '@angular/common';
describe('igxFocusTrap', () => {
configureTestSuite();
@@ -171,12 +170,20 @@ describe('igxFocusTrap', () => {
template: `
-
+ @if (showInput) {
+
+ }
+
-
-
+ @if (showInput) {
+
+ }
+
+ @if (showButton) {
+
+ }
`,
- imports: [IgxFocusTrapDirective, NgIf]
+ imports: [IgxFocusTrapDirective]
})
class TrapFocusTestComponent {
public showInput = true;
diff --git a/projects/igniteui-angular/src/lib/directives/for-of/for_of.directive.spec.ts b/projects/igniteui-angular/src/lib/directives/for-of/for_of.directive.spec.ts
index abc46f747e0..cea8758dec5 100644
--- a/projects/igniteui-angular/src/lib/directives/for-of/for_of.directive.spec.ts
+++ b/projects/igniteui-angular/src/lib/directives/for-of/for_of.directive.spec.ts
@@ -1,4 +1,4 @@
-import { AsyncPipe, NgClass, NgFor, NgForOfContext, NgIf } from '@angular/common';
+import { AsyncPipe, NgClass, NgForOfContext } from '@angular/common';
import {
AfterViewInit,
ChangeDetectorRef,
@@ -1514,22 +1514,24 @@ export class VerticalVirtualComponent extends VirtualComponent {
@Component({
template: `
-
-
-
-
{{rowData['1']}}
-
{{rowData['2']}}
-
{{rowData['3']}}
-
{{rowData['4']}}
-
{{rowData['5']}}
-
-
-
+ @if (exists) {
+
+
+
+
{{rowData['1']}}
+
{{rowData['2']}}
+
{{rowData['3']}}
+
{{rowData['4']}}
+
{{rowData['5']}}
+
+
+
+ }
`,
- imports: [TestIgxForOfDirective, IgxForOfDirective, NgIf]
+ imports: [TestIgxForOfDirective, IgxForOfDirective]
})
export class VerticalVirtualDestroyComponent extends VerticalVirtualComponent {
public exists = true;
@@ -1551,7 +1553,8 @@ export class VerticalVirtualDestroyComponent extends VerticalVirtualComponent {
-
+ @if (exists) {
+
+ }
`,
- imports: [IgxForOfDirective, NgIf]
+ imports: [IgxForOfDirective]
})
export class VerticalVirtualCreateComponent extends VerticalVirtualComponent {
@ViewChild('scrollContainer2', { read: IgxForOfDirective, static: false })
@@ -1585,18 +1589,20 @@ export class VerticalVirtualCreateComponent extends VerticalVirtualComponent {
[style.overflow]='"hidden"'
[style.float]='"left"'
[style.position]='"relative"'>
-
-
+ @for (rowData of data; track rowData) {
+
+
{{rowData[col.field]}}
-
-
+
+
+ }
`,
- imports: [TestIgxForOfDirective, IgxForOfDirective, NgFor]
+ imports: [TestIgxForOfDirective, IgxForOfDirective]
})
export class HorizontalVirtualComponent extends VirtualComponent {
public override width = '800px';
diff --git a/projects/igniteui-angular/src/lib/directives/radio/radio-group.directive.spec.ts b/projects/igniteui-angular/src/lib/directives/radio/radio-group.directive.spec.ts
index 468cb51d5c9..b8c3c2391f6 100644
--- a/projects/igniteui-angular/src/lib/directives/radio/radio-group.directive.spec.ts
+++ b/projects/igniteui-angular/src/lib/directives/radio/radio-group.directive.spec.ts
@@ -7,7 +7,6 @@ import { configureTestSuite } from '../../test-utils/configure-suite';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { By } from '@angular/platform-browser';
import { IgxRadioComponent } from '../../radio/radio.component';
-import { NgFor } from '@angular/common';
describe('IgxRadioGroupDirective', () => {
configureTestSuite();
@@ -281,12 +280,14 @@ class RadioGroupSimpleComponent {
@Component({
template: `
-
- {{item}}
-
-
-`,
- imports: [IgxRadioComponent, IgxRadioGroupDirective, NgFor]
+ @for (item of ['Foo', 'Bar', 'Baz']; track item) {
+
+ {{item}}
+
+ }
+
+ `,
+ imports: [IgxRadioComponent, IgxRadioGroupDirective]
})
class RadioGroupComponent {
@ViewChild('radioGroup', { read: IgxRadioGroupDirective, static: true }) public radioGroup: IgxRadioGroupDirective;
@@ -294,12 +295,14 @@ class RadioGroupComponent {
@Component({
template: `
-
- {{item}}
-
-
-`,
- imports: [IgxRadioComponent, IgxRadioGroupDirective, NgFor]
+ @for (item of ['Foo', 'Bar', 'Baz']; track item) {
+
+ {{item}}
+
+ }
+
+ `,
+ imports: [IgxRadioComponent, IgxRadioGroupDirective]
})
class RadioGroupRequiredComponent {
@ViewChild('radioGroup', { read: IgxRadioGroupDirective, static: true }) public radioGroup: IgxRadioGroupDirective;
@@ -334,12 +337,14 @@ class RadioGroupOnPushComponent {
@Component({
template: `
-
- {{item}}
-
-
-`,
- imports: [IgxRadioComponent, IgxRadioGroupDirective, NgFor, FormsModule]
+ @for (item of seasons; track item) {
+
+ {{item}}
+
+ }
+
+ `,
+ imports: [IgxRadioComponent, IgxRadioGroupDirective, FormsModule]
})
class RadioGroupWithModelComponent {
@ViewChild('radioGroupSeasons', { read: IgxRadioGroupDirective, static: true }) public radioGroup: IgxRadioGroupDirective;
@@ -358,13 +363,15 @@ class RadioGroupWithModelComponent {
template: `
`,
- imports: [IgxRadioComponent, IgxRadioGroupDirective, NgFor, ReactiveFormsModule]
+ imports: [IgxRadioComponent, IgxRadioGroupDirective, ReactiveFormsModule]
})
class RadioGroupReactiveFormsComponent {
public seasons = [
@@ -410,13 +417,15 @@ class RadioGroupReactiveFormsComponent {
template: `
`,
- imports: [IgxRadioComponent, IgxRadioGroupDirective, NgFor, ReactiveFormsModule]
+ imports: [IgxRadioComponent, IgxRadioGroupDirective, ReactiveFormsModule]
})
class RadioGroupDeepProjectionComponent {
diff --git a/projects/igniteui-angular/src/lib/drop-down/drop-down.component.html b/projects/igniteui-angular/src/lib/drop-down/drop-down.component.html
index 5d582b8c918..ea1e07c9c46 100644
--- a/projects/igniteui-angular/src/lib/drop-down/drop-down.component.html
+++ b/projects/igniteui-angular/src/lib/drop-down/drop-down.component.html
@@ -4,10 +4,10 @@
(opening)="onToggleOpening($event)" (opened)="onToggleOpened()"
(closing)="onToggleClosing($event)" (closed)="onToggleClosed()">
-
+ [style.height]="height"
+ [style.maxHeight]="maxHeight">
+ @if (!collapsed) {
-
+ }
diff --git a/projects/igniteui-angular/src/lib/drop-down/drop-down.component.spec.ts b/projects/igniteui-angular/src/lib/drop-down/drop-down.component.spec.ts
index 62440af898b..6ce79bc3fc3 100644
--- a/projects/igniteui-angular/src/lib/drop-down/drop-down.component.spec.ts
+++ b/projects/igniteui-angular/src/lib/drop-down/drop-down.component.spec.ts
@@ -16,7 +16,6 @@ import { IgxForOfDirective } from '../directives/for-of/for_of.directive';
import { IgxDropDownItemBaseDirective } from './drop-down-item.base';
import { IgxSelectionAPIService } from '../core/selection';
import { IgxButtonDirective } from '../directives/button/button.directive';
-import { NgFor } from '@angular/common';
import { ConnectedPositioningStrategy, HorizontalAlignment, OverlaySettings, VerticalAlignment } from '../services/public_api';
const CSS_CLASS_DROP_DOWN_BASE = 'igx-drop-down';
@@ -1298,12 +1297,14 @@ describe('IgxDropDown ', () => {
template: `
-
- {{item.field}}
-
+ [allowItemsFocus]="true" style="--ig-size: var(--ig-size-medium);">
+ @for (item of items; track item) {
+
+ {{item.field}}
+
+ }
`,
- imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective, NgFor]
+ imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective]
})
class IgxDropDownTestComponent {
@@ -1337,17 +1338,21 @@ class IgxDropDownTestComponent {
template: `
-
- {{ item.field }}
-
+ @for (item of items; track item) {
+
+ {{ item.field }}
+
+ }
-
- {{ item.field }}
-
+ @for (item of items; track item) {
+
+ {{ item.field }}
+
+ }
`,
- imports: [IgxDropDownComponent, IgxDropDownItemComponent, NgFor]
+ imports: [IgxDropDownComponent, IgxDropDownItemComponent]
})
class DoubleIgxDropDownComponent implements OnInit {
@@ -1396,13 +1401,15 @@ class DoubleIgxDropDownComponent implements OnInit {
-
- {{ item.field }}
-
+ (opening)="onToggleOpening()" (opened)="onToggleOpened()"
+ (closing)="onToggleClosing()" (closed)="onToggleClosed()" [width]="'400px'" [height]="'400px'">
+ @for (item of items; track item) {
+
+ {{ item.field }}
+
+ }
`,
- imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective, IgxTabsComponent, IgxTabItemComponent, IgxTabHeaderComponent, IgxTabContentComponent, NgFor]
+ imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective, IgxTabsComponent, IgxTabItemComponent, IgxTabHeaderComponent, IgxTabContentComponent]
})
class IgxDropDownAnchorTestComponent {
@ViewChild(IgxTabsComponent, { static: true })
@@ -1434,11 +1441,13 @@ class IgxDropDownAnchorTestComponent {
@Component({
template: `
-
- {{ item.field }}
-
+ @for (item of items; track item) {
+
+ {{ item.field }}
+
+ }
`,
- imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective, NgFor]
+ imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownItemNavigationDirective]
})
class InputWithDropDownDirectiveComponent {
@ViewChild(IgxDropDownComponent, { read: IgxDropDownComponent, static: true })
@@ -1457,13 +1466,17 @@ class InputWithDropDownDirectiveComponent {
@Component({
template: `
-
-
- {{ child.name }}
-
-
+ @for (parent of data; track parent) {
+
+ @for (child of parent.children; track child) {
+
+ {{ child.name }}
+
+ }
+
+ }
`,
- imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownGroupComponent, NgFor]
+ imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxDropDownGroupComponent]
})
class GroupDropDownComponent {
@ViewChild(IgxDropDownComponent, { read: IgxDropDownComponent, static: true })
diff --git a/projects/igniteui-angular/src/lib/drop-down/drop-down.component.ts b/projects/igniteui-angular/src/lib/drop-down/drop-down.component.ts
index d40ae93e004..30d8ccab1eb 100644
--- a/projects/igniteui-angular/src/lib/drop-down/drop-down.component.ts
+++ b/projects/igniteui-angular/src/lib/drop-down/drop-down.component.ts
@@ -30,7 +30,7 @@ import { IgxDropDownItemBaseDirective } from './drop-down-item.base';
import { IgxForOfToken } from '../directives/for-of/for_of.directive';
import { take } from 'rxjs/operators';
import { OverlaySettings } from '../services/overlay/utilities';
-import { DOCUMENT, NgIf } from '@angular/common';
+import { DOCUMENT } from '@angular/common';
import { ConnectedPositioningStrategy } from '../services/public_api';
/**
@@ -54,7 +54,7 @@ import { ConnectedPositioningStrategy } from '../services/public_api';
selector: 'igx-drop-down',
templateUrl: './drop-down.component.html',
providers: [{ provide: IGX_DROPDOWN_BASE, useExisting: IgxDropDownComponent }],
- imports: [IgxToggleDirective, NgIf]
+ imports: [IgxToggleDirective]
})
export class IgxDropDownComponent extends IgxDropDownBaseDirective implements IDropDownBase, OnChanges, AfterViewInit, OnDestroy {
/**
diff --git a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.html b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.html
index abdf2d1d6bf..685d574bce9 100644
--- a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.html
+++ b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.html
@@ -6,12 +6,15 @@
-
-
-
+ @if (iconTemplate) {
+
+ }
+ @if (!iconTemplate) {
+
+
+ }
diff --git a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.ts b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.ts
index 9f6649582ad..a3702617f75 100644
--- a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.ts
+++ b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel-header.component.ts
@@ -17,7 +17,6 @@ import { IgxExpansionPanelIconDirective } from './expansion-panel.directives';
import { IGX_EXPANSION_PANEL_COMPONENT, IgxExpansionPanelBase, IExpansionPanelCancelableEventArgs } from './expansion-panel.common';
import { mkenum } from '../core/utils';
import { IgxIconComponent } from '../icon/icon.component';
-import { NgIf } from '@angular/common';
/**
* @hidden
@@ -33,7 +32,7 @@ export type ExpansionPanelHeaderIconPosition = (typeof ExpansionPanelHeaderIconP
@Component({
selector: 'igx-expansion-panel-header',
templateUrl: 'expansion-panel-header.component.html',
- imports: [NgIf, IgxIconComponent]
+ imports: [IgxIconComponent]
})
export class IgxExpansionPanelHeaderComponent {
/**
diff --git a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.html b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.html
index 78902268be3..da28c2f0e1e 100644
--- a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.html
+++ b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.html
@@ -1,2 +1,4 @@
-
+@if (!collapsed) {
+
+}
diff --git a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.ts b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.ts
index f2f643adb21..dbbf42b64ae 100644
--- a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.ts
+++ b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.component.ts
@@ -22,7 +22,6 @@ import {
IGX_EXPANSION_PANEL_COMPONENT
} from './expansion-panel.common';
import { ToggleAnimationPlayer, ToggleAnimationSettings } from './toggle-animation-component';
-import { NgIf } from '@angular/common';
let NEXT_ID = 0;
@@ -30,7 +29,7 @@ let NEXT_ID = 0;
selector: 'igx-expansion-panel',
templateUrl: 'expansion-panel.component.html',
providers: [{ provide: IGX_EXPANSION_PANEL_COMPONENT, useExisting: IgxExpansionPanelComponent }],
- imports: [NgIf]
+ imports: []
})
export class IgxExpansionPanelComponent extends ToggleAnimationPlayer implements IgxExpansionPanelBase, AfterContentInit {
/**
diff --git a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.spec.ts b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.spec.ts
index 5b8d1fb1c26..c743e019df5 100644
--- a/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.spec.ts
+++ b/projects/igniteui-angular/src/lib/expansion-panel/expansion-panel.spec.ts
@@ -11,7 +11,6 @@ import { By } from '@angular/platform-browser';
import { IgxExpansionPanelBodyComponent } from './expansion-panel-body.component';
import { IgxListComponent } from '../list/list.component';
import { IgxListItemComponent } from '../list/list-item.component';
-import { NgIf } from '@angular/common';
import { IGX_EXPANSION_PANEL_DIRECTIVES } from './public_api';
const CSS_CLASS_EXPANSION_PANEL = 'igx-expansion-panel';
@@ -1364,19 +1363,27 @@ export class IgxExpansionPanelListComponent {
-
- Example Title
- Example Description
-
- TEST_ICON
-
-
-
- Example body
-
+ @if (showHeader) {
+
+ @if (showTitle) {
+ Example Title
+ }
+ Example Description
+ @if (customIcon) {
+
+ TEST_ICON
+
+ }
+
+ }
+ @if (showBody) {
+
+ Example body
+
+ }
`,
- imports: [IgxExpansionPanelComponent, IgxExpansionPanelHeaderComponent, IgxExpansionPanelBodyComponent, IgxExpansionPanelTitleDirective, IgxExpansionPanelDescriptionDirective, IgxExpansionPanelIconDirective, NgIf]
+ imports: [IgxExpansionPanelComponent, IgxExpansionPanelHeaderComponent, IgxExpansionPanelBodyComponent, IgxExpansionPanelTitleDirective, IgxExpansionPanelDescriptionDirective, IgxExpansionPanelIconDirective]
})
export class IgxExpansionPanelSampleComponent {
@ViewChild(IgxExpansionPanelHeaderComponent, { read: IgxExpansionPanelHeaderComponent })
diff --git a/projects/igniteui-angular/src/lib/grids/cell.component.html b/projects/igniteui-angular/src/lib/grids/cell.component.html
index 47531b44d61..b6f3f84656c 100644
--- a/projects/igniteui-angular/src/lib/grids/cell.component.html
+++ b/projects/igniteui-angular/src/lib/grids/cell.component.html
@@ -1,37 +1,38 @@
- {{ grid.resourceStrings.igx_grid_pinned_row_indicator }}
+ @if (displayPinnedChip) {
+ {{ grid.resourceStrings.igx_grid_pinned_row_indicator }}
+ }
-
-
+}
-
- {{grid.resourceStrings.igx_grid_required_validation_error}}
-
-
- {{grid.resourceStrings.igx_grid_min_length_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.minlength.requiredLength }}
-
-
- {{grid.resourceStrings.igx_grid_max_length_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.maxlength.requiredLength }}
-
-
- {{grid.resourceStrings.igx_grid_min_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.min.min }}
-
-
- {{grid.resourceStrings.igx_grid_max_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.max.max }}
-
-
- {{grid.resourceStrings.igx_grid_email_validation_error }}
-
-
- {{grid.resourceStrings.igx_grid_pattern_validation_error}}
-
+ @if (formGroup?.get(column?.field).errors?.['required']) {
+
+ {{grid.resourceStrings.igx_grid_required_validation_error}}
+
+ }
+ @if (formGroup?.get(column?.field).errors?.['minlength']) {
+
+ {{grid.resourceStrings.igx_grid_min_length_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.minlength.requiredLength }}
+
+ }
+ @if (formGroup?.get(column?.field).errors?.['maxlength']) {
+
+ {{grid.resourceStrings.igx_grid_max_length_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.maxlength.requiredLength }}
+
+ }
+ @if (formGroup?.get(column?.field).errors?.['min']) {
+
+ {{grid.resourceStrings.igx_grid_min_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.min.min }}
+
+ }
+ @if (formGroup?.get(column?.field).errors?.['max']) {
+
+ {{grid.resourceStrings.igx_grid_max_validation_error | igxStringReplace:'{0}':formGroup.get(column.field).errors.max.max }}
+
+ }
+ @if (formGroup?.get(column?.field).errors?.['email']) {
+
+ {{grid.resourceStrings.igx_grid_email_validation_error }}
+
+ }
+ @if (formGroup?.get(column?.field).errors?.['pattern']) {
+
+ {{grid.resourceStrings.igx_grid_pattern_validation_error}}
+
+ }
diff --git a/projects/igniteui-angular/src/lib/grids/cell.component.ts b/projects/igniteui-angular/src/lib/grids/cell.component.ts
index 53f64a97360..eaacd3064e5 100644
--- a/projects/igniteui-angular/src/lib/grids/cell.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/cell.component.ts
@@ -19,7 +19,7 @@
AfterViewInit,
booleanAttribute
} from '@angular/core';
-import { formatPercent, NgIf, NgClass, NgTemplateOutlet, DecimalPipe, PercentPipe, CurrencyPipe, DatePipe, getLocaleCurrencyCode, getCurrencySymbol } from '@angular/common';
+import { formatPercent, NgClass, NgTemplateOutlet, DecimalPipe, PercentPipe, CurrencyPipe, DatePipe, getLocaleCurrencyCode, getCurrencySymbol } from '@angular/common';
import { FormControl, FormGroup, ReactiveFormsModule } from '@angular/forms';
import { first, takeUntil, takeWhile } from 'rxjs/operators';
@@ -72,7 +72,6 @@ import { IgxChipComponent } from '../chips/chip.component';
templateUrl: './cell.component.html',
providers: [HammerGesturesManager],
imports: [
- NgIf,
NgClass,
NgTemplateOutlet,
DecimalPipe,
diff --git a/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.html b/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.html
index 35455cf958d..071b64a2ac8 100644
--- a/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.html
+++ b/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.html
@@ -1,30 +1,37 @@
-
{{ title }}
+ @if (title) {
+ {{ title }}
+ }
-
-
-
+ @if (!hideFilter) {
+
+
+
+ }
-
- {{ column.header || column.field }}
-
+ @for (
+ column of $any(grid)?._columns
+ | columnActionEnabled:actionsDirective.actionEnabledColumnsFilter:pipeTrigger
+ | filterActionColumns:filterCriteria:pipeTrigger
+ | sortActionColumns:columnDisplayOrder:pipeTrigger; track column
+ ) {
+
+ {{ column.header || column.field }}
+
+ }
diff --git a/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.ts b/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.ts
index 2c2c6075c55..43c6c34b0dd 100644
--- a/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/column-actions/column-actions.component.ts
@@ -9,7 +9,6 @@ import { IgxButtonDirective } from '../../directives/button/button.directive';
import { IgxInputDirective } from '../../directives/input/input.directive';
import { FormsModule } from '@angular/forms';
import { IgxInputGroupComponent } from '../../input-group/input-group.component';
-import { NgIf, NgFor } from '@angular/common';
let NEXT_ID = 0;
/**
@@ -21,7 +20,7 @@ let NEXT_ID = 0;
@Component({
selector: 'igx-column-actions',
templateUrl: './column-actions.component.html',
- imports: [NgIf, IgxInputGroupComponent, FormsModule, IgxInputDirective, NgFor, IgxCheckboxComponent, IgxButtonDirective, IgxRippleDirective, forwardRef(() => IgxColumnActionEnabledPipe), forwardRef(() => IgxFilterActionColumnsPipe), forwardRef(() => IgxSortActionColumnsPipe)]
+ imports: [IgxInputGroupComponent, FormsModule, IgxInputDirective, IgxCheckboxComponent, IgxButtonDirective, IgxRippleDirective, forwardRef(() => IgxColumnActionEnabledPipe), forwardRef(() => IgxFilterActionColumnsPipe), forwardRef(() => IgxSortActionColumnsPipe)]
})
export class IgxColumnActionsComponent implements DoCheck {
diff --git a/projects/igniteui-angular/src/lib/grids/columns/column.component.ts b/projects/igniteui-angular/src/lib/grids/columns/column.component.ts
index 281b6ad7d93..9333d911c50 100644
--- a/projects/igniteui-angular/src/lib/grids/columns/column.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/columns/column.component.ts
@@ -2182,8 +2182,11 @@ export class IgxColumnComponent implements AfterContentInit, OnDestroy, ColumnTy
grid._pinnedColumns.splice(args.insertAtIndex, 0, this);
} else {
// insert based only on root collection
- rootPinnedCols.splice(args.insertAtIndex, 0, this);
+ if (this.level === 0) {
+ rootPinnedCols.splice(args.insertAtIndex, 0, this);
+ }
let allPinned = [];
+ // FIX: this is duplicated on every step in the hierarchy....
// re-create hierarchy
rootPinnedCols.forEach(group => {
allPinned.push(group);
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.html b/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.html
index 6ccad0ef851..eb11d0aaa6c 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.html
+++ b/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.html
@@ -1,36 +1,38 @@
-
-
-
-
-
+@if (grid) {
+
+
+
+
+
-
-
+
+
+}
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.ts b/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.ts
index 64b7ffe7735..3a733ddd475 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/filtering/advanced-filtering/advanced-filtering-dialog.component.ts
@@ -12,7 +12,7 @@ import { GridResourceStringsEN } from '../../../core/i18n/grid-resources';
import { IFilteringExpressionsTree } from '../../../data-operations/filtering-expressions-tree';
import { IgxButtonDirective } from '../../../directives/button/button.directive';
import { IgxQueryBuilderHeaderComponent } from '../../../query-builder/query-builder-header.component';
-import { NgIf, NgClass } from '@angular/common';
+import { NgClass } from '@angular/common';
import { getCurrentResourceStrings } from '../../../core/i18n/resources';
import { QueryBuilderResourceStringsEN } from '../../../core/i18n/query-builder-resources';
@@ -30,7 +30,7 @@ import { QueryBuilderResourceStringsEN } from '../../../core/i18n/query-builder-
@Component({
selector: 'igx-advanced-filtering-dialog',
templateUrl: './advanced-filtering-dialog.component.html',
- imports: [NgIf, IgxDragDirective, NgClass, IgxQueryBuilderComponent, IgxQueryBuilderHeaderComponent, IgxDragHandleDirective, IgxButtonDirective]
+ imports: [IgxDragDirective, NgClass, IgxQueryBuilderComponent, IgxQueryBuilderHeaderComponent, IgxDragHandleDirective, IgxButtonDirective]
})
export class IgxAdvancedFilteringDialogComponent implements AfterViewInit, OnDestroy {
/**
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.html b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.html
index f3b49671574..3fb62f3b3b1 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.html
+++ b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.html
@@ -14,23 +14,28 @@
-
-
-
-
-
- {{filteringService.getChipLabel(item.expression)}}
-
-
- {{filteringService.getOperatorAsString(item.afterOperator)}}
-
+
+ @for (item of expressionsList; track item.expression; let last = $last; let index = $index) {
+ @if (isChipVisible(index)) {
+
+
+
+
+ {{filteringService.getChipLabel(item.expression)}}
+
+
+ }
+ @if (!last && isChipVisible(index + 1)) {
+ {{filteringService.getOperatorAsString(item.afterOperator)}}
+ }
+ }
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.ts b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.ts
index 620d99b1c5e..a2b08705437 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-cell.component.ts
@@ -18,7 +18,7 @@ import { IgxChipsAreaComponent } from '../../../chips/chips-area.component';
import { IBaseChipEventArgs, IgxChipComponent } from '../../../chips/chip.component';
import { ColumnType } from '../../common/grid.interface';
import { IgxBadgeComponent } from '../../../badge/badge.component';
-import { NgFor, NgIf, NgClass, NgTemplateOutlet } from '@angular/common';
+import { NgClass, NgTemplateOutlet } from '@angular/common';
import { IgxPrefixDirective } from '../../../directives/prefix/prefix.directive';
import { IgxIconComponent } from '../../../icon/icon.component';
import { Size } from '../../common/enums';
@@ -35,8 +35,6 @@ import { Size } from '../../common/enums';
IgxChipComponent,
IgxIconComponent,
IgxPrefixDirective,
- NgFor,
- NgIf,
NgClass,
IgxBadgeComponent,
NgTemplateOutlet
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.html b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.html
index 03728071432..48bf1c5c0a1 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.html
+++ b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.html
@@ -1,13 +1,15 @@
-
-
-
- {{ translateCondition(condition) }}
-
-
+ @for (condition of conditions; track condition) {
+
+
+
+ {{ translateCondition(condition) }}
+
+
+ }
@@ -34,22 +36,24 @@
(compositionend)="onCompositionEnd()"
(keydown)="onInputKeyDown($event)"
(keyup)="onInputKeyUp()"/>
-
-
-
-
-
-
+ @if (value || value === 0) {
+
+
+
+
+
+
+ }
@@ -75,22 +79,24 @@
[igxDropDownItemNavigation]="inputGroupConditions">
-
-
-
-
-
-
+ @if (value) {
+
+
+
+
+
+
+ }
@@ -120,22 +126,24 @@
[igxDropDownItemNavigation]="inputGroupConditions">
-
-
-
-
-
-
+ @if (value) {
+
+
+
+
+
+
+ }
@@ -166,7 +174,8 @@
(click)="onInputClick()"
(keydown)="onInputKeyDown($event)"
(keyup)="onInputKeyUp()"/>
-
+ @if (value || value === 0) {
+
+ }
-
+@if (showArrows) {
+
+}
-
-
-
-
-
- {{filteringService.getChipLabel(item.expression)}}
-
-
-
-
-
- {{filteringService.grid.resourceStrings.igx_grid_filter_operator_and}}
- {{filteringService.grid.resourceStrings.igx_grid_filter_operator_or}}
-
-
-
+
+
+ @for (item of expressionsList; track item.expression; let i = $index; let last = $last) {
+
+
+
+
+ {{filteringService.getChipLabel(item.expression)}}
+
+ @if (!last) {
+
+
+
+ {{filteringService.grid.resourceStrings.igx_grid_filter_operator_and}}
+ {{filteringService.grid.resourceStrings.igx_grid_filter_operator_or}}
+
+
+ }
+
+ }
-
+@if (showArrows) {
+
+}
-
+ @if (!isNarrowWidth) {
-
-
+ }
+ @if (isNarrowWidth) {
-
+ }
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.ts b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.ts
index b0e905acb03..ef7ab4f3b0a 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/filtering/base/grid-filtering-row.component.ts
@@ -43,7 +43,7 @@ import { IgxDropDownItemNavigationDirective } from '../../../drop-down/drop-down
import { IgxPrefixDirective } from '../../../directives/prefix/prefix.directive';
import { IgxInputGroupComponent } from '../../../input-group/input-group.component';
import { IgxIconComponent } from '../../../icon/icon.component';
-import { NgFor, NgIf, NgTemplateOutlet, NgClass } from '@angular/common';
+import { NgTemplateOutlet, NgClass } from '@angular/common';
import { IgxIconButtonDirective } from '../../../directives/button/icon-button.directive';
import { Size } from '../../common/enums';
@@ -54,7 +54,7 @@ import { Size } from '../../common/enums';
changeDetection: ChangeDetectionStrategy.OnPush,
selector: 'igx-grid-filtering-row',
templateUrl: './grid-filtering-row.component.html',
- imports: [NgFor, IgxDropDownComponent, IgxDropDownItemComponent, IgxChipsAreaComponent, IgxChipComponent, IgxIconComponent, IgxInputGroupComponent, IgxPrefixDirective, IgxDropDownItemNavigationDirective, IgxInputDirective, NgIf, IgxSuffixDirective, IgxDatePickerComponent, IgxPickerToggleComponent, IgxPickerClearComponent, IgxTimePickerComponent, IgxDateTimeEditorDirective, NgTemplateOutlet, IgxButtonDirective, NgClass, IgxRippleDirective, IgxIconButtonDirective]
+ imports: [IgxDropDownComponent, IgxDropDownItemComponent, IgxChipsAreaComponent, IgxChipComponent, IgxIconComponent, IgxInputGroupComponent, IgxPrefixDirective, IgxDropDownItemNavigationDirective, IgxInputDirective, IgxSuffixDirective, IgxDatePickerComponent, IgxPickerToggleComponent, IgxPickerClearComponent, IgxTimePickerComponent, IgxDateTimeEditorDirective, NgTemplateOutlet, IgxButtonDirective, NgClass, IgxRippleDirective, IgxIconButtonDirective]
})
export class IgxGridFilteringRowComponent implements AfterViewInit, OnDestroy {
@Input()
@@ -87,14 +87,8 @@ export class IgxGridFilteringRowComponent implements AfterViewInit, OnDestroy {
this.expression.searchVal = null;
this._value = null;
const index = this.expressionsList.findIndex(item => item.expression === this.expression);
- if (index === 0 && this.expressionsList.length === 1) {
+ if (index === 0 && this.expressionsList.length === 1 && !this.expression.condition.isUnary) {
this.filteringService.clearFilter(this.column.field);
-
- if (this.expression.condition.isUnary) {
- this.resetExpression(this.expression.condition.name);
- }
-
- return;
}
} else {
if (val === '') {
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/common.ts b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/common.ts
index ee666e0450a..d48448c1f46 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/common.ts
+++ b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/common.ts
@@ -21,11 +21,17 @@ export class FilterListItem {
* @hidden
*/
export class ExpressionUI {
+ public expressionId: string;
public expression: IFilteringExpression;
public beforeOperator: FilteringLogic;
public afterOperator: FilteringLogic;
public isSelected = false;
public isVisible = true;
+
+ constructor() {
+ // Use IDs to identify expressions clearly and use to track them in template @for cycles.
+ this.expressionId = crypto.randomUUID();
+ }
}
/**
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.html b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.html
index e4745fc79d4..a724862428e 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.html
+++ b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.html
@@ -1,10 +1,12 @@
-
- {{ esf.grid.resourceStrings.igx_grid_excel_filter_clear }}
-
-
+@if (esf.column) {
+
+ {{ esf.grid.resourceStrings.igx_grid_excel_filter_clear }}
+
+
+}
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.ts b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.ts
index 2a78c304f0e..65449e4ad25 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-clear-filters.component.ts
@@ -2,7 +2,7 @@ import { Component } from '@angular/core';
import { PlatformUtil } from '../../../core/utils';
import { BaseFilteringComponent } from './base-filtering.component';
import { IgxIconComponent } from '../../../icon/icon.component';
-import { NgIf, NgClass } from '@angular/common';
+import { NgClass } from '@angular/common';
/**
* A component used for presenting Excel style clear filters UI.
@@ -10,7 +10,7 @@ import { NgIf, NgClass } from '@angular/common';
@Component({
selector: 'igx-excel-style-clear-filters',
templateUrl: './excel-style-clear-filters.component.html',
- imports: [NgIf, NgClass, IgxIconComponent]
+ imports: [NgClass, IgxIconComponent]
})
export class IgxExcelStyleClearFiltersComponent {
constructor(
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.html b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.html
index 6aa4f2f8a8c..0e10c481086 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.html
+++ b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.html
@@ -1,4 +1,4 @@
-
+@if (esf.column) {
0 ? 'igx-excel-filter__actions-filter--active' : ''"
@@ -9,7 +9,10 @@
aria-haspopup="true"
[attr.aria-controls]="this.subMenu?.listId"
[attr.aria-activedescendant]="!this.subMenu?.collapsed ? this.subMenu?.focusedItem?.id : null">
- {{ subMenuText }} 0">({{filterNumber}})
+
+ {{ subMenuText }}
+ @if (filterNumber > 0) { ({{filterNumber}}) }
+
@@ -19,22 +22,25 @@
(selectionChanging)="onSubMenuSelection($event)"
(closed)="onSubMenuClosed()">
-
-
-
- {{ translateCondition(condition) }}
-
-
-
-
-
- {{ esf.grid.resourceStrings.igx_grid_excel_custom_filter }}
-
-
+ @for (condition of conditions; track condition) {
+
+
+
+ {{ translateCondition(condition) }}
+
+
+ }
+ @if (showCustomFilterItem()) {
+
+
+
+ {{ esf.grid.resourceStrings.igx_grid_excel_custom_filter }}
+
+
+ }
@@ -44,4 +50,4 @@
[filteringService]="esf.grid.filteringService"
[overlayComponentId]="esf.overlayComponentId">
-
+}
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.ts b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.ts
index 4cbd41d7e25..fa35a644bd1 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.ts
+++ b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-conditional-filter.component.ts
@@ -14,7 +14,7 @@ import { IgxDropDownItemComponent } from '../../../drop-down/drop-down-item.comp
import { IgxDropDownComponent } from '../../../drop-down/drop-down.component';
import { IgxIconComponent } from '../../../icon/icon.component';
import { IgxDropDownItemNavigationDirective } from '../../../drop-down/drop-down-navigation.directive';
-import { NgIf, NgFor, NgClass } from '@angular/common';
+import { NgClass } from '@angular/common';
import { ISelectionEventArgs } from '../../../drop-down/drop-down.common';
@@ -24,7 +24,7 @@ import { ISelectionEventArgs } from '../../../drop-down/drop-down.common';
@Component({
selector: 'igx-excel-style-conditional-filter',
templateUrl: './excel-style-conditional-filter.component.html',
- imports: [NgIf, NgClass, IgxDropDownItemNavigationDirective, IgxIconComponent, IgxDropDownComponent, NgFor, IgxDropDownItemComponent, IgxExcelStyleCustomDialogComponent]
+ imports: [NgClass, IgxDropDownItemNavigationDirective, IgxIconComponent, IgxDropDownComponent, IgxDropDownItemComponent, IgxExcelStyleCustomDialogComponent]
})
export class IgxExcelStyleConditionalFilterComponent implements OnDestroy {
/**
diff --git a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-custom-dialog.component.html b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-custom-dialog.component.html
index 419d11d42cb..9998443fd1f 100644
--- a/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-custom-dialog.component.html
+++ b/projects/igniteui-angular/src/lib/grids/filtering/excel-style/excel-style-custom-dialog.component.html
@@ -14,29 +14,33 @@
-
-
-
-
+ @if (column.dataType === 'date' || column.dataType === 'dateTime' || column.dataType === 'time') {
+ @for (expression of expressionsList; track expression.expressionId) {
+
+
+ }
+ }
-
-
-
-
+ @if (column.dataType !== 'date' && column.dataType !== 'dateTime' && column.dataType !== 'time') {
+ @for (expression of expressionsList; track expression.expressionId) {
+
+
+ }
+ }