@progress/kendo-angular-dropdowns 21.1.1-develop.2 → 21.2.0-develop.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/codemods/utils.js +805 -394
  2. package/codemods/v19/autocomplete-subtitle.js +10 -13
  3. package/codemods/v19/autocomplete-title.js +10 -13
  4. package/codemods/v19/combobox-subtitle.js +10 -13
  5. package/codemods/v19/combobox-title.js +10 -14
  6. package/codemods/v19/dropdownlist-subtitle.js +10 -13
  7. package/codemods/v19/dropdownlist-title.js +10 -14
  8. package/codemods/v19/dropdowntree-subtitle.js +10 -13
  9. package/codemods/v19/dropdowntree-title.js +10 -13
  10. package/codemods/v19/multicolumncombobox-subtitle.js +10 -13
  11. package/codemods/v19/multicolumncombobox-title.js +10 -13
  12. package/codemods/v19/multiselect-subtitle.js +10 -13
  13. package/codemods/v19/multiselect-title.js +10 -13
  14. package/codemods/v19/multiselecttree-subtitle.js +10 -13
  15. package/codemods/v19/multiselecttree-title.js +10 -13
  16. package/esm2022/autocomplete/autocomplete.component.mjs +261 -219
  17. package/esm2022/comboboxes/combobox.component.mjs +298 -256
  18. package/esm2022/comboboxes/multicolumncombobox.component.mjs +429 -383
  19. package/esm2022/common/adaptive-renderer.component.mjs +123 -107
  20. package/esm2022/common/list.component.mjs +295 -217
  21. package/esm2022/common/navigation/navigation.service.mjs +2 -2
  22. package/esm2022/common/searchbar.component.mjs +2 -2
  23. package/esm2022/common/taglist.component.mjs +73 -59
  24. package/esm2022/dropdownlist/dropdownlist.component.mjs +262 -234
  25. package/esm2022/dropdowntrees/dropdowntree.component.mjs +298 -258
  26. package/esm2022/dropdowntrees/multiselecttree.component.mjs +361 -333
  27. package/esm2022/multiselect/multiselect.component.mjs +308 -267
  28. package/esm2022/package-metadata.mjs +2 -2
  29. package/fesm2022/progress-kendo-angular-dropdowns.mjs +2700 -2325
  30. package/package.json +11 -12
  31. package/schematics/ngAdd/index.js +2 -2
  32. package/codemods/template-transformer/index.js +0 -93
@@ -8,7 +8,7 @@ import { validatePackage } from '@progress/kendo-licensing';
8
8
  import { packageMetadata } from '../package-metadata';
9
9
  import { merge, interval, Subscription } from 'rxjs';
10
10
  import { concatMap, filter, map, skipWhile, take, takeUntil, tap } from 'rxjs/operators';
11
- import { isDocumentAvailable, KendoInput, hasObservers, anyChanged, isChanged, EventsOutsideAngularDirective, ResizeSensorComponent, Keys, TemplateContextDirective, isSafari, guid, normalizeNumpadKeys } from '@progress/kendo-angular-common';
11
+ import { isDocumentAvailable, KendoInput, hasObservers, anyChanged, isChanged, EventsOutsideAngularDirective, ResizeSensorComponent, Keys, TemplateContextDirective, isSafari, guid, normalizeKeys } from '@progress/kendo-angular-common';
12
12
  import { AdaptiveService } from '@progress/kendo-angular-utils';
13
13
  import { isPresent, getter, shuffleData, sameCharsOnly, matchText, isUntouched, inDropDown, getSizeClass, getRoundedClass, getFillModeClass, isTruthy, setListBoxAriaLabelledBy, setActionSheetTitle, animationDuration } from '../common/util';
14
14
  import { SelectionService } from '../common/selection/selection.service';
@@ -33,7 +33,7 @@ import { normalizeVirtualizationSettings } from '../common/models/virtualization
33
33
  import { caretAltDownIcon, searchIcon, xIcon } from '@progress/kendo-svg-icons';
34
34
  import { AdaptiveRendererComponent } from '../common/adaptive-renderer.component';
35
35
  import { FilterInputDirective } from '../common/filter-input.directive';
36
- import { NgIf, NgClass, NgTemplateOutlet } from '@angular/common';
36
+ import { NgClass, NgTemplateOutlet } from '@angular/common';
37
37
  import { LocalizedMessagesDirective } from '../common/localization/localized-messages.directive';
38
38
  import { IconWrapperComponent } from '@progress/kendo-angular-icons';
39
39
  import { touchEnabled } from '@progress/kendo-common';
@@ -599,7 +599,7 @@ export class DropDownListComponent {
599
599
  return;
600
600
  }
601
601
  // on some keyboards, Home and End keys are mapped to Numpad keys
602
- const code = normalizeNumpadKeys(event);
602
+ const code = normalizeKeys(event);
603
603
  const isHomeKey = code === Keys.Home;
604
604
  const isEndKey = code === Keys.End;
605
605
  const isHomeEnd = isHomeKey || isEndKey;
@@ -1062,7 +1062,7 @@ export class DropDownListComponent {
1062
1062
  this.subs.add(merge(this.navigationService.pagedown, this.navigationService.pageup).subscribe((event) => {
1063
1063
  if (this.isOpen) {
1064
1064
  event.originalEvent.preventDefault();
1065
- const code = normalizeNumpadKeys(event.originalEvent);
1065
+ const code = normalizeKeys(event.originalEvent);
1066
1066
  this.optionsList.scrollWithOnePage(NavigationAction[code]);
1067
1067
  }
1068
1068
  }));
@@ -1452,7 +1452,7 @@ export class DropDownListComponent {
1452
1452
  this.opened.emit();
1453
1453
  }
1454
1454
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: DropDownListComponent, deps: [{ token: i0.ElementRef }, { token: i1.LocalizationService }, { token: i2.PopupService }, { token: i3.SelectionService }, { token: i4.NavigationService }, { token: i5.DisabledItemsService }, { token: i6.DataService }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i0.Injector }, { token: i7.AdaptiveService }], target: i0.ɵɵFactoryTarget.Component });
1455
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.14", type: DropDownListComponent, isStandalone: true, selector: "kendo-dropdownlist", inputs: { customIconClass: "customIconClass", showStickyHeader: "showStickyHeader", icon: "icon", svgIcon: "svgIcon", loading: "loading", data: "data", value: "value", textField: "textField", valueField: "valueField", adaptiveMode: "adaptiveMode", adaptiveTitle: "adaptiveTitle", adaptiveSubtitle: "adaptiveSubtitle", popupSettings: "popupSettings", listHeight: "listHeight", defaultItem: "defaultItem", disabled: "disabled", itemDisabled: "itemDisabled", readonly: "readonly", filterable: "filterable", virtual: "virtual", ignoreCase: "ignoreCase", delay: "delay", valuePrimitive: "valuePrimitive", tabindex: "tabindex", tabIndex: "tabIndex", size: "size", rounded: "rounded", fillMode: "fillMode", leftRightArrowsNavigation: "leftRightArrowsNavigation", focusableId: ["id", "focusableId"] }, outputs: { valueChange: "valueChange", filterChange: "filterChange", selectionChange: "selectionChange", open: "open", opened: "opened", close: "close", closed: "closed", onFocus: "focus", onBlur: "blur" }, host: { listeners: { "keydown": "keydown($event)", "keypress": "keypress($event)", "click": "click()" }, properties: { "class.k-readonly": "this.readonly", "class.k-dropdownlist": "this.hostClasses", "class.k-picker": "this.hostClasses", "class.k-disabled": "this.isDisabledClass", "attr.aria-disabled": "this.isDisabledClass", "class.k-loading": "this.isLoading", "attr.id": "this.focusableId", "attr.dir": "this.dir", "attr.tabindex": "this.hostTabIndex", "attr.readonly": "this.readonlyAttr", "attr.aria-busy": "this.isBusy", "attr.role": "this.role", "attr.aria-haspopup": "this.haspopup", "attr.aria-invalid": "this.hostAriaInvalid" } }, providers: [
1455
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: DropDownListComponent, isStandalone: true, selector: "kendo-dropdownlist", inputs: { customIconClass: "customIconClass", showStickyHeader: "showStickyHeader", icon: "icon", svgIcon: "svgIcon", loading: "loading", data: "data", value: "value", textField: "textField", valueField: "valueField", adaptiveMode: "adaptiveMode", adaptiveTitle: "adaptiveTitle", adaptiveSubtitle: "adaptiveSubtitle", popupSettings: "popupSettings", listHeight: "listHeight", defaultItem: "defaultItem", disabled: "disabled", itemDisabled: "itemDisabled", readonly: "readonly", filterable: "filterable", virtual: "virtual", ignoreCase: "ignoreCase", delay: "delay", valuePrimitive: "valuePrimitive", tabindex: "tabindex", tabIndex: "tabIndex", size: "size", rounded: "rounded", fillMode: "fillMode", leftRightArrowsNavigation: "leftRightArrowsNavigation", focusableId: ["id", "focusableId"] }, outputs: { valueChange: "valueChange", filterChange: "filterChange", selectionChange: "selectionChange", open: "open", opened: "opened", close: "close", closed: "closed", onFocus: "focus", onBlur: "blur" }, host: { listeners: { "keydown": "keydown($event)", "keypress": "keypress($event)", "click": "click()" }, properties: { "class.k-readonly": "this.readonly", "class.k-dropdownlist": "this.hostClasses", "class.k-picker": "this.hostClasses", "class.k-disabled": "this.isDisabledClass", "attr.aria-disabled": "this.isDisabledClass", "class.k-loading": "this.isLoading", "attr.id": "this.focusableId", "attr.dir": "this.dir", "attr.tabindex": "this.hostTabIndex", "attr.readonly": "this.readonlyAttr", "attr.aria-busy": "this.isBusy", "attr.role": "this.role", "attr.aria-haspopup": "this.haspopup", "attr.aria-invalid": "this.hostAriaInvalid" } }, providers: [
1456
1456
  DROPDOWNLIST_VALUE_ACCESSOR,
1457
1457
  DataService,
1458
1458
  SelectionService,
@@ -1471,152 +1471,166 @@ export class DropDownListComponent {
1471
1471
  }
1472
1472
  ], queries: [{ propertyName: "itemTemplate", first: true, predicate: ItemTemplateDirective, descendants: true }, { propertyName: "groupTemplate", first: true, predicate: GroupTemplateDirective, descendants: true }, { propertyName: "fixedGroupTemplate", first: true, predicate: FixedGroupTemplateDirective, descendants: true }, { propertyName: "valueTemplate", first: true, predicate: ValueTemplateDirective, descendants: true }, { propertyName: "headerTemplate", first: true, predicate: HeaderTemplateDirective, descendants: true }, { propertyName: "footerTemplate", first: true, predicate: FooterTemplateDirective, descendants: true }, { propertyName: "noDataTemplate", first: true, predicate: NoDataTemplateDirective, descendants: true }], viewQueries: [{ propertyName: "adaptiveRenderer", first: true, predicate: AdaptiveRendererComponent, descendants: true }, { propertyName: "searchInput", first: true, predicate: ["searchInput"], descendants: true }, { propertyName: "container", first: true, predicate: ["container"], descendants: true, read: ViewContainerRef, static: true }, { propertyName: "popupTemplate", first: true, predicate: ["popupTemplate"], descendants: true, static: true }, { propertyName: "optionsList", first: true, predicate: ["optionsList"], descendants: true }], exportAs: ["kendoDropDownList"], usesOnChanges: true, ngImport: i0, template: `
1473
1473
  <ng-container kendoDropDownListLocalizedMessages
1474
- i18n-noDataText="kendo.dropdownlist.noDataText|The text displayed in the popup when there are no items"
1475
- noDataText="NO DATA FOUND"
1476
-
1477
- i18n-selectButtonText="kendo.dropdownlist.selectButtonText|The text set as aria-label on the select button"
1478
- selectButtonText="Select"
1479
-
1480
- i18n-filterInputLabel="kendo.dropdownlist.filterInputLabel|The text set as aria-label on the filter input"
1481
- filterInputLabel="Filter"
1482
-
1483
- i18n-popupLabel="kendo.dropdownlist.popupLabel|The label of the popup element that contains the list of options when its role is 'region'"
1484
- popupLabel="Options list"
1485
-
1486
- i18n-adaptiveCloseButtonTitle="kendo.dropdownlist.adaptiveCloseButtonTitle|The title of the Close button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
1487
- adaptiveCloseButtonTitle="Close"
1488
-
1489
- i18n-filterPlaceholder="kendo.dropdownlist.filterPlaceholder|The text for the input's placeholder when filtering is enabled"
1490
- filterInputPlaceholder="Filter"
1491
- >
1474
+ i18n-noDataText="kendo.dropdownlist.noDataText|The text displayed in the popup when there are no items"
1475
+ noDataText="NO DATA FOUND"
1476
+
1477
+ i18n-selectButtonText="kendo.dropdownlist.selectButtonText|The text set as aria-label on the select button"
1478
+ selectButtonText="Select"
1479
+
1480
+ i18n-filterInputLabel="kendo.dropdownlist.filterInputLabel|The text set as aria-label on the filter input"
1481
+ filterInputLabel="Filter"
1482
+
1483
+ i18n-popupLabel="kendo.dropdownlist.popupLabel|The label of the popup element that contains the list of options when its role is 'region'"
1484
+ popupLabel="Options list"
1485
+
1486
+ i18n-adaptiveCloseButtonTitle="kendo.dropdownlist.adaptiveCloseButtonTitle|The title of the Close button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
1487
+ adaptiveCloseButtonTitle="Close"
1488
+
1489
+ i18n-filterPlaceholder="kendo.dropdownlist.filterPlaceholder|The text for the input's placeholder when filtering is enabled"
1490
+ filterInputPlaceholder="Filter"
1491
+ >
1492
1492
  </ng-container>
1493
1493
  <span class="k-input-inner" unselectable="on" [id]="valueLabelId" (click)="$event.preventDefault()">
1494
- <span class="k-input-value-text">
1495
- <ng-template *ngIf="valueTemplate"
1494
+ <span class="k-input-value-text">
1495
+ @if (valueTemplate) {
1496
+ <ng-template
1496
1497
  [templateContext]="{
1497
1498
  templateRef: valueTemplate.templateRef,
1498
1499
  $implicit: dataItem
1499
1500
  }">
1500
- </ng-template>
1501
- <ng-template [ngIf]="!valueTemplate">{{ getText() }}</ng-template>
1502
- </span>
1501
+ </ng-template>
1502
+ }
1503
+ @if (!valueTemplate) {{{ getText() }}}
1504
+ </span>
1503
1505
  </span>
1504
- <span *ngIf="loading" class="k-i-loading k-input-loading-icon k-icon"></span>
1506
+ @if (loading) {
1507
+ <span class="k-i-loading k-input-loading-icon k-icon"></span>
1508
+ }
1505
1509
  <button
1506
- tabindex="-1"
1507
- unselectable="on"
1508
- type="button"
1509
- class="k-input-button k-button k-icon-button"
1510
- [ngClass]="selectButtonClasses"
1511
- [attr.aria-label]="messageFor('selectButtonText')"
1512
- [attr.disabled]="disabled ? '' : null"
1510
+ tabindex="-1"
1511
+ unselectable="on"
1512
+ type="button"
1513
+ class="k-input-button k-button k-icon-button"
1514
+ [ngClass]="selectButtonClasses"
1515
+ [attr.aria-label]="messageFor('selectButtonText')"
1516
+ [attr.disabled]="disabled ? '' : null"
1513
1517
  [kendoEventsOutsideAngular]="{
1514
1518
  mousedown: onMouseDown
1515
1519
  }"
1516
- >
1517
- <kendo-icon-wrapper
1518
- unselectable="on"
1519
- [name]="icon || 'caret-alt-down'"
1520
- innerCssClass="k-button-icon"
1521
- [customFontClass]="customIconClass"
1522
- [svgIcon]="svgIcon || caretAltDownSVGIcon">
1523
- </kendo-icon-wrapper>
1520
+ >
1521
+ <kendo-icon-wrapper
1522
+ unselectable="on"
1523
+ [name]="icon || 'caret-alt-down'"
1524
+ innerCssClass="k-button-icon"
1525
+ [customFontClass]="customIconClass"
1526
+ [svgIcon]="svgIcon || caretAltDownSVGIcon">
1527
+ </kendo-icon-wrapper>
1524
1528
  </button>
1525
1529
  <ng-template #popupTemplate>
1526
- <ng-container *ngTemplateOutlet="sharedPopupActionSheetTemplate"></ng-container>
1530
+ <ng-container *ngTemplateOutlet="sharedPopupActionSheetTemplate"></ng-container>
1527
1531
  </ng-template>
1528
- <kendo-resize-sensor *ngIf="isOpen || isAdaptiveModeEnabled" (resize)="onResize()"></kendo-resize-sensor>
1532
+ @if (isOpen || isAdaptiveModeEnabled) {
1533
+ <kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
1534
+ }
1529
1535
  <ng-container #container></ng-container>
1530
-
1536
+
1531
1537
  <kendo-adaptive-renderer
1532
- [sharedPopupActionSheetTemplate]="sharedPopupActionSheetTemplate"
1533
- [title]="adaptiveTitle"
1534
- [showTextInput]="filterable"
1535
- [subtitle]="adaptiveSubtitle"
1536
- (closePopup)="togglePopup(false)"
1537
- (textInputChange)="onFilterChange($event)"
1538
- [filterable]="filterable">
1538
+ [sharedPopupActionSheetTemplate]="sharedPopupActionSheetTemplate"
1539
+ [title]="adaptiveTitle"
1540
+ [showTextInput]="filterable"
1541
+ [subtitle]="adaptiveSubtitle"
1542
+ (closePopup)="togglePopup(false)"
1543
+ (textInputChange)="onFilterChange($event)"
1544
+ [filterable]="filterable">
1539
1545
  </kendo-adaptive-renderer>
1540
-
1546
+
1541
1547
  <ng-template #sharedPopupActionSheetTemplate>
1542
- <!--filterable-->
1543
- <ng-template [ngIf]="filterable && !isActionSheetExpanded">
1544
- <div class="k-list-filter" (click)="$event.stopImmediatePropagation()">
1545
- <span
1546
- class="k-searchbox k-input"
1547
- [ngClass]="filterInputClasses">
1548
- <kendo-icon-wrapper
1549
- class="k-icon"
1550
- innerCssClass="k-input-icon"
1551
- name="search"
1552
- [svgIcon]="searchIcon">
1553
- </kendo-icon-wrapper>
1554
- <input
1555
- #searchInput
1556
- role="searchbox"
1557
- aria-autocomplete="list"
1558
- aria-haspopup="listbox"
1559
- [attr.aria-controls]="listBoxId"
1560
- tabindex="-1"
1561
- [filterInput]="isFocused && !touchEnabled"
1562
- [attr.aria-label]="messageFor('filterInputLabel')"
1563
- [dir]="direction"
1564
- [(ngModel)]="filterText"
1565
- class="k-input-inner"
1566
- (keydown)="keydown($event, searchInput)"
1567
- (input)="handleFilter($event)"
1568
- (focus)="onFilterFocus()"
1569
- (blur)="blurFilterInput()"
1570
- (click)="handleClick()" />
1571
- </span>
1572
- </div>
1573
- </ng-template>
1574
- <!--header template-->
1575
- <ng-template *ngIf="headerTemplate"
1548
+ <!--filterable-->
1549
+ @if (filterable && !isActionSheetExpanded) {
1550
+ <div class="k-list-filter" (click)="$event.stopImmediatePropagation()">
1551
+ <span
1552
+ class="k-searchbox k-input"
1553
+ [ngClass]="filterInputClasses">
1554
+ <kendo-icon-wrapper
1555
+ class="k-icon"
1556
+ innerCssClass="k-input-icon"
1557
+ name="search"
1558
+ [svgIcon]="searchIcon">
1559
+ </kendo-icon-wrapper>
1560
+ <input
1561
+ #searchInput
1562
+ role="searchbox"
1563
+ aria-autocomplete="list"
1564
+ aria-haspopup="listbox"
1565
+ [attr.aria-controls]="listBoxId"
1566
+ tabindex="-1"
1567
+ [filterInput]="isFocused && !touchEnabled"
1568
+ [attr.aria-label]="messageFor('filterInputLabel')"
1569
+ [dir]="direction"
1570
+ [(ngModel)]="filterText"
1571
+ class="k-input-inner"
1572
+ (keydown)="keydown($event, searchInput)"
1573
+ (input)="handleFilter($event)"
1574
+ (focus)="onFilterFocus()"
1575
+ (blur)="blurFilterInput()"
1576
+ (click)="handleClick()" />
1577
+ </span>
1578
+ </div>
1579
+ }
1580
+ <!--header template-->
1581
+ @if (headerTemplate) {
1582
+ <ng-template
1576
1583
  [templateContext]="{
1577
1584
  templateRef: headerTemplate.templateRef
1578
1585
  }">
1579
1586
  </ng-template>
1580
- <!--list-->
1581
- <kendo-list
1582
- #optionsList
1583
- [id]="listBoxId"
1584
- [size]="isAdaptive ? 'large' : size"
1585
- [rounded]="rounded"
1586
- [optionPrefix]="optionPrefix"
1587
- [data]="data"
1588
- [textField]="textField"
1589
- [valueField]="valueField"
1590
- [template]="itemTemplate"
1591
- [groupTemplate]="groupTemplate"
1592
- [fixedGroupTemplate]="fixedGroupTemplate"
1593
- [height]="listHeight"
1594
- [show]="isOpen"
1595
- [virtual]="virtual"
1596
- [ariaLive]="ariaLive"
1597
- [showStickyHeader]="showStickyHeader"
1598
- (pageChange)="pageChange($event)"
1599
- [defaultItem]="defaultItem">
1600
- </kendo-list>
1601
- <!--no-data template-->
1602
- <div class="k-no-data" *ngIf="data.length === 0">
1603
- <ng-template [ngIf]="noDataTemplate"
1587
+ }
1588
+ <!--list-->
1589
+ <kendo-list
1590
+ #optionsList
1591
+ [id]="listBoxId"
1592
+ [size]="isAdaptive ? 'large' : size"
1593
+ [rounded]="rounded"
1594
+ [optionPrefix]="optionPrefix"
1595
+ [data]="data"
1596
+ [textField]="textField"
1597
+ [valueField]="valueField"
1598
+ [template]="itemTemplate"
1599
+ [groupTemplate]="groupTemplate"
1600
+ [fixedGroupTemplate]="fixedGroupTemplate"
1601
+ [height]="listHeight"
1602
+ [show]="isOpen"
1603
+ [virtual]="virtual"
1604
+ [ariaLive]="ariaLive"
1605
+ [showStickyHeader]="showStickyHeader"
1606
+ (pageChange)="pageChange($event)"
1607
+ [defaultItem]="defaultItem">
1608
+ </kendo-list>
1609
+ <!--no-data template-->
1610
+ @if (data.length === 0) {
1611
+ <div class="k-no-data">
1612
+ @if (noDataTemplate) {
1613
+ <ng-template
1604
1614
  [templateContext]="{
1605
1615
  templateRef: noDataTemplate ? noDataTemplate.templateRef : undefined
1606
1616
  }">
1607
1617
  </ng-template>
1608
- <ng-template [ngIf]="!noDataTemplate">
1609
- <div>{{ messageFor('noDataText') }}</div>
1610
- </ng-template>
1618
+ }
1619
+ @if (!noDataTemplate) {
1620
+ <div>{{ messageFor('noDataText') }}</div>
1621
+ }
1611
1622
  </div>
1612
- <!--footer template-->
1613
- <ng-template *ngIf="footerTemplate"
1623
+ }
1624
+ <!--footer template-->
1625
+ @if (footerTemplate) {
1626
+ <ng-template
1614
1627
  [templateContext]="{
1615
1628
  templateRef: footerTemplate.templateRef
1616
1629
  }">
1617
1630
  </ng-template>
1631
+ }
1618
1632
  </ng-template>
1619
- `, isInline: true, dependencies: [{ kind: "directive", type: LocalizedMessagesDirective, selector: "\n [kendoDropDownListLocalizedMessages],\n [kendoDropDownTreeLocalizedMessages],\n [kendoComboBoxLocalizedMessages],\n [kendoMultiColumnComboBoxLocalizedMessages],\n [kendoAutoCompleteLocalizedMessages],\n [kendoMultiSelectLocalizedMessages],\n [kendoMultiSelectTreeLocalizedMessages]\n " }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: TemplateContextDirective, selector: "[templateContext]", inputs: ["templateContext"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: EventsOutsideAngularDirective, selector: "[kendoEventsOutsideAngular]", inputs: ["kendoEventsOutsideAngular", "scope"] }, { kind: "component", type: IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass", "size"], exportAs: ["kendoIconWrapper"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }, { kind: "component", type: AdaptiveRendererComponent, selector: "kendo-adaptive-renderer", inputs: ["title", "subtitle", "showTextInput", "sharedPopupActionSheetTemplate", "text", "placeholder", "searchBarValue", "filterable"], outputs: ["closePopup", "textInputChange", "navigate", "onExpand"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i8.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i8.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: FilterInputDirective, selector: "[filterInput]", inputs: ["filterInput"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i8.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ListComponent, selector: "kendo-list", inputs: ["selected", "focused", "textField", "valueField", "height", "template", "groupTemplate", "fixedGroupTemplate", "show", "id", "optionPrefix", "multipleSelection", "virtual", "type", "checkboxes", "ariaLive", "isMultiselect", "isActionSheetExpanded", "showStickyHeader", "rowWidth", "customItemTemplate", "text", "allowCustom", "defaultItem", "data", "size", "rounded"], outputs: ["onClick", "pageChange", "listResize", "popupListScroll"] }] });
1633
+ `, isInline: true, dependencies: [{ kind: "directive", type: LocalizedMessagesDirective, selector: "\n [kendoDropDownListLocalizedMessages],\n [kendoDropDownTreeLocalizedMessages],\n [kendoComboBoxLocalizedMessages],\n [kendoMultiColumnComboBoxLocalizedMessages],\n [kendoAutoCompleteLocalizedMessages],\n [kendoMultiSelectLocalizedMessages],\n [kendoMultiSelectTreeLocalizedMessages]\n " }, { kind: "directive", type: TemplateContextDirective, selector: "[templateContext]", inputs: ["templateContext"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: EventsOutsideAngularDirective, selector: "[kendoEventsOutsideAngular]", inputs: ["kendoEventsOutsideAngular", "scope"] }, { kind: "component", type: IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass", "size"], exportAs: ["kendoIconWrapper"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }, { kind: "component", type: AdaptiveRendererComponent, selector: "kendo-adaptive-renderer", inputs: ["title", "subtitle", "showTextInput", "sharedPopupActionSheetTemplate", "text", "placeholder", "searchBarValue", "filterable"], outputs: ["closePopup", "textInputChange", "navigate", "onExpand"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i8.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i8.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: FilterInputDirective, selector: "[filterInput]", inputs: ["filterInput"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i8.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: ListComponent, selector: "kendo-list", inputs: ["selected", "focused", "textField", "valueField", "height", "template", "groupTemplate", "fixedGroupTemplate", "show", "id", "optionPrefix", "multipleSelection", "virtual", "type", "checkboxes", "ariaLive", "isMultiselect", "isActionSheetExpanded", "showStickyHeader", "rowWidth", "customItemTemplate", "text", "allowCustom", "defaultItem", "data", "size", "rounded"], outputs: ["onClick", "pageChange", "listResize", "popupListScroll"] }] });
1620
1634
  }
1621
1635
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: DropDownListComponent, decorators: [{
1622
1636
  type: Component,
@@ -1643,154 +1657,168 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
1643
1657
  selector: 'kendo-dropdownlist',
1644
1658
  template: `
1645
1659
  <ng-container kendoDropDownListLocalizedMessages
1646
- i18n-noDataText="kendo.dropdownlist.noDataText|The text displayed in the popup when there are no items"
1647
- noDataText="NO DATA FOUND"
1648
-
1649
- i18n-selectButtonText="kendo.dropdownlist.selectButtonText|The text set as aria-label on the select button"
1650
- selectButtonText="Select"
1651
-
1652
- i18n-filterInputLabel="kendo.dropdownlist.filterInputLabel|The text set as aria-label on the filter input"
1653
- filterInputLabel="Filter"
1654
-
1655
- i18n-popupLabel="kendo.dropdownlist.popupLabel|The label of the popup element that contains the list of options when its role is 'region'"
1656
- popupLabel="Options list"
1657
-
1658
- i18n-adaptiveCloseButtonTitle="kendo.dropdownlist.adaptiveCloseButtonTitle|The title of the Close button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
1659
- adaptiveCloseButtonTitle="Close"
1660
-
1661
- i18n-filterPlaceholder="kendo.dropdownlist.filterPlaceholder|The text for the input's placeholder when filtering is enabled"
1662
- filterInputPlaceholder="Filter"
1663
- >
1660
+ i18n-noDataText="kendo.dropdownlist.noDataText|The text displayed in the popup when there are no items"
1661
+ noDataText="NO DATA FOUND"
1662
+
1663
+ i18n-selectButtonText="kendo.dropdownlist.selectButtonText|The text set as aria-label on the select button"
1664
+ selectButtonText="Select"
1665
+
1666
+ i18n-filterInputLabel="kendo.dropdownlist.filterInputLabel|The text set as aria-label on the filter input"
1667
+ filterInputLabel="Filter"
1668
+
1669
+ i18n-popupLabel="kendo.dropdownlist.popupLabel|The label of the popup element that contains the list of options when its role is 'region'"
1670
+ popupLabel="Options list"
1671
+
1672
+ i18n-adaptiveCloseButtonTitle="kendo.dropdownlist.adaptiveCloseButtonTitle|The title of the Close button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
1673
+ adaptiveCloseButtonTitle="Close"
1674
+
1675
+ i18n-filterPlaceholder="kendo.dropdownlist.filterPlaceholder|The text for the input's placeholder when filtering is enabled"
1676
+ filterInputPlaceholder="Filter"
1677
+ >
1664
1678
  </ng-container>
1665
1679
  <span class="k-input-inner" unselectable="on" [id]="valueLabelId" (click)="$event.preventDefault()">
1666
- <span class="k-input-value-text">
1667
- <ng-template *ngIf="valueTemplate"
1680
+ <span class="k-input-value-text">
1681
+ @if (valueTemplate) {
1682
+ <ng-template
1668
1683
  [templateContext]="{
1669
1684
  templateRef: valueTemplate.templateRef,
1670
1685
  $implicit: dataItem
1671
1686
  }">
1672
- </ng-template>
1673
- <ng-template [ngIf]="!valueTemplate">{{ getText() }}</ng-template>
1674
- </span>
1687
+ </ng-template>
1688
+ }
1689
+ @if (!valueTemplate) {{{ getText() }}}
1690
+ </span>
1675
1691
  </span>
1676
- <span *ngIf="loading" class="k-i-loading k-input-loading-icon k-icon"></span>
1692
+ @if (loading) {
1693
+ <span class="k-i-loading k-input-loading-icon k-icon"></span>
1694
+ }
1677
1695
  <button
1678
- tabindex="-1"
1679
- unselectable="on"
1680
- type="button"
1681
- class="k-input-button k-button k-icon-button"
1682
- [ngClass]="selectButtonClasses"
1683
- [attr.aria-label]="messageFor('selectButtonText')"
1684
- [attr.disabled]="disabled ? '' : null"
1696
+ tabindex="-1"
1697
+ unselectable="on"
1698
+ type="button"
1699
+ class="k-input-button k-button k-icon-button"
1700
+ [ngClass]="selectButtonClasses"
1701
+ [attr.aria-label]="messageFor('selectButtonText')"
1702
+ [attr.disabled]="disabled ? '' : null"
1685
1703
  [kendoEventsOutsideAngular]="{
1686
1704
  mousedown: onMouseDown
1687
1705
  }"
1688
- >
1689
- <kendo-icon-wrapper
1690
- unselectable="on"
1691
- [name]="icon || 'caret-alt-down'"
1692
- innerCssClass="k-button-icon"
1693
- [customFontClass]="customIconClass"
1694
- [svgIcon]="svgIcon || caretAltDownSVGIcon">
1695
- </kendo-icon-wrapper>
1706
+ >
1707
+ <kendo-icon-wrapper
1708
+ unselectable="on"
1709
+ [name]="icon || 'caret-alt-down'"
1710
+ innerCssClass="k-button-icon"
1711
+ [customFontClass]="customIconClass"
1712
+ [svgIcon]="svgIcon || caretAltDownSVGIcon">
1713
+ </kendo-icon-wrapper>
1696
1714
  </button>
1697
1715
  <ng-template #popupTemplate>
1698
- <ng-container *ngTemplateOutlet="sharedPopupActionSheetTemplate"></ng-container>
1716
+ <ng-container *ngTemplateOutlet="sharedPopupActionSheetTemplate"></ng-container>
1699
1717
  </ng-template>
1700
- <kendo-resize-sensor *ngIf="isOpen || isAdaptiveModeEnabled" (resize)="onResize()"></kendo-resize-sensor>
1718
+ @if (isOpen || isAdaptiveModeEnabled) {
1719
+ <kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
1720
+ }
1701
1721
  <ng-container #container></ng-container>
1702
-
1722
+
1703
1723
  <kendo-adaptive-renderer
1704
- [sharedPopupActionSheetTemplate]="sharedPopupActionSheetTemplate"
1705
- [title]="adaptiveTitle"
1706
- [showTextInput]="filterable"
1707
- [subtitle]="adaptiveSubtitle"
1708
- (closePopup)="togglePopup(false)"
1709
- (textInputChange)="onFilterChange($event)"
1710
- [filterable]="filterable">
1724
+ [sharedPopupActionSheetTemplate]="sharedPopupActionSheetTemplate"
1725
+ [title]="adaptiveTitle"
1726
+ [showTextInput]="filterable"
1727
+ [subtitle]="adaptiveSubtitle"
1728
+ (closePopup)="togglePopup(false)"
1729
+ (textInputChange)="onFilterChange($event)"
1730
+ [filterable]="filterable">
1711
1731
  </kendo-adaptive-renderer>
1712
-
1732
+
1713
1733
  <ng-template #sharedPopupActionSheetTemplate>
1714
- <!--filterable-->
1715
- <ng-template [ngIf]="filterable && !isActionSheetExpanded">
1716
- <div class="k-list-filter" (click)="$event.stopImmediatePropagation()">
1717
- <span
1718
- class="k-searchbox k-input"
1719
- [ngClass]="filterInputClasses">
1720
- <kendo-icon-wrapper
1721
- class="k-icon"
1722
- innerCssClass="k-input-icon"
1723
- name="search"
1724
- [svgIcon]="searchIcon">
1725
- </kendo-icon-wrapper>
1726
- <input
1727
- #searchInput
1728
- role="searchbox"
1729
- aria-autocomplete="list"
1730
- aria-haspopup="listbox"
1731
- [attr.aria-controls]="listBoxId"
1732
- tabindex="-1"
1733
- [filterInput]="isFocused && !touchEnabled"
1734
- [attr.aria-label]="messageFor('filterInputLabel')"
1735
- [dir]="direction"
1736
- [(ngModel)]="filterText"
1737
- class="k-input-inner"
1738
- (keydown)="keydown($event, searchInput)"
1739
- (input)="handleFilter($event)"
1740
- (focus)="onFilterFocus()"
1741
- (blur)="blurFilterInput()"
1742
- (click)="handleClick()" />
1743
- </span>
1744
- </div>
1745
- </ng-template>
1746
- <!--header template-->
1747
- <ng-template *ngIf="headerTemplate"
1734
+ <!--filterable-->
1735
+ @if (filterable && !isActionSheetExpanded) {
1736
+ <div class="k-list-filter" (click)="$event.stopImmediatePropagation()">
1737
+ <span
1738
+ class="k-searchbox k-input"
1739
+ [ngClass]="filterInputClasses">
1740
+ <kendo-icon-wrapper
1741
+ class="k-icon"
1742
+ innerCssClass="k-input-icon"
1743
+ name="search"
1744
+ [svgIcon]="searchIcon">
1745
+ </kendo-icon-wrapper>
1746
+ <input
1747
+ #searchInput
1748
+ role="searchbox"
1749
+ aria-autocomplete="list"
1750
+ aria-haspopup="listbox"
1751
+ [attr.aria-controls]="listBoxId"
1752
+ tabindex="-1"
1753
+ [filterInput]="isFocused && !touchEnabled"
1754
+ [attr.aria-label]="messageFor('filterInputLabel')"
1755
+ [dir]="direction"
1756
+ [(ngModel)]="filterText"
1757
+ class="k-input-inner"
1758
+ (keydown)="keydown($event, searchInput)"
1759
+ (input)="handleFilter($event)"
1760
+ (focus)="onFilterFocus()"
1761
+ (blur)="blurFilterInput()"
1762
+ (click)="handleClick()" />
1763
+ </span>
1764
+ </div>
1765
+ }
1766
+ <!--header template-->
1767
+ @if (headerTemplate) {
1768
+ <ng-template
1748
1769
  [templateContext]="{
1749
1770
  templateRef: headerTemplate.templateRef
1750
1771
  }">
1751
1772
  </ng-template>
1752
- <!--list-->
1753
- <kendo-list
1754
- #optionsList
1755
- [id]="listBoxId"
1756
- [size]="isAdaptive ? 'large' : size"
1757
- [rounded]="rounded"
1758
- [optionPrefix]="optionPrefix"
1759
- [data]="data"
1760
- [textField]="textField"
1761
- [valueField]="valueField"
1762
- [template]="itemTemplate"
1763
- [groupTemplate]="groupTemplate"
1764
- [fixedGroupTemplate]="fixedGroupTemplate"
1765
- [height]="listHeight"
1766
- [show]="isOpen"
1767
- [virtual]="virtual"
1768
- [ariaLive]="ariaLive"
1769
- [showStickyHeader]="showStickyHeader"
1770
- (pageChange)="pageChange($event)"
1771
- [defaultItem]="defaultItem">
1772
- </kendo-list>
1773
- <!--no-data template-->
1774
- <div class="k-no-data" *ngIf="data.length === 0">
1775
- <ng-template [ngIf]="noDataTemplate"
1773
+ }
1774
+ <!--list-->
1775
+ <kendo-list
1776
+ #optionsList
1777
+ [id]="listBoxId"
1778
+ [size]="isAdaptive ? 'large' : size"
1779
+ [rounded]="rounded"
1780
+ [optionPrefix]="optionPrefix"
1781
+ [data]="data"
1782
+ [textField]="textField"
1783
+ [valueField]="valueField"
1784
+ [template]="itemTemplate"
1785
+ [groupTemplate]="groupTemplate"
1786
+ [fixedGroupTemplate]="fixedGroupTemplate"
1787
+ [height]="listHeight"
1788
+ [show]="isOpen"
1789
+ [virtual]="virtual"
1790
+ [ariaLive]="ariaLive"
1791
+ [showStickyHeader]="showStickyHeader"
1792
+ (pageChange)="pageChange($event)"
1793
+ [defaultItem]="defaultItem">
1794
+ </kendo-list>
1795
+ <!--no-data template-->
1796
+ @if (data.length === 0) {
1797
+ <div class="k-no-data">
1798
+ @if (noDataTemplate) {
1799
+ <ng-template
1776
1800
  [templateContext]="{
1777
1801
  templateRef: noDataTemplate ? noDataTemplate.templateRef : undefined
1778
1802
  }">
1779
1803
  </ng-template>
1780
- <ng-template [ngIf]="!noDataTemplate">
1781
- <div>{{ messageFor('noDataText') }}</div>
1782
- </ng-template>
1804
+ }
1805
+ @if (!noDataTemplate) {
1806
+ <div>{{ messageFor('noDataText') }}</div>
1807
+ }
1783
1808
  </div>
1784
- <!--footer template-->
1785
- <ng-template *ngIf="footerTemplate"
1809
+ }
1810
+ <!--footer template-->
1811
+ @if (footerTemplate) {
1812
+ <ng-template
1786
1813
  [templateContext]="{
1787
1814
  templateRef: footerTemplate.templateRef
1788
1815
  }">
1789
1816
  </ng-template>
1817
+ }
1790
1818
  </ng-template>
1791
- `,
1819
+ `,
1792
1820
  standalone: true,
1793
- imports: [LocalizedMessagesDirective, NgIf, TemplateContextDirective, NgClass, EventsOutsideAngularDirective, IconWrapperComponent, NgTemplateOutlet, ResizeSensorComponent, AdaptiveRendererComponent, ReactiveFormsModule, FilterInputDirective, FormsModule, ListComponent]
1821
+ imports: [LocalizedMessagesDirective, TemplateContextDirective, NgClass, EventsOutsideAngularDirective, IconWrapperComponent, NgTemplateOutlet, ResizeSensorComponent, AdaptiveRendererComponent, ReactiveFormsModule, FilterInputDirective, FormsModule, ListComponent]
1794
1822
  }]
1795
1823
  }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1.LocalizationService }, { type: i2.PopupService }, { type: i3.SelectionService }, { type: i4.NavigationService }, { type: i5.DisabledItemsService }, { type: i6.DataService }, { type: i0.NgZone }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }, { type: i0.Injector }, { type: i7.AdaptiveService }], propDecorators: { customIconClass: [{
1796
1824
  type: Input