File tree Expand file tree Collapse file tree 1 file changed +2
-8
lines changed
Expand file tree Collapse file tree 1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change 11import { Component , HostListener , ElementRef } from "@angular/core" ;
22import { Dialog } from "../dialog.component" ;
33import { position } from "../../utils/position" ;
4- import { isFocusInLastItem , isFocusInFirstItem } from "./../../common/tab.service" ;
4+ import { getFocusElementList , isFocusInLastItem , isFocusInFirstItem } from "./../../common/tab.service" ;
55import { I18n } from "./../../i18n/i18n.module" ;
66
77/**
@@ -47,13 +47,7 @@ export class OverflowMenuPane extends Dialog {
4747 }
4848
4949 setTimeout ( ( ) => {
50- let options = Array . from < any > ( this . dialog . nativeElement . querySelectorAll ( "*" ) ) ;
51-
52- options . forEach ( element => {
53- if ( element . tabIndex === 0 ) {
54- element . tabIndex = - 1 ;
55- }
56- } ) ;
50+ getFocusElementList ( this . elementRef . nativeElement ) . every ( button => button . tabIndex = - 1 ) ;
5751 this . listItems ( ) [ 0 ] . focus ( ) ;
5852 } , 0 ) ;
5953 }
You can’t perform that action at this time.
0 commit comments