File tree Expand file tree Collapse file tree
packages/eui/src/components Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -52,7 +52,7 @@ const Modal = ({
5252 title : 'Do this thing' ,
5353 onClose : closeModal ,
5454 children : null ,
55- focusTrapProps ,
55+ 'aria-labelledby' : 'modalTitle' ,
5656 } ;
5757
5858 return (
@@ -71,7 +71,9 @@ const Modal = ({
7171 { isModalVisible && (
7272 < EuiModal { ...modalProps } >
7373 < EuiModalHeader >
74- < EuiModalHeaderTitle > Title of modal</ EuiModalHeaderTitle >
74+ < EuiModalHeaderTitle id = "modalTitle" >
75+ Title of modal
76+ </ EuiModalHeaderTitle >
7577 </ EuiModalHeader >
7678
7779 < EuiModalBody >
@@ -152,7 +154,6 @@ describe('EuiModal', () => {
152154 cy . realPress ( 'Enter' ) ;
153155 cy . focused ( ) . contains ( 'Title of modal' ) ;
154156 cy . realPress ( 'Tab' ) ;
155- cy . realPress ( 'Tab' ) ;
156157 cy . focused ( ) . contains ( 'Close' ) ;
157158 cy . realPress ( 'Escape' ) ;
158159 cy . focused ( ) . contains ( 'Show confirm modal' ) ;
@@ -186,7 +187,6 @@ describe('EuiModal', () => {
186187 cy . realPress ( 'Enter' ) ;
187188 cy . focused ( ) . contains ( 'Title of modal' ) ;
188189 cy . realPress ( 'Tab' ) ;
189- cy . realPress ( 'Tab' ) ;
190190 cy . focused ( ) . contains ( 'Show Popover' ) ;
191191 cy . realPress ( 'Enter' ) ;
192192 cy . focused ( ) . contains ( 'Popover content' ) ;
Original file line number Diff line number Diff line change @@ -152,7 +152,7 @@ describe('EuiToolTip', () => {
152152
153153 cy . get ( '[data-test-subj="modal"]' ) . focus ( ) ;
154154
155- cy . repeatRealPress ( 'Tab' , 2 ) ;
155+ cy . realPress ( 'Tab' ) ;
156156 cy . get ( '[data-test-subj="tool_tip"]' ) . should ( 'exist' ) ;
157157
158158 cy . realPress ( 'Escape' ) ;
You can’t perform that action at this time.
0 commit comments