Skip to content

Commit

Permalink
Fixed #14358
Browse files Browse the repository at this point in the history
  • Loading branch information
cetincakiroglu committed Feb 29, 2024
1 parent 4e9ee35 commit c77dbbb
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 18 deletions.
8 changes: 4 additions & 4 deletions src/app/components/autocomplete/autocomplete.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ export const AUTOCOMPLETE_VALUE_ACCESSOR: any = {
[attr.aria-label]="ariaLabel"
[attr.aria-labelledby]="ariaLabelledBy"
[attr.aria-required]="required"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="id + '_list'"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-controls]="overlayVisible ? id + '_list' : null"
[attr.aria-aria-activedescendant]="focused ? focusedOptionId : undefined"
(input)="onInput($event)"
(keydown)="onKeyDown($event)"
Expand Down Expand Up @@ -155,8 +155,8 @@ export const AUTOCOMPLETE_VALUE_ACCESSOR: any = {
[attr.aria-label]="ariaLabel"
[attr.aria-labelledby]="ariaLabelledBy"
[attr.aria-required]="required"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="id + '_list'"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-controls]="overlayVisible ? id + '_list' : null"
[attr.aria-aria-activedescendant]="focused ? focusedOptionId : undefined"
(input)="onInput($event)"
(keydown)="onKeyDown($event)"
Expand Down
8 changes: 4 additions & 4 deletions src/app/components/calendar/calendar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ export const CALENDAR_VALUE_ACCESSOR: any = {
[attr.aria-required]="required"
aria-autocomplete="none"
aria-haspopup="dialog"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="panelId"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-controls]="overlayVisible ? panelId : null"
[attr.aria-labelledby]="ariaLabelledBy"
[attr.aria-label]="ariaLabel"
[value]="inputFieldValue"
Expand Down Expand Up @@ -103,8 +103,8 @@ export const CALENDAR_VALUE_ACCESSOR: any = {
type="button"
[attr.aria-label]="iconButtonAriaLabel"
aria-haspopup="dialog"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="panelId"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-controls]="overlayVisible ? panelId : null"
pButton
pRipple
*ngIf="showIcon && iconDisplay === 'button'"
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/cascadeselect/cascadeselect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,8 @@ export class CascadeSelectSub implements OnInit {
[attr.aria-label]="ariaLabel"
[attr.aria-labelledby]="ariaLabelledBy"
aria-haspopup="tree"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="id + '_tree'"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-controls]="overlayVisible ? id + '_tree' : null"
[attr.aria-activedescendant]="focused ? focusedOptionId : undefined"
(focus)="onInputFocus($event)"
(blur)="onInputBlur($event)"
Expand All @@ -267,7 +267,7 @@ export class CascadeSelectSub implements OnInit {
</span>
</ng-container>
<div class="p-cascadeselect-trigger" role="button" aria-haspopup="listbox" [attr.aria-expanded]="overlayVisible" [attr.data-pc-section]="'dropdownIcon'" [attr.aria-hidden]="true">
<div class="p-cascadeselect-trigger" role="button" aria-haspopup="listbox" [attr.aria-expanded]="overlayVisible ?? false" [attr.data-pc-section]="'dropdownIcon'" [attr.aria-hidden]="true">
<ChevronDownIcon *ngIf="!triggerIconTemplate" [styleClass]="'p-cascadeselect-trigger-icon'" />
<span *ngIf="triggerIconTemplate" class="p-cascadeselect-trigger-icon">
<ng-template *ngTemplateOutlet="triggerIconTemplate"></ng-template>
Expand Down
4 changes: 2 additions & 2 deletions src/app/components/multiselect/multiselect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,8 @@ export class MultiSelectItem {
[attr.aria-label]="ariaLabel"
[attr.aria-labelledby]="ariaLabelledBy"
[attr.aria-haspopup]="'listbox'"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="id + '_list'"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-controls]="overlayVisible ? id + '_list' : null"
[attr.tabindex]="!disabled ? tabindex : -1"
[attr.aria-activedescendant]="focused ? focusedOptionId : undefined"
(focus)="onInputFocus($event)"
Expand Down
4 changes: 2 additions & 2 deletions src/app/components/table/table.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4951,8 +4951,8 @@ export class ReorderableRow implements AfterViewInit {
class="p-column-filter-menu-button p-link"
aria-haspopup="true"
[attr.aria-label]="filterMenuButtonAriaLabel"
[attr.aria-controls]="overlayId"
[attr.aria-expanded]="overlayVisible"
[attr.aria-controls]="overlayVisible ? overlayId : null"
[attr.aria-expanded]="overlayVisible ?? false"
[ngClass]="{ 'p-column-filter-menu-button-open': overlayVisible, 'p-column-filter-menu-button-active': hasFilter() }"
(click)="toggleMenu()"
(keydown)="onToggleButtonKeyDown($event)"
Expand Down
6 changes: 3 additions & 3 deletions src/app/components/treeselect/treeselect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ export const TREESELECT_VALUE_ACCESSOR: any = {
(blur)="onBlur()"
(keydown)="onKeyDown($event)"
[attr.tabindex]="!disabled ? tabindex : -1"
[attr.aria-controls]="listId"
[attr.aria-controls]="overlayVisible ? listId : null"
[attr.aria-haspopup]="'tree'"
[attr.aria-expanded]="overlayVisible"
[attr.aria-expanded]="overlayVisible ?? false"
[attr.aria-labelledby]="ariaLabelledBy"
[attr.aria-label]="ariaLabel || (label === 'p-emptylabel' ? undefined : label)"
/>
Expand Down Expand Up @@ -70,7 +70,7 @@ export const TREESELECT_VALUE_ACCESSOR: any = {
</span>
</ng-container>
</div>
<div class="p-treeselect-trigger" role="button" aria-haspopup="tree" [attr.aria-expanded]="overlayVisible" [attr.aria-label]="'treeselect trigger'">
<div class="p-treeselect-trigger" role="button" aria-haspopup="tree" [attr.aria-expanded]="overlayVisible ?? false" [attr.aria-label]="'treeselect trigger'">
<ChevronDownIcon *ngIf="!triggerIconTemplate" [styleClass]="'p-treeselect-trigger-icon'" />
<span *ngIf="triggerIconTemplate" class="p-treeselect-trigger-icon">
<ng-template *ngTemplateOutlet="triggerIconTemplate"></ng-template>
Expand Down

0 comments on commit c77dbbb

Please sign in to comment.