Skip to content

Commit a958d52

Browse files
nikkimkbennypowers
andauthored
fix(chip): fixed chip-group keyboard accessibility (#2709)
Co-authored-by: Benny Powers - עם ישראל חי! <[email protected]>
1 parent b9bb7e3 commit a958d52

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/rotten-geese-invite.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@patternfly/elements": patch
3+
---
4+
5+
`<pf-chip-group>`: ensures that overflow and close buttons are keyboard accessible via arrow keys

elements/pf-chip/pf-chip-group.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ export class PfChipGroup extends LitElement {
180180
*/
181181
#handleChipsChanged() {
182182
if (this.#chips.length > 0) {
183-
const oldButtons = [...(this.#buttons || [])];
183+
const oldButtons = [...(this.#tabindex.items || [])];
184184
const max = this.open ? this.#chips.length : Math.min(this.#chips.length, this.numChips);
185185
this.#buttons = [
186186
...this.#chips.slice(0, max),

0 commit comments

Comments
 (0)