File tree Expand file tree Collapse file tree
packages/core/src/api/parsers/html/util Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ function wrapOrphanListItems(element: HTMLElement) {
2020 const orphans = Array . from ( element . querySelectorAll ( "li" ) ) . filter (
2121 ( li ) => li . closest ( "ul, ol" ) === null ,
2222 ) ;
23- const orphanSet = new Set ( orphans ) ;
23+ const orphanSet : Set < Element > = new Set ( orphans ) ;
2424 const handled = new Set < Element > ( ) ;
2525
2626 for ( const orphan of orphans ) {
@@ -32,7 +32,7 @@ function wrapOrphanListItems(element: HTMLElement) {
3232 handled . add ( orphan ) ;
3333
3434 let next = orphan . nextElementSibling ;
35- while ( next && next . tagName === "LI" && orphanSet . has ( next as HTMLElement ) ) {
35+ while ( next && next . tagName === "LI" && orphanSet . has ( next ) ) {
3636 group . push ( next ) ;
3737 handled . add ( next ) ;
3838 next = next . nextElementSibling ;
You can’t perform that action at this time.
0 commit comments