@@ -434,7 +434,7 @@ describe("Heading", () => {
434434 initialContent : toggleHeadingDocument ,
435435 props : { editable : false } ,
436436 } ) ;
437- const first = page . getByRole ( "textbox " ) . nth ( 0 ) ;
437+ const first = page . getByRole ( "document " ) . nth ( 0 ) ;
438438 const toggle = first . getByRole ( "button" , {
439439 name : editor . dictionary . toggle_blocks . toggle_button ,
440440 exact : true ,
@@ -470,7 +470,7 @@ describe("Heading", () => {
470470 props : { editable : false } ,
471471 } ) ;
472472 expect ( recreated ) . not . toBe ( editor ) ;
473- const restored = page . getByRole ( "textbox " ) . nth ( 1 ) ;
473+ const restored = page . getByRole ( "document " ) . nth ( 1 ) ;
474474 await expect
475475 . element (
476476 restored . getByRole ( "button" , {
@@ -719,22 +719,22 @@ describe("Heading", () => {
719719 name : blockNoteEditor . dictionary . toggle_blocks . toggle_button ,
720720 exact : true ,
721721 } ) ;
722- const editor = page . getByRole ( "textbox " ) ;
722+ const editor = page . getByRole ( "document " ) ;
723723 await expect . element ( editor ) . toMatchAriaInlineSnapshot ( `
724- - textbox :
724+ - document :
725725 - button "Expand or collapse"
726726 - heading "Details" [level=2]
727727 ` ) ;
728728 await toggleButton . click ( ) ;
729729 await expect . element ( editor ) . toMatchAriaInlineSnapshot ( `
730- - textbox :
730+ - document :
731731 - button "Expand or collapse" [expanded]
732732 - heading "Details" [level=2]
733733 - paragraph: Nested read-only content
734734 ` ) ;
735735 await toggleButton . click ( ) ;
736736 await expect . element ( editor ) . toMatchAriaInlineSnapshot ( `
737- - textbox :
737+ - document :
738738 - button "Expand or collapse"
739739 - heading "Details" [level=2]
740740 ` ) ;
@@ -825,9 +825,9 @@ describe("Heading", () => {
825825 initialContent : toggleHeadingDocument ,
826826 props : { editable : false , theme : "light" } ,
827827 } ) ;
828- const textbox = page . getByRole ( "textbox " ) ;
829- await expect . element ( textbox ) . toBeVisible ( ) ;
830- expect ( ( await runAxe ( textbox ) ) . violations ) . toEqual ( [ ] ) ;
828+ const readOnlyDocument = page . getByRole ( "document " ) ;
829+ await expect . element ( readOnlyDocument ) . toBeVisible ( ) ;
830+ expect ( ( await runAxe ( readOnlyDocument ) ) . violations ) . toEqual ( [ ] ) ;
831831
832832 await page
833833 . getByRole ( "button" , {
@@ -838,7 +838,7 @@ describe("Heading", () => {
838838 await expect
839839 . element ( page . getByText ( "Nested read-only content" , { exact : true } ) )
840840 . toBeVisible ( ) ;
841- expect ( ( await runAxe ( textbox ) ) . violations ) . toEqual ( [ ] ) ;
841+ expect ( ( await runAxe ( readOnlyDocument ) ) . violations ) . toEqual ( [ ] ) ;
842842 } ) ;
843843 } ) ;
844844
0 commit comments