Skip to content

Commit 7fb25b5

Browse files
committed
fixup! refactor(cdk-experimental/ui-patterns): track list selection by value
1 parent 8cc9789 commit 7fb25b5

File tree

1 file changed

+3
-2
lines changed
  • src/cdk-experimental/ui-patterns/behaviors/list-focus

1 file changed

+3
-2
lines changed

src/cdk-experimental/ui-patterns/behaviors/list-focus/list-focus.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,14 @@ export class ListFocus<T extends ListFocusItem> {
3434
}
3535

3636
/** The id of the current active item. */
37-
getActiveDescendant(): string | void {
37+
getActiveDescendant(): string | undefined {
3838
if (this.inputs.focusMode() === 'roving') {
39-
return;
39+
return undefined;
4040
}
4141
if (this.navigation.inputs.items().length) {
4242
return this.navigation.inputs.items()[this.navigation.inputs.activeIndex()].id();
4343
}
44+
return undefined;
4445
}
4546

4647
/** The tabindex for the list. */

0 commit comments

Comments
 (0)