support diagram plotting via mermaid !

This commit is contained in:
binary-husky
2024-01-15 02:49:21 +08:00
parent a2099f1622
commit 71adc40901
8 changed files with 1825 additions and 8 deletions

View File

@@ -3,8 +3,9 @@ import re
import os
import math
from textwrap import dedent
from functools import lru_cache
from pymdownx.superfences import fence_div_format, fence_code_format
from latex2mathml.converter import convert as tex2mathml
from functools import wraps, lru_cache
from shared_utils.config_loader import get_conf as get_conf
pj = os.path.join
@@ -17,10 +18,16 @@ markdown_extension_configs = {
},
}
code_highlight_configs = {
"pymdownx.superfences": {
'css_class': 'codehilite',
"custom_fences": [
{
'name': 'mermaid',
'class': 'mermaid',
'format': fence_code_format
}
]
},
"pymdownx.highlight": {
'css_class': 'codehilite',