Commit e49ca05
fix: extract main innerHTML for .plain.html fallback and improve test fixture
Parse the full HTML document and return only the innerHTML of <main>
rather than sending the raw file content. Uses existing hast-util-select
and hast-util-to-html deps. Test fixture updated to use a realistic full
document and a multiline fragment string for readability.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent 89d12d5 commit e49ca05
3 files changed
Lines changed: 35 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
476 | 476 | | |
477 | 477 | | |
478 | 478 | | |
479 | | - | |
| 479 | + | |
480 | 480 | | |
481 | 481 | | |
482 | 482 | | |
| 483 | + | |
483 | 484 | | |
484 | 485 | | |
485 | 486 | | |
486 | 487 | | |
487 | | - | |
| 488 | + | |
488 | 489 | | |
489 | 490 | | |
490 | 491 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
25 | 27 | | |
26 | 28 | | |
| 29 | + | |
27 | 30 | | |
28 | 31 | | |
29 | 32 | | |
| |||
787 | 790 | | |
788 | 791 | | |
789 | 792 | | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
790 | 806 | | |
791 | 807 | | |
792 | 808 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1353 | 1353 | | |
1354 | 1354 | | |
1355 | 1355 | | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
| 1359 | + | |
| 1360 | + | |
| 1361 | + | |
| 1362 | + | |
| 1363 | + | |
| 1364 | + | |
1356 | 1365 | | |
1357 | 1366 | | |
1358 | | - | |
| 1367 | + | |
1359 | 1368 | | |
1360 | 1369 | | |
1361 | 1370 | | |
| |||
1369 | 1378 | | |
1370 | 1379 | | |
1371 | 1380 | | |
1372 | | - | |
1373 | | - | |
| 1381 | + | |
| 1382 | + | |
1374 | 1383 | | |
| 1384 | + | |
| 1385 | + | |
| 1386 | + | |
| 1387 | + | |
1375 | 1388 | | |
1376 | 1389 | | |
1377 | 1390 | | |
| |||
0 commit comments