feat: refine table presentation and editable Word export

This commit is contained in:
2026-11-04 15:40:52 +08:00
parent 31d0ccfde5
commit 3bb2cc5438
15 changed files with 337 additions and 58 deletions
+2
View File
@@ -98,6 +98,8 @@ class MarkdownRenderer:
elif token.type == 'list_item_open':
key = 'list_task' if 'task-list-item' in (token.attrGet('class') or '') else (lists[-1] if lists else 'list_bullet')
token.attrSet('data-mdh-style', key)
elif token.type == 'table_open':
token.attrSet('data-mdh-table', '')
elif token.type in ('th_open', 'td_open'):
token.attrSet('data-mdh-style', 'table_head' if token.type == 'th_open' else 'table_cell')
for child in token.children or []: