From be587f8b06207e92eb1630756974e27321f64276 Mon Sep 17 00:00:00 2001 From: DBowen33 Date: Fri, 12 Jul 2024 14:45:05 +0000 Subject: [PATCH] fix(material/chips): fix focus issue fix focus issue fixes b/290959510 --- src/material/chips/chip-grid.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/material/chips/chip-grid.ts b/src/material/chips/chip-grid.ts index 1c57110d6f56..60cb8f6af3bd 100644 --- a/src/material/chips/chip-grid.ts +++ b/src/material/chips/chip-grid.ts @@ -340,7 +340,7 @@ export class MatChipGrid // Delay until the next tick, because this can cause a "changed after checked" // error if the input does something on focus (e.g. opens an autocomplete). Promise.resolve().then(() => this._chipInput.focus()); - } else if (this._chips.length) { + } else if (this._chips.length && this._keyManager.activeItemIndex !== 0) { this._keyManager.setFirstItemActive(); }