@anguless/angulux 22.6.4 → 22.6.6

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 (34) hide show
  1. package/fesm2022/anguless-angulux-button.mjs +4 -1
  2. package/fesm2022/anguless-angulux-button.mjs.map +1 -1
  3. package/fesm2022/anguless-angulux-datepicker.mjs +17 -3
  4. package/fesm2022/anguless-angulux-datepicker.mjs.map +1 -1
  5. package/fesm2022/anguless-angulux-dom.mjs +9 -1
  6. package/fesm2022/anguless-angulux-dom.mjs.map +1 -1
  7. package/fesm2022/anguless-angulux-drawer.mjs +5 -1
  8. package/fesm2022/anguless-angulux-drawer.mjs.map +1 -1
  9. package/fesm2022/anguless-angulux-menu.mjs +4 -1
  10. package/fesm2022/anguless-angulux-menu.mjs.map +1 -1
  11. package/fesm2022/anguless-angulux-message.mjs +5 -2
  12. package/fesm2022/anguless-angulux-message.mjs.map +1 -1
  13. package/fesm2022/anguless-angulux-multiselect.mjs +8 -5
  14. package/fesm2022/anguless-angulux-multiselect.mjs.map +1 -1
  15. package/fesm2022/anguless-angulux-overlay.mjs +11 -1
  16. package/fesm2022/anguless-angulux-overlay.mjs.map +1 -1
  17. package/fesm2022/anguless-angulux-paginator.mjs +6 -6
  18. package/fesm2022/anguless-angulux-paginator.mjs.map +1 -1
  19. package/fesm2022/anguless-angulux-select.mjs +169 -37
  20. package/fesm2022/anguless-angulux-select.mjs.map +1 -1
  21. package/fesm2022/anguless-angulux-selectbutton.mjs +2 -2
  22. package/fesm2022/anguless-angulux-selectbutton.mjs.map +1 -1
  23. package/fesm2022/anguless-angulux-table.mjs +120 -20
  24. package/fesm2022/anguless-angulux-table.mjs.map +1 -1
  25. package/fesm2022/anguless-angulux-tabs.mjs +7 -1
  26. package/fesm2022/anguless-angulux-tabs.mjs.map +1 -1
  27. package/fesm2022/anguless-angulux-tooltip.mjs +231 -46
  28. package/fesm2022/anguless-angulux-tooltip.mjs.map +1 -1
  29. package/fesm2022/anguless-angulux-treetable.mjs +4 -4
  30. package/fesm2022/anguless-angulux-treetable.mjs.map +1 -1
  31. package/package.json +1 -1
  32. package/types/anguless-angulux-select.d.ts +28 -3
  33. package/types/anguless-angulux-table.d.ts +10 -0
  34. package/types/anguless-angulux-tooltip.d.ts +74 -18
@@ -1,6 +1,6 @@
1
1
  export * from '@anguless/angulux/types/select';
2
2
  import * as i1 from '@angular/common';
3
- import { CommonModule } from '@angular/common';
3
+ import { CommonModule, isPlatformBrowser } from '@angular/common';
4
4
  import * as i0 from '@angular/core';
5
5
  import { Injectable, InjectionToken, forwardRef, inject, EventEmitter, booleanAttribute, numberAttribute, Output, Input, ChangeDetectionStrategy, Component, input, computed, contentChild, signal, effect, ViewChild, ViewEncapsulation, NgModule } from '@angular/core';
6
6
  import { NG_VALUE_ACCESSOR } from '@angular/forms';
@@ -60,7 +60,9 @@ const classes = {
60
60
  label: ({ instance }) => [
61
61
  'p-select-label',
62
62
  {
63
- 'p-placeholder': instance.placeholder() && instance.label() === instance.placeholder(),
63
+ // The editable input shows a typed value no option matches, while label() falls back to the
64
+ // placeholder: that text is not a placeholder (upstream 22.1.3).
65
+ 'p-placeholder': instance.placeholder() && (instance.editable ? instance.modelValue() === undefined || instance.modelValue() === null || instance.modelValue() === '' : instance.label() === instance.placeholder()),
64
66
  'p-select-label-empty': !instance.editable && !instance.selectedItemTemplate() && (instance.label() === undefined || instance.label() === null || instance.label() === 'p-emptylabel' || instance.label().length === 0)
65
67
  }
66
68
  ],
@@ -215,16 +217,21 @@ class SelectItem extends BaseComponent {
215
217
  onOptionMouseEnter(event) {
216
218
  this.onMouseEnter.emit(event);
217
219
  }
220
+ /**
221
+ * The pass-through options of this row, from the state this row was given. Asking the Select
222
+ * (getPTItemOptions) checked the selection a second time for every row on every change
223
+ * detection (upstream 22.1.3, measured 2026-11-17: two isSelected calls per row).
224
+ */
218
225
  getPTOptions() {
219
- return (this.$pcSelect?.getPTItemOptions?.(this.option, this.scrollerOptions, this.index ?? 0, 'option') ??
220
- this.$pcSelect?.ptm('option', {
221
- context: {
222
- option: this.option,
223
- selected: this.selected,
224
- focused: this.focused,
225
- disabled: this.disabled
226
- }
227
- }));
226
+ return this.$pcSelect?.ptm('option', {
227
+ context: {
228
+ option: this.option,
229
+ index: this.index ?? 0,
230
+ selected: this.selected,
231
+ focused: this.focused,
232
+ disabled: this.disabled
233
+ }
234
+ });
228
235
  }
229
236
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.2", ngImport: i0, type: SelectItem, deps: null, target: i0.ɵɵFactoryTarget.Component });
230
237
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "22.2.2", type: SelectItem, isStandalone: true, selector: "agl-selectItem", inputs: { id: "id", option: "option", selected: ["selected", "selected", booleanAttribute], focused: ["focused", "focused", booleanAttribute], label: "label", disabled: ["disabled", "disabled", booleanAttribute], visible: ["visible", "visible", booleanAttribute], itemSize: ["itemSize", "itemSize", numberAttribute], ariaPosInset: "ariaPosInset", ariaSetSize: "ariaSetSize", template: "template", checkmark: ["checkmark", "checkmark", booleanAttribute], index: "index", scrollerOptions: "scrollerOptions" }, outputs: { onClick: "onClick", onMouseEnter: "onMouseEnter" }, providers: [SelectStyle, { provide: PARENT_INSTANCE, useExisting: SelectItem }], usesInheritance: true, ngImport: i0, template: `
@@ -235,7 +242,7 @@ class SelectItem extends BaseComponent {
235
242
  (mouseenter)="onOptionMouseEnter($event)"
236
243
  role="option"
237
244
  aglRipple
238
- [attr.aria-label]="label"
245
+ [attr.aria-label]="template ? null : label"
239
246
  [attr.aria-setsize]="ariaSetSize"
240
247
  [attr.aria-posinset]="ariaPosInset"
241
248
  [attr.aria-selected]="selected"
@@ -270,7 +277,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
270
277
  (mouseenter)="onOptionMouseEnter($event)"
271
278
  role="option"
272
279
  aglRipple
273
- [attr.aria-label]="label"
280
+ [attr.aria-label]="template ? null : label"
274
281
  [attr.aria-setsize]="ariaSetSize"
275
282
  [attr.aria-posinset]="ariaPosInset"
276
283
  [attr.aria-selected]="selected"
@@ -416,7 +423,8 @@ class Select extends BaseInput {
416
423
  */
417
424
  inputId;
418
425
  /**
419
- * A property to uniquely identify a value in options.
426
+ * A property to uniquely identify a value in options. Ignored when optionValue is set: the value
427
+ * is then the field optionValue names, and is compared as it is.
420
428
  * @group Props
421
429
  */
422
430
  dataKey;
@@ -501,7 +509,8 @@ class Select extends BaseInput {
501
509
  */
502
510
  emptyMessage = '';
503
511
  /**
504
- * Defines if data is loaded and interacted with in lazy manner.
512
+ * Defines if data is loaded and interacted with in lazy manner. Takes effect with virtualScroll,
513
+ * which is what emits onLazyLoad; without it, lazy does nothing.
505
514
  * @group Props
506
515
  */
507
516
  lazy = false;
@@ -789,7 +798,17 @@ class Select extends BaseInput {
789
798
  return this.emptyFilterMessage || this.config.getTranslation(TranslationKeys.EMPTY_FILTER_MESSAGE);
790
799
  }
791
800
  get isVisibleClearIcon() {
792
- return this.modelValue() != null && this.hasSelectedOption() && this.showClear && !this.$disabled();
801
+ // A read-only Select offers no way to clear it (upstream 22.1.2: the icon emptied it).
802
+ return this.modelValue() != null && this.hasSelectedOption() && this.showClear && !this.$disabled() && !this.readonly;
803
+ }
804
+ /** What the status region says while filtering: that results are there, or that none are. */
805
+ get filterResultMessage() {
806
+ if (!this._filterValue())
807
+ return '';
808
+ const count = (this.visibleOptions() ?? []).filter((option) => !this.isOptionGroup(option)).length;
809
+ // The keys the translation already carries (searchMessage, emptySearchMessage), read by name.
810
+ const message = this.config.getTranslation(count ? 'searchMessage' : 'emptySearchMessage');
811
+ return String(message ?? '').replace('{0}', String(count));
793
812
  }
794
813
  get listLabel() {
795
814
  return this.config.getTranslation(TranslationKeys.ARIA)['listLabel'];
@@ -813,7 +832,8 @@ class Select extends BaseInput {
813
832
  const optionGroups = this.options || [];
814
833
  const filtered = [];
815
834
  optionGroups.forEach((group) => {
816
- const groupChildren = this.getOptionGroupChildren(group);
835
+ // A group may have no children; it then has nothing to match (upstream 22.1.3).
836
+ const groupChildren = this.getOptionGroupChildren(group) ?? [];
817
837
  const filteredItems = groupChildren.filter((item) => filteredOptions?.includes(item));
818
838
  if (filteredItems.length > 0)
819
839
  filtered.push({
@@ -855,7 +875,11 @@ class Select extends BaseInput {
855
875
  const visibleOptions = this.visibleOptions();
856
876
  if (visibleOptions && isNotEmpty(visibleOptions)) {
857
877
  const selectedOptionIndex = this.findSelectedOptionIndex();
858
- if (selectedOptionIndex !== -1 || modelValue === undefined || (typeof modelValue === 'string' && modelValue.length === 0) || this.isModelValueNotSet() || this.editable) {
878
+ if (this.editable && selectedOptionIndex === -1) {
879
+ // The filter can hide the selected option; it is still the selected one.
880
+ this.selectedOption = this.getAllVisibleAndNonVisibleOptions().find((option) => this.isValidSelectedOption(option));
881
+ }
882
+ else if (selectedOptionIndex !== -1 || modelValue === undefined || (typeof modelValue === 'string' && modelValue.length === 0) || this.isModelValueNotSet() || this.editable) {
859
883
  this.selectedOption = visibleOptions[selectedOptionIndex];
860
884
  }
861
885
  else {
@@ -967,6 +991,38 @@ class Select extends BaseInput {
967
991
  this.updateEditableLabel();
968
992
  }
969
993
  this.updatePlaceHolderForFloatingLabel();
994
+ this.bindLabelClickListener();
995
+ }
996
+ labelClickListener = null;
997
+ searchFocusTimeout = null;
998
+ /**
999
+ * A label naming inputId focuses the Select when clicked, as a label does for a native control.
1000
+ * The non-editable Select's inputId sits on a span, which a label cannot target natively, so a
1001
+ * click on it did nothing (upstream 22.1.3). A disabled Select is neither focused nor touched.
1002
+ */
1003
+ bindLabelClickListener() {
1004
+ if (!isPlatformBrowser(this.platformId) || this.labelClickListener)
1005
+ return;
1006
+ this.zone.runOutsideAngular(() => {
1007
+ this.labelClickListener = this.renderer.listen(this.document, 'click', (event) => {
1008
+ const label = event.target?.closest?.('label');
1009
+ if (!label || !this.inputId || label.htmlFor !== this.inputId || this.$disabled())
1010
+ return;
1011
+ this.applyFocus();
1012
+ });
1013
+ });
1014
+ }
1015
+ clearTimer(timer) {
1016
+ if (timer)
1017
+ clearTimeout(timer);
1018
+ }
1019
+ onDestroy() {
1020
+ this.labelClickListener?.();
1021
+ this.labelClickListener = null;
1022
+ // Timers started by a keystroke do not outlive the component (upstream 22.1.5).
1023
+ this.clearTimer(this.searchTimeout);
1024
+ this.clearTimer(this.searchFocusTimeout);
1025
+ this.searchTimeout = this.searchFocusTimeout = null;
970
1026
  }
971
1027
  updatePlaceHolderForFloatingLabel() {
972
1028
  const parentElement = this.el.nativeElement.parentElement;
@@ -980,9 +1036,32 @@ class Select extends BaseInput {
980
1036
  }
981
1037
  updateEditableLabel() {
982
1038
  if (this.editableInputViewChild) {
983
- this.editableInputViewChild.nativeElement.value = this.getOptionLabel(this.selectedOption) || this.modelValue() || '';
1039
+ const input = this.editableInputViewChild.nativeElement;
1040
+ const value = this.editableLabel();
1041
+ // Only write when it differs: writing moves the caret to the end, so a partly matched
1042
+ // value could not be edited in the middle.
1043
+ if (input.value !== value)
1044
+ input.value = value;
984
1045
  }
985
1046
  }
1047
+ /**
1048
+ * The text of the editable input: the label of the selected option, else the model value. An
1049
+ * object value no option matches is shown by its optionLabel field, not as "[object Object]"
1050
+ * (upstream 22.1.5).
1051
+ */
1052
+ editableLabel() {
1053
+ const label = this.getOptionLabel(this.selectedOption);
1054
+ if (label !== undefined && label !== null && label !== '')
1055
+ return String(label);
1056
+ const value = this.modelValue();
1057
+ if (value === undefined || value === null)
1058
+ return '';
1059
+ if (typeof value === 'object') {
1060
+ const own = this.optionLabel ? resolveFieldData(value, this.optionLabel) : value.label;
1061
+ return own === undefined || own === null ? '' : String(own);
1062
+ }
1063
+ return String(value);
1064
+ }
986
1065
  clearEditableLabel() {
987
1066
  if (this.editableInputViewChild) {
988
1067
  this.editableInputViewChild.nativeElement.value = '';
@@ -1064,7 +1143,8 @@ class Select extends BaseInput {
1064
1143
  this.searchValue = '';
1065
1144
  const matched = this.searchOptions(event, value);
1066
1145
  !matched && this.focusedOptionIndex.set(-1);
1067
- this.onModelChange(value);
1146
+ // One write per keystroke. onModelChange was also called here, before updateModel calls it
1147
+ // (upstream 22.1.3: the form saw every keystroke twice).
1068
1148
  this.updateModel(value || null, event);
1069
1149
  setTimeout(() => {
1070
1150
  this.onChange.emit({ originalEvent: event, value: value });
@@ -1121,6 +1201,13 @@ class Select extends BaseInput {
1121
1201
  */
1122
1202
  hide(isFocus) {
1123
1203
  this.overlayVisible = false;
1204
+ // The panel stops taking pointer input now, not when change detection starts its leave
1205
+ // phase: Chrome runs a pending click before that timer, so a quick second click still picked
1206
+ // an option of the closing panel (upstream 22.1.3, held under P3.a, fixed under P3.c on
1207
+ // 2026-11-17). The overlay turns it back on when it opens.
1208
+ const panel = this.overlayViewChild?.overlayEl;
1209
+ if (panel)
1210
+ panel.style.pointerEvents = 'none';
1124
1211
  this.focusedOptionIndex.set(-1);
1125
1212
  this.clicked.set(false);
1126
1213
  this.searchValue = '';
@@ -1163,6 +1250,11 @@ class Select extends BaseInput {
1163
1250
  if (this.$disabled() || this.readonly || this.loading) {
1164
1251
  return;
1165
1252
  }
1253
+ // Keys pressed while an IME composes belong to the IME: Enter commits a candidate, arrows
1254
+ // move through candidates (upstream 22.1.3).
1255
+ if (event.isComposing) {
1256
+ return;
1257
+ }
1166
1258
  switch (event.code) {
1167
1259
  //down
1168
1260
  case 'ArrowDown':
@@ -1224,6 +1316,11 @@ class Select extends BaseInput {
1224
1316
  this.clicked.set(false);
1225
1317
  }
1226
1318
  onFilterKeyDown(event) {
1319
+ // Keys pressed while an IME composes belong to the IME: an Enter that committed a candidate
1320
+ // selected the focused option (upstream 22.1.3).
1321
+ if (event.isComposing) {
1322
+ return;
1323
+ }
1227
1324
  switch (event.code) {
1228
1325
  case 'ArrowDown':
1229
1326
  this.onArrowDownKey(event);
@@ -1441,6 +1538,8 @@ class Select extends BaseInput {
1441
1538
  if (this.overlayVisible && this.hasFocusableElements()) {
1442
1539
  focus(event.shiftKey ? this.lastHiddenFocusableElementOnOverlay?.nativeElement : this.firstHiddenFocusableElementOnOverlay?.nativeElement);
1443
1540
  event.preventDefault();
1541
+ // Focus was moved into the panel, so the Tab is handled here.
1542
+ event.stopPropagation();
1444
1543
  }
1445
1544
  else {
1446
1545
  if (this.focusedOptionIndex() !== -1 && this.overlayVisible) {
@@ -1450,7 +1549,8 @@ class Select extends BaseInput {
1450
1549
  this.overlayVisible && this.hide(this.filter);
1451
1550
  }
1452
1551
  }
1453
- event.stopPropagation();
1552
+ // Otherwise Tab goes on to the parent. It was stopped on every keydown, so a parent's own
1553
+ // handler (a focus trap, a form) never saw it (upstream 22.1.4).
1454
1554
  }
1455
1555
  onFirstHiddenFocus(event) {
1456
1556
  const focusableEl = event.relatedTarget === this.focusInputViewChild?.nativeElement ? getFirstFocusableElement(this.overlayViewChild?.el?.nativeElement, ':not([data-p-hidden-focusable="true"])') : this.focusInputViewChild?.nativeElement;
@@ -1479,12 +1579,24 @@ class Select extends BaseInput {
1479
1579
  if (optionIndex !== -1) {
1480
1580
  matched = true;
1481
1581
  }
1482
- if (optionIndex === -1 && this.focusedOptionIndex() === -1) {
1582
+ // Type-ahead falls back to the first option; typing into the editable input does not, since
1583
+ // what was typed is the value (upstream 22.1.3: every second keystroke focused it).
1584
+ if (optionIndex === -1 && this.focusedOptionIndex() === -1 && !this.editable) {
1483
1585
  optionIndex = this.findFirstFocusedOptionIndex();
1484
1586
  }
1485
1587
  if (optionIndex !== -1) {
1486
- setTimeout(() => {
1487
- this.changeFocusedOptionIndex(event, optionIndex);
1588
+ this.clearTimer(this.searchFocusTimeout);
1589
+ this.searchFocusTimeout = setTimeout(() => {
1590
+ this.searchFocusTimeout = null;
1591
+ if (this.editable) {
1592
+ // Typing focuses the match without selecting it, even with selectOnFocus: the
1593
+ // typed text is the value (upstream 22.1.3: a second write replaced it).
1594
+ this.focusedOptionIndex.set(optionIndex);
1595
+ this.scrollInView();
1596
+ }
1597
+ else {
1598
+ this.changeFocusedOptionIndex(event, optionIndex);
1599
+ }
1488
1600
  });
1489
1601
  }
1490
1602
  if (this.searchTimeout) {
@@ -1497,7 +1609,9 @@ class Select extends BaseInput {
1497
1609
  return matched;
1498
1610
  }
1499
1611
  isOptionMatched(option) {
1500
- return this.isValidOption(option) && this.getOptionLabel(option).toString().toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue?.toLocaleLowerCase(this.filterLocale));
1612
+ // String(… ?? ''): an option whose label is null threw here (upstream 22.1.5).
1613
+ const label = String(this.getOptionLabel(option) ?? '');
1614
+ return this.isValidOption(option) && label.toLocaleLowerCase(this.filterLocale).startsWith(String(this.searchValue ?? '').toLocaleLowerCase(this.filterLocale));
1501
1615
  }
1502
1616
  onFilterInputChange(event) {
1503
1617
  let value = event.target.value;
@@ -1528,6 +1642,10 @@ class Select extends BaseInput {
1528
1642
  * @group Method
1529
1643
  */
1530
1644
  clear(event) {
1645
+ // Neither a read-only nor a loading Select is cleared from its icon (upstream 22.1.2).
1646
+ if (event && (this.readonly || this.loading)) {
1647
+ return;
1648
+ }
1531
1649
  this.updateModel(null, event);
1532
1650
  this.clearEditableLabel();
1533
1651
  this.onModelTouched();
@@ -1607,6 +1725,7 @@ class Select extends BaseInput {
1607
1725
  (blur)="onInputBlur($event)"
1608
1726
  (keydown)="onKeyDown($event)"
1609
1727
  [attr.aria-required]="$required()"
1728
+ [attr.aria-readonly]="readonly || undefined"
1610
1729
  [attr.aria-invalid]="$invalid() || undefined"
1611
1730
  [attr.required]="$required() ? '' : undefined"
1612
1731
  [attr.disabled]="$disabled() ? '' : undefined"
@@ -1625,9 +1744,14 @@ class Select extends BaseInput {
1625
1744
  [attr.id]="inputId"
1626
1745
  [class]="cx('label')"
1627
1746
  [aglBind]="ptm('label')"
1747
+ role="combobox"
1748
+ aria-autocomplete="list"
1628
1749
  [attr.aria-haspopup]="'listbox'"
1629
- [attr.placeholder]="modelValue() === undefined || modelValue() === null ? placeholder() : undefined"
1630
- [attr.aria-label]="ariaLabel || (label() === 'p-emptylabel' ? undefined : label())"
1750
+ [attr.aria-expanded]="overlayVisible ?? false"
1751
+ [attr.aria-controls]="overlayVisible ? id + '_list' : null"
1752
+ [attr.placeholder]="modelValue() === undefined || modelValue() === null || modelValue() === '' ? placeholder() : undefined"
1753
+ [attr.aria-label]="ariaLabel"
1754
+ [attr.aria-labelledby]="ariaLabelledBy"
1631
1755
  (input)="onEditableInput($event)"
1632
1756
  (keydown)="onKeyDown($event)"
1633
1757
  [aglAutoFocus]="autofocus"
@@ -1654,7 +1778,7 @@ class Select extends BaseInput {
1654
1778
  </span>
1655
1779
  </ng-container>
1656
1780
 
1657
- <div [class]="cx('dropdown')" [aglBind]="ptm('dropdown')" role="button" aria-label="dropdown trigger" aria-haspopup="listbox" [attr.aria-expanded]="overlayVisible ?? false" [attr.data-pc-section]="'trigger'">
1781
+ <div [class]="cx('dropdown')" [aglBind]="ptm('dropdown')" aria-hidden="true" [attr.data-pc-section]="'trigger'">
1658
1782
  <ng-container *ngIf="loading; else elseBlock">
1659
1783
  <ng-container *ngIf="loadingIconTemplate()">
1660
1784
  <ng-container *ngTemplateOutlet="loadingIconTemplate()"></ng-container>
@@ -1704,7 +1828,7 @@ class Select extends BaseInput {
1704
1828
  >
1705
1829
  </span>
1706
1830
  <ng-container *ngTemplateOutlet="headerTemplate()"></ng-container>
1707
- <div [class]="cx('header')" *ngIf="filter" (click)="$event.stopPropagation()" [aglBind]="ptm('header')">
1831
+ <div [class]="cx('header')" *ngIf="filter" (click)="$event.stopPropagation()" (keydown)="filterTemplate() && onFilterKeyDown($event)" [aglBind]="ptm('header')">
1708
1832
  <ng-container *ngIf="filterTemplate(); else builtInFilterElement">
1709
1833
  <ng-container *ngTemplateOutlet="filterTemplate(); context: { options: filterOptions }"></ng-container>
1710
1834
  </ng-container>
@@ -1739,6 +1863,7 @@ class Select extends BaseInput {
1739
1863
  </agl-iconfield>
1740
1864
  </ng-template>
1741
1865
  </div>
1866
+ <span *ngIf="filter" role="status" aria-live="polite" class="p-hidden-accessible" [attr.data-p-hidden-accessible]="true">{{ filterResultMessage }}</span>
1742
1867
  <div [class]="cx('listContainer')" [style.max-height]="virtualScroll ? 'auto' : scrollHeight || 'auto'" [aglBind]="ptm('listContainer')">
1743
1868
  <agl-scroller
1744
1869
  *ngIf="virtualScroll"
@@ -1795,14 +1920,14 @@ class Select extends BaseInput {
1795
1920
  ></agl-selectItem>
1796
1921
  </ng-container>
1797
1922
  </ng-template>
1798
- <li *ngIf="filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" [aglBind]="ptm('emptyMessage')">
1923
+ <li *ngIf="filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" aria-disabled="true" [aglBind]="ptm('emptyMessage')">
1799
1924
  @if (!emptyFilterTemplate() && !emptyTemplate()) {
1800
1925
  {{ emptyFilterMessageLabel }}
1801
1926
  } @else {
1802
1927
  <ng-container #emptyFilter *ngTemplateOutlet="emptyFilterTemplate() || emptyTemplate()"></ng-container>
1803
1928
  }
1804
1929
  </li>
1805
- <li *ngIf="!filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" [aglBind]="ptm('emptyMessage')">
1930
+ <li *ngIf="!filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" aria-disabled="true" [aglBind]="ptm('emptyMessage')">
1806
1931
  @if (!emptyTemplate()) {
1807
1932
  {{ emptyMessageLabel || emptyFilterMessageLabel }}
1808
1933
  } @else {
@@ -1860,6 +1985,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
1860
1985
  (blur)="onInputBlur($event)"
1861
1986
  (keydown)="onKeyDown($event)"
1862
1987
  [attr.aria-required]="$required()"
1988
+ [attr.aria-readonly]="readonly || undefined"
1863
1989
  [attr.aria-invalid]="$invalid() || undefined"
1864
1990
  [attr.required]="$required() ? '' : undefined"
1865
1991
  [attr.disabled]="$disabled() ? '' : undefined"
@@ -1878,9 +2004,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
1878
2004
  [attr.id]="inputId"
1879
2005
  [class]="cx('label')"
1880
2006
  [aglBind]="ptm('label')"
2007
+ role="combobox"
2008
+ aria-autocomplete="list"
1881
2009
  [attr.aria-haspopup]="'listbox'"
1882
- [attr.placeholder]="modelValue() === undefined || modelValue() === null ? placeholder() : undefined"
1883
- [attr.aria-label]="ariaLabel || (label() === 'p-emptylabel' ? undefined : label())"
2010
+ [attr.aria-expanded]="overlayVisible ?? false"
2011
+ [attr.aria-controls]="overlayVisible ? id + '_list' : null"
2012
+ [attr.placeholder]="modelValue() === undefined || modelValue() === null || modelValue() === '' ? placeholder() : undefined"
2013
+ [attr.aria-label]="ariaLabel"
2014
+ [attr.aria-labelledby]="ariaLabelledBy"
1884
2015
  (input)="onEditableInput($event)"
1885
2016
  (keydown)="onKeyDown($event)"
1886
2017
  [aglAutoFocus]="autofocus"
@@ -1907,7 +2038,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
1907
2038
  </span>
1908
2039
  </ng-container>
1909
2040
 
1910
- <div [class]="cx('dropdown')" [aglBind]="ptm('dropdown')" role="button" aria-label="dropdown trigger" aria-haspopup="listbox" [attr.aria-expanded]="overlayVisible ?? false" [attr.data-pc-section]="'trigger'">
2041
+ <div [class]="cx('dropdown')" [aglBind]="ptm('dropdown')" aria-hidden="true" [attr.data-pc-section]="'trigger'">
1911
2042
  <ng-container *ngIf="loading; else elseBlock">
1912
2043
  <ng-container *ngIf="loadingIconTemplate()">
1913
2044
  <ng-container *ngTemplateOutlet="loadingIconTemplate()"></ng-container>
@@ -1957,7 +2088,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
1957
2088
  >
1958
2089
  </span>
1959
2090
  <ng-container *ngTemplateOutlet="headerTemplate()"></ng-container>
1960
- <div [class]="cx('header')" *ngIf="filter" (click)="$event.stopPropagation()" [aglBind]="ptm('header')">
2091
+ <div [class]="cx('header')" *ngIf="filter" (click)="$event.stopPropagation()" (keydown)="filterTemplate() && onFilterKeyDown($event)" [aglBind]="ptm('header')">
1961
2092
  <ng-container *ngIf="filterTemplate(); else builtInFilterElement">
1962
2093
  <ng-container *ngTemplateOutlet="filterTemplate(); context: { options: filterOptions }"></ng-container>
1963
2094
  </ng-container>
@@ -1992,6 +2123,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
1992
2123
  </agl-iconfield>
1993
2124
  </ng-template>
1994
2125
  </div>
2126
+ <span *ngIf="filter" role="status" aria-live="polite" class="p-hidden-accessible" [attr.data-p-hidden-accessible]="true">{{ filterResultMessage }}</span>
1995
2127
  <div [class]="cx('listContainer')" [style.max-height]="virtualScroll ? 'auto' : scrollHeight || 'auto'" [aglBind]="ptm('listContainer')">
1996
2128
  <agl-scroller
1997
2129
  *ngIf="virtualScroll"
@@ -2048,14 +2180,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.2", ngImpor
2048
2180
  ></agl-selectItem>
2049
2181
  </ng-container>
2050
2182
  </ng-template>
2051
- <li *ngIf="filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" [aglBind]="ptm('emptyMessage')">
2183
+ <li *ngIf="filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" aria-disabled="true" [aglBind]="ptm('emptyMessage')">
2052
2184
  @if (!emptyFilterTemplate() && !emptyTemplate()) {
2053
2185
  {{ emptyFilterMessageLabel }}
2054
2186
  } @else {
2055
2187
  <ng-container #emptyFilter *ngTemplateOutlet="emptyFilterTemplate() || emptyTemplate()"></ng-container>
2056
2188
  }
2057
2189
  </li>
2058
- <li *ngIf="!filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" [aglBind]="ptm('emptyMessage')">
2190
+ <li *ngIf="!filterValue && isEmpty()" [class]="cx('emptyMessage')" [ngStyle]="{ height: scrollerOptions.itemSize + 'px' }" role="option" aria-disabled="true" [aglBind]="ptm('emptyMessage')">
2059
2191
  @if (!emptyTemplate()) {
2060
2192
  {{ emptyMessageLabel || emptyFilterMessageLabel }}
2061
2193
  } @else {