@@ -9,10 +9,12 @@ import {toHast} from '../index.js'
99test ( 'footnote' , ( ) => {
1010 let tree = toHast ( {
1111 type : 'root' ,
12+ // @ts -expect-error: to do: remove `footnote`s.
1213 children : [ { type : 'footnote' , children : [ { type : 'text' , value : 'alpha' } ] } ]
1314 } )
1415 assert ( tree , 'expected node' )
1516 assert . equal (
17+ // @ts -expect-error: to do: remove when `to-html` is released.
1618 toHtml ( tree ) ,
1719 `<sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup>
1820<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
@@ -39,11 +41,13 @@ test('footnote', () => {
3941 type : 'paragraph' ,
4042 children : [ { type : 'footnoteReference' , identifier : '1' } ]
4143 } ,
44+ // @ts -expect-error: to do: remove `footnote`s.
4245 { type : 'footnote' , children : [ { type : 'text' , value : 'charlie' } ] }
4346 ]
4447 } )
4548 assert ( tree , 'expected node' )
4649 assert . equal (
50+ // @ts -expect-error: to do: remove when `to-html` is released.
4751 toHtml ( tree ) ,
4852 `<p><sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
4953<sup><a href="#user-content-fn-2" id="user-content-fnref-2" data-footnote-ref aria-describedby="footnote-label">2</a></sup>
@@ -83,6 +87,7 @@ test('footnote', () => {
8387 } )
8488 assert ( tree , 'expected node' )
8589 assert . equal (
90+ // @ts -expect-error: to do: remove when `to-html` is released.
8691 toHtml ( tree ) ,
8792 `<p><sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
8893<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
@@ -112,6 +117,7 @@ test('footnote', () => {
112117 )
113118 assert ( tree , 'expected node' )
114119 assert . equal (
120+ // @ts -expect-error: to do: remove when `to-html` is released.
115121 toHtml ( tree ) ,
116122 `<table>
117123<thead>
@@ -153,6 +159,7 @@ test('footnote', () => {
153159 )
154160 assert ( tree , 'expected node' )
155161 assert . equal (
162+ // @ts -expect-error: to do: remove when `to-html` is released.
156163 toHtml ( tree ) ,
157164 `<table>
158165<thead>
@@ -183,6 +190,7 @@ test('footnote', () => {
183190 )
184191 assert ( tree , 'expected node' )
185192 assert . equal (
193+ // @ts -expect-error: to do: remove when `to-html` is released.
186194 toHtml ( tree ) ,
187195 `<p>Call<sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup><sup><a href="#user-content-fn-1" id="user-content-fnref-1-2" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
188196<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
@@ -204,6 +212,7 @@ test('footnote', () => {
204212 )
205213 assert ( tree , 'expected node' )
206214 assert . equal (
215+ // @ts -expect-error: to do: remove when `to-html` is released.
207216 toHtml ( tree ) ,
208217 `<p><sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
209218<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Voetnoten</h2>
@@ -225,6 +234,7 @@ test('footnote', () => {
225234 )
226235 assert ( tree , 'expected node' )
227236 assert . equal (
237+ // @ts -expect-error: to do: remove when `to-html` is released.
228238 toHtml ( tree ) ,
229239 `<p><sup><a href="#fn-1" id="fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
230240<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
@@ -246,6 +256,7 @@ test('footnote', () => {
246256 )
247257 assert ( tree , 'expected node' )
248258 assert . equal (
259+ // @ts -expect-error: to do: remove when `to-html` is released.
249260 toHtml ( tree ) ,
250261 `<p><sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
251262<section data-footnotes class="footnotes"><h1 class="sr-only" id="footnote-label">Footnotes</h1>
@@ -267,6 +278,7 @@ test('footnote', () => {
267278 )
268279 assert ( tree , 'expected node' )
269280 assert . equal (
281+ // @ts -expect-error: to do: remove when `to-html` is released.
270282 toHtml ( tree ) ,
271283 `<p><sup><a href="#user-content-fn-1" id="user-content-fnref-1" data-footnote-ref aria-describedby="footnote-label">1</a></sup></p>
272284<section data-footnotes class="footnotes"><h2 id="footnote-label">Footnotes</h2>
@@ -290,6 +302,7 @@ test('footnote', () => {
290302 )
291303 assert ( tree , 'expected node' )
292304 assert . equal (
305+ // @ts -expect-error: to do: remove when `to-html` is released.
293306 toHtml ( tree ) ,
294307 `<p>a<sup><a href="#user-content-fn-__proto__" id="user-content-fnref-__proto__" data-footnote-ref aria-describedby="footnote-label">1</a></sup> b<sup><a href="#user-content-fn-__proto__" id="user-content-fnref-__proto__-2" data-footnote-ref aria-describedby="footnote-label">1</a></sup> c<sup><a href="#user-content-fn-constructor" id="user-content-fnref-constructor" data-footnote-ref aria-describedby="footnote-label">2</a></sup></p>
295308<section data-footnotes class="footnotes"><h2 class="sr-only" id="footnote-label">Footnotes</h2>
0 commit comments