fix(html): prevent hierarchy reset in rich table cells (#2716)

* fix(html): restore parents after rich cell walking

Signed-off-by: Matvei Smirnov <vdalekesmirnov@gmail.com>

* fix(html): add table cell context manager, update tests

Signed-off-by: Matvei Smirnov <vdalekesmirnov@gmail.com>

* fix(html): table with heading test data

Signed-off-by: Matvei Smirnov <vdalekesmirnov@gmail.com>

---------

Signed-off-by: Matvei Smirnov <vdalekesmirnov@gmail.com>
This commit is contained in:
Matvei Smirnov
2025-12-03 20:52:23 +03:00
committed by GitHub
parent c97715f5fd
commit aebe25cf00
33 changed files with 373 additions and 32 deletions

View File

@@ -0,0 +1,23 @@
<html>
<head>
<style>
table, th, td {border: 1px solid black; border-collapse: collapse;}
td {padding:30px;}
table {margin: 30px;}
</style>
</head>
<body>
<p>Before tha table</p>
<table>
<tr>
<td><h1>A</h1></td>
<td>B</td>
</tr>
<tr>
<td>1...</td>
<td>2...</td>
</tr>
</table>
After the table
</body>
</html>